diff --git a/src/static/assets/AdminView-CBzT_n85.js b/src/static/assets/AdminView-Y8GgaF2G.js similarity index 89% rename from src/static/assets/AdminView-CBzT_n85.js rename to src/static/assets/AdminView-Y8GgaF2G.js index 4371166..3958d13 100644 --- a/src/static/assets/AdminView-CBzT_n85.js +++ b/src/static/assets/AdminView-Y8GgaF2G.js @@ -1 +1 @@ -import{d as _,u as y,A as h,c as r,a as t,e as n,k as v,w as d,f as g,s as m,o as s,F as b,r as k,t as a,q as u,h as A}from"./index-BiYpJJoC.js";import{a as w}from"./admin-BG8iXstk.js";import{_ as B,a as S}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as f}from"./Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js";import{_ as V}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{a as $}from"./utils-7WVCegLb.js";const N={class:"p-6 space-y-8"},C={key:0,class:"flex items-center justify-center h-20"},D={class:"w-full"},E={class:"px-4 py-3"},F={class:"text-sm font-medium text-foreground"},R={class:"px-4 py-3 text-sm text-muted-foreground"},U={class:"px-4 py-3"},j={class:"px-4 py-3"},q={class:"px-4 py-3 text-xs text-muted-foreground"},H=_({__name:"AdminView",setup(I){const x=y(),p=g(),i=m([]),l=m(!1);return h(async()=>{if(!x.isAdmin){p.push("/");return}l.value=!0;try{const c=await w.users();i.value=c.data}finally{l.value=!1}}),(c,o)=>(s(),r("div",N,[o[1]||(o[1]=t("h2",{class:"text-lg font-semibold text-foreground"},"Admin — Users",-1)),l.value?(s(),r("div",C,[n(V,{class:"text-primary"})])):(s(),v(B,{key:1},{default:d(()=>[n(S,{class:"p-0"},{default:d(()=>[t("table",D,[o[0]||(o[0]=t("thead",null,[t("tr",{class:"border-b border-border"},[t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"User"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Email"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Role"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Status"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Joined")])],-1)),t("tbody",null,[(s(!0),r(b,null,k(i.value,e=>(s(),r("tr",{key:e.id,class:"border-b border-border last:border-0 hover:bg-muted/30"},[t("td",E,[t("p",F,a(e.username),1)]),t("td",R,a(e.email),1),t("td",U,[n(f,{variant:e.role==="admin"?"default":"secondary",class:"text-xs"},{default:d(()=>[u(a(e.role),1)]),_:2},1032,["variant"])]),t("td",j,[n(f,{variant:e.is_active?"success":"outline",class:"text-xs"},{default:d(()=>[u(a(e.is_active?"Active":"Inactive"),1)]),_:2},1032,["variant"])]),t("td",q,a(A($)(e.created_at)),1)]))),128))])])]),_:1})]),_:1}))]))}});export{H as default}; +import{d as _,u as y,A as h,c as r,a as t,e as n,k as v,w as d,f as g,s as m,o as s,F as b,r as k,t as a,q as u,h as A}from"./index-aIsLHJPY.js";import{a as w}from"./admin-DlFdRGBL.js";import{_ as B,a as S}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as f}from"./Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js";import{_ as V}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{a as $}from"./utils-7WVCegLb.js";const N={class:"p-6 space-y-8"},C={key:0,class:"flex items-center justify-center h-20"},D={class:"w-full"},E={class:"px-4 py-3"},F={class:"text-sm font-medium text-foreground"},R={class:"px-4 py-3 text-sm text-muted-foreground"},U={class:"px-4 py-3"},j={class:"px-4 py-3"},q={class:"px-4 py-3 text-xs text-muted-foreground"},H=_({__name:"AdminView",setup(I){const x=y(),p=g(),i=m([]),l=m(!1);return h(async()=>{if(!x.isAdmin){p.push("/");return}l.value=!0;try{const c=await w.users();i.value=c.data}finally{l.value=!1}}),(c,o)=>(s(),r("div",N,[o[1]||(o[1]=t("h2",{class:"text-lg font-semibold text-foreground"},"Admin — Users",-1)),l.value?(s(),r("div",C,[n(V,{class:"text-primary"})])):(s(),v(B,{key:1},{default:d(()=>[n(S,{class:"p-0"},{default:d(()=>[t("table",D,[o[0]||(o[0]=t("thead",null,[t("tr",{class:"border-b border-border"},[t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"User"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Email"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Role"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Status"),t("th",{class:"text-left text-xs font-medium text-muted-foreground px-4 py-3"},"Joined")])],-1)),t("tbody",null,[(s(!0),r(b,null,k(i.value,e=>(s(),r("tr",{key:e.id,class:"border-b border-border last:border-0 hover:bg-muted/30"},[t("td",E,[t("p",F,a(e.username),1)]),t("td",R,a(e.email),1),t("td",U,[n(f,{variant:e.role==="admin"?"default":"secondary",class:"text-xs"},{default:d(()=>[u(a(e.role),1)]),_:2},1032,["variant"])]),t("td",j,[n(f,{variant:e.is_active?"success":"outline",class:"text-xs"},{default:d(()=>[u(a(e.is_active?"Active":"Inactive"),1)]),_:2},1032,["variant"])]),t("td",q,a(A($)(e.created_at)),1)]))),128))])])]),_:1})]),_:1}))]))}});export{H as default}; diff --git a/src/static/assets/AppLayout-CNLTau4W.js b/src/static/assets/AppLayout-9kXWPrU9.js similarity index 99% rename from src/static/assets/AppLayout-CNLTau4W.js rename to src/static/assets/AppLayout-9kXWPrU9.js index 8e1d36c..6ec908b 100644 --- a/src/static/assets/AppLayout-CNLTau4W.js +++ b/src/static/assets/AppLayout-9kXWPrU9.js @@ -1 +1 @@ -import{d as C,u as M,c as n,b as B,a as e,F as V,r as _,t as g,h as p,j as b,o as r,k as $,w as j,i as y,n as d,m as A,l as H,R as D,g as z,p as S,q as T,K as L,f as O,e as m,T as R,s as I,v as N}from"./index-BiYpJJoC.js";const P={class:"flex flex-col h-full bg-white border-r border-slate-200/80"},F={class:"flex-1 px-3 py-4 space-y-0.5 overflow-y-auto"},K={key:0,class:"absolute left-0 top-1/2 -translate-y-1/2 w-1 h-6 bg-orange-500 rounded-r-full"},q={class:"text-sm"},E={class:"p-4 border-t border-slate-100 shrink-0"},G={class:"flex items-center gap-3 px-2 py-2 rounded-xl bg-slate-50"},U={class:"h-8 w-8 rounded-full bg-gradient-to-br from-orange-400 to-orange-600 flex items-center justify-center text-[11px] font-bold text-white shrink-0 shadow-sm shadow-orange-200"},W={class:"flex-1 min-w-0"},J={class:"text-xs font-semibold text-slate-700 truncate"},Q=C({__name:"Sidebar",emits:["close"],setup(w,{emit:v}){const a=z(),l=M(),k=v,u=[{name:"Dashboard",path:"/",icon:"grid"},{name:"Calendar",path:"/calendar",icon:"calendar"},{name:"Tasks",path:"/tasks",icon:"check-square"},{name:"OMG",path:"/omg",icon:"omg"},{name:"Projects",path:"/projects",icon:"folder"},{name:"Live Feed",path:"/live",icon:"activity"},{name:"Reports",path:"/reports",icon:"file-text"},{name:"Keys",path:"/keys",icon:"key"},{name:"DevOps",path:"/devops",icon:"devops"},{name:"Settings",path:"/settings",icon:"settings"},{name:"Admin",path:"/admin",icon:"shield",adminOnly:!0}],x=b(()=>u.filter(h=>!h.adminOnly||l.isAdmin));function s(h){return h==="/"?a.path==="/":a.path.startsWith(h)}const i=b(()=>{var t,c;return(((t=l.user)==null?void 0:t.username)??((c=l.user)==null?void 0:c.email)??"?").slice(0,2).toUpperCase()});return(h,t)=>{var c,f;return r(),n("aside",P,[t[13]||(t[13]=B('

CC Dashboard

Oliver Agency

',1)),e("nav",F,[(r(!0),n(V,null,_(x.value,o=>(r(),$(H(o.external?"a":p(D)),A({key:o.path},{ref_for:!0},o.external?{href:o.path,target:"_blank",rel:"noopener"}:{to:o.path},{class:["relative flex items-center gap-3 px-3 h-10 rounded-xl text-sm font-medium transition-all duration-200 group",s(o.path)?"bg-orange-50 text-orange-600":"text-slate-500 hover:bg-slate-50 hover:text-slate-800"],onClick:t[0]||(t[0]=le=>k("close"))}),{default:j(()=>[s(o.path)?(r(),n("span",K)):y("",!0),o.icon==="grid"?(r(),n("svg",{key:1,class:d(["h-4 w-4 shrink-0 transition-colors",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[1]||(t[1]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"},null,-1)])],2)):o.icon==="calendar"?(r(),n("svg",{key:2,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[2]||(t[2]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"},null,-1)])],2)):o.icon==="check-square"?(r(),n("svg",{key:3,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[3]||(t[3]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"},null,-1)])],2)):o.icon==="omg"?(r(),n("svg",{key:4,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[4]||(t[4]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 13.255A23.931 23.931 0 0112 15c-3.183 0-6.22-.62-9-1.745M16 6V4a2 2 0 00-2-2h-4a2 2 0 00-2 2v2m4 6h.01M5 20h14a2 2 0 002-2V8a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"},null,-1)])],2)):o.icon==="folder"?(r(),n("svg",{key:5,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[5]||(t[5]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M3 7a2 2 0 012-2h3.586a1 1 0 01.707.293l1.414 1.414A1 1 0 0011.414 7H19a2 2 0 012 2v9a2 2 0 01-2 2H5a2 2 0 01-2-2V7z"},null,-1)])],2)):o.icon==="activity"?(r(),n("svg",{key:6,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[6]||(t[6]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 10V3L4 14h7v7l9-11h-7z"},null,-1)])],2)):o.icon==="file-text"?(r(),n("svg",{key:7,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[7]||(t[7]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"},null,-1)])],2)):o.icon==="key"?(r(),n("svg",{key:8,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[8]||(t[8]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 7a2 2 0 012 2m4 0a6 6 0 01-7.743 5.743L11 17H9v2H7v2H4a1 1 0 01-1-1v-2.586a1 1 0 01.293-.707l5.964-5.964A6 6 0 1121 9z"},null,-1)])],2)):o.icon==="devops"?(r(),n("svg",{key:9,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[9]||(t[9]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10 20l4-16m4 4l4 4-4 4M6 16l-4-4 4-4"},null,-1)])],2)):o.icon==="settings"?(r(),n("svg",{key:10,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[10]||(t[10]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.065 2.572c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.572 1.065c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.065-2.572c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z"},null,-1),e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 12a3 3 0 11-6 0 3 3 0 016 0z"},null,-1)])],2)):o.icon==="shield"?(r(),n("svg",{key:11,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[11]||(t[11]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z"},null,-1)])],2)):y("",!0),e("span",q,g(o.name),1)]),_:2},1040,["class"]))),128))]),e("div",E,[e("div",G,[e("div",U,g(i.value),1),e("div",W,[e("p",J,g(((c=p(l).user)==null?void 0:c.username)??((f=p(l).user)==null?void 0:f.email)),1),t[12]||(t[12]=e("div",{class:"flex items-center gap-1 mt-0.5"},[e("div",{class:"h-1.5 w-1.5 rounded-full bg-emerald-400"}),e("span",{class:"text-[10px] text-slate-400 font-medium"},"Online")],-1))])])])])}}}),X={class:"h-14 border-b border-slate-200/80 bg-white/80 backdrop-blur-xl flex items-center px-4 gap-3 shrink-0 sticky top-0 z-10 shadow-sm shadow-slate-100/60"},Y={class:"flex-1"},Z={class:"text-sm font-semibold text-foreground"},ee={class:"flex items-center gap-2.5"},te={class:"h-7 w-7 rounded-full bg-gradient-to-br from-orange-400 to-orange-600 flex items-center justify-center text-[10px] font-bold text-white shrink-0 shadow-sm shadow-orange-200"},oe={class:"hidden sm:block text-xs font-medium text-foreground max-w-[120px] truncate"},se=C({__name:"TopBar",props:{title:{},sidebarOpen:{type:Boolean}},emits:["toggleSidebar","toggleDark"],setup(w,{emit:v}){const a=v,l=M(),k=O();async function u(){await l.logout(),L.success("Logged out"),k.push({name:"login"})}function x(){const s=document.documentElement.classList.toggle("dark");localStorage.setItem("theme",s?"dark":"light"),a("toggleDark")}return(s,i)=>{var h,t,c,f;return r(),n("header",X,[e("button",{class:"lg:hidden flex h-9 w-9 items-center justify-center rounded-lg text-muted-foreground hover:bg-muted hover:text-foreground transition-colors","aria-label":"Toggle sidebar",onClick:i[0]||(i[0]=o=>a("toggleSidebar"))},[...i[1]||(i[1]=[e("svg",{class:"h-5 w-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M4 6h16M4 12h16M4 18h16"})],-1)])]),e("div",Y,[e("h1",Z,g(w.title??"CC Dashboard"),1)]),S(s.$slots,"actions"),e("button",{class:"flex h-9 w-9 items-center justify-center rounded-lg text-muted-foreground hover:bg-muted hover:text-foreground transition-colors","aria-label":"Toggle dark mode",onClick:x},[...i[2]||(i[2]=[e("svg",{class:"h-4 w-4 hidden dark:block",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 3v1m0 16v1m9-9h-1M4 12H3m15.364 6.364l-.707-.707M6.343 6.343l-.707-.707m12.728 0l-.707.707M6.343 17.657l-.707.707M16 12a4 4 0 11-8 0 4 4 0 018 0z"})],-1),e("svg",{class:"h-4 w-4 dark:hidden",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M20.354 15.354A9 9 0 018.646 3.646 9.003 9.003 0 0012 21a9.003 9.003 0 008.354-5.646z"})],-1)])]),i[4]||(i[4]=e("div",{class:"h-6 w-px bg-border"},null,-1)),e("div",ee,[e("div",te,g((((h=p(l).user)==null?void 0:h.username)??((t=p(l).user)==null?void 0:t.email)??"?").slice(0,2).toUpperCase()),1),e("span",oe,g(((c=p(l).user)==null?void 0:c.username)??((f=p(l).user)==null?void 0:f.email)),1),e("button",{class:"flex h-7 items-center gap-1 rounded-md px-2 text-xs text-muted-foreground hover:bg-muted hover:text-foreground transition-colors",onClick:u},[...i[3]||(i[3]=[e("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M17 16l4-4m0 0l-4-4m4 4H7m6 4v1a3 3 0 01-3 3H6a3 3 0 01-3-3V7a3 3 0 013-3h4a3 3 0 013 3v1"})],-1),T(" Sign out ",-1)])])])])}}}),re={class:"h-screen flex overflow-hidden",style:{background:"linear-gradient(135deg, #f0f4fa 0%, #f8f9fd 50%, #fef9f5 100%)"}},ne={class:"flex-1 flex flex-col overflow-hidden min-w-0"},ae={class:"flex-1 overflow-y-auto"},de=C({__name:"AppLayout",setup(w){const v=z(),a=I(!1),l=b(()=>({dashboard:"Dashboard",calendar:"Calendar",projects:"Projects","project-detail":"Project Details",live:"Live Feed",reports:"AI Reports",keys:"API Keys",tasks:"Tasks",omg:"OMG",devops:"Azure DevOps",settings:"Settings",admin:"Admin"})[v.name]??"CC Dashboard");return(k,u)=>{const x=N("RouterView");return r(),n("div",re,[m(R,{"enter-active-class":"transition-opacity duration-200","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-opacity duration-200","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:j(()=>[a.value?(r(),n("div",{key:0,class:"fixed inset-0 z-20 bg-black/60 lg:hidden",onClick:u[0]||(u[0]=s=>a.value=!1)})):y("",!0)]),_:1}),e("div",{class:d(["fixed inset-y-0 left-0 z-30 w-60 transform transition-transform duration-300 lg:relative lg:translate-x-0",a.value?"translate-x-0":"-translate-x-full"])},[m(Q,{onClose:u[1]||(u[1]=s=>a.value=!1)})],2),e("div",ne,[m(se,{title:l.value,"sidebar-open":a.value,onToggleSidebar:u[2]||(u[2]=s=>a.value=!a.value)},null,8,["title","sidebar-open"]),e("main",ae,[m(x)])])])}}});export{de as default}; +import{d as C,u as M,c as n,b as B,a as e,F as V,r as _,t as g,h as p,j as b,o as r,k as $,w as j,i as y,n as d,m as A,l as H,R as D,g as z,p as S,q as T,K as L,f as O,e as m,T as R,s as I,v as N}from"./index-aIsLHJPY.js";const P={class:"flex flex-col h-full bg-white border-r border-slate-200/80"},F={class:"flex-1 px-3 py-4 space-y-0.5 overflow-y-auto"},K={key:0,class:"absolute left-0 top-1/2 -translate-y-1/2 w-1 h-6 bg-orange-500 rounded-r-full"},q={class:"text-sm"},E={class:"p-4 border-t border-slate-100 shrink-0"},G={class:"flex items-center gap-3 px-2 py-2 rounded-xl bg-slate-50"},U={class:"h-8 w-8 rounded-full bg-gradient-to-br from-orange-400 to-orange-600 flex items-center justify-center text-[11px] font-bold text-white shrink-0 shadow-sm shadow-orange-200"},W={class:"flex-1 min-w-0"},J={class:"text-xs font-semibold text-slate-700 truncate"},Q=C({__name:"Sidebar",emits:["close"],setup(w,{emit:v}){const a=z(),l=M(),k=v,u=[{name:"Dashboard",path:"/",icon:"grid"},{name:"Calendar",path:"/calendar",icon:"calendar"},{name:"Tasks",path:"/tasks",icon:"check-square"},{name:"OMG",path:"/omg",icon:"omg"},{name:"Projects",path:"/projects",icon:"folder"},{name:"Live Feed",path:"/live",icon:"activity"},{name:"Reports",path:"/reports",icon:"file-text"},{name:"Keys",path:"/keys",icon:"key"},{name:"DevOps",path:"/devops",icon:"devops"},{name:"Settings",path:"/settings",icon:"settings"},{name:"Admin",path:"/admin",icon:"shield",adminOnly:!0}],x=b(()=>u.filter(h=>!h.adminOnly||l.isAdmin));function s(h){return h==="/"?a.path==="/":a.path.startsWith(h)}const i=b(()=>{var t,c;return(((t=l.user)==null?void 0:t.username)??((c=l.user)==null?void 0:c.email)??"?").slice(0,2).toUpperCase()});return(h,t)=>{var c,f;return r(),n("aside",P,[t[13]||(t[13]=B('

CC Dashboard

Oliver Agency

',1)),e("nav",F,[(r(!0),n(V,null,_(x.value,o=>(r(),$(H(o.external?"a":p(D)),A({key:o.path},{ref_for:!0},o.external?{href:o.path,target:"_blank",rel:"noopener"}:{to:o.path},{class:["relative flex items-center gap-3 px-3 h-10 rounded-xl text-sm font-medium transition-all duration-200 group",s(o.path)?"bg-orange-50 text-orange-600":"text-slate-500 hover:bg-slate-50 hover:text-slate-800"],onClick:t[0]||(t[0]=le=>k("close"))}),{default:j(()=>[s(o.path)?(r(),n("span",K)):y("",!0),o.icon==="grid"?(r(),n("svg",{key:1,class:d(["h-4 w-4 shrink-0 transition-colors",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[1]||(t[1]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M4 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2V6zM14 6a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2V6zM4 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2H6a2 2 0 01-2-2v-2zM14 16a2 2 0 012-2h2a2 2 0 012 2v2a2 2 0 01-2 2h-2a2 2 0 01-2-2v-2z"},null,-1)])],2)):o.icon==="calendar"?(r(),n("svg",{key:2,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[2]||(t[2]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M8 7V3m8 4V3m-9 8h10M5 21h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"},null,-1)])],2)):o.icon==="check-square"?(r(),n("svg",{key:3,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[3]||(t[3]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"},null,-1)])],2)):o.icon==="omg"?(r(),n("svg",{key:4,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[4]||(t[4]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 13.255A23.931 23.931 0 0112 15c-3.183 0-6.22-.62-9-1.745M16 6V4a2 2 0 00-2-2h-4a2 2 0 00-2 2v2m4 6h.01M5 20h14a2 2 0 002-2V8a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z"},null,-1)])],2)):o.icon==="folder"?(r(),n("svg",{key:5,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[5]||(t[5]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M3 7a2 2 0 012-2h3.586a1 1 0 01.707.293l1.414 1.414A1 1 0 0011.414 7H19a2 2 0 012 2v9a2 2 0 01-2 2H5a2 2 0 01-2-2V7z"},null,-1)])],2)):o.icon==="activity"?(r(),n("svg",{key:6,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[6]||(t[6]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M13 10V3L4 14h7v7l9-11h-7z"},null,-1)])],2)):o.icon==="file-text"?(r(),n("svg",{key:7,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[7]||(t[7]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 12h6m-6 4h6m2 5H7a2 2 0 01-2-2V5a2 2 0 012-2h5.586a1 1 0 01.707.293l5.414 5.414a1 1 0 01.293.707V19a2 2 0 01-2 2z"},null,-1)])],2)):o.icon==="key"?(r(),n("svg",{key:8,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[8]||(t[8]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 7a2 2 0 012 2m4 0a6 6 0 01-7.743 5.743L11 17H9v2H7v2H4a1 1 0 01-1-1v-2.586a1 1 0 01.293-.707l5.964-5.964A6 6 0 1121 9z"},null,-1)])],2)):o.icon==="devops"?(r(),n("svg",{key:9,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[9]||(t[9]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10 20l4-16m4 4l4 4-4 4M6 16l-4-4 4-4"},null,-1)])],2)):o.icon==="settings"?(r(),n("svg",{key:10,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[10]||(t[10]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10.325 4.317c.426-1.756 2.924-1.756 3.35 0a1.724 1.724 0 002.573 1.066c1.543-.94 3.31.826 2.37 2.37a1.724 1.724 0 001.065 2.572c1.756.426 1.756 2.924 0 3.35a1.724 1.724 0 00-1.066 2.573c.94 1.543-.826 3.31-2.37 2.37a1.724 1.724 0 00-2.572 1.065c-.426 1.756-2.924 1.756-3.35 0a1.724 1.724 0 00-2.573-1.066c-1.543.94-3.31-.826-2.37-2.37a1.724 1.724 0 00-1.065-2.572c-1.756-.426-1.756-2.924 0-3.35a1.724 1.724 0 001.066-2.573c-.94-1.543.826-3.31 2.37-2.37.996.608 2.296.07 2.572-1.065z"},null,-1),e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M15 12a3 3 0 11-6 0 3 3 0 016 0z"},null,-1)])],2)):o.icon==="shield"?(r(),n("svg",{key:11,class:d(["h-4 w-4 shrink-0",s(o.path)?"text-orange-500":"text-slate-400 group-hover:text-slate-600"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[...t[11]||(t[11]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 12l2 2 4-4m5.618-4.016A11.955 11.955 0 0112 2.944a11.955 11.955 0 01-8.618 3.04A12.02 12.02 0 003 9c0 5.591 3.824 10.29 9 11.622 5.176-1.332 9-6.03 9-11.622 0-1.042-.133-2.052-.382-3.016z"},null,-1)])],2)):y("",!0),e("span",q,g(o.name),1)]),_:2},1040,["class"]))),128))]),e("div",E,[e("div",G,[e("div",U,g(i.value),1),e("div",W,[e("p",J,g(((c=p(l).user)==null?void 0:c.username)??((f=p(l).user)==null?void 0:f.email)),1),t[12]||(t[12]=e("div",{class:"flex items-center gap-1 mt-0.5"},[e("div",{class:"h-1.5 w-1.5 rounded-full bg-emerald-400"}),e("span",{class:"text-[10px] text-slate-400 font-medium"},"Online")],-1))])])])])}}}),X={class:"h-14 border-b border-slate-200/80 bg-white/80 backdrop-blur-xl flex items-center px-4 gap-3 shrink-0 sticky top-0 z-10 shadow-sm shadow-slate-100/60"},Y={class:"flex-1"},Z={class:"text-sm font-semibold text-foreground"},ee={class:"flex items-center gap-2.5"},te={class:"h-7 w-7 rounded-full bg-gradient-to-br from-orange-400 to-orange-600 flex items-center justify-center text-[10px] font-bold text-white shrink-0 shadow-sm shadow-orange-200"},oe={class:"hidden sm:block text-xs font-medium text-foreground max-w-[120px] truncate"},se=C({__name:"TopBar",props:{title:{},sidebarOpen:{type:Boolean}},emits:["toggleSidebar","toggleDark"],setup(w,{emit:v}){const a=v,l=M(),k=O();async function u(){await l.logout(),L.success("Logged out"),k.push({name:"login"})}function x(){const s=document.documentElement.classList.toggle("dark");localStorage.setItem("theme",s?"dark":"light"),a("toggleDark")}return(s,i)=>{var h,t,c,f;return r(),n("header",X,[e("button",{class:"lg:hidden flex h-9 w-9 items-center justify-center rounded-lg text-muted-foreground hover:bg-muted hover:text-foreground transition-colors","aria-label":"Toggle sidebar",onClick:i[0]||(i[0]=o=>a("toggleSidebar"))},[...i[1]||(i[1]=[e("svg",{class:"h-5 w-5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M4 6h16M4 12h16M4 18h16"})],-1)])]),e("div",Y,[e("h1",Z,g(w.title??"CC Dashboard"),1)]),S(s.$slots,"actions"),e("button",{class:"flex h-9 w-9 items-center justify-center rounded-lg text-muted-foreground hover:bg-muted hover:text-foreground transition-colors","aria-label":"Toggle dark mode",onClick:x},[...i[2]||(i[2]=[e("svg",{class:"h-4 w-4 hidden dark:block",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 3v1m0 16v1m9-9h-1M4 12H3m15.364 6.364l-.707-.707M6.343 6.343l-.707-.707m12.728 0l-.707.707M6.343 17.657l-.707.707M16 12a4 4 0 11-8 0 4 4 0 018 0z"})],-1),e("svg",{class:"h-4 w-4 dark:hidden",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M20.354 15.354A9 9 0 018.646 3.646 9.003 9.003 0 0012 21a9.003 9.003 0 008.354-5.646z"})],-1)])]),i[4]||(i[4]=e("div",{class:"h-6 w-px bg-border"},null,-1)),e("div",ee,[e("div",te,g((((h=p(l).user)==null?void 0:h.username)??((t=p(l).user)==null?void 0:t.email)??"?").slice(0,2).toUpperCase()),1),e("span",oe,g(((c=p(l).user)==null?void 0:c.username)??((f=p(l).user)==null?void 0:f.email)),1),e("button",{class:"flex h-7 items-center gap-1 rounded-md px-2 text-xs text-muted-foreground hover:bg-muted hover:text-foreground transition-colors",onClick:u},[...i[3]||(i[3]=[e("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M17 16l4-4m0 0l-4-4m4 4H7m6 4v1a3 3 0 01-3 3H6a3 3 0 01-3-3V7a3 3 0 013-3h4a3 3 0 013 3v1"})],-1),T(" Sign out ",-1)])])])])}}}),re={class:"h-screen flex overflow-hidden",style:{background:"linear-gradient(135deg, #f0f4fa 0%, #f8f9fd 50%, #fef9f5 100%)"}},ne={class:"flex-1 flex flex-col overflow-hidden min-w-0"},ae={class:"flex-1 overflow-y-auto"},de=C({__name:"AppLayout",setup(w){const v=z(),a=I(!1),l=b(()=>({dashboard:"Dashboard",calendar:"Calendar",projects:"Projects","project-detail":"Project Details",live:"Live Feed",reports:"AI Reports",keys:"API Keys",tasks:"Tasks",omg:"OMG",devops:"Azure DevOps",settings:"Settings",admin:"Admin"})[v.name]??"CC Dashboard");return(k,u)=>{const x=N("RouterView");return r(),n("div",re,[m(R,{"enter-active-class":"transition-opacity duration-200","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-opacity duration-200","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:j(()=>[a.value?(r(),n("div",{key:0,class:"fixed inset-0 z-20 bg-black/60 lg:hidden",onClick:u[0]||(u[0]=s=>a.value=!1)})):y("",!0)]),_:1}),e("div",{class:d(["fixed inset-y-0 left-0 z-30 w-60 transform transition-transform duration-300 lg:relative lg:translate-x-0",a.value?"translate-x-0":"-translate-x-full"])},[m(Q,{onClose:u[1]||(u[1]=s=>a.value=!1)})],2),e("div",ne,[m(se,{title:l.value,"sidebar-open":a.value,onToggleSidebar:u[2]||(u[2]=s=>a.value=!a.value)},null,8,["title","sidebar-open"]),e("main",ae,[m(x)])])])}}});export{de as default}; diff --git a/src/static/assets/Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js b/src/static/assets/Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js similarity index 91% rename from src/static/assets/Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js rename to src/static/assets/Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js index e1c2cde..ea779bd 100644 --- a/src/static/assets/Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js +++ b/src/static/assets/Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js @@ -1 +1 @@ -import{c as a}from"./utils-7WVCegLb.js";import{d as n,o,c as s,n as d,h as i,p as c}from"./index-BiYpJJoC.js";const f=n({__name:"Badge",props:{variant:{default:"default"},class:{}},setup(r){const e=r;return(t,l)=>(o(),s("span",{class:d(i(a)("inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-semibold transition-colors",{"bg-primary text-primary-foreground":e.variant==="default","bg-secondary text-secondary-foreground":e.variant==="secondary","bg-destructive text-destructive-foreground":e.variant==="destructive","border border-border text-foreground":e.variant==="outline","bg-emerald-500/20 text-emerald-400":e.variant==="success","bg-amber-500/20 text-amber-400":e.variant==="warning"},e.class))},[c(t.$slots,"default")],2))}});export{f as _}; +import{c as a}from"./utils-7WVCegLb.js";import{d as n,o,c as s,n as d,h as i,p as c}from"./index-aIsLHJPY.js";const f=n({__name:"Badge",props:{variant:{default:"default"},class:{}},setup(r){const e=r;return(t,l)=>(o(),s("span",{class:d(i(a)("inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-semibold transition-colors",{"bg-primary text-primary-foreground":e.variant==="default","bg-secondary text-secondary-foreground":e.variant==="secondary","bg-destructive text-destructive-foreground":e.variant==="destructive","border border-border text-foreground":e.variant==="outline","bg-emerald-500/20 text-emerald-400":e.variant==="success","bg-amber-500/20 text-amber-400":e.variant==="warning"},e.class))},[c(t.$slots,"default")],2))}});export{f as _}; diff --git a/src/static/assets/Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js b/src/static/assets/Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js similarity index 91% rename from src/static/assets/Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js rename to src/static/assets/Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js index 4ce90c8..b617e19 100644 --- a/src/static/assets/Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js +++ b/src/static/assets/Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js @@ -1 +1 @@ -import{_ as c}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{c as l}from"./utils-7WVCegLb.js";import{d as u,c as f,n as m,k as b,i as v,p as g,j as p,o as n}from"./index-BiYpJJoC.js";const y=["type","disabled"],z=u({__name:"Button",props:{variant:{default:"default"},size:{default:"md"},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},type:{default:"button"},class:{}},emits:["click"],setup(t,{emit:s}){const e=t,a=s,r=p(()=>l("inline-flex items-center justify-center rounded-md font-medium transition-colors","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50",{"bg-primary text-primary-foreground hover:bg-primary/90":e.variant==="default","border border-input bg-background hover:bg-accent hover:text-accent-foreground":e.variant==="outline","hover:bg-accent hover:text-accent-foreground":e.variant==="ghost","bg-destructive text-destructive-foreground hover:bg-destructive/90":e.variant==="destructive","bg-secondary text-secondary-foreground hover:bg-secondary/80":e.variant==="secondary","underline-offset-4 hover:underline text-primary":e.variant==="link","h-8 px-3 text-xs":e.size==="sm","h-10 px-4 py-2 text-sm":e.size==="md","h-11 px-8 text-base":e.size==="lg","h-10 w-10 p-0":e.size==="icon"},e.class));return(i,o)=>(n(),f("button",{class:m(r.value),type:t.type,disabled:t.disabled||t.loading,onClick:o[0]||(o[0]=d=>a("click",d))},[t.loading?(n(),b(c,{key:0,size:"sm",class:"mr-2"})):v("",!0),g(i.$slots,"default")],10,y))}});export{z as _}; +import{_ as c}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{c as l}from"./utils-7WVCegLb.js";import{d as u,c as f,n as m,k as b,i as v,p as g,j as p,o as n}from"./index-aIsLHJPY.js";const y=["type","disabled"],z=u({__name:"Button",props:{variant:{default:"default"},size:{default:"md"},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},type:{default:"button"},class:{}},emits:["click"],setup(t,{emit:s}){const e=t,a=s,r=p(()=>l("inline-flex items-center justify-center rounded-md font-medium transition-colors","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:pointer-events-none disabled:opacity-50",{"bg-primary text-primary-foreground hover:bg-primary/90":e.variant==="default","border border-input bg-background hover:bg-accent hover:text-accent-foreground":e.variant==="outline","hover:bg-accent hover:text-accent-foreground":e.variant==="ghost","bg-destructive text-destructive-foreground hover:bg-destructive/90":e.variant==="destructive","bg-secondary text-secondary-foreground hover:bg-secondary/80":e.variant==="secondary","underline-offset-4 hover:underline text-primary":e.variant==="link","h-8 px-3 text-xs":e.size==="sm","h-10 px-4 py-2 text-sm":e.size==="md","h-11 px-8 text-base":e.size==="lg","h-10 w-10 p-0":e.size==="icon"},e.class));return(i,o)=>(n(),f("button",{class:m(r.value),type:t.type,disabled:t.disabled||t.loading,onClick:o[0]||(o[0]=d=>a("click",d))},[t.loading?(n(),b(c,{key:0,size:"sm",class:"mr-2"})):v("",!0),g(i.$slots,"default")],10,y))}});export{z as _}; diff --git a/src/static/assets/CalendarView-B0jfXKKY.js b/src/static/assets/CalendarView-B0jfXKKY.js deleted file mode 100644 index 5d8fbc4..0000000 --- a/src/static/assets/CalendarView-B0jfXKKY.js +++ /dev/null @@ -1,2 +0,0 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/tasks-DwSuZPNM.js","assets/index-BiYpJJoC.js","assets/index-bBdb_PCl.css"])))=>i.map(i=>d[i]); -import{B as be,s as T,j as E,d as A,o as f,c as k,a as l,e as C,w as O,h as p,q as de,t as D,i as M,k as ce,z as j,n as I,C as fe,F as L,r as V,A as ve,g as xe,_ as he,K as R,f as we}from"./index-BiYpJJoC.js";import{d as ye}from"./dashboard-Ca6WcfdV.js";import{i as S,f as W}from"./utils-7WVCegLb.js";import{_ as U}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as le}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js";import{C as De,a as $e,f as P}from"./format-WqwOLoqz.js";import{u as Z}from"./tasks-DwSuZPNM.js";import{_ as Te}from"./_plugin-vue_export-helper-DlAUqK2U.js";import{_ as Se}from"./Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js";import{_ as Ce}from"./TaskForm.vue_vue_type_script_setup_true_lang-BvqRdc1Q.js";import{_ as Me}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js";import"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import"./createLucideIcon-D7qP-VdO.js";import"./Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js";import"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import"./Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js";import"./devops-y1AYKG_U.js";const G=40/30;function Be(a){if(a.length===0)return[];const t=[...a].sort((d,w)=>new Date(d.start_at).getTime()-new Date(w.start_at).getTime()),o=[],m=[];for(const d of t){const w=new Date(d.start_at).getTime(),y=new Date(d.end_at).getTime();let i=-1;for(let u=0;u{const y=new Date(d.start_at).getTime(),i=new Date(d.end_at).getTime();let u=w;for(const n of m){const r=new Date(n.block.start_at).getTime(),_=new Date(n.block.end_at).getTime();ry&&n.lane>u&&(u=n.lane)}return{block:d,lane:w,totalLanes:u+1}})}function Ee(a,t=7){return((a.getHours()-t)*60+a.getMinutes())*G}function ze(a,t){const o=(t.getTime()-a.getTime())/6e4;return Math.max(o*G,20)}function ie(a,t=7){const o=a.getDay(),m=new Date(a);return m.setDate(a.getDate()-(o+6)%7),m.setHours(0,0,0,0),Array.from({length:t},(h,d)=>{const w=new Date(m);return w.setDate(m.getDate()+d),w})}function ue(a,t=15){return Math.round(a/t)*t}const N=be("calendar",()=>{const a=T([]),t=T(new Date),o=T("week"),m=T(7),h=T(!1),d=T(null),w=E(()=>ie(t.value,m.value));async function y(e,x,g){h.value=!0,d.value=null;try{const B=await ye.calendar({from:e,to:x,view:g});a.value=B.data}catch(B){const Y=B;d.value=Y.message??"Failed to fetch calendar"}finally{h.value=!1}}function i(e){m.value=e}async function u(){if(o.value==="week"){const e=ie(t.value,m.value),x=S(e[0]),g=S(e[m.value-1]);await y(x,g,"week")}else{const e=S(t.value);await y(e,e,"day")}}function n(){const e=new Date(t.value);o.value==="week"?e.setDate(e.getDate()-7):e.setDate(e.getDate()-1),t.value=e}function r(){const e=new Date(t.value);o.value==="week"?e.setDate(e.getDate()+7):e.setDate(e.getDate()+1),t.value=e}function _(){t.value=new Date}function b(e){o.value=e}function $(e){a.value.push(e)}function v(e){const x=a.value.findIndex(g=>g.id===e.id);x!==-1&&(a.value[x]=e)}function s(e){a.value=a.value.filter(x=>x.id!==e)}function c(e){const x=S(e);return a.value.filter(g=>S(new Date(g.start_at))===x)}return{blocks:a,currentDate:t,view:o,weekLength:m,loading:h,error:d,weekDays:w,fetch:y,fetchCurrentView:u,navigatePrev:n,navigateNext:r,goToToday:_,setView:b,setWeekLength:i,addBlock:$,updateBlock:v,removeBlock:s,getBlocksForDay:c}}),Le={class:"flex items-center gap-2 flex-wrap"},Ve={class:"flex items-center gap-1"},je={class:"text-sm font-medium text-foreground flex-1 min-w-0 truncate"},Pe={key:0,class:"text-xs text-muted-foreground"},Fe=A({__name:"CalendarToolbar",setup(a){const t=N(),o=E(()=>{if(t.view==="week"){const u=t.weekDays;if(!u.length)return"";const n=u[0],r=u[u.length-1];return n.getMonth()===r.getMonth()?`${P(n,"MMM d")} – ${P(r,"d, yyyy")}`:`${P(n,"MMM d")} – ${P(r,"MMM d, yyyy")}`}else return P(t.currentDate,"EEEE, MMMM d, yyyy")}),m=[{value:"day",label:"Day"},{value:"week",label:"Week"}],h=[{value:"5",label:"5d"},{value:"7",label:"7d"}],d=E({get:()=>t.view,set:async u=>{t.setView(u),await t.fetchCurrentView()}}),w=E({get:()=>String(t.weekLength),set:async u=>{t.setWeekLength(Number(u)),await t.fetchCurrentView()}});async function y(u){u==="prev"?t.navigatePrev():t.navigateNext(),await t.fetchCurrentView()}async function i(){t.goToToday(),await t.fetchCurrentView()}return(u,n)=>(f(),k("div",Le,[l("div",Ve,[C(U,{variant:"ghost",size:"icon","aria-label":"Previous",onClick:n[0]||(n[0]=r=>y("prev"))},{default:O(()=>[C(p(De),{class:"h-4 w-4"})]),_:1}),C(U,{variant:"outline",size:"sm",onClick:i},{default:O(()=>[...n[4]||(n[4]=[de("Today",-1)])]),_:1}),C(U,{variant:"ghost",size:"icon","aria-label":"Next",onClick:n[1]||(n[1]=r=>y("next"))},{default:O(()=>[C(p($e),{class:"h-4 w-4"})]),_:1})]),l("span",je,D(o.value),1),p(t).loading?(f(),k("div",Pe,"Loading...")):M("",!0),C(le,{modelValue:d.value,"onUpdate:modelValue":n[2]||(n[2]=r=>d.value=r),options:m,"aria-label":"Calendar view"},null,8,["modelValue"]),p(t).view==="week"?(f(),ce(le,{key:1,modelValue:w.value,"onUpdate:modelValue":n[3]||(n[3]=r=>w.value=r),options:h,"aria-label":"Week length"},null,8,["modelValue"])):M("",!0)]))}}),Re=7;function me(){const a=Z(),t=N(),o=T(null),m=T(null),h=T(null),d=T(null);function w(v,s){var c,e;o.value=v.id,(c=s.dataTransfer)==null||c.setData("task_id",v.id),(e=s.dataTransfer)==null||e.setData("estimate_hours",String(v.estimate_hours??1))}function y(v,s){var e,x,g,B;const c=new Date(v.end_at).getTime()-new Date(v.start_at).getTime();(e=s.dataTransfer)==null||e.setData("block_id",v.id),(x=s.dataTransfer)==null||x.setData("block_duration_ms",String(c)),(g=s.dataTransfer)==null||g.setData("task_id",v.task_id??""),(B=s.dataTransfer)==null||B.setData("estimate_hours",String(c/36e5))}function i(v,s){s.preventDefault(),m.value=S(v)}function u(){m.value=null}async function n(v,s){var ne,ae,oe,se;s.preventDefault(),m.value=null,o.value=null;const c=(ne=s.dataTransfer)==null?void 0:ne.getData("block_id"),e=(ae=s.dataTransfer)==null?void 0:ae.getData("task_id"),x=parseFloat(((oe=s.dataTransfer)==null?void 0:oe.getData("estimate_hours"))??"1")||1,g=parseFloat(((se=s.dataTransfer)==null?void 0:se.getData("block_duration_ms"))??"0"),Y=s.currentTarget.getBoundingClientRect(),q=s.clientY-Y.top,K=ue(q/G,15),ge=Math.max(0,Math.min(K,12*60)),F=new Date(v);F.setHours(Re,0,0,0),F.setMinutes(F.getMinutes()+ge);const X=F.toISOString();if(c&&g>0){const pe=new Date(F.getTime()+g).toISOString();try{await a.updateBlock(c,{start_at:X,end_at:pe}),await t.fetchCurrentView()}catch(_e){console.error("Failed to move block:",_e)}return}if(!e)return;const J=new Date(F);J.setMinutes(J.getMinutes()+Math.round(x*60));const ee=J.toISOString(),te=`temp_${Date.now()}`,ke={kind:"planned",id:te,project_id:null,job_number:"",display_name:"Loading...",start_at:X,end_at:ee,title:"",color_hue:260,tags:[],task_id:e,session_id:null,manual_entry_id:null};t.addBlock(ke);try{await a.createBlock(e,{start_at:X,end_at:ee}),await t.fetchCurrentView()}catch(re){t.removeBlock(te),console.error("Failed to create task block:",re)}}let r=0,_="",b=null;function $(v,s){s.preventDefault(),s.stopPropagation(),h.value=v,b=v,r=s.clientY,_=v.end_at,d.value=v.end_at;const c=x=>{if(!b)return;const g=x.clientY-r,B=ue(g/G,15),q=new Date(_).getTime()+B*6e4,K=new Date(b.start_at).getTime()+15*6e4;d.value=new Date(Math.max(q,K)).toISOString()},e=async()=>{if(document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",e),!b||!d.value){h.value=null;return}const x=b.id,g=d.value;if(g===_){h.value=null,d.value=null;return}try{b.task_id&&await a.updateBlock(x,{start_at:b.start_at,end_at:g}),t.updateBlock({...b,end_at:g})}catch(B){console.error("Failed to resize block:",B),t.updateBlock({...b,end_at:_})}h.value=null,d.value=null,b=null};document.addEventListener("mousemove",c),document.addEventListener("mouseup",e)}return{draggingTaskId:o,dragOverDay:m,resizingBlock:h,resizePreviewEnd:d,onDragStart:w,onBlockDragStart:y,onDragOver:i,onDragLeave:u,onDrop:n,onResizeStart:$}}function He(a){return`hsla(${a}, 65%, 45%, 0.85)`}function Oe(a){return`hsla(${a}, 65%, 55%, 1)`}const Ie=["draggable"],Ae={class:"px-1.5 py-1 h-full flex flex-col text-white overflow-hidden"},Ne={class:"text-xs font-semibold leading-tight truncate"},Ye={key:0,class:"text-xs opacity-75 truncate"},We={key:1,class:"text-xs opacity-75 mt-auto"},Ue=A({__name:"CalendarBlock",props:{block:{},lane:{},totalLanes:{},top:{},height:{},resizeEnd:{}},emits:["resizeStart","click","blockDragStart"],setup(a,{emit:t}){const o=a,m=t,h=E(()=>o.resizeEnd?new Date(o.resizeEnd):new Date(o.block.end_at)),d=E(()=>{if(!o.resizeEnd)return o.height;const n=(h.value.getTime()-new Date(o.block.start_at).getTime())/6e4;return Math.max(n*(40/30),20)}),w=E(()=>{const u=h.value.getTime()-new Date(o.block.start_at).getTime();return W(u/36e5)}),y=E(()=>{const u=`calc(${100/o.totalLanes}% - 2px)`,n=`calc(${o.lane/o.totalLanes*100}% + 1px)`;return{top:`${o.top}px`,height:`${d.value}px`,width:u,left:n,backgroundColor:He(o.block.color_hue),borderColor:Oe(o.block.color_hue)}}),i=E(()=>d.value<40);return(u,n)=>(f(),k("div",{class:I(["absolute rounded overflow-hidden cursor-pointer select-none group",{"border-2":a.block.kind==="session","border-2 border-dashed opacity-80":a.block.kind==="planned","border-2 calendar-block--manual":a.block.kind==="manual"}]),draggable:a.block.kind==="planned"&&!!a.block.task_id,style:j(y.value),onClick:n[1]||(n[1]=r=>m("click",a.block)),onDragstart:n[2]||(n[2]=r=>a.block.kind==="planned"&&a.block.task_id?m("blockDragStart",a.block,r):void 0)},[l("div",Ae,[l("p",Ne,D(a.block.kind==="planned"&&a.block.title?a.block.title:a.block.display_name),1),!i.value&&a.block.job_number?(f(),k("p",Ye,D(a.block.job_number),1)):M("",!0),i.value?M("",!0):(f(),k("p",We,D(w.value),1))]),l("div",{class:"absolute bottom-0 left-0 right-0 h-2 cursor-s-resize opacity-0 group-hover:opacity-100 flex items-center justify-center",onMousedown:n[0]||(n[0]=fe(r=>m("resizeStart",r),["stop"]))},[...n[3]||(n[3]=[l("div",{class:"w-8 h-0.5 bg-white/60 rounded"},null,-1)])],32)],46,Ie))}}),Ge=Te(Ue,[["__scopeId","data-v-7d0575a8"]]),qe={class:"flex overflow-auto h-full"},Ke={class:"flex flex-1 gap-px min-w-0"},Xe=["onDragover","onDrop"],Je={key:1,class:"absolute inset-0 bg-primary/10 pointer-events-none z-0"},z=7,Q=19,H=40,Qe=A({__name:"CalendarGrid",emits:["blockClick"],setup(a,{emit:t}){const o=Array.from({length:Q-z+1},(b,$)=>z+$),m=N(),h=me(),d=t,w=E(()=>m.view==="week"?m.weekDays:[m.currentDate]),y=S(new Date);function i(b){const $=m.getBlocksForDay(b);return Be($)}function u(b){return Ee(new Date(b.start_at),z)}function n(b){return ze(new Date(b.start_at),new Date(b.end_at))}function r(b){var $;return(($=h.resizingBlock.value)==null?void 0:$.id)===b.id}function _(b){return b===12?"12 PM":b>12?`${b-12} PM`:`${b} AM`}return(b,$)=>(f(),k("div",qe,[l("div",{class:"w-12 shrink-0 relative",style:j({height:`${(Q-z+1)*H*2}px`})},[(f(!0),k(L,null,V(p(o),v=>(f(),k("div",{key:v,class:"absolute right-2 text-xs text-muted-foreground",style:j({top:`${(v-z)*H*2-6}px`})},D(_(v)),5))),128))],4),l("div",Ke,[(f(!0),k(L,null,V(w.value,v=>(f(),k("div",{key:p(S)(v),class:I(["flex-1 relative border-l border-border",{"bg-primary/5":p(S)(v)===p(y)}]),style:j({height:`${(Q-z)*H*2}px`}),onDragover:s=>p(h).onDragOver(v,s),onDragleave:$[1]||($[1]=s=>p(h).onDragLeave()),onDrop:s=>p(h).onDrop(v,s)},[p(m).view==="week"?(f(),k("div",{key:0,class:I(["sticky top-0 z-10 text-center py-1 text-xs font-medium border-b border-border bg-background",p(S)(v)===p(y)?"text-primary":"text-muted-foreground"])},[l("div",null,D(p(P)(v,"EEE")),1),l("div",{class:I(["inline-flex h-6 w-6 mx-auto items-center justify-center rounded-full text-sm",p(S)(v)===p(y)?"bg-primary text-primary-foreground":""])},D(p(P)(v,"d")),3)],2)):M("",!0),(f(!0),k(L,null,V(p(o),s=>(f(),k("div",{key:s,class:"absolute left-0 right-0 border-t border-border/40",style:j({top:`${(s-z)*H*2}px`})},null,4))),128)),(f(!0),k(L,null,V(p(o).slice(0,-1),s=>(f(),k("div",{key:`half-${s}`,class:"absolute left-0 right-0 border-t border-border/20",style:j({top:`${(s-z)*H*2+H}px`})},null,4))),128)),p(h).dragOverDay.value===p(S)(v)?(f(),k("div",Je)):M("",!0),(f(!0),k(L,null,V(i(v),({block:s,lane:c,totalLanes:e})=>(f(),ce(Ge,{key:s.id,block:s,lane:c,"total-lanes":e,top:u(s),height:n(s),"resize-end":r(s)?p(h).resizePreviewEnd.value:null,onClick:x=>d("blockClick",s),onResizeStart:x=>p(h).onResizeStart(s,x),onBlockDragStart:$[0]||($[0]=(x,g)=>p(h).onBlockDragStart(x,g))},null,8,["block","lane","total-lanes","top","height","resize-end","onClick","onResizeStart"]))),128))],46,Xe))),128))])]))}}),Ze={class:"flex flex-col h-full bg-card border-l border-border"},et={class:"p-3 border-b border-border flex items-center justify-between shrink-0"},tt={class:"flex-1 overflow-y-auto p-2 space-y-1.5"},nt={key:0,class:"text-xs text-muted-foreground p-2"},at={key:1,class:"text-xs text-muted-foreground p-2 text-center"},ot=["onDragstart"],st={class:"flex items-start gap-2"},rt={class:"flex-1 min-w-0"},lt={class:"text-xs font-medium text-foreground leading-tight truncate"},it={class:"flex items-center gap-1.5 mt-1 flex-wrap"},ut={key:0,class:"text-xs text-muted-foreground"},dt={key:0,class:"p-3 border-t border-border shrink-0"},ct={class:"space-y-1"},ft={class:"text-muted-foreground truncate max-w-[100px]"},vt={class:"text-foreground"},mt=A({__name:"PlannerSidebar",emits:["createTask"],setup(a,{emit:t}){const o=Z(),m=N(),h=me(),d=t,w=E(()=>S(m.currentDate));ve(()=>{o.fetchForDate(w.value)});const y=n=>({todo:"outline",doing:"default",testing:"warning",done:"success",cancelled:"secondary"})[n],i=n=>n>=4?"bg-red-500":n===3?"bg-amber-500":"bg-emerald-500",u=E(()=>{const n={};for(const r of o.tasks){const _=r.project_id??"_none";n[_]||(n[_]={name:r.project_id?_:"No Project",planned:0,actual:0}),n[_].planned+=r.estimate_hours??0,n[_].actual+=r.actual_hours??0}return Object.values(n)});return(n,r)=>(f(),k("div",Ze,[l("div",et,[r[2]||(r[2]=l("h3",{class:"text-sm font-semibold text-foreground"},"Planner",-1)),C(U,{size:"sm",variant:"ghost",onClick:r[0]||(r[0]=_=>d("createTask"))},{default:O(()=>[...r[1]||(r[1]=[l("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[l("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 4v16m8-8H4"})],-1)])]),_:1})]),l("div",tt,[p(o).loading?(f(),k("div",nt,"Loading...")):p(o).tasks.length===0?(f(),k("div",at," No tasks for today ")):M("",!0),(f(!0),k(L,null,V(p(o).tasks,_=>(f(),k("div",{key:_.id,class:"rounded-md border border-border bg-background p-2 cursor-grab active:cursor-grabbing hover:border-primary/50 transition-colors",draggable:"true",onDragstart:b=>p(h).onDragStart(_,b)},[l("div",st,[l("div",{class:I(["h-2 w-2 rounded-full mt-1.5 shrink-0",i(_.priority)])},null,2),l("div",rt,[l("p",lt,D(_.title),1),l("div",it,[C(Se,{variant:y(_.status),class:"text-xs py-0"},{default:O(()=>[de(D(_.status),1)]),_:2},1032,["variant"]),_.estimate_hours?(f(),k("span",ut,D(p(W)(_.estimate_hours)),1)):M("",!0)])])])],40,ot))),128))]),u.value.length?(f(),k("div",dt,[r[3]||(r[3]=l("p",{class:"text-xs font-medium text-muted-foreground mb-2"},"Plan vs Actual",-1)),l("div",ct,[(f(!0),k(L,null,V(u.value,_=>(f(),k("div",{key:_.name,class:"flex items-center justify-between text-xs"},[l("span",ft,D(_.name),1),l("span",vt,D(p(W)(_.planned))+" / "+D(p(W)(_.actual)),1)]))),128))])])):M("",!0)]))}}),gt={class:"h-full flex flex-col"},kt={class:"p-4 border-b border-border flex items-center gap-3 flex-wrap"},pt={class:"flex items-center gap-2 ml-auto"},_t={class:"flex-1 flex overflow-hidden"},bt={class:"flex-1 overflow-auto"},xt={key:0,class:"w-56 shrink-0 overflow-hidden"},ht={class:"bg-card border border-border rounded-lg shadow-xl p-4 w-72"},wt={class:"flex items-start justify-between gap-2 mb-3"},yt={class:"font-semibold text-sm text-foreground"},Dt={key:0,class:"text-xs text-muted-foreground"},$t={class:"space-y-1 text-xs text-muted-foreground"},Tt={key:0,class:"mt-2 flex flex-wrap gap-1"},St={key:1,class:"mt-3 pt-3 border-t border-border flex items-center gap-2"},Ct=["disabled"],Mt={key:2,class:"mt-3 pt-3 border-t border-border text-xs text-muted-foreground"},Gt=A({__name:"CalendarView",setup(a){const t=N(),o=Z(),m=we(),h=xe(),d=T(!0),w=T(!1),y=T(null),i=T(null),u=T(!1),n=T(!1),r=T(null);ve(async()=>{const c=h.query.date;c&&(t.currentDate=new Date(c+"T12:00:00"),t.setView("day")),await t.fetchCurrentView()});function _(c){if(c.project_id&&c.kind==="session"){const e=c.start_at.substring(0,10);m.push({name:"project-detail",params:{id:c.project_id,date:e}})}else i.value=c}async function b(c){try{y.value?(await o.update(y.value.id,c),R.success("Task updated")):(await o.create(c),R.success("Task created")),w.value=!1,y.value=null,o.fetchForDate(S(t.currentDate))}catch{R.error("Failed to save task")}}async function $(c){if(c.task_id)try{const e=await he(()=>import("./tasks-DwSuZPNM.js").then(x=>x.t),__vite__mapDeps([0,1,2])).then(x=>x.tasksApi.get(c.task_id));y.value=e.data,i.value=null,w.value=!0}catch{R.error("Failed to load task")}}function v(c){r.value=c,n.value=!0}async function s(){const c=r.value;if(c){u.value=!0;try{await o.deleteBlock(c.id),t.removeBlock(c.id),i.value=null,R.success("Block deleted")}catch{R.error("Failed to delete block")}finally{u.value=!1,r.value=null}}}return(c,e)=>{var x;return f(),k("div",gt,[l("div",kt,[C(Fe),l("div",pt,[l("button",{class:"text-xs text-muted-foreground hover:text-foreground transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring rounded",onClick:e[0]||(e[0]=g=>d.value=!d.value)},D(d.value?"Hide Planner":"Show Planner"),1)])]),l("div",_t,[l("div",bt,[C(Qe,{onBlockClick:_})]),d.value?(f(),k("div",xt,[C(mt,{onCreateTask:e[1]||(e[1]=g=>w.value=!0)})])):M("",!0)]),i.value?(f(),k("div",{key:0,class:"fixed inset-0 z-40 flex items-center justify-center p-4",onClick:e[5]||(e[5]=fe(g=>i.value=null,["self"]))},[l("div",ht,[l("div",wt,[l("div",null,[l("p",yt,D(i.value.display_name),1),i.value.job_number?(f(),k("p",Dt,D(i.value.job_number),1)):M("",!0)]),l("button",{class:"text-muted-foreground hover:text-foreground",onClick:e[2]||(e[2]=g=>i.value=null)},[...e[8]||(e[8]=[l("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[l("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])])]),l("div",$t,[l("p",null,"Start: "+D(new Date(i.value.start_at).toLocaleString()),1),l("p",null,"End: "+D(new Date(i.value.end_at).toLocaleString()),1),l("p",null,"Type: "+D(i.value.kind),1)]),i.value.tags.length?(f(),k("div",Tt,[(f(!0),k(L,null,V(i.value.tags,g=>(f(),k("span",{key:g.id,class:"px-1.5 py-0.5 rounded text-xs",style:j({background:`${g.color_hex}22`,color:g.color_hex})},D(g.name),5))),128))])):M("",!0),i.value.kind==="planned"?(f(),k("div",St,[l("button",{class:"flex-1 text-xs px-2 py-1.5 rounded bg-muted hover:bg-muted/80 text-foreground transition-colors",onClick:e[3]||(e[3]=g=>$(i.value))},"Edit task"),l("button",{class:"flex-1 text-xs px-2 py-1.5 rounded bg-destructive/10 hover:bg-destructive/20 text-destructive transition-colors",disabled:u.value,onClick:e[4]||(e[4]=g=>v(i.value))},"Delete block",8,Ct)])):(f(),k("p",Mt,D(i.value.kind==="session"?"Session from Claude Code — read-only":"Read-only entry"),1))])])):M("",!0),C(Ce,{open:w.value,task:y.value,"default-date":p(S)(p(t).currentDate),onClose:e[6]||(e[6]=g=>{w.value=!1,y.value=null}),onSave:b},null,8,["open","task","default-date"]),C(Me,{open:n.value,"onUpdate:open":e[7]||(e[7]=g=>n.value=g),title:"Delete block",description:`Delete '${(x=r.value)==null?void 0:x.display_name}'? This action cannot be undone.`,"confirm-label":"Delete",variant:"destructive",onConfirm:s},null,8,["open","description"])])}}});export{Gt as default}; diff --git a/src/static/assets/CalendarView-myth_Gpl.js b/src/static/assets/CalendarView-myth_Gpl.js new file mode 100644 index 0000000..8902c88 --- /dev/null +++ b/src/static/assets/CalendarView-myth_Gpl.js @@ -0,0 +1,2 @@ +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/tasks-caOFGu41.js","assets/index-aIsLHJPY.js","assets/index-Crx9eGr0.css"])))=>i.map(i=>d[i]); +import{B as be,s as T,j as E,d as A,o as f,c as k,a as l,e as C,w as O,h as p,q as de,t as D,i as M,k as ce,z as j,n as I,C as fe,F as L,r as V,A as ve,g as xe,_ as he,K as R,f as we}from"./index-aIsLHJPY.js";import{d as ye}from"./dashboard-CdOgDJq5.js";import{i as S,f as W}from"./utils-7WVCegLb.js";import{_ as U}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as le}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js";import{C as De,a as $e,f as P}from"./format-DDf_am8g.js";import{u as Z}from"./tasks-caOFGu41.js";import{_ as Te}from"./_plugin-vue_export-helper-DlAUqK2U.js";import{_ as Se}from"./Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js";import{_ as Ce}from"./TaskForm.vue_vue_type_script_setup_true_lang-BWg_Q6_w.js";import{_ as Me}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js";import"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import"./createLucideIcon-B5Z2hHtI.js";import"./Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js";import"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import"./projects-BYok-JQo.js";import"./devops-DsTCxAug.js";const G=40/30;function Be(a){if(a.length===0)return[];const t=[...a].sort((d,w)=>new Date(d.start_at).getTime()-new Date(w.start_at).getTime()),o=[],m=[];for(const d of t){const w=new Date(d.start_at).getTime(),y=new Date(d.end_at).getTime();let i=-1;for(let u=0;u{const y=new Date(d.start_at).getTime(),i=new Date(d.end_at).getTime();let u=w;for(const n of m){const r=new Date(n.block.start_at).getTime(),_=new Date(n.block.end_at).getTime();ry&&n.lane>u&&(u=n.lane)}return{block:d,lane:w,totalLanes:u+1}})}function Ee(a,t=7){return((a.getHours()-t)*60+a.getMinutes())*G}function ze(a,t){const o=(t.getTime()-a.getTime())/6e4;return Math.max(o*G,20)}function ie(a,t=7){const o=a.getDay(),m=new Date(a);return m.setDate(a.getDate()-(o+6)%7),m.setHours(0,0,0,0),Array.from({length:t},(h,d)=>{const w=new Date(m);return w.setDate(m.getDate()+d),w})}function ue(a,t=15){return Math.round(a/t)*t}const N=be("calendar",()=>{const a=T([]),t=T(new Date),o=T("week"),m=T(7),h=T(!1),d=T(null),w=E(()=>ie(t.value,m.value));async function y(e,x,g){h.value=!0,d.value=null;try{const B=await ye.calendar({from:e,to:x,view:g});a.value=B.data}catch(B){const Y=B;d.value=Y.message??"Failed to fetch calendar"}finally{h.value=!1}}function i(e){m.value=e}async function u(){if(o.value==="week"){const e=ie(t.value,m.value),x=S(e[0]),g=S(e[m.value-1]);await y(x,g,"week")}else{const e=S(t.value);await y(e,e,"day")}}function n(){const e=new Date(t.value);o.value==="week"?e.setDate(e.getDate()-7):e.setDate(e.getDate()-1),t.value=e}function r(){const e=new Date(t.value);o.value==="week"?e.setDate(e.getDate()+7):e.setDate(e.getDate()+1),t.value=e}function _(){t.value=new Date}function b(e){o.value=e}function $(e){a.value.push(e)}function v(e){const x=a.value.findIndex(g=>g.id===e.id);x!==-1&&(a.value[x]=e)}function s(e){a.value=a.value.filter(x=>x.id!==e)}function c(e){const x=S(e);return a.value.filter(g=>S(new Date(g.start_at))===x)}return{blocks:a,currentDate:t,view:o,weekLength:m,loading:h,error:d,weekDays:w,fetch:y,fetchCurrentView:u,navigatePrev:n,navigateNext:r,goToToday:_,setView:b,setWeekLength:i,addBlock:$,updateBlock:v,removeBlock:s,getBlocksForDay:c}}),Le={class:"flex items-center gap-2 flex-wrap"},Ve={class:"flex items-center gap-1"},je={class:"text-sm font-medium text-foreground flex-1 min-w-0 truncate"},Pe={key:0,class:"text-xs text-muted-foreground"},Fe=A({__name:"CalendarToolbar",setup(a){const t=N(),o=E(()=>{if(t.view==="week"){const u=t.weekDays;if(!u.length)return"";const n=u[0],r=u[u.length-1];return n.getMonth()===r.getMonth()?`${P(n,"MMM d")} – ${P(r,"d, yyyy")}`:`${P(n,"MMM d")} – ${P(r,"MMM d, yyyy")}`}else return P(t.currentDate,"EEEE, MMMM d, yyyy")}),m=[{value:"day",label:"Day"},{value:"week",label:"Week"}],h=[{value:"5",label:"5d"},{value:"7",label:"7d"}],d=E({get:()=>t.view,set:async u=>{t.setView(u),await t.fetchCurrentView()}}),w=E({get:()=>String(t.weekLength),set:async u=>{t.setWeekLength(Number(u)),await t.fetchCurrentView()}});async function y(u){u==="prev"?t.navigatePrev():t.navigateNext(),await t.fetchCurrentView()}async function i(){t.goToToday(),await t.fetchCurrentView()}return(u,n)=>(f(),k("div",Le,[l("div",Ve,[C(U,{variant:"ghost",size:"icon","aria-label":"Previous",onClick:n[0]||(n[0]=r=>y("prev"))},{default:O(()=>[C(p(De),{class:"h-4 w-4"})]),_:1}),C(U,{variant:"outline",size:"sm",onClick:i},{default:O(()=>[...n[4]||(n[4]=[de("Today",-1)])]),_:1}),C(U,{variant:"ghost",size:"icon","aria-label":"Next",onClick:n[1]||(n[1]=r=>y("next"))},{default:O(()=>[C(p($e),{class:"h-4 w-4"})]),_:1})]),l("span",je,D(o.value),1),p(t).loading?(f(),k("div",Pe,"Loading...")):M("",!0),C(le,{modelValue:d.value,"onUpdate:modelValue":n[2]||(n[2]=r=>d.value=r),options:m,"aria-label":"Calendar view"},null,8,["modelValue"]),p(t).view==="week"?(f(),ce(le,{key:1,modelValue:w.value,"onUpdate:modelValue":n[3]||(n[3]=r=>w.value=r),options:h,"aria-label":"Week length"},null,8,["modelValue"])):M("",!0)]))}}),Re=7;function me(){const a=Z(),t=N(),o=T(null),m=T(null),h=T(null),d=T(null);function w(v,s){var c,e;o.value=v.id,(c=s.dataTransfer)==null||c.setData("task_id",v.id),(e=s.dataTransfer)==null||e.setData("estimate_hours",String(v.estimate_hours??1))}function y(v,s){var e,x,g,B;const c=new Date(v.end_at).getTime()-new Date(v.start_at).getTime();(e=s.dataTransfer)==null||e.setData("block_id",v.id),(x=s.dataTransfer)==null||x.setData("block_duration_ms",String(c)),(g=s.dataTransfer)==null||g.setData("task_id",v.task_id??""),(B=s.dataTransfer)==null||B.setData("estimate_hours",String(c/36e5))}function i(v,s){s.preventDefault(),m.value=S(v)}function u(){m.value=null}async function n(v,s){var ne,ae,oe,se;s.preventDefault(),m.value=null,o.value=null;const c=(ne=s.dataTransfer)==null?void 0:ne.getData("block_id"),e=(ae=s.dataTransfer)==null?void 0:ae.getData("task_id"),x=parseFloat(((oe=s.dataTransfer)==null?void 0:oe.getData("estimate_hours"))??"1")||1,g=parseFloat(((se=s.dataTransfer)==null?void 0:se.getData("block_duration_ms"))??"0"),Y=s.currentTarget.getBoundingClientRect(),q=s.clientY-Y.top,K=ue(q/G,15),ge=Math.max(0,Math.min(K,12*60)),F=new Date(v);F.setHours(Re,0,0,0),F.setMinutes(F.getMinutes()+ge);const X=F.toISOString();if(c&&g>0){const pe=new Date(F.getTime()+g).toISOString();try{await a.updateBlock(c,{start_at:X,end_at:pe}),await t.fetchCurrentView()}catch(_e){console.error("Failed to move block:",_e)}return}if(!e)return;const J=new Date(F);J.setMinutes(J.getMinutes()+Math.round(x*60));const ee=J.toISOString(),te=`temp_${Date.now()}`,ke={kind:"planned",id:te,project_id:null,job_number:"",display_name:"Loading...",start_at:X,end_at:ee,title:"",color_hue:260,tags:[],task_id:e,session_id:null,manual_entry_id:null};t.addBlock(ke);try{await a.createBlock(e,{start_at:X,end_at:ee}),await t.fetchCurrentView()}catch(re){t.removeBlock(te),console.error("Failed to create task block:",re)}}let r=0,_="",b=null;function $(v,s){s.preventDefault(),s.stopPropagation(),h.value=v,b=v,r=s.clientY,_=v.end_at,d.value=v.end_at;const c=x=>{if(!b)return;const g=x.clientY-r,B=ue(g/G,15),q=new Date(_).getTime()+B*6e4,K=new Date(b.start_at).getTime()+15*6e4;d.value=new Date(Math.max(q,K)).toISOString()},e=async()=>{if(document.removeEventListener("mousemove",c),document.removeEventListener("mouseup",e),!b||!d.value){h.value=null;return}const x=b.id,g=d.value;if(g===_){h.value=null,d.value=null;return}try{b.task_id&&await a.updateBlock(x,{start_at:b.start_at,end_at:g}),t.updateBlock({...b,end_at:g})}catch(B){console.error("Failed to resize block:",B),t.updateBlock({...b,end_at:_})}h.value=null,d.value=null,b=null};document.addEventListener("mousemove",c),document.addEventListener("mouseup",e)}return{draggingTaskId:o,dragOverDay:m,resizingBlock:h,resizePreviewEnd:d,onDragStart:w,onBlockDragStart:y,onDragOver:i,onDragLeave:u,onDrop:n,onResizeStart:$}}function He(a){return`hsla(${a}, 65%, 45%, 0.85)`}function Oe(a){return`hsla(${a}, 65%, 55%, 1)`}const Ie=["draggable"],Ae={class:"px-1.5 py-1 h-full flex flex-col text-white overflow-hidden"},Ne={class:"text-xs font-semibold leading-tight truncate"},Ye={key:0,class:"text-xs opacity-75 truncate"},We={key:1,class:"text-xs opacity-75 mt-auto"},Ue=A({__name:"CalendarBlock",props:{block:{},lane:{},totalLanes:{},top:{},height:{},resizeEnd:{}},emits:["resizeStart","click","blockDragStart"],setup(a,{emit:t}){const o=a,m=t,h=E(()=>o.resizeEnd?new Date(o.resizeEnd):new Date(o.block.end_at)),d=E(()=>{if(!o.resizeEnd)return o.height;const n=(h.value.getTime()-new Date(o.block.start_at).getTime())/6e4;return Math.max(n*(40/30),20)}),w=E(()=>{const u=h.value.getTime()-new Date(o.block.start_at).getTime();return W(u/36e5)}),y=E(()=>{const u=`calc(${100/o.totalLanes}% - 2px)`,n=`calc(${o.lane/o.totalLanes*100}% + 1px)`;return{top:`${o.top}px`,height:`${d.value}px`,width:u,left:n,backgroundColor:He(o.block.color_hue),borderColor:Oe(o.block.color_hue)}}),i=E(()=>d.value<40);return(u,n)=>(f(),k("div",{class:I(["absolute rounded overflow-hidden cursor-pointer select-none group",{"border-2":a.block.kind==="session","border-2 border-dashed opacity-80":a.block.kind==="planned","border-2 calendar-block--manual":a.block.kind==="manual"}]),draggable:a.block.kind==="planned"&&!!a.block.task_id,style:j(y.value),onClick:n[1]||(n[1]=r=>m("click",a.block)),onDragstart:n[2]||(n[2]=r=>a.block.kind==="planned"&&a.block.task_id?m("blockDragStart",a.block,r):void 0)},[l("div",Ae,[l("p",Ne,D(a.block.kind==="planned"&&a.block.title?a.block.title:a.block.display_name),1),!i.value&&a.block.job_number?(f(),k("p",Ye,D(a.block.job_number),1)):M("",!0),i.value?M("",!0):(f(),k("p",We,D(w.value),1))]),l("div",{class:"absolute bottom-0 left-0 right-0 h-2 cursor-s-resize opacity-0 group-hover:opacity-100 flex items-center justify-center",onMousedown:n[0]||(n[0]=fe(r=>m("resizeStart",r),["stop"]))},[...n[3]||(n[3]=[l("div",{class:"w-8 h-0.5 bg-white/60 rounded"},null,-1)])],32)],46,Ie))}}),Ge=Te(Ue,[["__scopeId","data-v-7d0575a8"]]),qe={class:"flex overflow-auto h-full"},Ke={class:"flex flex-1 gap-px min-w-0"},Xe=["onDragover","onDrop"],Je={key:1,class:"absolute inset-0 bg-primary/10 pointer-events-none z-0"},z=7,Q=19,H=40,Qe=A({__name:"CalendarGrid",emits:["blockClick"],setup(a,{emit:t}){const o=Array.from({length:Q-z+1},(b,$)=>z+$),m=N(),h=me(),d=t,w=E(()=>m.view==="week"?m.weekDays:[m.currentDate]),y=S(new Date);function i(b){const $=m.getBlocksForDay(b);return Be($)}function u(b){return Ee(new Date(b.start_at),z)}function n(b){return ze(new Date(b.start_at),new Date(b.end_at))}function r(b){var $;return(($=h.resizingBlock.value)==null?void 0:$.id)===b.id}function _(b){return b===12?"12 PM":b>12?`${b-12} PM`:`${b} AM`}return(b,$)=>(f(),k("div",qe,[l("div",{class:"w-12 shrink-0 relative",style:j({height:`${(Q-z+1)*H*2}px`})},[(f(!0),k(L,null,V(p(o),v=>(f(),k("div",{key:v,class:"absolute right-2 text-xs text-muted-foreground",style:j({top:`${(v-z)*H*2-6}px`})},D(_(v)),5))),128))],4),l("div",Ke,[(f(!0),k(L,null,V(w.value,v=>(f(),k("div",{key:p(S)(v),class:I(["flex-1 relative border-l border-border",{"bg-primary/5":p(S)(v)===p(y)}]),style:j({height:`${(Q-z)*H*2}px`}),onDragover:s=>p(h).onDragOver(v,s),onDragleave:$[1]||($[1]=s=>p(h).onDragLeave()),onDrop:s=>p(h).onDrop(v,s)},[p(m).view==="week"?(f(),k("div",{key:0,class:I(["sticky top-0 z-10 text-center py-1 text-xs font-medium border-b border-border bg-background",p(S)(v)===p(y)?"text-primary":"text-muted-foreground"])},[l("div",null,D(p(P)(v,"EEE")),1),l("div",{class:I(["inline-flex h-6 w-6 mx-auto items-center justify-center rounded-full text-sm",p(S)(v)===p(y)?"bg-primary text-primary-foreground":""])},D(p(P)(v,"d")),3)],2)):M("",!0),(f(!0),k(L,null,V(p(o),s=>(f(),k("div",{key:s,class:"absolute left-0 right-0 border-t border-border/40",style:j({top:`${(s-z)*H*2}px`})},null,4))),128)),(f(!0),k(L,null,V(p(o).slice(0,-1),s=>(f(),k("div",{key:`half-${s}`,class:"absolute left-0 right-0 border-t border-border/20",style:j({top:`${(s-z)*H*2+H}px`})},null,4))),128)),p(h).dragOverDay.value===p(S)(v)?(f(),k("div",Je)):M("",!0),(f(!0),k(L,null,V(i(v),({block:s,lane:c,totalLanes:e})=>(f(),ce(Ge,{key:s.id,block:s,lane:c,"total-lanes":e,top:u(s),height:n(s),"resize-end":r(s)?p(h).resizePreviewEnd.value:null,onClick:x=>d("blockClick",s),onResizeStart:x=>p(h).onResizeStart(s,x),onBlockDragStart:$[0]||($[0]=(x,g)=>p(h).onBlockDragStart(x,g))},null,8,["block","lane","total-lanes","top","height","resize-end","onClick","onResizeStart"]))),128))],46,Xe))),128))])]))}}),Ze={class:"flex flex-col h-full bg-card border-l border-border"},et={class:"p-3 border-b border-border flex items-center justify-between shrink-0"},tt={class:"flex-1 overflow-y-auto p-2 space-y-1.5"},nt={key:0,class:"text-xs text-muted-foreground p-2"},at={key:1,class:"text-xs text-muted-foreground p-2 text-center"},ot=["onDragstart"],st={class:"flex items-start gap-2"},rt={class:"flex-1 min-w-0"},lt={class:"text-xs font-medium text-foreground leading-tight truncate"},it={class:"flex items-center gap-1.5 mt-1 flex-wrap"},ut={key:0,class:"text-xs text-muted-foreground"},dt={key:0,class:"p-3 border-t border-border shrink-0"},ct={class:"space-y-1"},ft={class:"text-muted-foreground truncate max-w-[100px]"},vt={class:"text-foreground"},mt=A({__name:"PlannerSidebar",emits:["createTask"],setup(a,{emit:t}){const o=Z(),m=N(),h=me(),d=t,w=E(()=>S(m.currentDate));ve(()=>{o.fetchForDate(w.value)});const y=n=>({todo:"outline",doing:"default",testing:"warning",done:"success",cancelled:"secondary"})[n],i=n=>n>=4?"bg-red-500":n===3?"bg-amber-500":"bg-emerald-500",u=E(()=>{const n={};for(const r of o.tasks){const _=r.project_id??"_none";n[_]||(n[_]={name:r.project_id?_:"No Project",planned:0,actual:0}),n[_].planned+=r.estimate_hours??0,n[_].actual+=r.actual_hours??0}return Object.values(n)});return(n,r)=>(f(),k("div",Ze,[l("div",et,[r[2]||(r[2]=l("h3",{class:"text-sm font-semibold text-foreground"},"Planner",-1)),C(U,{size:"sm",variant:"ghost",onClick:r[0]||(r[0]=_=>d("createTask"))},{default:O(()=>[...r[1]||(r[1]=[l("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[l("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 4v16m8-8H4"})],-1)])]),_:1})]),l("div",tt,[p(o).loading?(f(),k("div",nt,"Loading...")):p(o).tasks.length===0?(f(),k("div",at," No tasks for today ")):M("",!0),(f(!0),k(L,null,V(p(o).tasks,_=>(f(),k("div",{key:_.id,class:"rounded-md border border-border bg-background p-2 cursor-grab active:cursor-grabbing hover:border-primary/50 transition-colors",draggable:"true",onDragstart:b=>p(h).onDragStart(_,b)},[l("div",st,[l("div",{class:I(["h-2 w-2 rounded-full mt-1.5 shrink-0",i(_.priority)])},null,2),l("div",rt,[l("p",lt,D(_.title),1),l("div",it,[C(Se,{variant:y(_.status),class:"text-xs py-0"},{default:O(()=>[de(D(_.status),1)]),_:2},1032,["variant"]),_.estimate_hours?(f(),k("span",ut,D(p(W)(_.estimate_hours)),1)):M("",!0)])])])],40,ot))),128))]),u.value.length?(f(),k("div",dt,[r[3]||(r[3]=l("p",{class:"text-xs font-medium text-muted-foreground mb-2"},"Plan vs Actual",-1)),l("div",ct,[(f(!0),k(L,null,V(u.value,_=>(f(),k("div",{key:_.name,class:"flex items-center justify-between text-xs"},[l("span",ft,D(_.name),1),l("span",vt,D(p(W)(_.planned))+" / "+D(p(W)(_.actual)),1)]))),128))])])):M("",!0)]))}}),gt={class:"h-full flex flex-col"},kt={class:"p-4 border-b border-border flex items-center gap-3 flex-wrap"},pt={class:"flex items-center gap-2 ml-auto"},_t={class:"flex-1 flex overflow-hidden"},bt={class:"flex-1 overflow-auto"},xt={key:0,class:"w-56 shrink-0 overflow-hidden"},ht={class:"bg-card border border-border rounded-lg shadow-xl p-4 w-72"},wt={class:"flex items-start justify-between gap-2 mb-3"},yt={class:"font-semibold text-sm text-foreground"},Dt={key:0,class:"text-xs text-muted-foreground"},$t={class:"space-y-1 text-xs text-muted-foreground"},Tt={key:0,class:"mt-2 flex flex-wrap gap-1"},St={key:1,class:"mt-3 pt-3 border-t border-border flex items-center gap-2"},Ct=["disabled"],Mt={key:2,class:"mt-3 pt-3 border-t border-border text-xs text-muted-foreground"},Gt=A({__name:"CalendarView",setup(a){const t=N(),o=Z(),m=we(),h=xe(),d=T(!0),w=T(!1),y=T(null),i=T(null),u=T(!1),n=T(!1),r=T(null);ve(async()=>{const c=h.query.date;c&&(t.currentDate=new Date(c+"T12:00:00"),t.setView("day")),await t.fetchCurrentView()});function _(c){if(c.project_id&&c.kind==="session"){const e=c.start_at.substring(0,10);m.push({name:"project-detail",params:{id:c.project_id,date:e}})}else i.value=c}async function b(c){try{y.value?(await o.update(y.value.id,c),R.success("Task updated")):(await o.create(c),R.success("Task created")),w.value=!1,y.value=null,o.fetchForDate(S(t.currentDate))}catch{R.error("Failed to save task")}}async function $(c){if(c.task_id)try{const e=await he(()=>import("./tasks-caOFGu41.js").then(x=>x.t),__vite__mapDeps([0,1,2])).then(x=>x.tasksApi.get(c.task_id));y.value=e.data,i.value=null,w.value=!0}catch{R.error("Failed to load task")}}function v(c){r.value=c,n.value=!0}async function s(){const c=r.value;if(c){u.value=!0;try{await o.deleteBlock(c.id),t.removeBlock(c.id),i.value=null,R.success("Block deleted")}catch{R.error("Failed to delete block")}finally{u.value=!1,r.value=null}}}return(c,e)=>{var x;return f(),k("div",gt,[l("div",kt,[C(Fe),l("div",pt,[l("button",{class:"text-xs text-muted-foreground hover:text-foreground transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring rounded",onClick:e[0]||(e[0]=g=>d.value=!d.value)},D(d.value?"Hide Planner":"Show Planner"),1)])]),l("div",_t,[l("div",bt,[C(Qe,{onBlockClick:_})]),d.value?(f(),k("div",xt,[C(mt,{onCreateTask:e[1]||(e[1]=g=>w.value=!0)})])):M("",!0)]),i.value?(f(),k("div",{key:0,class:"fixed inset-0 z-40 flex items-center justify-center p-4",onClick:e[5]||(e[5]=fe(g=>i.value=null,["self"]))},[l("div",ht,[l("div",wt,[l("div",null,[l("p",yt,D(i.value.display_name),1),i.value.job_number?(f(),k("p",Dt,D(i.value.job_number),1)):M("",!0)]),l("button",{class:"text-muted-foreground hover:text-foreground",onClick:e[2]||(e[2]=g=>i.value=null)},[...e[8]||(e[8]=[l("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[l("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])])]),l("div",$t,[l("p",null,"Start: "+D(new Date(i.value.start_at).toLocaleString()),1),l("p",null,"End: "+D(new Date(i.value.end_at).toLocaleString()),1),l("p",null,"Type: "+D(i.value.kind),1)]),i.value.tags.length?(f(),k("div",Tt,[(f(!0),k(L,null,V(i.value.tags,g=>(f(),k("span",{key:g.id,class:"px-1.5 py-0.5 rounded text-xs",style:j({background:`${g.color_hex}22`,color:g.color_hex})},D(g.name),5))),128))])):M("",!0),i.value.kind==="planned"?(f(),k("div",St,[l("button",{class:"flex-1 text-xs px-2 py-1.5 rounded bg-muted hover:bg-muted/80 text-foreground transition-colors",onClick:e[3]||(e[3]=g=>$(i.value))},"Edit task"),l("button",{class:"flex-1 text-xs px-2 py-1.5 rounded bg-destructive/10 hover:bg-destructive/20 text-destructive transition-colors",disabled:u.value,onClick:e[4]||(e[4]=g=>v(i.value))},"Delete block",8,Ct)])):(f(),k("p",Mt,D(i.value.kind==="session"?"Session from Claude Code — read-only":"Read-only entry"),1))])])):M("",!0),C(Ce,{open:w.value,task:y.value,"default-date":p(S)(p(t).currentDate),onClose:e[6]||(e[6]=g=>{w.value=!1,y.value=null}),onSave:b},null,8,["open","task","default-date"]),C(Me,{open:n.value,"onUpdate:open":e[7]||(e[7]=g=>n.value=g),title:"Delete block",description:`Delete '${(x=r.value)==null?void 0:x.display_name}'? This action cannot be undone.`,"confirm-label":"Delete",variant:"destructive",onConfirm:s},null,8,["open","description"])])}}});export{Gt as default}; diff --git a/src/static/assets/CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js b/src/static/assets/CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js similarity index 86% rename from src/static/assets/CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js rename to src/static/assets/CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js index 19a0fd7..4984e43 100644 --- a/src/static/assets/CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js +++ b/src/static/assets/CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js @@ -1 +1 @@ -import{c as e}from"./utils-7WVCegLb.js";import{d as o,c as n,n as t,h as c,p,o as l}from"./index-BiYpJJoC.js";const _=o({__name:"Card",props:{class:{}},setup(s){const a=s;return(r,d)=>(l(),n("div",{class:t(c(e)("rounded-lg border bg-card text-card-foreground shadow-sm",a.class))},[p(r.$slots,"default")],2))}}),f=o({__name:"CardContent",props:{class:{}},setup(s){const a=s;return(r,d)=>(l(),n("div",{class:t(c(e)("p-6 pt-0",a.class))},[p(r.$slots,"default")],2))}});export{_,f as a}; +import{c as e}from"./utils-7WVCegLb.js";import{d as o,c as n,n as t,h as c,p,o as l}from"./index-aIsLHJPY.js";const _=o({__name:"Card",props:{class:{}},setup(s){const a=s;return(r,d)=>(l(),n("div",{class:t(c(e)("rounded-lg border bg-card text-card-foreground shadow-sm",a.class))},[p(r.$slots,"default")],2))}}),f=o({__name:"CardContent",props:{class:{}},setup(s){const a=s;return(r,d)=>(l(),n("div",{class:t(c(e)("p-6 pt-0",a.class))},[p(r.$slots,"default")],2))}});export{_,f as a}; diff --git a/src/static/assets/CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js b/src/static/assets/CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js similarity index 87% rename from src/static/assets/CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js rename to src/static/assets/CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js index 22cb2b9..b851d9a 100644 --- a/src/static/assets/CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js +++ b/src/static/assets/CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js @@ -1 +1 @@ -import{c as t}from"./utils-7WVCegLb.js";import{d as n,o,c as r,n as c,h as l,p}from"./index-BiYpJJoC.js";const f=n({__name:"CardHeader",props:{class:{}},setup(s){const e=s;return(a,i)=>(o(),r("div",{class:c(l(t)("flex flex-col space-y-1.5 p-6",e.class))},[p(a.$slots,"default")],2))}}),_=n({__name:"CardTitle",props:{class:{}},setup(s){const e=s;return(a,i)=>(o(),r("h3",{class:c(l(t)("text-lg font-semibold leading-none tracking-tight",e.class))},[p(a.$slots,"default")],2))}});export{f as _,_ as a}; +import{c as t}from"./utils-7WVCegLb.js";import{d as n,o,c as r,n as c,h as l,p}from"./index-aIsLHJPY.js";const f=n({__name:"CardHeader",props:{class:{}},setup(s){const e=s;return(a,i)=>(o(),r("div",{class:c(l(t)("flex flex-col space-y-1.5 p-6",e.class))},[p(a.$slots,"default")],2))}}),_=n({__name:"CardTitle",props:{class:{}},setup(s){const e=s;return(a,i)=>(o(),r("h3",{class:c(l(t)("text-lg font-semibold leading-none tracking-tight",e.class))},[p(a.$slots,"default")],2))}});export{f as _,_ as a}; diff --git a/src/static/assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js b/src/static/assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js similarity index 92% rename from src/static/assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js rename to src/static/assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js index 74849bf..fb22541 100644 --- a/src/static/assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js +++ b/src/static/assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js @@ -1,4 +1,4 @@ -import{d as b,k,w as a,h as o,P as y,o as u,e as t,Q as g,V as h,a as i,X as C,q as s,t as c,Y as T,c as V,i as w,Z as B,$ as L,a0 as N,s as z}from"./index-BiYpJJoC.js";import{_ as m}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{c as A}from"./createLucideIcon-D7qP-VdO.js";/** +import{d as b,k,w as a,h as o,P as y,o as u,e as t,Q as g,V as h,a as i,X as C,q as s,t as c,Y as T,c as V,i as w,Z as B,$ as L,a0 as N,s as z}from"./index-aIsLHJPY.js";import{_ as m}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{c as A}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/DashboardView-Cl3r92sM.js b/src/static/assets/DashboardView-Bg0DXGZC.js similarity index 96% rename from src/static/assets/DashboardView-Cl3r92sM.js rename to src/static/assets/DashboardView-Bg0DXGZC.js index b1bd497..bfda581 100644 --- a/src/static/assets/DashboardView-Cl3r92sM.js +++ b/src/static/assets/DashboardView-Bg0DXGZC.js @@ -1,4 +1,4 @@ -import{d as z,c as a,a as e,F as h,r as w,e as l,w as u,i as F,o,q as k,n as M,t as y,s as b,x as E,y as ee,k as v,h as m,l as K,R as P,j as D,z as T,f as te,A as oe}from"./index-BiYpJJoC.js";import{d as S}from"./dashboard-Ca6WcfdV.js";import{_ as B,a as V}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as A,a as I}from"./CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js";import{_ as se}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{c as q,f as R,i as H}from"./utils-7WVCegLb.js";import{_ as ae}from"./Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js";import{c as U}from"./createLucideIcon-D7qP-VdO.js";import{C as le}from"./calendar-days-DjiBFm4u.js";import{F as re,_ as ne}from"./Progress.vue_vue_type_script_setup_true_lang-CE8EWOvP.js";import{_ as de}from"./Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js";import{u as ie}from"./tasks-DwSuZPNM.js";import{u as ue}from"./devops-y1AYKG_U.js";import"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";const ce={class:"flex flex-wrap items-center gap-3"},me={class:"flex items-center rounded-lg border border-border overflow-hidden bg-muted/30"},ge=["onClick"],fe=["value"],pe=["value"],xe=z({__name:"DateRangeFilter",props:{preset:{},customFrom:{},customTo:{},loading:{type:Boolean}},emits:["update:preset","update:customFrom","update:customTo","apply"],setup(t,{emit:g}){const c=g;return(i,s)=>(o(),a("div",ce,[s[5]||(s[5]=e("h2",{class:"text-base font-semibold text-foreground flex-1 tracking-tight"},"Overview",-1)),e("div",me,[(o(),a(h,null,w(["today","7d","30d","custom"],r=>e("button",{key:r,class:M(["px-3 py-1.5 text-xs font-medium transition-colors",t.preset===r?"bg-primary text-primary-foreground":"text-muted-foreground hover:text-foreground hover:bg-muted/50"]),onClick:p=>c("update:preset",r)},y(r==="today"?"Today":r==="7d"?"7 days":r==="30d"?"30 days":"Custom"),11,ge)),64))]),t.preset==="custom"?(o(),a(h,{key:0},[e("input",{value:t.customFrom,type:"date",class:"h-8 rounded-lg border border-input bg-muted/30 px-2 text-xs text-foreground focus:outline-none focus:ring-1 focus:ring-ring",onInput:s[0]||(s[0]=r=>c("update:customFrom",r.target.value))},null,40,fe),s[4]||(s[4]=e("span",{class:"text-xs text-muted-foreground"},"to",-1)),e("input",{value:t.customTo,type:"date",class:"h-8 rounded-lg border border-input bg-muted/30 px-2 text-xs text-foreground focus:outline-none focus:ring-1 focus:ring-ring",onInput:s[1]||(s[1]=r=>c("update:customTo",r.target.value))},null,40,pe),l(se,{size:"sm",loading:t.loading,onClick:s[2]||(s[2]=r=>c("apply"))},{default:u(()=>[...s[3]||(s[3]=[k("Apply",-1)])]),_:1},8,["loading"])],64)):F("",!0)]))}});/** +import{d as z,c as a,a as e,F as h,r as w,e as l,w as u,i as F,o,q as k,n as M,t as y,s as b,x as E,y as ee,k as v,h as m,l as K,R as P,j as D,z as T,f as te,A as oe}from"./index-aIsLHJPY.js";import{d as S}from"./dashboard-CdOgDJq5.js";import{_ as B,a as V}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as A,a as I}from"./CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js";import{_ as se}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{c as q,f as R,i as H}from"./utils-7WVCegLb.js";import{_ as ae}from"./Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js";import{c as U}from"./createLucideIcon-B5Z2hHtI.js";import{C as le}from"./calendar-days-Bx0aIed-.js";import{F as re,_ as ne}from"./Progress.vue_vue_type_script_setup_true_lang-Fry_ZKRI.js";import{_ as de}from"./Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js";import{u as ie}from"./tasks-caOFGu41.js";import{u as ue}from"./devops-DsTCxAug.js";import"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";const ce={class:"flex flex-wrap items-center gap-3"},me={class:"flex items-center rounded-lg border border-border overflow-hidden bg-muted/30"},ge=["onClick"],fe=["value"],pe=["value"],xe=z({__name:"DateRangeFilter",props:{preset:{},customFrom:{},customTo:{},loading:{type:Boolean}},emits:["update:preset","update:customFrom","update:customTo","apply"],setup(t,{emit:g}){const c=g;return(i,s)=>(o(),a("div",ce,[s[5]||(s[5]=e("h2",{class:"text-base font-semibold text-foreground flex-1 tracking-tight"},"Overview",-1)),e("div",me,[(o(),a(h,null,w(["today","7d","30d","custom"],r=>e("button",{key:r,class:M(["px-3 py-1.5 text-xs font-medium transition-colors",t.preset===r?"bg-primary text-primary-foreground":"text-muted-foreground hover:text-foreground hover:bg-muted/50"]),onClick:p=>c("update:preset",r)},y(r==="today"?"Today":r==="7d"?"7 days":r==="30d"?"30 days":"Custom"),11,ge)),64))]),t.preset==="custom"?(o(),a(h,{key:0},[e("input",{value:t.customFrom,type:"date",class:"h-8 rounded-lg border border-input bg-muted/30 px-2 text-xs text-foreground focus:outline-none focus:ring-1 focus:ring-ring",onInput:s[0]||(s[0]=r=>c("update:customFrom",r.target.value))},null,40,fe),s[4]||(s[4]=e("span",{class:"text-xs text-muted-foreground"},"to",-1)),e("input",{value:t.customTo,type:"date",class:"h-8 rounded-lg border border-input bg-muted/30 px-2 text-xs text-foreground focus:outline-none focus:ring-1 focus:ring-ring",onInput:s[1]||(s[1]=r=>c("update:customTo",r.target.value))},null,40,pe),l(se,{size:"sm",loading:t.loading,onClick:s[2]||(s[2]=r=>c("apply"))},{default:u(()=>[...s[3]||(s[3]=[k("Apply",-1)])]),_:1},8,["loading"])],64)):F("",!0)]))}});/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-DfDWa0N1.js b/src/static/assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-BoAmreBJ.js similarity index 90% rename from src/static/assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-DfDWa0N1.js rename to src/static/assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-BoAmreBJ.js index 5c5f025..e414c86 100644 --- a/src/static/assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-DfDWa0N1.js +++ b/src/static/assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-BoAmreBJ.js @@ -1 +1 @@ -import{u as b}from"./devops-y1AYKG_U.js";import{_ as y}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as k}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as j}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js";import{d as z,s as i,o as d,c as p,F,a as o,h as n,q as v,t as u,i as g,e as c,w,k as U,K as m}from"./index-BiYpJJoC.js";const A={class:"space-y-4"},B={key:0,class:"text-xs text-muted-foreground space-y-1"},I={class:"text-foreground"},N={class:"text-foreground"},O={key:0},P={key:1,class:"text-red-400"},S={class:"grid grid-cols-2 gap-3"},T={class:"space-y-1.5"},$={class:"space-y-1.5"},q={class:"space-y-1.5"},E={class:"flex items-center gap-2"},Q=z({__name:"DevopsConnectForm",setup(K){var x,V;const t=b(),r=i(((x=t.integration)==null?void 0:x.organization)??""),l=i(((V=t.integration)==null?void 0:V.project)??""),s=i(""),f=i(!1),_=i(!1);async function C(){if(!r.value||!l.value||!s.value){m.error("All fields are required");return}f.value=!0;try{await t.saveIntegration({organization:r.value,project:l.value,pat:s.value}),s.value="",m.success("Integration saved")}catch{m.error("Failed to save integration")}finally{f.value=!1}}async function D(){try{await t.deleteIntegration(),r.value="",l.value="",s.value="",m.success("Integration deleted")}catch{m.error("Failed to delete integration")}}return(L,e)=>(d(),p(F,null,[o("div",A,[n(t).integration?(d(),p("div",B,[o("p",null,[e[5]||(e[5]=v(" Connected to ",-1)),o("strong",I,u(n(t).integration.organization),1),e[6]||(e[6]=v(" / ",-1)),o("strong",N,u(n(t).integration.project),1)]),n(t).integration.last_synced_at?(d(),p("p",O," Last synced: "+u(new Date(n(t).integration.last_synced_at).toLocaleString()),1)):g("",!0),n(t).integration.last_sync_error?(d(),p("p",P," Error: "+u(n(t).integration.last_sync_error),1)):g("",!0)])):g("",!0),o("div",S,[o("div",T,[e[7]||(e[7]=o("label",{class:"text-sm font-medium text-foreground"},"Organization",-1)),c(y,{modelValue:r.value,"onUpdate:modelValue":e[0]||(e[0]=a=>r.value=a),placeholder:"myorg"},null,8,["modelValue"])]),o("div",$,[e[8]||(e[8]=o("label",{class:"text-sm font-medium text-foreground"},"Project",-1)),c(y,{modelValue:l.value,"onUpdate:modelValue":e[1]||(e[1]=a=>l.value=a),placeholder:"myproject"},null,8,["modelValue"])])]),o("div",q,[e[9]||(e[9]=o("label",{class:"text-sm font-medium text-foreground"}," Personal Access Token ",-1)),c(y,{modelValue:s.value,"onUpdate:modelValue":e[2]||(e[2]=a=>s.value=a),type:"password",placeholder:"••••••••",autocomplete:"new-password"},null,8,["modelValue"])]),o("div",E,[c(k,{loading:f.value,onClick:C},{default:w(()=>[v(u(n(t).integration?"Update":"Connect"),1)]),_:1},8,["loading"]),n(t).integration?(d(),U(k,{key:0,variant:"destructive",size:"sm",onClick:e[3]||(e[3]=a=>_.value=!0)},{default:w(()=>[...e[10]||(e[10]=[v(" Disconnect ",-1)])]),_:1})):g("",!0)])]),c(j,{open:_.value,"onUpdate:open":e[4]||(e[4]=a=>_.value=a),title:"Disconnect Azure DevOps",description:"This will remove the ADO integration and all synced work items. This action cannot be undone.","confirm-label":"Disconnect","cancel-label":"Cancel",variant:"destructive",onConfirm:D},null,8,["open"])],64))}});export{Q as _}; +import{u as b}from"./devops-DsTCxAug.js";import{_ as y}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{_ as k}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as j}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js";import{d as z,s as i,o as d,c as p,F,a as o,h as n,q as v,t as u,i as g,e as c,w,k as U,K as m}from"./index-aIsLHJPY.js";const A={class:"space-y-4"},B={key:0,class:"text-xs text-muted-foreground space-y-1"},I={class:"text-foreground"},N={class:"text-foreground"},O={key:0},P={key:1,class:"text-red-400"},S={class:"grid grid-cols-2 gap-3"},T={class:"space-y-1.5"},$={class:"space-y-1.5"},q={class:"space-y-1.5"},E={class:"flex items-center gap-2"},Q=z({__name:"DevopsConnectForm",setup(K){var x,V;const t=b(),r=i(((x=t.integration)==null?void 0:x.organization)??""),l=i(((V=t.integration)==null?void 0:V.project)??""),s=i(""),f=i(!1),_=i(!1);async function C(){if(!r.value||!l.value||!s.value){m.error("All fields are required");return}f.value=!0;try{await t.saveIntegration({organization:r.value,project:l.value,pat:s.value}),s.value="",m.success("Integration saved")}catch{m.error("Failed to save integration")}finally{f.value=!1}}async function D(){try{await t.deleteIntegration(),r.value="",l.value="",s.value="",m.success("Integration deleted")}catch{m.error("Failed to delete integration")}}return(L,e)=>(d(),p(F,null,[o("div",A,[n(t).integration?(d(),p("div",B,[o("p",null,[e[5]||(e[5]=v(" Connected to ",-1)),o("strong",I,u(n(t).integration.organization),1),e[6]||(e[6]=v(" / ",-1)),o("strong",N,u(n(t).integration.project),1)]),n(t).integration.last_synced_at?(d(),p("p",O," Last synced: "+u(new Date(n(t).integration.last_synced_at).toLocaleString()),1)):g("",!0),n(t).integration.last_sync_error?(d(),p("p",P," Error: "+u(n(t).integration.last_sync_error),1)):g("",!0)])):g("",!0),o("div",S,[o("div",T,[e[7]||(e[7]=o("label",{class:"text-sm font-medium text-foreground"},"Organization",-1)),c(y,{modelValue:r.value,"onUpdate:modelValue":e[0]||(e[0]=a=>r.value=a),placeholder:"myorg"},null,8,["modelValue"])]),o("div",$,[e[8]||(e[8]=o("label",{class:"text-sm font-medium text-foreground"},"Project",-1)),c(y,{modelValue:l.value,"onUpdate:modelValue":e[1]||(e[1]=a=>l.value=a),placeholder:"myproject"},null,8,["modelValue"])])]),o("div",q,[e[9]||(e[9]=o("label",{class:"text-sm font-medium text-foreground"}," Personal Access Token ",-1)),c(y,{modelValue:s.value,"onUpdate:modelValue":e[2]||(e[2]=a=>s.value=a),type:"password",placeholder:"••••••••",autocomplete:"new-password"},null,8,["modelValue"])]),o("div",E,[c(k,{loading:f.value,onClick:C},{default:w(()=>[v(u(n(t).integration?"Update":"Connect"),1)]),_:1},8,["loading"]),n(t).integration?(d(),U(k,{key:0,variant:"destructive",size:"sm",onClick:e[3]||(e[3]=a=>_.value=!0)},{default:w(()=>[...e[10]||(e[10]=[v(" Disconnect ",-1)])]),_:1})):g("",!0)])]),c(j,{open:_.value,"onUpdate:open":e[4]||(e[4]=a=>_.value=a),title:"Disconnect Azure DevOps",description:"This will remove the ADO integration and all synced work items. This action cannot be undone.","confirm-label":"Disconnect","cancel-label":"Cancel",variant:"destructive",onConfirm:D},null,8,["open"])],64))}});export{Q as _}; diff --git a/src/static/assets/DevopsView-O5QaTl8f.js b/src/static/assets/DevopsView-CWz6iIis.js similarity index 93% rename from src/static/assets/DevopsView-O5QaTl8f.js rename to src/static/assets/DevopsView-CWz6iIis.js index 6170e2a..6d51539 100644 --- a/src/static/assets/DevopsView-O5QaTl8f.js +++ b/src/static/assets/DevopsView-CWz6iIis.js @@ -1 +1 @@ -import{s as $,x as H,d as R,c as l,a as e,t as v,k as A,w as c,n as h,i as p,F as _,r as N,e as k,G as q,j as T,o as r,q as L,z as G,C as E,p as J,A as Q,h as f,K as V}from"./index-BiYpJJoC.js";import{u as Y,d as Z}from"./devops-y1AYKG_U.js";import{_ as ee,a as te}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{a as se,_ as oe}from"./CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js";import{_ as O}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as P}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{_ as re}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as ne}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{_ as ie}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js";import{_ as K}from"./Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js";import{_ as le}from"./DevopsConnectForm.vue_vue_type_script_setup_true_lang-DfDWa0N1.js";import"./utils-7WVCegLb.js";import"./ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js";import"./createLucideIcon-D7qP-VdO.js";function ae(g,a){const y=$(g.value);let x;return H(g,b=>{clearTimeout(x),x=setTimeout(()=>{y.value=b},a)},{deep:!0}),y}const ue={class:"w-full"},de={class:"flex items-center gap-2 mb-2"},ce={class:"text-xs text-muted-foreground"},me={key:0,class:"h-1.5 w-1.5 rounded-full bg-primary"},fe={class:"overflow-x-auto rounded-xl border border-border"},pe={class:"w-full table-fixed border-collapse",style:{"min-width":"600px"}},ve={class:"bg-muted/30"},ge=["onClick"],ye={class:"text-xs font-semibold text-muted-foreground tracking-wide uppercase"},ke=["d"],xe=["onMousedown"],be={key:0},he=["onClick"],_e={class:"text-sm text-foreground truncate block"},we={key:0},Ce=["colspan"],$e=R({__name:"DataTable",props:{columns:{},rows:{},rowKey:{default:"id"}},emits:["rowClick"],setup(g,{emit:a}){const y=g,x=a,b=$(null),w=$("asc"),C=$({}),z=q({}),S=$(!1);y.columns.forEach(o=>{o.width&&(z[o.key]=o.width)});const F=ae(C,250);function B(o){const n=z[o.key]??o.width;return n?`${n}px`:"auto"}function m(o){o.sortable&&(b.value===o.key?w.value=w.value==="asc"?"desc":"asc":(b.value=o.key,w.value="asc"))}function t(o,n,s="auto"){if(o==null&&n==null)return 0;if(o==null)return-1;if(n==null)return 1;if(s==="number")return Number(o)-Number(n);if(s==="date")return new Date(String(o)).getTime()-new Date(String(n)).getTime();if(s==="auto"){const d=Number(o),u=Number(n);if(!isNaN(d)&&!isNaN(u))return d-u}return String(o).localeCompare(String(n))}const j=T(()=>{let o=[...y.rows];for(const[n,s]of Object.entries(F.value))s&&(o=o.filter(d=>String(d[n]??"").toLowerCase().includes(s.toLowerCase())));return o}),i=T(()=>{if(!b.value)return j.value;const o=b.value,n=y.columns.find(s=>s.key===o);return[...j.value].sort((s,d)=>{const u=s[o],I=d[o],M=t(u,I,n==null?void 0:n.type);return w.value==="asc"?M:-M})}),D=T(()=>Object.values(C.value).some(Boolean));let W=null;function U(o,n){if(!o.resizable)return;n.preventDefault(),n.stopPropagation();const s=z[o.key]??o.width??100;W={key:o.key,startX:n.clientX,startW:s};function d(I){if(!W)return;const M=I.clientX-W.startX;z[W.key]=Math.max(o.minWidth??60,W.startW+M)}function u(){W=null,window.removeEventListener("mousemove",d),window.removeEventListener("mouseup",u)}window.addEventListener("mousemove",d),window.addEventListener("mouseup",u)}function X(){C.value={}}return(o,n)=>(r(),l("div",ue,[e("div",de,[e("span",ce,v(i.value.length)+" items",1),n[5]||(n[5]=e("div",{class:"flex-1"},null,-1)),g.columns.some(s=>s.filterable)?(r(),A(O,{key:0,variant:"ghost",size:"sm",class:h(S.value||D.value?"flex items-center gap-1.5 text-primary":"flex items-center gap-1.5"),onClick:n[0]||(n[0]=s=>S.value=!S.value)},{default:c(()=>[n[2]||(n[2]=e("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M3 4a1 1 0 011-1h16a1 1 0 011 1v2a1 1 0 01-.293.707L13 13.414V19a1 1 0 01-.553.894l-4 2A1 1 0 017 21v-7.586L3.293 6.707A1 1 0 013 6V4z"})],-1)),n[3]||(n[3]=L(" Filter ",-1)),D.value?(r(),l("span",me)):p("",!0)]),_:1},8,["class"])):p("",!0),D.value?(r(),A(O,{key:1,variant:"ghost",size:"sm",onClick:X},{default:c(()=>[...n[4]||(n[4]=[L(" Clear ",-1)])]),_:1})):p("",!0)]),e("div",fe,[e("table",pe,[e("colgroup",null,[(r(!0),l(_,null,N(g.columns,s=>(r(),l("col",{key:s.key,style:G({width:B(s)})},null,4))),128))]),e("thead",ve,[e("tr",null,[(r(!0),l(_,null,N(g.columns,s=>(r(),l("th",{key:s.key,class:h(["relative px-3 py-2 text-left group select-none",[s.sortable?"cursor-pointer hover:bg-muted/50":""]]),onClick:d=>m(s)},[e("div",{class:h(["flex items-center gap-1",{"justify-center":s.align==="center","justify-end":s.align==="right"}])},[e("span",ye,v(s.title),1),s.sortable?(r(),l("svg",{key:0,class:h(["h-3 w-3 shrink-0 transition-opacity",b.value===s.key?"opacity-100 text-primary":"opacity-0 group-hover:opacity-40"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:b.value===s.key&&w.value==="desc"?"M19 9l-7 7-7-7":"M5 15l7-7 7 7"},null,8,ke)],2)):p("",!0)],2),s.resizable?(r(),l("div",{key:0,class:"absolute right-0 top-0 bottom-0 w-1 cursor-col-resize opacity-0 group-hover:opacity-100 hover:opacity-100 hover:bg-primary/30 transition-opacity",onMousedown:E(d=>U(s,d),["stop"])},null,40,xe)):p("",!0)],10,ge))),128))]),S.value?(r(),l("tr",be,[(r(!0),l(_,null,N(g.columns,s=>(r(),l("th",{key:`filter-${s.key}`,class:"px-2 pb-2 pt-0"},[s.filterable?(r(),A(re,{key:0,"model-value":C.value[s.key]??"",type:"text",class:"h-7 text-xs py-1",placeholder:"Filter…","onUpdate:modelValue":d=>{C.value[s.key]=d},onClick:n[1]||(n[1]=E(()=>{},["stop"]))},null,8,["model-value","onUpdate:modelValue"])):p("",!0)]))),128))])):p("",!0)]),e("tbody",null,[(r(!0),l(_,null,N(i.value,(s,d)=>(r(),l("tr",{key:String(s[g.rowKey]??d),class:"border-t border-border/50 hover:bg-muted/20 transition-colors cursor-pointer",onClick:u=>x("rowClick",s)},[(r(!0),l(_,null,N(g.columns,u=>(r(),l("td",{key:u.key,class:h(["px-3 py-2",[u.className,u.align==="center"?"text-center":u.align==="right"?"text-right":"text-left"]])},[J(o.$slots,`cell-${u.key}`,{row:s,value:s[u.key]},()=>[e("span",_e,v(s[u.key]??"—"),1)])],2))),128))],8,he))),128)),i.value.length===0?(r(),l("tr",we,[e("td",{colspan:g.columns.length,class:"py-12"},[k(ne,{title:"No items found",description:"Try adjusting your filter.",size:"sm"})],8,Ce)])):p("",!0)])])])]))}}),ze={class:"p-6 space-y-8"},Se={class:"flex items-center justify-between gap-4 flex-wrap"},We={class:"glass-card rounded-xl px-4 py-3 flex items-center gap-3 flex-wrap"},je={class:"text-sm text-foreground"},De={class:"text-foreground"},Ne={key:0,class:"text-xs text-muted-foreground ml-auto"},Ae={key:3,class:"w-full text-xs text-destructive"},Le={key:1,class:"space-y-4"},Me={class:"flex items-center justify-between gap-3 flex-wrap"},Ve={key:0,class:"flex items-center justify-center py-12"},Te={key:1,class:"bg-background rounded-xl shadow-sm border border-border overflow-hidden"},Fe={class:"text-xs font-mono text-muted-foreground"},Be={class:"min-w-0"},Ie={class:"text-sm text-foreground truncate font-medium"},Ee={class:"text-xs text-muted-foreground truncate"},Oe=["title"],Pe={class:"text-xs text-muted-foreground"},Ke={class:"flex items-center gap-1 justify-end"},Re=["onClick"],Ue={key:0,class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},Xe={key:1,class:"h-3.5 w-3.5 animate-spin",fill:"none",viewBox:"0 0 24 24"},He=["href"],at=R({__name:"DevopsView",setup(g){const a=Y(),y=$("All"),x=$(null),b=[{value:"All",label:"All"},{value:"Active",label:"Active"},{value:"Resolved",label:"Resolved"},{value:"Closed",label:"Closed"}];Q(async()=>{await a.fetchIntegration(),a.integration&&await a.fetchWorkItems()});const w=T(()=>y.value==="All"?a.workItems:a.workItems.filter(t=>t.state===y.value)),C=[{key:"ado_id",title:"#",width:70,minWidth:50,sortable:!0,resizable:!0},{key:"title",title:"Title",minWidth:120,sortable:!0,filterable:!0,resizable:!0},{key:"team_project",title:"Project",width:140,minWidth:80,sortable:!0,filterable:!0,resizable:!0},{key:"priority",title:"P",width:60,minWidth:50,sortable:!0,align:"center",resizable:!0},{key:"created_date",title:"Created",width:110,minWidth:80,sortable:!0,resizable:!0},{key:"state",title:"State",width:110,minWidth:80,sortable:!0,filterable:!0,resizable:!0},{key:"id",title:"Actions",width:90,minWidth:80,align:"right"}];async function z(){try{await a.sync(),V.success("Sync complete"),await a.fetchWorkItems()}catch{V.error(a.error??"Sync failed")}}async function S(m,t){if(t.stopPropagation(),!x.value){x.value=m;try{await Z.cloneWorkItem(m),V.success("Cloned to Tasks")}catch{V.error("Failed to clone")}finally{x.value=null}}}function F(m){const t=m??3;return t<=1?"text-red-500 font-bold":t<=2?"text-amber-500 font-semibold":"text-muted-foreground"}function B(m){return m==="Active"||m==="Doing"||m==="In Progress"?"bg-blue-50 text-blue-600 border border-blue-100":m==="Resolved"||m==="Done"||m==="Closed"?"bg-emerald-50 text-emerald-600 border border-emerald-100":"bg-muted text-muted-foreground border border-border"}return(m,t)=>{var j;return r(),l("div",ze,[e("div",Se,[t[3]||(t[3]=e("h2",{class:"text-lg font-semibold text-foreground"},"Azure DevOps",-1)),f(a).integration?(r(),A(O,{key:0,variant:"outline",size:"sm",loading:f(a).syncing,onClick:z},{default:c(()=>[...t[2]||(t[2]=[L(" Sync Now ",-1)])]),_:1},8,["loading"])):p("",!0)]),e("div",We,[f(a).loading&&!f(a).integration?(r(),l(_,{key:0},[k(P,{size:"sm"}),t[4]||(t[4]=e("span",{class:"text-sm text-muted-foreground"},"Loading…",-1))],64)):f(a).integration?(r(),l(_,{key:1},[t[8]||(t[8]=e("div",{class:"h-2 w-2 rounded-full bg-emerald-400 shadow-sm shadow-emerald-200"},null,-1)),e("span",je,[t[5]||(t[5]=L(" Connected to ",-1)),e("strong",De,v(f(a).integration.organization),1),t[6]||(t[6]=e("span",{class:"text-muted-foreground mx-1"},"·",-1)),t[7]||(t[7]=e("span",{class:"text-muted-foreground text-xs"},"all assigned work items",-1))]),f(a).integration.last_synced_at?(r(),l("span",Ne," Last synced: "+v(new Date(f(a).integration.last_synced_at).toLocaleString()),1)):p("",!0)],64)):(r(),l(_,{key:2},[t[9]||(t[9]=e("div",{class:"h-2 w-2 rounded-full bg-muted-foreground/30"},null,-1)),t[10]||(t[10]=e("span",{class:"text-sm text-muted-foreground"},"Not connected",-1))],64)),(j=f(a).integration)!=null&&j.last_sync_error?(r(),l("p",Ae," Error: "+v(f(a).integration.last_sync_error),1)):p("",!0)]),!f(a).integration&&!f(a).loading?(r(),A(ee,{key:0},{default:c(()=>[k(oe,null,{default:c(()=>[k(se,{class:"text-sm"},{default:c(()=>[...t[11]||(t[11]=[L("Connect Azure DevOps",-1)])]),_:1})]),_:1}),k(te,{class:"space-y-4"},{default:c(()=>[k(le)]),_:1})]),_:1})):p("",!0),f(a).integration?(r(),l("div",Le,[e("div",Me,[t[12]||(t[12]=e("h3",{class:"text-sm font-semibold text-foreground"},"Work Items",-1)),k(ie,{modelValue:y.value,"onUpdate:modelValue":t[0]||(t[0]=i=>y.value=i),options:b,"aria-label":"Filter by state"},null,8,["modelValue"])]),f(a).loading?(r(),l("div",Ve,[k(P,{size:"md",class:"text-primary"})])):(r(),l("div",Te,[k($e,{columns:C,rows:w.value,"row-key":"id"},{"cell-ado_id":c(({value:i})=>[e("span",Fe,"#"+v(i),1)]),"cell-title":c(({row:i})=>[e("div",Be,[e("p",Ie,v(i.title),1),e("p",Ee,v(i.type),1)])]),"cell-team_project":c(({value:i})=>[e("span",{class:"text-xs text-muted-foreground truncate block",title:String(i??"")},v(i||"—"),9,Oe)]),"cell-priority":c(({value:i})=>[e("span",{class:h(["text-xs font-semibold",F(i)])}," P"+v(i??3),3)]),"cell-created_date":c(({value:i})=>[e("span",Pe,v(i?new Date(String(i)).toLocaleDateString():"—"),1)]),"cell-state":c(({value:i})=>[e("span",{class:h(["text-xs px-2 py-0.5 rounded-full font-medium",B(String(i??""))])},v(i),3)]),"cell-id":c(({row:i})=>[e("div",Ke,[k(K,{content:"Clone to Tasks"},{default:c(()=>[e("button",{class:h(["p-1.5 rounded-lg text-muted-foreground hover:text-primary hover:bg-primary/10 transition-colors focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",{"opacity-50":x.value===String(i.id)}]),onClick:D=>S(String(i.id),D)},[x.value!==String(i.id)?(r(),l("svg",Ue,[...t[13]||(t[13]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 4v16m8-8H4"},null,-1)])])):(r(),l("svg",Xe,[...t[14]||(t[14]=[e("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"},null,-1),e("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"},null,-1)])]))],10,Re)]),_:2},1024),k(K,{content:"Open in Azure DevOps"},{default:c(()=>[i.url?(r(),l("a",{key:0,href:String(i.url),target:"_blank",rel:"noopener",class:"p-1.5 rounded-lg text-muted-foreground hover:text-blue-500 hover:bg-blue-50 transition-colors focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",onClick:t[1]||(t[1]=E(()=>{},["stop"]))},[...t[15]||(t[15]=[e("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})],-1)])],8,He)):p("",!0)]),_:2},1024)])]),_:1},8,["rows"])]))])):p("",!0)])}}});export{at as default}; +import{s as $,x as H,d as R,c as l,a as e,t as v,k as A,w as c,n as h,i as p,F as _,r as N,e as k,G as q,j as T,o as r,q as L,z as G,C as E,p as J,A as Q,h as f,K as V}from"./index-aIsLHJPY.js";import{u as Y,d as Z}from"./devops-DsTCxAug.js";import{_ as ee,a as te}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{a as se,_ as oe}from"./CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js";import{_ as O}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as P}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{_ as re}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{_ as ne}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{_ as ie}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js";import{_ as K}from"./Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js";import{_ as le}from"./DevopsConnectForm.vue_vue_type_script_setup_true_lang-BoAmreBJ.js";import"./utils-7WVCegLb.js";import"./ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js";import"./createLucideIcon-B5Z2hHtI.js";function ae(g,a){const y=$(g.value);let x;return H(g,b=>{clearTimeout(x),x=setTimeout(()=>{y.value=b},a)},{deep:!0}),y}const ue={class:"w-full"},de={class:"flex items-center gap-2 mb-2"},ce={class:"text-xs text-muted-foreground"},me={key:0,class:"h-1.5 w-1.5 rounded-full bg-primary"},fe={class:"overflow-x-auto rounded-xl border border-border"},pe={class:"w-full table-fixed border-collapse",style:{"min-width":"600px"}},ve={class:"bg-muted/30"},ge=["onClick"],ye={class:"text-xs font-semibold text-muted-foreground tracking-wide uppercase"},ke=["d"],xe=["onMousedown"],be={key:0},he=["onClick"],_e={class:"text-sm text-foreground truncate block"},we={key:0},Ce=["colspan"],$e=R({__name:"DataTable",props:{columns:{},rows:{},rowKey:{default:"id"}},emits:["rowClick"],setup(g,{emit:a}){const y=g,x=a,b=$(null),w=$("asc"),C=$({}),z=q({}),S=$(!1);y.columns.forEach(o=>{o.width&&(z[o.key]=o.width)});const F=ae(C,250);function B(o){const n=z[o.key]??o.width;return n?`${n}px`:"auto"}function m(o){o.sortable&&(b.value===o.key?w.value=w.value==="asc"?"desc":"asc":(b.value=o.key,w.value="asc"))}function t(o,n,s="auto"){if(o==null&&n==null)return 0;if(o==null)return-1;if(n==null)return 1;if(s==="number")return Number(o)-Number(n);if(s==="date")return new Date(String(o)).getTime()-new Date(String(n)).getTime();if(s==="auto"){const d=Number(o),u=Number(n);if(!isNaN(d)&&!isNaN(u))return d-u}return String(o).localeCompare(String(n))}const j=T(()=>{let o=[...y.rows];for(const[n,s]of Object.entries(F.value))s&&(o=o.filter(d=>String(d[n]??"").toLowerCase().includes(s.toLowerCase())));return o}),i=T(()=>{if(!b.value)return j.value;const o=b.value,n=y.columns.find(s=>s.key===o);return[...j.value].sort((s,d)=>{const u=s[o],I=d[o],M=t(u,I,n==null?void 0:n.type);return w.value==="asc"?M:-M})}),D=T(()=>Object.values(C.value).some(Boolean));let W=null;function U(o,n){if(!o.resizable)return;n.preventDefault(),n.stopPropagation();const s=z[o.key]??o.width??100;W={key:o.key,startX:n.clientX,startW:s};function d(I){if(!W)return;const M=I.clientX-W.startX;z[W.key]=Math.max(o.minWidth??60,W.startW+M)}function u(){W=null,window.removeEventListener("mousemove",d),window.removeEventListener("mouseup",u)}window.addEventListener("mousemove",d),window.addEventListener("mouseup",u)}function X(){C.value={}}return(o,n)=>(r(),l("div",ue,[e("div",de,[e("span",ce,v(i.value.length)+" items",1),n[5]||(n[5]=e("div",{class:"flex-1"},null,-1)),g.columns.some(s=>s.filterable)?(r(),A(O,{key:0,variant:"ghost",size:"sm",class:h(S.value||D.value?"flex items-center gap-1.5 text-primary":"flex items-center gap-1.5"),onClick:n[0]||(n[0]=s=>S.value=!S.value)},{default:c(()=>[n[2]||(n[2]=e("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M3 4a1 1 0 011-1h16a1 1 0 011 1v2a1 1 0 01-.293.707L13 13.414V19a1 1 0 01-.553.894l-4 2A1 1 0 017 21v-7.586L3.293 6.707A1 1 0 013 6V4z"})],-1)),n[3]||(n[3]=L(" Filter ",-1)),D.value?(r(),l("span",me)):p("",!0)]),_:1},8,["class"])):p("",!0),D.value?(r(),A(O,{key:1,variant:"ghost",size:"sm",onClick:X},{default:c(()=>[...n[4]||(n[4]=[L(" Clear ",-1)])]),_:1})):p("",!0)]),e("div",fe,[e("table",pe,[e("colgroup",null,[(r(!0),l(_,null,N(g.columns,s=>(r(),l("col",{key:s.key,style:G({width:B(s)})},null,4))),128))]),e("thead",ve,[e("tr",null,[(r(!0),l(_,null,N(g.columns,s=>(r(),l("th",{key:s.key,class:h(["relative px-3 py-2 text-left group select-none",[s.sortable?"cursor-pointer hover:bg-muted/50":""]]),onClick:d=>m(s)},[e("div",{class:h(["flex items-center gap-1",{"justify-center":s.align==="center","justify-end":s.align==="right"}])},[e("span",ye,v(s.title),1),s.sortable?(r(),l("svg",{key:0,class:h(["h-3 w-3 shrink-0 transition-opacity",b.value===s.key?"opacity-100 text-primary":"opacity-0 group-hover:opacity-40"]),fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:b.value===s.key&&w.value==="desc"?"M19 9l-7 7-7-7":"M5 15l7-7 7 7"},null,8,ke)],2)):p("",!0)],2),s.resizable?(r(),l("div",{key:0,class:"absolute right-0 top-0 bottom-0 w-1 cursor-col-resize opacity-0 group-hover:opacity-100 hover:opacity-100 hover:bg-primary/30 transition-opacity",onMousedown:E(d=>U(s,d),["stop"])},null,40,xe)):p("",!0)],10,ge))),128))]),S.value?(r(),l("tr",be,[(r(!0),l(_,null,N(g.columns,s=>(r(),l("th",{key:`filter-${s.key}`,class:"px-2 pb-2 pt-0"},[s.filterable?(r(),A(re,{key:0,"model-value":C.value[s.key]??"",type:"text",class:"h-7 text-xs py-1",placeholder:"Filter…","onUpdate:modelValue":d=>{C.value[s.key]=d},onClick:n[1]||(n[1]=E(()=>{},["stop"]))},null,8,["model-value","onUpdate:modelValue"])):p("",!0)]))),128))])):p("",!0)]),e("tbody",null,[(r(!0),l(_,null,N(i.value,(s,d)=>(r(),l("tr",{key:String(s[g.rowKey]??d),class:"border-t border-border/50 hover:bg-muted/20 transition-colors cursor-pointer",onClick:u=>x("rowClick",s)},[(r(!0),l(_,null,N(g.columns,u=>(r(),l("td",{key:u.key,class:h(["px-3 py-2",[u.className,u.align==="center"?"text-center":u.align==="right"?"text-right":"text-left"]])},[J(o.$slots,`cell-${u.key}`,{row:s,value:s[u.key]},()=>[e("span",_e,v(s[u.key]??"—"),1)])],2))),128))],8,he))),128)),i.value.length===0?(r(),l("tr",we,[e("td",{colspan:g.columns.length,class:"py-12"},[k(ne,{title:"No items found",description:"Try adjusting your filter.",size:"sm"})],8,Ce)])):p("",!0)])])])]))}}),ze={class:"p-6 space-y-8"},Se={class:"flex items-center justify-between gap-4 flex-wrap"},We={class:"glass-card rounded-xl px-4 py-3 flex items-center gap-3 flex-wrap"},je={class:"text-sm text-foreground"},De={class:"text-foreground"},Ne={key:0,class:"text-xs text-muted-foreground ml-auto"},Ae={key:3,class:"w-full text-xs text-destructive"},Le={key:1,class:"space-y-4"},Me={class:"flex items-center justify-between gap-3 flex-wrap"},Ve={key:0,class:"flex items-center justify-center py-12"},Te={key:1,class:"bg-background rounded-xl shadow-sm border border-border overflow-hidden"},Fe={class:"text-xs font-mono text-muted-foreground"},Be={class:"min-w-0"},Ie={class:"text-sm text-foreground truncate font-medium"},Ee={class:"text-xs text-muted-foreground truncate"},Oe=["title"],Pe={class:"text-xs text-muted-foreground"},Ke={class:"flex items-center gap-1 justify-end"},Re=["onClick"],Ue={key:0,class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},Xe={key:1,class:"h-3.5 w-3.5 animate-spin",fill:"none",viewBox:"0 0 24 24"},He=["href"],at=R({__name:"DevopsView",setup(g){const a=Y(),y=$("All"),x=$(null),b=[{value:"All",label:"All"},{value:"Active",label:"Active"},{value:"Resolved",label:"Resolved"},{value:"Closed",label:"Closed"}];Q(async()=>{await a.fetchIntegration(),a.integration&&await a.fetchWorkItems()});const w=T(()=>y.value==="All"?a.workItems:a.workItems.filter(t=>t.state===y.value)),C=[{key:"ado_id",title:"#",width:70,minWidth:50,sortable:!0,resizable:!0},{key:"title",title:"Title",minWidth:120,sortable:!0,filterable:!0,resizable:!0},{key:"team_project",title:"Project",width:140,minWidth:80,sortable:!0,filterable:!0,resizable:!0},{key:"priority",title:"P",width:60,minWidth:50,sortable:!0,align:"center",resizable:!0},{key:"created_date",title:"Created",width:110,minWidth:80,sortable:!0,resizable:!0},{key:"state",title:"State",width:110,minWidth:80,sortable:!0,filterable:!0,resizable:!0},{key:"id",title:"Actions",width:90,minWidth:80,align:"right"}];async function z(){try{await a.sync(),V.success("Sync complete"),await a.fetchWorkItems()}catch{V.error(a.error??"Sync failed")}}async function S(m,t){if(t.stopPropagation(),!x.value){x.value=m;try{await Z.cloneWorkItem(m),V.success("Cloned to Tasks")}catch{V.error("Failed to clone")}finally{x.value=null}}}function F(m){const t=m??3;return t<=1?"text-red-500 font-bold":t<=2?"text-amber-500 font-semibold":"text-muted-foreground"}function B(m){return m==="Active"||m==="Doing"||m==="In Progress"?"bg-blue-50 text-blue-600 border border-blue-100":m==="Resolved"||m==="Done"||m==="Closed"?"bg-emerald-50 text-emerald-600 border border-emerald-100":"bg-muted text-muted-foreground border border-border"}return(m,t)=>{var j;return r(),l("div",ze,[e("div",Se,[t[3]||(t[3]=e("h2",{class:"text-lg font-semibold text-foreground"},"Azure DevOps",-1)),f(a).integration?(r(),A(O,{key:0,variant:"outline",size:"sm",loading:f(a).syncing,onClick:z},{default:c(()=>[...t[2]||(t[2]=[L(" Sync Now ",-1)])]),_:1},8,["loading"])):p("",!0)]),e("div",We,[f(a).loading&&!f(a).integration?(r(),l(_,{key:0},[k(P,{size:"sm"}),t[4]||(t[4]=e("span",{class:"text-sm text-muted-foreground"},"Loading…",-1))],64)):f(a).integration?(r(),l(_,{key:1},[t[8]||(t[8]=e("div",{class:"h-2 w-2 rounded-full bg-emerald-400 shadow-sm shadow-emerald-200"},null,-1)),e("span",je,[t[5]||(t[5]=L(" Connected to ",-1)),e("strong",De,v(f(a).integration.organization),1),t[6]||(t[6]=e("span",{class:"text-muted-foreground mx-1"},"·",-1)),t[7]||(t[7]=e("span",{class:"text-muted-foreground text-xs"},"all assigned work items",-1))]),f(a).integration.last_synced_at?(r(),l("span",Ne," Last synced: "+v(new Date(f(a).integration.last_synced_at).toLocaleString()),1)):p("",!0)],64)):(r(),l(_,{key:2},[t[9]||(t[9]=e("div",{class:"h-2 w-2 rounded-full bg-muted-foreground/30"},null,-1)),t[10]||(t[10]=e("span",{class:"text-sm text-muted-foreground"},"Not connected",-1))],64)),(j=f(a).integration)!=null&&j.last_sync_error?(r(),l("p",Ae," Error: "+v(f(a).integration.last_sync_error),1)):p("",!0)]),!f(a).integration&&!f(a).loading?(r(),A(ee,{key:0},{default:c(()=>[k(oe,null,{default:c(()=>[k(se,{class:"text-sm"},{default:c(()=>[...t[11]||(t[11]=[L("Connect Azure DevOps",-1)])]),_:1})]),_:1}),k(te,{class:"space-y-4"},{default:c(()=>[k(le)]),_:1})]),_:1})):p("",!0),f(a).integration?(r(),l("div",Le,[e("div",Me,[t[12]||(t[12]=e("h3",{class:"text-sm font-semibold text-foreground"},"Work Items",-1)),k(ie,{modelValue:y.value,"onUpdate:modelValue":t[0]||(t[0]=i=>y.value=i),options:b,"aria-label":"Filter by state"},null,8,["modelValue"])]),f(a).loading?(r(),l("div",Ve,[k(P,{size:"md",class:"text-primary"})])):(r(),l("div",Te,[k($e,{columns:C,rows:w.value,"row-key":"id"},{"cell-ado_id":c(({value:i})=>[e("span",Fe,"#"+v(i),1)]),"cell-title":c(({row:i})=>[e("div",Be,[e("p",Ie,v(i.title),1),e("p",Ee,v(i.type),1)])]),"cell-team_project":c(({value:i})=>[e("span",{class:"text-xs text-muted-foreground truncate block",title:String(i??"")},v(i||"—"),9,Oe)]),"cell-priority":c(({value:i})=>[e("span",{class:h(["text-xs font-semibold",F(i)])}," P"+v(i??3),3)]),"cell-created_date":c(({value:i})=>[e("span",Pe,v(i?new Date(String(i)).toLocaleDateString():"—"),1)]),"cell-state":c(({value:i})=>[e("span",{class:h(["text-xs px-2 py-0.5 rounded-full font-medium",B(String(i??""))])},v(i),3)]),"cell-id":c(({row:i})=>[e("div",Ke,[k(K,{content:"Clone to Tasks"},{default:c(()=>[e("button",{class:h(["p-1.5 rounded-lg text-muted-foreground hover:text-primary hover:bg-primary/10 transition-colors focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",{"opacity-50":x.value===String(i.id)}]),onClick:D=>S(String(i.id),D)},[x.value!==String(i.id)?(r(),l("svg",Ue,[...t[13]||(t[13]=[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M12 4v16m8-8H4"},null,-1)])])):(r(),l("svg",Xe,[...t[14]||(t[14]=[e("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"},null,-1),e("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4z"},null,-1)])]))],10,Re)]),_:2},1024),k(K,{content:"Open in Azure DevOps"},{default:c(()=>[i.url?(r(),l("a",{key:0,href:String(i.url),target:"_blank",rel:"noopener",class:"p-1.5 rounded-lg text-muted-foreground hover:text-blue-500 hover:bg-blue-50 transition-colors focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",onClick:t[1]||(t[1]=E(()=>{},["stop"]))},[...t[15]||(t[15]=[e("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[e("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M10 6H6a2 2 0 00-2 2v10a2 2 0 002 2h10a2 2 0 002-2v-4M14 4h6m0 0v6m0-6L10 14"})],-1)])],8,He)):p("",!0)]),_:2},1024)])]),_:1},8,["rows"])]))])):p("",!0)])}}});export{at as default}; diff --git a/src/static/assets/Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js b/src/static/assets/Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js similarity index 95% rename from src/static/assets/Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js rename to src/static/assets/Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js index 23b4af4..a9b16a3 100644 --- a/src/static/assets/Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js +++ b/src/static/assets/Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js @@ -1 +1 @@ -import{x as h,y as b,d as w,A as x,k as g,H as E,e as v,T as C,w as p,o as c,c as u,a,p as m,i as f,n as $,s as B,t as y,I as L}from"./index-BiYpJJoC.js";import{_ as T}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";const j=["[autofocus]","button:not([disabled])","[href]","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(", ");function D(t,d){let r=null;function i(){return t.value?Array.from(t.value.querySelectorAll(j)):[]}function l(s){if(!d.value||!t.value||s.key!=="Tab")return;const e=i();if(!e.length){s.preventDefault();return}const o=e[0],n=e[e.length-1];s.shiftKey?document.activeElement===o&&(s.preventDefault(),n.focus()):document.activeElement===n&&(s.preventDefault(),o.focus())}h(d,s=>{if(s)r=document.activeElement,document.addEventListener("keydown",l),setTimeout(()=>{const e=i();e.length&&e[0].focus()},50);else{document.removeEventListener("keydown",l);const e=r;setTimeout(()=>{e&&"focus"in e&&e.focus()},150)}}),b(()=>{document.removeEventListener("keydown",l)})}const z={key:0,class:"fixed inset-0 z-50 flex items-center justify-center p-4"},A=["aria-label"],F={key:0,class:"flex items-center justify-between p-6 pb-4"},S={class:"text-lg font-semibold text-foreground"},K={key:0,class:"text-sm text-muted-foreground mt-1"},M={class:"px-6 pb-4 max-h-[85vh] overflow-y-auto"},N={key:1,class:"flex justify-end gap-2 px-6 pb-6"},W=w({__name:"Dialog",props:{open:{type:Boolean},title:{},description:{},maxWidth:{default:"max-w-lg"}},emits:["close"],setup(t,{emit:d}){const r=t,i=d,l=B(null),s=L(r,"open");D(l,s);function e(o){o.key==="Escape"&&r.open&&i("close")}return x(()=>document.addEventListener("keydown",e)),b(()=>document.removeEventListener("keydown",e)),(o,n)=>(c(),g(E,{to:"body"},[v(C,{"enter-active-class":"transition-opacity duration-200","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-opacity duration-200","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[t.open?(c(),u("div",z,[a("div",{class:"absolute inset-0 bg-black/60 backdrop-blur-sm",onClick:n[0]||(n[0]=k=>i("close"))}),a("div",{ref_key:"contentRef",ref:l,class:$(["relative w-full bg-card border border-border rounded-lg shadow-xl z-10",t.maxWidth]),role:"dialog","aria-modal":"true","aria-label":t.title},[t.title||o.$slots.header?(c(),u("div",F,[a("div",null,[m(o.$slots,"header",{},()=>[a("h2",S,y(t.title),1),t.description?(c(),u("p",K,y(t.description),1)):f("",!0)])]),v(T,{variant:"ghost",size:"icon",class:"shrink-0",onClick:n[1]||(n[1]=k=>i("close"))},{default:p(()=>[...n[2]||(n[2]=[a("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])]),_:1})])):f("",!0),a("div",M,[m(o.$slots,"default")]),o.$slots.footer?(c(),u("div",N,[m(o.$slots,"footer")])):f("",!0)],10,A)])):f("",!0)]),_:3})]))}});export{W as _}; +import{x as h,y as b,d as w,A as x,k as g,H as E,e as v,T as C,w as p,o as c,c as u,a,p as m,i as f,n as $,s as B,t as y,I as L}from"./index-aIsLHJPY.js";import{_ as T}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";const j=["[autofocus]","button:not([disabled])","[href]","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(", ");function D(t,d){let r=null;function i(){return t.value?Array.from(t.value.querySelectorAll(j)):[]}function l(s){if(!d.value||!t.value||s.key!=="Tab")return;const e=i();if(!e.length){s.preventDefault();return}const o=e[0],n=e[e.length-1];s.shiftKey?document.activeElement===o&&(s.preventDefault(),n.focus()):document.activeElement===n&&(s.preventDefault(),o.focus())}h(d,s=>{if(s)r=document.activeElement,document.addEventListener("keydown",l),setTimeout(()=>{const e=i();e.length&&e[0].focus()},50);else{document.removeEventListener("keydown",l);const e=r;setTimeout(()=>{e&&"focus"in e&&e.focus()},150)}}),b(()=>{document.removeEventListener("keydown",l)})}const z={key:0,class:"fixed inset-0 z-50 flex items-center justify-center p-4"},A=["aria-label"],F={key:0,class:"flex items-center justify-between p-6 pb-4"},S={class:"text-lg font-semibold text-foreground"},K={key:0,class:"text-sm text-muted-foreground mt-1"},M={class:"px-6 pb-4 max-h-[85vh] overflow-y-auto"},N={key:1,class:"flex justify-end gap-2 px-6 pb-6"},W=w({__name:"Dialog",props:{open:{type:Boolean},title:{},description:{},maxWidth:{default:"max-w-lg"}},emits:["close"],setup(t,{emit:d}){const r=t,i=d,l=B(null),s=L(r,"open");D(l,s);function e(o){o.key==="Escape"&&r.open&&i("close")}return x(()=>document.addEventListener("keydown",e)),b(()=>document.removeEventListener("keydown",e)),(o,n)=>(c(),g(E,{to:"body"},[v(C,{"enter-active-class":"transition-opacity duration-200","enter-from-class":"opacity-0","enter-to-class":"opacity-100","leave-active-class":"transition-opacity duration-200","leave-from-class":"opacity-100","leave-to-class":"opacity-0"},{default:p(()=>[t.open?(c(),u("div",z,[a("div",{class:"absolute inset-0 bg-black/60 backdrop-blur-sm",onClick:n[0]||(n[0]=k=>i("close"))}),a("div",{ref_key:"contentRef",ref:l,class:$(["relative w-full bg-card border border-border rounded-lg shadow-xl z-10",t.maxWidth]),role:"dialog","aria-modal":"true","aria-label":t.title},[t.title||o.$slots.header?(c(),u("div",F,[a("div",null,[m(o.$slots,"header",{},()=>[a("h2",S,y(t.title),1),t.description?(c(),u("p",K,y(t.description),1)):f("",!0)])]),v(T,{variant:"ghost",size:"icon",class:"shrink-0",onClick:n[1]||(n[1]=k=>i("close"))},{default:p(()=>[...n[2]||(n[2]=[a("svg",{class:"h-4 w-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[a("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])]),_:1})])):f("",!0),a("div",M,[m(o.$slots,"default")]),o.$slots.footer?(c(),u("div",N,[m(o.$slots,"footer")])):f("",!0)],10,A)])):f("",!0)]),_:3})]))}});export{W as _}; diff --git a/src/static/assets/EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js b/src/static/assets/EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js similarity index 94% rename from src/static/assets/EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js rename to src/static/assets/EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js index 9f538f4..a9c8ae3 100644 --- a/src/static/assets/EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js +++ b/src/static/assets/EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js @@ -1 +1 @@ -import{c as s}from"./utils-7WVCegLb.js";import{_ as k}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{d as w,c as a,n as o,h as r,F as S,r as B,i as n,a as m,t as i,k as l,w as L,o as t,l as f,q as j}from"./index-BiYpJJoC.js";const I=["aria-label"],N={key:0,class:"relative mb-6 flex items-end justify-center gap-2"},V={class:"space-y-2"},$=w({__name:"EmptyState",props:{title:{},description:{},icons:{},actionLabel:{},actionIcon:{},size:{default:"default"}},emits:["action"],setup(e,{emit:x}){const g=x,h={sm:"p-6",default:"p-8",lg:"p-12"},b={sm:"h-9 w-9",default:"h-11 w-11",lg:"h-14 w-14"},v=["z-10 translate-y-1 -rotate-6 group-hover:-translate-x-3 group-hover:-translate-y-1 group-hover:-rotate-12","z-20 group-hover:-translate-y-3","z-10 translate-y-1 rotate-6 group-hover:translate-x-3 group-hover:-translate-y-1 group-hover:rotate-12"],y={sm:"text-sm",default:"text-base",lg:"text-lg"},z={sm:"text-xs",default:"text-sm",lg:"text-base"},C={sm:"h-7 text-xs px-3",default:"",lg:"h-11 text-base px-6"};return(p,c)=>(t(),a("div",{class:o(r(s)("group flex flex-col items-center justify-center text-center","rounded-xl border-2 border-dashed border-border bg-card","transition-all duration-300 hover:border-foreground/30",h[e.size])),role:"status","aria-label":e.title},[e.icons&&e.icons.length?(t(),a("div",N,[(t(!0),a(S,null,B(e.icons.slice(0,3),(d,u)=>(t(),a("div",{key:u,class:o(r(s)("flex items-center justify-center rounded-xl border border-border bg-background shadow-sm","text-muted-foreground transition-all duration-300",b[e.size],v[u]??"z-20"))},[(t(),l(f(d),{class:"h-5 w-5"}))],2))),128))])):n("",!0),m("div",V,[m("h3",{class:o(r(s)("font-semibold text-foreground",y[e.size]))},i(e.title),3),e.description?(t(),a("p",{key:0,class:o(r(s)("text-muted-foreground",z[e.size]))},i(e.description),3)):n("",!0)]),e.actionLabel?(t(),l(k,{key:1,variant:"outline",class:o(r(s)("mt-6",C[e.size])),onClick:c[0]||(c[0]=d=>g("action"))},{default:L(()=>[e.actionIcon?(t(),l(f(e.actionIcon),{key:0,class:"mr-2 h-4 w-4 transition-transform duration-200 group-hover/btn:rotate-90"})):n("",!0),j(" "+i(e.actionLabel),1)]),_:1},8,["class"])):n("",!0)],10,I))}});export{$ as _}; +import{c as s}from"./utils-7WVCegLb.js";import{_ as k}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{d as w,c as a,n as o,h as r,F as S,r as B,i as n,a as m,t as i,k as l,w as L,o as t,l as f,q as j}from"./index-aIsLHJPY.js";const I=["aria-label"],N={key:0,class:"relative mb-6 flex items-end justify-center gap-2"},V={class:"space-y-2"},$=w({__name:"EmptyState",props:{title:{},description:{},icons:{},actionLabel:{},actionIcon:{},size:{default:"default"}},emits:["action"],setup(e,{emit:x}){const g=x,h={sm:"p-6",default:"p-8",lg:"p-12"},b={sm:"h-9 w-9",default:"h-11 w-11",lg:"h-14 w-14"},v=["z-10 translate-y-1 -rotate-6 group-hover:-translate-x-3 group-hover:-translate-y-1 group-hover:-rotate-12","z-20 group-hover:-translate-y-3","z-10 translate-y-1 rotate-6 group-hover:translate-x-3 group-hover:-translate-y-1 group-hover:rotate-12"],y={sm:"text-sm",default:"text-base",lg:"text-lg"},z={sm:"text-xs",default:"text-sm",lg:"text-base"},C={sm:"h-7 text-xs px-3",default:"",lg:"h-11 text-base px-6"};return(p,c)=>(t(),a("div",{class:o(r(s)("group flex flex-col items-center justify-center text-center","rounded-xl border-2 border-dashed border-border bg-card","transition-all duration-300 hover:border-foreground/30",h[e.size])),role:"status","aria-label":e.title},[e.icons&&e.icons.length?(t(),a("div",N,[(t(!0),a(S,null,B(e.icons.slice(0,3),(d,u)=>(t(),a("div",{key:u,class:o(r(s)("flex items-center justify-center rounded-xl border border-border bg-background shadow-sm","text-muted-foreground transition-all duration-300",b[e.size],v[u]??"z-20"))},[(t(),l(f(d),{class:"h-5 w-5"}))],2))),128))])):n("",!0),m("div",V,[m("h3",{class:o(r(s)("font-semibold text-foreground",y[e.size]))},i(e.title),3),e.description?(t(),a("p",{key:0,class:o(r(s)("text-muted-foreground",z[e.size]))},i(e.description),3)):n("",!0)]),e.actionLabel?(t(),l(k,{key:1,variant:"outline",class:o(r(s)("mt-6",C[e.size])),onClick:c[0]||(c[0]=d=>g("action"))},{default:L(()=>[e.actionIcon?(t(),l(f(e.actionIcon),{key:0,class:"mr-2 h-4 w-4 transition-transform duration-200 group-hover/btn:rotate-90"})):n("",!0),j(" "+i(e.actionLabel),1)]),_:1},8,["class"])):n("",!0)],10,I))}});export{$ as _}; diff --git a/src/static/assets/Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js b/src/static/assets/Input.vue_vue_type_script_setup_true_lang-DulGPujX.js similarity index 94% rename from src/static/assets/Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js rename to src/static/assets/Input.vue_vue_type_script_setup_true_lang-DulGPujX.js index ec4b673..1571390 100644 --- a/src/static/assets/Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js +++ b/src/static/assets/Input.vue_vue_type_script_setup_true_lang-DulGPujX.js @@ -1 +1 @@ -import{c as i}from"./utils-7WVCegLb.js";import{d,c as s,n as u,h as m,o as r}from"./index-BiYpJJoC.js";const c=["id","name","type","value","placeholder","disabled","autocomplete","min","max","step"],g=d({__name:"Input",props:{modelValue:{},type:{},placeholder:{},disabled:{type:Boolean},class:{},id:{},name:{},autocomplete:{},min:{},max:{},step:{}},emits:["update:modelValue","change","blur","focus"],setup(e,{emit:n}){const a=e,o=n;return(f,t)=>(r(),s("input",{id:e.id,name:e.name,type:e.type??"text",value:e.modelValue,placeholder:e.placeholder,disabled:e.disabled,autocomplete:e.autocomplete,min:e.min,max:e.max,step:e.step,class:u(m(i)("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm","ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium","placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50",a.class)),onInput:t[0]||(t[0]=l=>o("update:modelValue",l.target.value)),onChange:t[1]||(t[1]=l=>o("change",l.target.value)),onBlur:t[2]||(t[2]=l=>o("blur",l)),onFocus:t[3]||(t[3]=l=>o("focus",l))},null,42,c))}});export{g as _}; +import{c as i}from"./utils-7WVCegLb.js";import{d,c as s,n as u,h as m,o as r}from"./index-aIsLHJPY.js";const c=["id","name","type","value","placeholder","disabled","autocomplete","min","max","step"],g=d({__name:"Input",props:{modelValue:{},type:{},placeholder:{},disabled:{type:Boolean},class:{},id:{},name:{},autocomplete:{},min:{},max:{},step:{}},emits:["update:modelValue","change","blur","focus"],setup(e,{emit:n}){const a=e,o=n;return(f,t)=>(r(),s("input",{id:e.id,name:e.name,type:e.type??"text",value:e.modelValue,placeholder:e.placeholder,disabled:e.disabled,autocomplete:e.autocomplete,min:e.min,max:e.max,step:e.step,class:u(m(i)("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm","ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium","placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50",a.class)),onInput:t[0]||(t[0]=l=>o("update:modelValue",l.target.value)),onChange:t[1]||(t[1]=l=>o("change",l.target.value)),onBlur:t[2]||(t[2]=l=>o("blur",l)),onFocus:t[3]||(t[3]=l=>o("focus",l))},null,42,c))}});export{g as _}; diff --git a/src/static/assets/KeysView-x4Ow5p_D.js b/src/static/assets/KeysView-D20WCgag.js similarity index 87% rename from src/static/assets/KeysView-x4Ow5p_D.js rename to src/static/assets/KeysView-D20WCgag.js index 0d0885a..baf7539 100644 --- a/src/static/assets/KeysView-x4Ow5p_D.js +++ b/src/static/assets/KeysView-D20WCgag.js @@ -1,4 +1,4 @@ -import{a as h}from"./admin-BG8iXstk.js";import{_ as N,a as R}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as y}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as B}from"./Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js";import{_ as j}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as D}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{_ as F}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js";import{_ as S}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{d as q,A as z,c as n,a as t,e as o,w as r,s as i,o as l,q as _,h as p,F as M,r as U,t as c,k as T,i as E,K as k}from"./index-BiYpJJoC.js";import{a as V}from"./utils-7WVCegLb.js";import{c as A}from"./createLucideIcon-D7qP-VdO.js";import{P as G}from"./plus-PpKYs9wJ.js";/** +import{a as h}from"./admin-DlFdRGBL.js";import{_ as N,a as R}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as y}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as B}from"./Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js";import{_ as j}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{_ as D}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{_ as F}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js";import{_ as S}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{d as q,A as z,c as n,a as t,e as o,w as r,s as i,o as l,q as _,h as p,F as M,r as U,t as c,k as T,i as E,K as k}from"./index-aIsLHJPY.js";import{a as V}from"./utils-7WVCegLb.js";import{c as A}from"./createLucideIcon-B5Z2hHtI.js";import{P as G}from"./plus-CZK8TJCO.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/LiveView-Drr7Q-W3.js b/src/static/assets/LiveView-DS0o7b1g.js similarity index 90% rename from src/static/assets/LiveView-Drr7Q-W3.js rename to src/static/assets/LiveView-DS0o7b1g.js index cb0dac2..9944cb6 100644 --- a/src/static/assets/LiveView-Drr7Q-W3.js +++ b/src/static/assets/LiveView-DS0o7b1g.js @@ -1,4 +1,4 @@ -import{y as J,s as b,d as M,u as O,A as V,c as f,a as i,n as k,h as o,t as v,k as N,w as g,i as C,e as _,o as l,q as j,F as B,r as F,j as I}from"./index-BiYpJJoC.js";import{_ as R,a as z}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as L}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as S}from"./Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js";import{_ as A}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{c as D}from"./createLucideIcon-D7qP-VdO.js";import{Z as U}from"./zap-CGuBGf0F.js";import"./utils-7WVCegLb.js";import"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";/** +import{y as J,s as b,d as M,u as O,A as V,c as f,a as i,n as k,h as o,t as v,k as N,w as g,i as C,e as _,o as l,q as j,F as B,r as F,j as I}from"./index-aIsLHJPY.js";import{_ as R,a as z}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as L}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as S}from"./Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js";import{_ as A}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{c as D}from"./createLucideIcon-B5Z2hHtI.js";import{Z as U}from"./zap-BQ6FEFi3.js";import"./utils-7WVCegLb.js";import"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/LoginView-DmmhvYTb.js b/src/static/assets/LoginView-Dy4ecRek.js similarity index 94% rename from src/static/assets/LoginView-DmmhvYTb.js rename to src/static/assets/LoginView-Dy4ecRek.js index a9a459e..79f006f 100644 --- a/src/static/assets/LoginView-DmmhvYTb.js +++ b/src/static/assets/LoginView-Dy4ecRek.js @@ -1 +1 @@ -import{d as h,u as f,c as o,a as e,b as g,e as a,w as d,o as i,f as m,g as p,h as r,t as x,i as b}from"./index-BiYpJJoC.js";import{_ as v,a as w}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import"./utils-7WVCegLb.js";const y={class:"min-h-screen flex items-center justify-center bg-background p-4"},_={class:"w-full max-w-sm"},k={class:"space-y-4"},C={key:0,class:"rounded-md bg-destructive/10 border border-destructive/30 px-3 py-2 text-sm text-destructive"},B=["disabled"],V={key:0},S={key:1},M=h({__name:"LoginView",setup(F){const l=m(),c=p(),s=f();async function u(){try{await s.loginWithMicrosoft();const n=c.query.redirect;l.push(n??"/")}catch{}}return(n,t)=>(i(),o("div",y,[e("div",_,[t[2]||(t[2]=g('

CC Dashboard

Corporate Planning Hub

',1)),a(v,null,{default:d(()=>[a(w,{class:"pt-6"},{default:d(()=>[e("div",k,[r(s).error?(i(),o("div",C,x(r(s).error),1)):b("",!0),e("button",{type:"button",disabled:r(s).loading,class:"w-full flex items-center justify-center gap-3 rounded-md border border-border bg-white px-4 py-2.5 text-sm font-medium text-gray-700 shadow-sm hover:bg-gray-50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:opacity-50 disabled:cursor-not-allowed transition-colors",onClick:u},[t[0]||(t[0]=e("svg",{class:"h-5 w-5 shrink-0",viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("rect",{x:"1",y:"1",width:"9",height:"9",fill:"#F25022"}),e("rect",{x:"11",y:"1",width:"9",height:"9",fill:"#7FBA00"}),e("rect",{x:"1",y:"11",width:"9",height:"9",fill:"#00A4EF"}),e("rect",{x:"11",y:"11",width:"9",height:"9",fill:"#FFB900"})],-1)),r(s).loading?(i(),o("span",V,"Signing in…")):(i(),o("span",S,"Sign in with Microsoft"))],8,B),t[1]||(t[1]=e("p",{class:"text-center text-xs text-muted-foreground"}," Use your @oliver.agency account ",-1))])]),_:1})]),_:1})])]))}});export{M as default}; +import{d as h,u as f,c as o,a as e,b as g,e as a,w as d,o as i,f as m,g as p,h as r,t as x,i as b}from"./index-aIsLHJPY.js";import{_ as v,a as w}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import"./utils-7WVCegLb.js";const y={class:"min-h-screen flex items-center justify-center bg-background p-4"},_={class:"w-full max-w-sm"},k={class:"space-y-4"},C={key:0,class:"rounded-md bg-destructive/10 border border-destructive/30 px-3 py-2 text-sm text-destructive"},B=["disabled"],V={key:0},S={key:1},M=h({__name:"LoginView",setup(F){const l=m(),c=p(),s=f();async function u(){try{await s.loginWithMicrosoft();const n=c.query.redirect;l.push(n??"/")}catch{}}return(n,t)=>(i(),o("div",y,[e("div",_,[t[2]||(t[2]=g('

CC Dashboard

Corporate Planning Hub

',1)),a(v,null,{default:d(()=>[a(w,{class:"pt-6"},{default:d(()=>[e("div",k,[r(s).error?(i(),o("div",C,x(r(s).error),1)):b("",!0),e("button",{type:"button",disabled:r(s).loading,class:"w-full flex items-center justify-center gap-3 rounded-md border border-border bg-white px-4 py-2.5 text-sm font-medium text-gray-700 shadow-sm hover:bg-gray-50 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:opacity-50 disabled:cursor-not-allowed transition-colors",onClick:u},[t[0]||(t[0]=e("svg",{class:"h-5 w-5 shrink-0",viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[e("rect",{x:"1",y:"1",width:"9",height:"9",fill:"#F25022"}),e("rect",{x:"11",y:"1",width:"9",height:"9",fill:"#7FBA00"}),e("rect",{x:"1",y:"11",width:"9",height:"9",fill:"#00A4EF"}),e("rect",{x:"11",y:"11",width:"9",height:"9",fill:"#FFB900"})],-1)),r(s).loading?(i(),o("span",V,"Signing in…")):(i(),o("span",S,"Sign in with Microsoft"))],8,B),t[1]||(t[1]=e("p",{class:"text-center text-xs text-muted-foreground"}," Use your @oliver.agency account ",-1))])]),_:1})]),_:1})])]))}});export{M as default}; diff --git a/src/static/assets/OmgView-4RQpS0NB.js b/src/static/assets/OmgView-4RQpS0NB.js new file mode 100644 index 0000000..e61e017 --- /dev/null +++ b/src/static/assets/OmgView-4RQpS0NB.js @@ -0,0 +1,11 @@ +import{D as A,d as W,A as X,K as x,c as k,a as l,e as a,w as d,k as b,h as w,F as Y,r as Z,s as c,o as i,q as I,E as y,t as C,n as O,R as ee,C as te,j as oe}from"./index-aIsLHJPY.js";import{p as le,_ as ne}from"./projects-BYok-JQo.js";import{_ as ae}from"./Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js";import{_ as h}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{_ as V}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as se}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{_ as ie}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js";import{_ as $}from"./Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js";import{_ as re}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{F as de}from"./file-text-CF0U4KSF.js";import{P as ue}from"./plus-CZK8TJCO.js";import{c as S}from"./createLucideIcon-B5Z2hHtI.js";import"./utils-7WVCegLb.js";/** + * @license lucide-vue-next v0.427.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const ce=S("PencilIcon",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);/** + * @license lucide-vue-next v0.427.0 - ISC + * + * This source code is licensed under the ISC license. + * See the LICENSE file in the root directory of this source tree. + */const me=S("Trash2Icon",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]),D={list:()=>A.get("/api/omg"),create:_=>A.post("/api/omg",_),update:(_,r)=>A.patch(`/api/omg/${_}`,r),remove:_=>A.delete(`/api/omg/${_}`)},ve={class:"p-6"},pe={class:"flex items-center gap-3 mb-6"},fe={key:0,class:"flex items-center justify-center h-40"},be={key:2,class:"border border-border rounded-xl overflow-hidden"},xe=["onDblclick"],_e=["onDblclick"],ge=["onDblclick"],ke={key:1,class:"text-xs text-muted-foreground/40 italic"},ye={class:"flex items-center justify-end gap-1"},he={class:"space-y-1.5"},je={class:"grid grid-cols-2 gap-3"},we={class:"space-y-1.5"},Ce={class:"space-y-1.5"},Ve={class:"space-y-1.5"},Te=W({__name:"OmgView",setup(_){const r=c([]),T=c([]),K=c(!1),N=oe(()=>{const o={};for(const e of T.value)e.job_number&&(o[e.job_number.trim()]=e);return o}),E=c(!1),m=c(null),v=c(!1),s=c({name:"",client:"",job_number:"",notes:""}),u=c(null),p=c(""),U=c(!1),B=c(null);X(async()=>{await Promise.all([q(),H()])});async function q(){K.value=!0;try{const o=await D.list();r.value=o.data}catch{x.error("Failed to load entries")}finally{K.value=!1}}async function H(){try{const o=await le.list();T.value=o.data}catch{}}function J(){m.value=null,s.value={name:"",client:"",job_number:"",notes:""},E.value=!0}function R(o){m.value=o,s.value={name:o.name,client:o.client,job_number:o.job_number,notes:o.notes},E.value=!0}function F(){E.value=!1,m.value=null}async function L(){if(s.value.name.trim()){v.value=!0;try{const o={name:s.value.name.trim(),client:s.value.client.trim(),job_number:s.value.job_number.trim(),notes:s.value.notes.trim()};if(m.value){const e=await D.update(m.value.id,o),t=r.value.findIndex(f=>f.id===m.value.id);t!==-1&&(r.value[t]=e.data),x.success("Entry updated")}else{const e=await D.create(o);r.value.push(e.data),r.value.sort((t,f)=>t.name.localeCompare(f.name)),x.success("Entry created")}F()}catch{x.error("Failed to save entry")}finally{v.value=!1}}}function G(o){B.value=o.id,U.value=!0}async function Q(){if(!B.value)return;const o=B.value;B.value=null;try{await D.remove(o),r.value=r.value.filter(e=>e.id!==o),x.success("Entry deleted")}catch{x.error("Failed to delete entry")}}function M(o,e){u.value={id:o.id,field:e},p.value=o[e]}async function g(o){if(!u.value)return;const e=u.value.field,t=p.value.trim();if(t===o[e]){u.value=null;return}try{const f=await D.update(o.id,{[e]:t}),j=r.value.findIndex(P=>P.id===o.id);j!==-1&&(r.value[j]=f.data)}catch{x.error("Failed to update")}u.value=null}function z(){u.value=null}return(o,e)=>(i(),k("div",ve,[l("div",pe,[e[9]||(e[9]=l("h2",{class:"text-lg font-semibold text-foreground flex-1"},"OMG",-1)),a(V,{size:"sm",onClick:J},{default:d(()=>[...e[8]||(e[8]=[l("svg",{class:"h-3.5 w-3.5 mr-1.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[l("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2.5",d:"M12 4v16m8-8H4"})],-1),I(" Add entry ",-1)])]),_:1})]),K.value?(i(),k("div",fe,[a(se,{size:"lg",class:"text-primary"})])):r.value.length===0?(i(),b(re,{key:1,title:"No entries yet",description:'Click "Add entry" to create one.',icons:[w(de),w(ue)],"action-label":"Add entry",onAction:J},null,8,["icons"])):(i(),k("div",be,[e[10]||(e[10]=l("div",{class:"grid grid-cols-[1fr_1fr_120px_180px_96px] gap-4 px-4 py-2.5 bg-muted/30 border-b border-border text-xs font-semibold text-muted-foreground uppercase tracking-wide"},[l("span",null,"Project name"),l("span",null,"Client"),l("span",null,"Job #"),l("span",null,"CC Project"),l("span",{class:"text-right"},"Actions")],-1)),(i(!0),k(Y,null,Z(r.value,t=>{var f,j,P;return i(),k("div",{key:t.id,class:"grid grid-cols-[1fr_1fr_120px_180px_96px] gap-4 px-4 py-3 border-b border-border last:border-0 items-center hover:bg-muted/10 transition-colors"},[l("div",null,[((f=u.value)==null?void 0:f.id)===t.id&&u.value.field==="name"?(i(),b(h,{key:0,"model-value":p.value,class:"h-7 border-0 border-b border-primary rounded-none bg-transparent px-0 focus-visible:ring-0 text-sm",autofocus:"","onUpdate:modelValue":e[0]||(e[0]=n=>p.value=n),onBlur:n=>g(t),onKeydown:[y(n=>g(t),["enter"]),y(z,["escape"])]},null,8,["model-value","onBlur","onKeydown"])):(i(),b($,{key:1,content:"Double-click to edit"},{default:d(()=>[l("span",{class:"text-sm font-medium text-foreground cursor-pointer hover:text-primary transition-colors",onDblclick:n=>M(t,"name")},C(t.name),41,xe)]),_:2},1024))]),l("div",null,[((j=u.value)==null?void 0:j.id)===t.id&&u.value.field==="client"?(i(),b(h,{key:0,"model-value":p.value,class:"h-7 border-0 border-b border-primary rounded-none bg-transparent px-0 focus-visible:ring-0 text-sm",autofocus:"","onUpdate:modelValue":e[1]||(e[1]=n=>p.value=n),onBlur:n=>g(t),onKeydown:[y(n=>g(t),["enter"]),y(z,["escape"])]},null,8,["model-value","onBlur","onKeydown"])):(i(),b($,{key:1,content:"Double-click to edit"},{default:d(()=>[l("span",{class:O(["text-sm text-muted-foreground cursor-pointer hover:text-foreground transition-colors",t.client?"":"italic opacity-40"]),onDblclick:n=>M(t,"client")},C(t.client||"No client"),43,_e)]),_:2},1024))]),l("div",null,[((P=u.value)==null?void 0:P.id)===t.id&&u.value.field==="job_number"?(i(),b(h,{key:0,"model-value":p.value,class:"h-7 border-0 border-b border-primary rounded-none bg-transparent px-0 focus-visible:ring-0 text-sm",autofocus:"","onUpdate:modelValue":e[2]||(e[2]=n=>p.value=n),onBlur:n=>g(t),onKeydown:[y(n=>g(t),["enter"]),y(z,["escape"])]},null,8,["model-value","onBlur","onKeydown"])):(i(),b($,{key:1,content:"Double-click to edit"},{default:d(()=>[l("span",{class:O(["text-sm tabular-nums cursor-pointer hover:text-foreground transition-colors",t.job_number?"text-foreground":"text-muted-foreground/40 italic"]),onDblclick:n=>M(t,"job_number")},C(t.job_number||"—"),43,ge)]),_:2},1024))]),l("div",null,[t.job_number&&N.value[t.job_number.trim()]?(i(),b(w(ee),{key:0,to:`/projects/${N.value[t.job_number.trim()].id}`,class:"text-sm text-primary hover:underline truncate block"},{default:d(()=>[I(C(N.value[t.job_number.trim()].display_name),1)]),_:2},1032,["to"])):(i(),k("span",ke,"—"))]),l("div",ye,[a($,{content:"Edit entry"},{default:d(()=>[a(V,{variant:"ghost",size:"icon",class:"text-muted-foreground hover:text-foreground",onClick:n=>R(t)},{default:d(()=>[a(w(ce),{class:"h-4 w-4"})]),_:1},8,["onClick"])]),_:2},1024),a($,{content:"Delete entry"},{default:d(()=>[a(V,{variant:"ghost",size:"icon",class:"text-muted-foreground hover:text-red-500 hover:bg-red-50 dark:hover:bg-red-950/30",onClick:n=>G(t)},{default:d(()=>[a(w(me),{class:"h-4 w-4"})]),_:1},8,["onClick"])]),_:2},1024)])])}),128))])),a(ae,{open:E.value,title:m.value?"Edit Entry":"New Entry","max-width":"max-w-md",onClose:F},{footer:d(()=>[a(V,{variant:"outline",disabled:v.value,onClick:F},{default:d(()=>[...e[15]||(e[15]=[I("Cancel",-1)])]),_:1},8,["disabled"]),a(V,{loading:v.value,onClick:L},{default:d(()=>[I(C(m.value?"Update":"Create"),1)]),_:1},8,["loading"])]),default:d(()=>[l("form",{class:"space-y-4",onSubmit:te(L,["prevent"])},[l("div",he,[e[11]||(e[11]=l("label",{class:"text-sm font-medium text-foreground"},"Project name *",-1)),a(h,{modelValue:s.value.name,"onUpdate:modelValue":e[3]||(e[3]=t=>s.value.name=t),placeholder:"Project name...",disabled:v.value,autofocus:""},null,8,["modelValue","disabled"])]),l("div",je,[l("div",we,[e[12]||(e[12]=l("label",{class:"text-sm font-medium text-foreground"},"Client",-1)),a(h,{modelValue:s.value.client,"onUpdate:modelValue":e[4]||(e[4]=t=>s.value.client=t),placeholder:"Client...",disabled:v.value},null,8,["modelValue","disabled"])]),l("div",Ce,[e[13]||(e[13]=l("label",{class:"text-sm font-medium text-foreground"},"Job #",-1)),a(h,{modelValue:s.value.job_number,"onUpdate:modelValue":e[5]||(e[5]=t=>s.value.job_number=t),placeholder:"J-001",disabled:v.value},null,8,["modelValue","disabled"])])]),l("div",Ve,[e[14]||(e[14]=l("label",{class:"text-sm font-medium text-foreground"},"Notes",-1)),a(ne,{modelValue:s.value.notes,"onUpdate:modelValue":e[6]||(e[6]=t=>s.value.notes=t),placeholder:"Additional notes...",disabled:v.value},null,8,["modelValue","disabled"])])],32)]),_:1},8,["open","title"]),a(ie,{open:U.value,"onUpdate:open":e[7]||(e[7]=t=>U.value=t),title:"Delete entry",description:"This action cannot be undone.",onConfirm:Q},null,8,["open"])]))}});export{Te as default}; diff --git a/src/static/assets/OmgView-BM5Lo3rq.js b/src/static/assets/OmgView-BM5Lo3rq.js deleted file mode 100644 index f8957ee..0000000 --- a/src/static/assets/OmgView-BM5Lo3rq.js +++ /dev/null @@ -1,11 +0,0 @@ -import{D as B,d as G,A as Q,K as b,c as w,a as o,e as a,w as d,k as x,h as I,F as R,r as W,s as c,o as u,q as z,E as k,t as K,n as J,C as X}from"./index-BiYpJJoC.js";import{_ as Y}from"./Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js";import{_ as y}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as Z}from"./Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js";import{_ as C}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as ee}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{_ as te}from"./ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js";import{_ as V}from"./Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js";import{_ as oe}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{F as le}from"./file-text-C0mXX88J.js";import{P as ne}from"./plus-PpKYs9wJ.js";import{c as L}from"./createLucideIcon-D7qP-VdO.js";import"./utils-7WVCegLb.js";/** - * @license lucide-vue-next v0.427.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const ae=L("PencilIcon",[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]]);/** - * @license lucide-vue-next v0.427.0 - ISC - * - * This source code is licensed under the ISC license. - * See the LICENSE file in the root directory of this source tree. - */const se=L("Trash2Icon",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]),$={list:()=>B.get("/api/omg"),create:g=>B.post("/api/omg",g),update:(g,i)=>B.patch(`/api/omg/${g}`,i),remove:g=>B.delete(`/api/omg/${g}`)},ie={class:"p-6"},re={class:"flex items-center gap-3 mb-6"},de={key:0,class:"flex items-center justify-center h-40"},ue={key:2,class:"border border-border rounded-xl overflow-hidden"},ce=["onDblclick"],me=["onDblclick"],ve=["onDblclick"],fe={class:"flex items-center justify-end gap-1"},pe={class:"space-y-1.5"},be={class:"grid grid-cols-2 gap-3"},xe={class:"space-y-1.5"},ge={class:"space-y-1.5"},_e={class:"space-y-1.5"},Ue=G({__name:"OmgView",setup(g){const i=c([]),U=c(!1),j=c(!1),m=c(null),v=c(!1),s=c({name:"",client:"",job_number:"",notes:""}),r=c(null),f=c(""),A=c(!1),D=c(null);Q(O);async function O(){U.value=!0;try{const l=await $.list();i.value=l.data}catch{b.error("Failed to load entries")}finally{U.value=!1}}function P(){m.value=null,s.value={name:"",client:"",job_number:"",notes:""},j.value=!0}function S(l){m.value=l,s.value={name:l.name,client:l.client,job_number:l.job_number,notes:l.notes},j.value=!0}function F(){j.value=!1,m.value=null}async function T(){if(s.value.name.trim()){v.value=!0;try{const l={name:s.value.name.trim(),client:s.value.client.trim(),job_number:s.value.job_number.trim(),notes:s.value.notes.trim()};if(m.value){const e=await $.update(m.value.id,l),t=i.value.findIndex(p=>p.id===m.value.id);t!==-1&&(i.value[t]=e.data),b.success("Entry updated")}else{const e=await $.create(l);i.value.push(e.data),i.value.sort((t,p)=>t.name.localeCompare(p.name)),b.success("Entry created")}F()}catch{b.error("Failed to save entry")}finally{v.value=!1}}}function q(l){D.value=l.id,A.value=!0}async function H(){if(!D.value)return;const l=D.value;D.value=null;try{await $.remove(l),i.value=i.value.filter(e=>e.id!==l),b.success("Entry deleted")}catch{b.error("Failed to delete entry")}}function M(l,e){r.value={id:l.id,field:e},f.value=l[e]}async function _(l){if(!r.value)return;const e=r.value.field,t=f.value.trim();if(t===l[e]){r.value=null;return}try{const p=await $.update(l.id,{[e]:t}),h=i.value.findIndex(E=>E.id===l.id);h!==-1&&(i.value[h]=p.data)}catch{b.error("Failed to update")}r.value=null}function N(){r.value=null}return(l,e)=>(u(),w("div",ie,[o("div",re,[e[9]||(e[9]=o("h2",{class:"text-lg font-semibold text-foreground flex-1"},"OMG",-1)),a(C,{size:"sm",onClick:P},{default:d(()=>[...e[8]||(e[8]=[o("svg",{class:"h-3.5 w-3.5 mr-1.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[o("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2.5",d:"M12 4v16m8-8H4"})],-1),z(" Add entry ",-1)])]),_:1})]),U.value?(u(),w("div",de,[a(ee,{size:"lg",class:"text-primary"})])):i.value.length===0?(u(),x(oe,{key:1,title:"No entries yet",description:'Click "Add entry" to create one.',icons:[I(le),I(ne)],"action-label":"Add entry",onAction:P},null,8,["icons"])):(u(),w("div",ue,[e[10]||(e[10]=o("div",{class:"grid grid-cols-[1fr_1fr_140px_96px] gap-4 px-4 py-2.5 bg-muted/30 border-b border-border text-xs font-semibold text-muted-foreground uppercase tracking-wide"},[o("span",null,"Project name"),o("span",null,"Client"),o("span",null,"Job #"),o("span",{class:"text-right"},"Actions")],-1)),(u(!0),w(R,null,W(i.value,t=>{var p,h,E;return u(),w("div",{key:t.id,class:"grid grid-cols-[1fr_1fr_140px_96px] gap-4 px-4 py-3 border-b border-border last:border-0 items-center hover:bg-muted/10 transition-colors"},[o("div",null,[((p=r.value)==null?void 0:p.id)===t.id&&r.value.field==="name"?(u(),x(y,{key:0,"model-value":f.value,class:"h-7 border-0 border-b border-primary rounded-none bg-transparent px-0 focus-visible:ring-0 text-sm",autofocus:"","onUpdate:modelValue":e[0]||(e[0]=n=>f.value=n),onBlur:n=>_(t),onKeydown:[k(n=>_(t),["enter"]),k(N,["escape"])]},null,8,["model-value","onBlur","onKeydown"])):(u(),x(V,{key:1,content:"Double-click to edit"},{default:d(()=>[o("span",{class:"text-sm font-medium text-foreground cursor-pointer hover:text-primary transition-colors",onDblclick:n=>M(t,"name")},K(t.name),41,ce)]),_:2},1024))]),o("div",null,[((h=r.value)==null?void 0:h.id)===t.id&&r.value.field==="client"?(u(),x(y,{key:0,"model-value":f.value,class:"h-7 border-0 border-b border-primary rounded-none bg-transparent px-0 focus-visible:ring-0 text-sm",autofocus:"","onUpdate:modelValue":e[1]||(e[1]=n=>f.value=n),onBlur:n=>_(t),onKeydown:[k(n=>_(t),["enter"]),k(N,["escape"])]},null,8,["model-value","onBlur","onKeydown"])):(u(),x(V,{key:1,content:"Double-click to edit"},{default:d(()=>[o("span",{class:J(["text-sm text-muted-foreground cursor-pointer hover:text-foreground transition-colors",t.client?"":"italic opacity-40"]),onDblclick:n=>M(t,"client")},K(t.client||"No client"),43,me)]),_:2},1024))]),o("div",null,[((E=r.value)==null?void 0:E.id)===t.id&&r.value.field==="job_number"?(u(),x(y,{key:0,"model-value":f.value,class:"h-7 border-0 border-b border-primary rounded-none bg-transparent px-0 focus-visible:ring-0 text-sm",autofocus:"","onUpdate:modelValue":e[2]||(e[2]=n=>f.value=n),onBlur:n=>_(t),onKeydown:[k(n=>_(t),["enter"]),k(N,["escape"])]},null,8,["model-value","onBlur","onKeydown"])):(u(),x(V,{key:1,content:"Double-click to edit"},{default:d(()=>[o("span",{class:J(["text-sm tabular-nums cursor-pointer hover:text-foreground transition-colors",t.job_number?"text-foreground":"text-muted-foreground/40 italic"]),onDblclick:n=>M(t,"job_number")},K(t.job_number||"—"),43,ve)]),_:2},1024))]),o("div",fe,[a(V,{content:"Edit entry"},{default:d(()=>[a(C,{variant:"ghost",size:"icon",class:"text-muted-foreground hover:text-foreground",onClick:n=>S(t)},{default:d(()=>[a(I(ae),{class:"h-4 w-4"})]),_:1},8,["onClick"])]),_:2},1024),a(V,{content:"Delete entry"},{default:d(()=>[a(C,{variant:"ghost",size:"icon",class:"text-muted-foreground hover:text-red-500 hover:bg-red-50 dark:hover:bg-red-950/30",onClick:n=>q(t)},{default:d(()=>[a(I(se),{class:"h-4 w-4"})]),_:1},8,["onClick"])]),_:2},1024)])])}),128))])),a(Y,{open:j.value,title:m.value?"Edit Entry":"New Entry","max-width":"max-w-md",onClose:F},{footer:d(()=>[a(C,{variant:"outline",disabled:v.value,onClick:F},{default:d(()=>[...e[15]||(e[15]=[z("Cancel",-1)])]),_:1},8,["disabled"]),a(C,{loading:v.value,onClick:T},{default:d(()=>[z(K(m.value?"Update":"Create"),1)]),_:1},8,["loading"])]),default:d(()=>[o("form",{class:"space-y-4",onSubmit:X(T,["prevent"])},[o("div",pe,[e[11]||(e[11]=o("label",{class:"text-sm font-medium text-foreground"},"Project name *",-1)),a(y,{modelValue:s.value.name,"onUpdate:modelValue":e[3]||(e[3]=t=>s.value.name=t),placeholder:"Project name...",disabled:v.value,autofocus:""},null,8,["modelValue","disabled"])]),o("div",be,[o("div",xe,[e[12]||(e[12]=o("label",{class:"text-sm font-medium text-foreground"},"Client",-1)),a(y,{modelValue:s.value.client,"onUpdate:modelValue":e[4]||(e[4]=t=>s.value.client=t),placeholder:"Client...",disabled:v.value},null,8,["modelValue","disabled"])]),o("div",ge,[e[13]||(e[13]=o("label",{class:"text-sm font-medium text-foreground"},"Job #",-1)),a(y,{modelValue:s.value.job_number,"onUpdate:modelValue":e[5]||(e[5]=t=>s.value.job_number=t),placeholder:"J-001",disabled:v.value},null,8,["modelValue","disabled"])])]),o("div",_e,[e[14]||(e[14]=o("label",{class:"text-sm font-medium text-foreground"},"Notes",-1)),a(Z,{modelValue:s.value.notes,"onUpdate:modelValue":e[6]||(e[6]=t=>s.value.notes=t),placeholder:"Additional notes...",disabled:v.value},null,8,["modelValue","disabled"])])],32)]),_:1},8,["open","title"]),a(te,{open:A.value,"onUpdate:open":e[7]||(e[7]=t=>A.value=t),title:"Delete entry",description:"This action cannot be undone.",onConfirm:H},null,8,["open"])]))}});export{Ue as default}; diff --git a/src/static/assets/Progress.vue_vue_type_script_setup_true_lang-CE8EWOvP.js b/src/static/assets/Progress.vue_vue_type_script_setup_true_lang-Fry_ZKRI.js similarity index 90% rename from src/static/assets/Progress.vue_vue_type_script_setup_true_lang-CE8EWOvP.js rename to src/static/assets/Progress.vue_vue_type_script_setup_true_lang-Fry_ZKRI.js index 00a59fd..a5f06de 100644 --- a/src/static/assets/Progress.vue_vue_type_script_setup_true_lang-CE8EWOvP.js +++ b/src/static/assets/Progress.vue_vue_type_script_setup_true_lang-Fry_ZKRI.js @@ -1,4 +1,4 @@ -import{c as r}from"./createLucideIcon-D7qP-VdO.js";import{c as s}from"./utils-7WVCegLb.js";import{d as n,o as c,c as t,n as l,h as d,a as u,z as m}from"./index-BiYpJJoC.js";/** +import{c as r}from"./createLucideIcon-B5Z2hHtI.js";import{c as s}from"./utils-7WVCegLb.js";import{d as n,o as c,c as t,n as l,h as d,a as u,z as m}from"./index-aIsLHJPY.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/ProjectDetailView-DmKhTvpx.js b/src/static/assets/ProjectDetailView-ZLh0yx2w.js similarity index 92% rename from src/static/assets/ProjectDetailView-DmKhTvpx.js rename to src/static/assets/ProjectDetailView-ZLh0yx2w.js index 579769a..9720489 100644 --- a/src/static/assets/ProjectDetailView-DmKhTvpx.js +++ b/src/static/assets/ProjectDetailView-ZLh0yx2w.js @@ -1,4 +1,4 @@ -import{d as K,u as W,A as q,c as r,e as a,a as s,F as f,t as d,h as n,i as x,w as i,k as V,g as Q,f as X,s as h,G as Y,o as l,q as _,r as g,z as F,n as T,j as Z,K as E}from"./index-BiYpJJoC.js";import{d as ee}from"./dashboard-Ca6WcfdV.js";import{_ as y,a as b}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as k,a as w}from"./CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js";import{_ as z}from"./Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js";import{_ as S}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as H}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as D}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{_ as I}from"./Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js";import{f as B,b as J}from"./utils-7WVCegLb.js";import{F as te}from"./file-text-C0mXX88J.js";import{c as se}from"./createLucideIcon-D7qP-VdO.js";import{C as oe}from"./calendar-days-DjiBFm4u.js";import"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";/** +import{d as K,u as W,A as q,c as r,e as a,a as s,F as f,t as d,h as n,i as x,w as i,k as V,g as Q,f as X,s as h,G as Y,o as l,q as _,r as g,z as F,n as T,j as Z,K as E}from"./index-aIsLHJPY.js";import{d as ee}from"./dashboard-CdOgDJq5.js";import{_ as y,a as b}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as k,a as w}from"./CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js";import{_ as z}from"./Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js";import{_ as S}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{_ as H}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as D}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{_ as I}from"./Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js";import{f as B,b as J}from"./utils-7WVCegLb.js";import{F as te}from"./file-text-CF0U4KSF.js";import{c as se}from"./createLucideIcon-B5Z2hHtI.js";import{C as oe}from"./calendar-days-Bx0aIed-.js";import"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/ProjectsView-lK4Qdm9A.js b/src/static/assets/ProjectsView-BIEkK9YZ.js similarity index 91% rename from src/static/assets/ProjectsView-lK4Qdm9A.js rename to src/static/assets/ProjectsView-BIEkK9YZ.js index 24aea1b..b84e9ba 100644 --- a/src/static/assets/ProjectsView-lK4Qdm9A.js +++ b/src/static/assets/ProjectsView-BIEkK9YZ.js @@ -1,4 +1,4 @@ -import{d as $,x as L,A as S,c as r,a as e,e as d,h as n,F as g,r as f,b as B,s as m,o,k as F,w as y,t as a,i as l,n as h,f as I}from"./index-BiYpJJoC.js";import{d as N}from"./dashboard-Ca6WcfdV.js";import{a as z,_ as A}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{F as D,_ as G}from"./Progress.vue_vue_type_script_setup_true_lang-CE8EWOvP.js";import{_ as P}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{_ as q}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js";import{_ as M}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{f as v,a as b}from"./utils-7WVCegLb.js";import{c as x}from"./createLucideIcon-D7qP-VdO.js";import{Z as O}from"./zap-CGuBGf0F.js";import"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";/** +import{d as $,x as L,A as S,c as r,a as e,e as d,h as n,F as g,r as f,b as B,s as m,o,k as F,w as y,t as a,i as l,n as h,f as I}from"./index-aIsLHJPY.js";import{d as N}from"./dashboard-CdOgDJq5.js";import{a as z,_ as A}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{F as D,_ as G}from"./Progress.vue_vue_type_script_setup_true_lang-Fry_ZKRI.js";import{_ as P}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{_ as q}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js";import{_ as M}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{f as v,a as b}from"./utils-7WVCegLb.js";import{c as x}from"./createLucideIcon-B5Z2hHtI.js";import{Z as O}from"./zap-BQ6FEFi3.js";import"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/ReportsView-b-OOza6x.js b/src/static/assets/ReportsView-C9gnodtt.js similarity index 98% rename from src/static/assets/ReportsView-b-OOza6x.js rename to src/static/assets/ReportsView-C9gnodtt.js index 8d299f0..bff7f79 100644 --- a/src/static/assets/ReportsView-b-OOza6x.js +++ b/src/static/assets/ReportsView-C9gnodtt.js @@ -1,4 +1,4 @@ -var Ee=Object.defineProperty;var pe=a=>{throw TypeError(a)};var Le=(a,t,e)=>t in a?Ee(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var x=(a,t,e)=>Le(a,typeof t!="symbol"?t+"":t,e),Be=(a,t,e)=>t.has(a)||pe("Cannot "+e);var he=(a,t,e)=>t.has(a)?pe("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(a):t.set(a,e);var D=(a,t,e)=>(Be(a,t,"access private method"),e);import{D as G,d as qe,u as Ze,A as Pe,c as v,a as w,e as z,w as S,h as W,F as Me,r as De,s as E,o as T,q as L,k as ue,t as X,i as fe,n as Qe,K as Q}from"./index-BiYpJJoC.js";import{a as je,_ as Oe}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as de}from"./Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js";import{_ as K}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as Ne}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import{_ as Fe}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js";import{_ as He}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{a as Ue,i as Ve}from"./utils-7WVCegLb.js";import{F as Ge}from"./file-text-C0mXX88J.js";import{C as We}from"./calendar-C9xlMu6k.js";import{_ as Xe}from"./_plugin-vue_export-helper-DlAUqK2U.js";import"./createLucideIcon-D7qP-VdO.js";const ge={list:()=>G.get("/api/reports"),get:a=>G.get(`/api/reports/${a}`),generate:a=>G.post("/api/reports/generate",a)};function ee(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let C=ee();function ye(a){C=a}const $e=/[&<>"']/,Ke=new RegExp($e.source,"g"),_e=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,Je=new RegExp(_e.source,"g"),Ye={"&":"&","<":"<",">":">",'"':""","'":"'"},ke=a=>Ye[a];function b(a,t){if(t){if($e.test(a))return a.replace(Ke,ke)}else if(_e.test(a))return a.replace(Je,ke);return a}const et=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function tt(a){return a.replace(et,(t,e)=>(e=e.toLowerCase(),e==="colon"?":":e.charAt(0)==="#"?e.charAt(1)==="x"?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}const nt=/(^|[^\[])\^/g;function g(a,t){let e=typeof a=="string"?a:a.source;t=t||"";const n={replace:(i,r)=>{let s=typeof r=="string"?r:r.source;return s=s.replace(nt,"$1"),e=e.replace(i,s),n},getRegex:()=>new RegExp(e,t)};return n}function xe(a){try{a=encodeURI(a).replace(/%25/g,"%")}catch{return null}return a}const q={exec:()=>null};function me(a,t){const e=a.replace(/\|/g,(r,s,l)=>{let o=!1,u=s;for(;--u>=0&&l[u]==="\\";)o=!o;return o?"|":" |"}),n=e.split(/ \|/);let i=0;if(n[0].trim()||n.shift(),n.length>0&&!n[n.length-1].trim()&&n.pop(),t)if(n.length>t)n.splice(t);else for(;n.length{throw TypeError(a)};var Le=(a,t,e)=>t in a?Ee(a,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):a[t]=e;var x=(a,t,e)=>Le(a,typeof t!="symbol"?t+"":t,e),Be=(a,t,e)=>t.has(a)||pe("Cannot "+e);var he=(a,t,e)=>t.has(a)?pe("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(a):t.set(a,e);var D=(a,t,e)=>(Be(a,t,"access private method"),e);import{D as G,d as qe,u as Ze,A as Pe,c as v,a as w,e as z,w as S,h as W,F as Me,r as De,s as E,o as T,q as L,k as ue,t as X,i as fe,n as Qe,K as Q}from"./index-aIsLHJPY.js";import{a as je,_ as Oe}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as de}from"./Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js";import{_ as K}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as Ne}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import{_ as Fe}from"./SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js";import{_ as He}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{a as Ue,i as Ve}from"./utils-7WVCegLb.js";import{F as Ge}from"./file-text-CF0U4KSF.js";import{C as We}from"./calendar-CF-bck6k.js";import{_ as Xe}from"./_plugin-vue_export-helper-DlAUqK2U.js";import"./createLucideIcon-B5Z2hHtI.js";const ge={list:()=>G.get("/api/reports"),get:a=>G.get(`/api/reports/${a}`),generate:a=>G.post("/api/reports/generate",a)};function ee(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}let C=ee();function ye(a){C=a}const $e=/[&<>"']/,Ke=new RegExp($e.source,"g"),_e=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,Je=new RegExp(_e.source,"g"),Ye={"&":"&","<":"<",">":">",'"':""","'":"'"},ke=a=>Ye[a];function b(a,t){if(t){if($e.test(a))return a.replace(Ke,ke)}else if(_e.test(a))return a.replace(Je,ke);return a}const et=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function tt(a){return a.replace(et,(t,e)=>(e=e.toLowerCase(),e==="colon"?":":e.charAt(0)==="#"?e.charAt(1)==="x"?String.fromCharCode(parseInt(e.substring(2),16)):String.fromCharCode(+e.substring(1)):""))}const nt=/(^|[^\[])\^/g;function g(a,t){let e=typeof a=="string"?a:a.source;t=t||"";const n={replace:(i,r)=>{let s=typeof r=="string"?r:r.source;return s=s.replace(nt,"$1"),e=e.replace(i,s),n},getRegex:()=>new RegExp(e,t)};return n}function xe(a){try{a=encodeURI(a).replace(/%25/g,"%")}catch{return null}return a}const q={exec:()=>null};function me(a,t){const e=a.replace(/\|/g,(r,s,l)=>{let o=!1,u=s;for(;--u>=0&&l[u]==="\\";)o=!o;return o?"|":" |"}),n=e.split(/ \|/);let i=0;if(n[0].trim()||n.shift(),n.length>0&&!n[n.length-1].trim()&&n.pop(),t)if(n.length>t)n.splice(t);else for(;n.length{const r=i.match(/^\s+/);if(r===null)return i;const[s]=r;return s.length>=n.length?i.slice(n.length):i}).join(` `)}class N{constructor(t){x(this,"options");x(this,"rules");x(this,"lexer");this.options=t||C}space(t){const e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){const e=this.rules.block.code.exec(t);if(e){const n=e[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?n:j(n,` `)}}}fences(t){const e=this.rules.block.fences.exec(t);if(e){const n=e[0],i=it(n,e[3]||"");return{type:"code",raw:n,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:i}}}heading(t){const e=this.rules.block.heading.exec(t);if(e){let n=e[2].trim();if(/#$/.test(n)){const i=j(n,"#");(this.options.pedantic||!i||/ $/.test(i))&&(n=i.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:n,tokens:this.lexer.inline(n)}}}hr(t){const e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:e[0]}}blockquote(t){const e=this.rules.block.blockquote.exec(t);if(e){let n=e[0].replace(/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,` diff --git a/src/static/assets/SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js b/src/static/assets/SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js similarity index 95% rename from src/static/assets/SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js rename to src/static/assets/SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js index 692f605..f7a2762 100644 --- a/src/static/assets/SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js +++ b/src/static/assets/SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js @@ -1 +1 @@ -import{c as d}from"./utils-7WVCegLb.js";import{d as c,c as s,F as m,r as f,o as a,n as p,h as g,k as v,l as b,i as x,q as h,t as k}from"./index-BiYpJJoC.js";const y=["aria-label"],V=["aria-pressed","onClick"],A=c({__name:"SegmentedControl",props:{modelValue:{},options:{},ariaLabel:{}},emits:["update:modelValue"],setup(t,{emit:i}){const o=t,l=i;function u(n){const r=o.options.findIndex(e=>e.value===o.modelValue);if(n.key==="ArrowRight"||n.key==="ArrowDown"){n.preventDefault();const e=o.options[(r+1)%o.options.length];l("update:modelValue",e.value)}else if(n.key==="ArrowLeft"||n.key==="ArrowUp"){n.preventDefault();const e=o.options[(r-1+o.options.length)%o.options.length];l("update:modelValue",e.value)}}return(n,r)=>(a(),s("div",{class:"inline-flex items-center rounded-lg border border-border bg-muted/40 p-1",role:"group","aria-label":t.ariaLabel,onKeydown:u},[(a(!0),s(m,null,f(t.options,e=>(a(),s("button",{key:e.value,type:"button","aria-pressed":t.modelValue===e.value,class:p(g(d)("inline-flex items-center gap-1.5 rounded-md px-3 h-8 text-xs font-medium transition-all","focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",t.modelValue===e.value?"bg-background text-foreground shadow-sm":"text-muted-foreground hover:text-foreground")),onClick:w=>l("update:modelValue",e.value)},[e.icon?(a(),v(b(e.icon),{key:0,class:"h-3.5 w-3.5"})):x("",!0),h(" "+k(e.label),1)],10,V))),128))],40,y))}});export{A as _}; +import{c as d}from"./utils-7WVCegLb.js";import{d as c,c as s,F as m,r as f,o as a,n as p,h as g,k as v,l as b,i as x,q as h,t as k}from"./index-aIsLHJPY.js";const y=["aria-label"],V=["aria-pressed","onClick"],A=c({__name:"SegmentedControl",props:{modelValue:{},options:{},ariaLabel:{}},emits:["update:modelValue"],setup(t,{emit:i}){const o=t,l=i;function u(n){const r=o.options.findIndex(e=>e.value===o.modelValue);if(n.key==="ArrowRight"||n.key==="ArrowDown"){n.preventDefault();const e=o.options[(r+1)%o.options.length];l("update:modelValue",e.value)}else if(n.key==="ArrowLeft"||n.key==="ArrowUp"){n.preventDefault();const e=o.options[(r-1+o.options.length)%o.options.length];l("update:modelValue",e.value)}}return(n,r)=>(a(),s("div",{class:"inline-flex items-center rounded-lg border border-border bg-muted/40 p-1",role:"group","aria-label":t.ariaLabel,onKeydown:u},[(a(!0),s(m,null,f(t.options,e=>(a(),s("button",{key:e.value,type:"button","aria-pressed":t.modelValue===e.value,class:p(g(d)("inline-flex items-center gap-1.5 rounded-md px-3 h-8 text-xs font-medium transition-all","focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",t.modelValue===e.value?"bg-background text-foreground shadow-sm":"text-muted-foreground hover:text-foreground")),onClick:w=>l("update:modelValue",e.value)},[e.icon?(a(),v(b(e.icon),{key:0,class:"h-3.5 w-3.5"})):x("",!0),h(" "+k(e.label),1)],10,V))),128))],40,y))}});export{A as _}; diff --git a/src/static/assets/SettingsView-Dx5EOob_.js b/src/static/assets/SettingsView-Di3_0rdi.js similarity index 94% rename from src/static/assets/SettingsView-Dx5EOob_.js rename to src/static/assets/SettingsView-Di3_0rdi.js index 1e2619d..24bf7fc 100644 --- a/src/static/assets/SettingsView-Dx5EOob_.js +++ b/src/static/assets/SettingsView-Di3_0rdi.js @@ -1 +1 @@ -import{d as G,s as x,o as h,c as _,a as f,e as d,h as v,t as S,F as j,r as L,n as W,j as V,x as re,k as se,w as c,M as ue,N as ie,S as de,i as le,q as w,O as fe,u as ce,A as me,D as ve,K as R}from"./index-BiYpJJoC.js";import{u as pe}from"./devops-y1AYKG_U.js";import{_ as B,a as H}from"./CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js";import{_ as Y,a as K}from"./CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js";import{_ as Q}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as k}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{c as q,i as X}from"./utils-7WVCegLb.js";import{t as b,c as U,s as Z,C as ge,a as be,f as $}from"./format-WqwOLoqz.js";import{C as ye}from"./calendar-C9xlMu6k.js";import{_ as he}from"./DevopsConnectForm.vue_vue_type_script_setup_true_lang-DfDWa0N1.js";import"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import"./createLucideIcon-D7qP-VdO.js";import"./ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js";function _e(l,s){const o=b(l);return isNaN(s)?U(l,NaN):(s&&o.setDate(o.getDate()+s),o)}function ae(l,s){const o=b(l);if(isNaN(s))return U(l,NaN);if(!s)return o;const r=o.getDate(),u=U(l,o.getTime());u.setMonth(o.getMonth()+s+1,0);const i=u.getDate();return r>=i?u:(o.setFullYear(u.getFullYear(),u.getMonth(),r),o)}function xe(l){return U(l,Date.now())}function I(l,s){const o=Z(l),r=Z(s);return+o==+r}function Me(l){const s=b(l),o=s.getMonth();return s.setFullYear(s.getFullYear(),o+1,0),s.setHours(23,59,59,999),s}function we(l,s){const o=b(l.start),r=b(l.end);let u=+o>+r;const i=u?+o:+r,m=u?r:o;m.setHours(0,0,0,0);let g=1;const M=[];for(;+m<=i;)M.push(b(m)),m.setDate(m.getDate()+g),m.setHours(0,0,0,0);return u?M.reverse():M}function A(l){const s=b(l);return s.setDate(1),s.setHours(0,0,0,0),s}function De(l){return b(l).getDay()}function ee(l,s){const o=b(l),r=b(s);return+o<+r}function Ve(l){return I(l,xe(l))}function te(l,s){const o=+b(l),[r,u]=[+b(s.start),+b(s.end)].sort((i,m)=>i-m);return o>=r&&o<=u}function oe(l,s){return _e(l,-s)}function $e(l,s){return ae(l,-1)}const Ce={class:"p-3 select-none"},ke={class:"mb-3 flex items-center justify-between"},Se={class:"text-sm font-medium"},Ne={class:"mb-1 grid grid-cols-7 gap-1"},Te={class:"grid grid-cols-7 gap-1"},Ee=["onClick","onMouseenter","aria-label","aria-pressed"],ne=G({__name:"Calendar",props:{modelValue:{default:()=>({from:null,to:null})},mode:{default:"range"},initialMonth:{}},emits:["update:modelValue"],setup(l,{emit:s}){const o=l,r=s,u=x(o.initialMonth??new Date),i=x(null),m=["Mo","Tu","We","Th","Fr","Sa","Su"],g=V(()=>$(u.value,"MMMM yyyy")),M=V(()=>{const e=A(u.value),n=Me(u.value);return we({start:e,end:n})}),z=V(()=>{const e=De(A(u.value));return e===0?6:e-1});function D(){u.value=$e(u.value)}function a(){u.value=ae(u.value,1)}function p(e){return e.getMonth()!==u.value.getMonth()}function N(e){return Ve(e)}function C(e){return T(e)||E(e)}function T(e){var n;return(n=o.modelValue)!=null&&n.from?I(e,o.modelValue.from):!1}function E(e){var n;return(n=o.modelValue)!=null&&n.to?I(e,o.modelValue.to):!1}function O(e){const{from:n,to:t}=o.modelValue??{};return!n||!t?!1:te(e,{start:n,end:t})&&!I(e,n)&&!I(e,t)}function P(e){var y,J;const n=(y=o.modelValue)==null?void 0:y.from;if(!n||(J=o.modelValue)!=null&&J.to||!i.value)return!1;const t=i.value;return ee(t,n)?!1:te(e,{start:n,end:t})}function F(e){if(o.mode==="single"){r("update:modelValue",{from:e,to:e});return}const{from:n,to:t}=o.modelValue??{};!n||n&&t?r("update:modelValue",{from:e,to:null}):ee(e,n)?r("update:modelValue",{from:e,to:n}):r("update:modelValue",{from:n,to:e})}return(e,n)=>(h(),_("div",Ce,[f("div",ke,[f("button",{type:"button",class:"flex h-8 w-8 items-center justify-center rounded-md hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",onClick:D,"aria-label":"Previous month"},[d(v(ge),{class:"h-4 w-4"})]),f("span",Se,S(g.value),1),f("button",{type:"button",class:"flex h-8 w-8 items-center justify-center rounded-md hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",onClick:a,"aria-label":"Next month"},[d(v(be),{class:"h-4 w-4"})])]),f("div",Ne,[(h(),_(j,null,L(m,t=>f("div",{key:t,class:"flex h-8 items-center justify-center text-[11px] font-medium uppercase tracking-wide text-muted-foreground"},S(t),1)),64))]),f("div",Te,[(h(!0),_(j,null,L(z.value,t=>(h(),_("div",{key:"blank-"+t}))),128)),(h(!0),_(j,null,L(M.value,t=>(h(),_("button",{key:t.toISOString(),type:"button",class:W(v(q)("flex h-9 w-9 items-center justify-center rounded-md text-sm transition-colors","focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",p(t)&&"text-muted-foreground/40",N(t)&&!C(t)&&"ring-1 ring-primary",T(t)&&"rounded-l-md bg-primary text-primary-foreground",E(t)&&"rounded-r-md bg-primary text-primary-foreground",O(t)&&!T(t)&&!E(t)&&"bg-primary/15 rounded-none",P(t)&&!O(t)&&!C(t)&&"bg-primary/10",!C(t)&&!O(t)&&!P(t)&&"hover:bg-accent")),onClick:y=>F(t),onMouseenter:y=>i.value=t,onMouseleave:n[0]||(n[0]=y=>i.value=null),"aria-label":v($)(t,"EEEE, MMMM d, yyyy"),"aria-pressed":C(t)},S(v($)(t,"d")),43,Ee))),128))])]))}}),Oe={class:"flex"},Pe={class:"flex w-36 flex-col border-r border-border p-2 gap-1"},Ie=["onClick"],ze={class:"flex flex-col"},Fe={class:"flex"},Re={class:"border-l border-border"},je={key:0,class:"px-4 pb-2 text-xs text-destructive"},Le={class:"flex items-center justify-end gap-2 border-t border-border px-4 py-3"},Ue=G({__name:"DateRangePicker",props:{modelValue:{default:()=>({from:null,to:null})}},emits:["update:modelValue"],setup(l,{emit:s}){var P,F;const o=l,r=s,u=x(!1),i=x({from:((P=o.modelValue)==null?void 0:P.from)??null,to:((F=o.modelValue)==null?void 0:F.to)??null}),m=new Date,g=V(()=>A(i.value.from??m)),M=V(()=>{const e=new Date(g.value);return e.setMonth(e.getMonth()+1),e}),D=[{value:"today",label:"Today"},{value:"last7",label:"Last 7 days"},{value:"last30",label:"Last 30 days"},{value:"thisMonth",label:"This month"},{value:"custom",label:"Custom"}],a=x("custom");function p(e){if(a.value=e,e==="custom")return;const n=new Date;let t,y;if(e==="today")t=n,y=n;else if(e==="last7")t=oe(n,6),y=n;else if(e==="last30")t=oe(n,29),y=n;else if(e==="thisMonth")t=A(n),y=n;else return;i.value={from:t,to:y}}const N=V(()=>i.value.from&&i.value.to&&i.value.from>i.value.to?"End date must be after start date":null),C=V(()=>i.value.from!==null&&i.value.to!==null&&!N.value),T=V(()=>{const{from:e,to:n}=o.modelValue??{};return e?!n||e.getTime()===n.getTime()?$(e,"MMM d, yyyy"):`${$(e,"MMM d")} – ${$(n,"MMM d, yyyy")}`:"Pick a date range"});function E(){C.value&&(r("update:modelValue",{from:i.value.from,to:i.value.to}),u.value=!1)}function O(){var e,n;i.value={from:((e=o.modelValue)==null?void 0:e.from)??null,to:((n=o.modelValue)==null?void 0:n.to)??null},u.value=!1}return re(()=>o.modelValue,e=>{i.value={from:(e==null?void 0:e.from)??null,to:(e==null?void 0:e.to)??null}},{deep:!0}),(e,n)=>(h(),se(v(fe),{open:u.value,"onUpdate:open":n[2]||(n[2]=t=>u.value=t)},{default:c(()=>[d(v(ue),{"as-child":""},{default:c(()=>{var t;return[d(k,{variant:"outline",class:W(v(q)("w-full justify-start gap-2 text-left font-normal",!((t=l.modelValue)!=null&&t.from)&&"text-muted-foreground"))},{default:c(()=>[d(v(ye),{class:"h-4 w-4 shrink-0"}),f("span",null,S(T.value),1)]),_:1},8,["class"])]}),_:1}),d(v(ie),null,{default:c(()=>[d(v(de),{"side-offset":8,class:"z-50 w-auto rounded-xl border border-border bg-popover p-0 shadow-xl animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95"},{default:c(()=>[f("div",Oe,[f("div",Pe,[(h(!0),_(j,null,L(v(D),t=>(h(),_("button",{key:t.value,type:"button",class:W(v(q)("rounded-md px-3 py-2 text-left text-sm transition-colors","hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",a.value===t.value&&"bg-primary/10 font-medium text-primary")),onClick:y=>p(t.value)},S(t.label),11,Ie))),128))]),f("div",ze,[f("div",Fe,[d(ne,{modelValue:i.value,"onUpdate:modelValue":n[0]||(n[0]=t=>i.value=t),"initial-month":g.value,mode:"range"},null,8,["modelValue","initial-month"]),f("div",Re,[d(ne,{modelValue:i.value,"onUpdate:modelValue":n[1]||(n[1]=t=>i.value=t),"initial-month":M.value,mode:"range"},null,8,["modelValue","initial-month"])])]),N.value?(h(),_("p",je,S(N.value),1)):le("",!0),f("div",Le,[d(k,{variant:"ghost",size:"sm",onClick:O},{default:c(()=>[...n[3]||(n[3]=[w("Cancel",-1)])]),_:1}),d(k,{size:"sm",disabled:!C.value,onClick:E},{default:c(()=>[...n[4]||(n[4]=[w("Apply",-1)])]),_:1},8,["disabled"])])])])]),_:1})]),_:1})]),_:1},8,["open"]))}});function Ae(l,s){const o=`/cc-dashboard/api/export/timesheet.csv?from=${l}&to=${s}`,r=document.createElement("a");r.href=o,r.download=`timesheet-${l}-${s}.csv`,r.click()}function Be(l,s){const o=`/cc-dashboard/api/export/timesheet.ics?from=${l}&to=${s}`,r=document.createElement("a");r.href=o,r.download=`timesheet-${l}-${s}.ics`,r.click()}const He={class:"p-6 space-y-8 max-w-2xl"},Ye={class:"space-y-2"},Ke={class:"space-y-2"},We={class:"flex items-center justify-between"},qe={class:"space-y-2"},Ge={class:"flex items-center gap-2"},it=G({__name:"SettingsView",setup(l){const s=ce(),o=pe(),r=x(""),u=x(0),i=x(!1),m=x(""),g=x("");me(()=>{s.user&&(r.value=s.user.username,u.value=s.user.daily_overhead_hours??0),o.fetchIntegration();const D=new Date;g.value=X(D);const a=new Date(D);a.setDate(D.getDate()-30),m.value=X(a)});async function M(){i.value=!0;try{await ve.patch("/api/auth/me",{username:r.value,daily_overhead_hours:u.value}),await s.fetchMe(),R.success("Profile saved")}catch{R.error("Failed to save profile")}finally{i.value=!1}}async function z(){try{await o.sync(),R.success("Sync complete")}catch{R.error(o.error??"Sync failed")}}return(D,a)=>(h(),_("div",He,[a[16]||(a[16]=f("h2",{class:"text-lg font-semibold text-foreground"},"Settings",-1)),d(B,null,{default:c(()=>[d(Y,null,{default:c(()=>[d(K,{class:"text-sm"},{default:c(()=>[...a[5]||(a[5]=[w("Profile",-1)])]),_:1})]),_:1}),d(H,{class:"space-y-6"},{default:c(()=>[f("div",Ye,[a[6]||(a[6]=f("label",{class:"text-sm font-medium text-foreground"},"Username",-1)),d(Q,{modelValue:r.value,"onUpdate:modelValue":a[0]||(a[0]=p=>r.value=p),placeholder:"username"},null,8,["modelValue"])]),f("div",Ke,[a[7]||(a[7]=f("label",{class:"text-sm font-medium text-foreground"},"Daily Overhead Hours",-1)),d(Q,{modelValue:u.value,"onUpdate:modelValue":a[1]||(a[1]=p=>u.value=p),type:"number",min:"0",max:"8",step:"0.25",class:"w-32"},null,8,["modelValue"]),a[8]||(a[8]=f("p",{class:"text-xs text-muted-foreground"}," Hours per day to add for overhead / meetings ",-1))]),d(k,{loading:i.value,class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:M},{default:c(()=>[...a[9]||(a[9]=[w("Save Profile",-1)])]),_:1},8,["loading"])]),_:1})]),_:1}),d(B,null,{default:c(()=>[d(Y,null,{default:c(()=>[f("div",We,[d(K,{class:"text-sm"},{default:c(()=>[...a[10]||(a[10]=[w("Azure DevOps Integration",-1)])]),_:1}),v(o).integration?(h(),se(k,{key:0,variant:"outline",size:"sm",loading:v(o).syncing,class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:z},{default:c(()=>[...a[11]||(a[11]=[w(" Sync Now ",-1)])]),_:1},8,["loading"])):le("",!0)])]),_:1}),d(H,null,{default:c(()=>[d(he)]),_:1})]),_:1}),d(B,null,{default:c(()=>[d(Y,null,{default:c(()=>[d(K,{class:"text-sm"},{default:c(()=>[...a[12]||(a[12]=[w("Export",-1)])]),_:1})]),_:1}),d(H,{class:"space-y-6"},{default:c(()=>[f("div",qe,[a[13]||(a[13]=f("label",{class:"text-sm font-medium text-foreground"},"Date range",-1)),d(Ue,{"model-value":{from:m.value?new Date(m.value):null,to:g.value?new Date(g.value):null},"onUpdate:modelValue":a[2]||(a[2]=p=>{m.value=p.from?v($)(p.from,"yyyy-MM-dd"):"",g.value=p.to?v($)(p.to,"yyyy-MM-dd"):""})},null,8,["model-value"])]),f("div",Ge,[d(k,{variant:"outline",size:"sm",class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:a[3]||(a[3]=p=>v(Ae)(m.value,g.value))},{default:c(()=>[...a[14]||(a[14]=[w(" Download CSV ",-1)])]),_:1}),d(k,{variant:"outline",size:"sm",class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:a[4]||(a[4]=p=>v(Be)(m.value,g.value))},{default:c(()=>[...a[15]||(a[15]=[w(" Download ICS ",-1)])]),_:1})])]),_:1})]),_:1})]))}});export{it as default}; +import{d as G,s as x,o as h,c as _,a as f,e as d,h as v,t as S,F as j,r as L,n as W,j as V,x as re,k as se,w as c,M as ue,N as ie,S as de,i as le,q as w,O as fe,u as ce,A as me,D as ve,K as R}from"./index-aIsLHJPY.js";import{u as pe}from"./devops-DsTCxAug.js";import{_ as B,a as H}from"./CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js";import{_ as Y,a as K}from"./CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js";import{_ as Q}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{_ as k}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{c as q,i as X}from"./utils-7WVCegLb.js";import{t as b,c as U,s as Z,C as ge,a as be,f as $}from"./format-DDf_am8g.js";import{C as ye}from"./calendar-CF-bck6k.js";import{_ as he}from"./DevopsConnectForm.vue_vue_type_script_setup_true_lang-BoAmreBJ.js";import"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import"./createLucideIcon-B5Z2hHtI.js";import"./ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js";function _e(l,s){const o=b(l);return isNaN(s)?U(l,NaN):(s&&o.setDate(o.getDate()+s),o)}function ae(l,s){const o=b(l);if(isNaN(s))return U(l,NaN);if(!s)return o;const r=o.getDate(),u=U(l,o.getTime());u.setMonth(o.getMonth()+s+1,0);const i=u.getDate();return r>=i?u:(o.setFullYear(u.getFullYear(),u.getMonth(),r),o)}function xe(l){return U(l,Date.now())}function I(l,s){const o=Z(l),r=Z(s);return+o==+r}function Me(l){const s=b(l),o=s.getMonth();return s.setFullYear(s.getFullYear(),o+1,0),s.setHours(23,59,59,999),s}function we(l,s){const o=b(l.start),r=b(l.end);let u=+o>+r;const i=u?+o:+r,m=u?r:o;m.setHours(0,0,0,0);let g=1;const M=[];for(;+m<=i;)M.push(b(m)),m.setDate(m.getDate()+g),m.setHours(0,0,0,0);return u?M.reverse():M}function A(l){const s=b(l);return s.setDate(1),s.setHours(0,0,0,0),s}function De(l){return b(l).getDay()}function ee(l,s){const o=b(l),r=b(s);return+o<+r}function Ve(l){return I(l,xe(l))}function te(l,s){const o=+b(l),[r,u]=[+b(s.start),+b(s.end)].sort((i,m)=>i-m);return o>=r&&o<=u}function oe(l,s){return _e(l,-s)}function $e(l,s){return ae(l,-1)}const Ce={class:"p-3 select-none"},ke={class:"mb-3 flex items-center justify-between"},Se={class:"text-sm font-medium"},Ne={class:"mb-1 grid grid-cols-7 gap-1"},Te={class:"grid grid-cols-7 gap-1"},Ee=["onClick","onMouseenter","aria-label","aria-pressed"],ne=G({__name:"Calendar",props:{modelValue:{default:()=>({from:null,to:null})},mode:{default:"range"},initialMonth:{}},emits:["update:modelValue"],setup(l,{emit:s}){const o=l,r=s,u=x(o.initialMonth??new Date),i=x(null),m=["Mo","Tu","We","Th","Fr","Sa","Su"],g=V(()=>$(u.value,"MMMM yyyy")),M=V(()=>{const e=A(u.value),n=Me(u.value);return we({start:e,end:n})}),z=V(()=>{const e=De(A(u.value));return e===0?6:e-1});function D(){u.value=$e(u.value)}function a(){u.value=ae(u.value,1)}function p(e){return e.getMonth()!==u.value.getMonth()}function N(e){return Ve(e)}function C(e){return T(e)||E(e)}function T(e){var n;return(n=o.modelValue)!=null&&n.from?I(e,o.modelValue.from):!1}function E(e){var n;return(n=o.modelValue)!=null&&n.to?I(e,o.modelValue.to):!1}function O(e){const{from:n,to:t}=o.modelValue??{};return!n||!t?!1:te(e,{start:n,end:t})&&!I(e,n)&&!I(e,t)}function P(e){var y,J;const n=(y=o.modelValue)==null?void 0:y.from;if(!n||(J=o.modelValue)!=null&&J.to||!i.value)return!1;const t=i.value;return ee(t,n)?!1:te(e,{start:n,end:t})}function F(e){if(o.mode==="single"){r("update:modelValue",{from:e,to:e});return}const{from:n,to:t}=o.modelValue??{};!n||n&&t?r("update:modelValue",{from:e,to:null}):ee(e,n)?r("update:modelValue",{from:e,to:n}):r("update:modelValue",{from:n,to:e})}return(e,n)=>(h(),_("div",Ce,[f("div",ke,[f("button",{type:"button",class:"flex h-8 w-8 items-center justify-center rounded-md hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",onClick:D,"aria-label":"Previous month"},[d(v(ge),{class:"h-4 w-4"})]),f("span",Se,S(g.value),1),f("button",{type:"button",class:"flex h-8 w-8 items-center justify-center rounded-md hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",onClick:a,"aria-label":"Next month"},[d(v(be),{class:"h-4 w-4"})])]),f("div",Ne,[(h(),_(j,null,L(m,t=>f("div",{key:t,class:"flex h-8 items-center justify-center text-[11px] font-medium uppercase tracking-wide text-muted-foreground"},S(t),1)),64))]),f("div",Te,[(h(!0),_(j,null,L(z.value,t=>(h(),_("div",{key:"blank-"+t}))),128)),(h(!0),_(j,null,L(M.value,t=>(h(),_("button",{key:t.toISOString(),type:"button",class:W(v(q)("flex h-9 w-9 items-center justify-center rounded-md text-sm transition-colors","focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",p(t)&&"text-muted-foreground/40",N(t)&&!C(t)&&"ring-1 ring-primary",T(t)&&"rounded-l-md bg-primary text-primary-foreground",E(t)&&"rounded-r-md bg-primary text-primary-foreground",O(t)&&!T(t)&&!E(t)&&"bg-primary/15 rounded-none",P(t)&&!O(t)&&!C(t)&&"bg-primary/10",!C(t)&&!O(t)&&!P(t)&&"hover:bg-accent")),onClick:y=>F(t),onMouseenter:y=>i.value=t,onMouseleave:n[0]||(n[0]=y=>i.value=null),"aria-label":v($)(t,"EEEE, MMMM d, yyyy"),"aria-pressed":C(t)},S(v($)(t,"d")),43,Ee))),128))])]))}}),Oe={class:"flex"},Pe={class:"flex w-36 flex-col border-r border-border p-2 gap-1"},Ie=["onClick"],ze={class:"flex flex-col"},Fe={class:"flex"},Re={class:"border-l border-border"},je={key:0,class:"px-4 pb-2 text-xs text-destructive"},Le={class:"flex items-center justify-end gap-2 border-t border-border px-4 py-3"},Ue=G({__name:"DateRangePicker",props:{modelValue:{default:()=>({from:null,to:null})}},emits:["update:modelValue"],setup(l,{emit:s}){var P,F;const o=l,r=s,u=x(!1),i=x({from:((P=o.modelValue)==null?void 0:P.from)??null,to:((F=o.modelValue)==null?void 0:F.to)??null}),m=new Date,g=V(()=>A(i.value.from??m)),M=V(()=>{const e=new Date(g.value);return e.setMonth(e.getMonth()+1),e}),D=[{value:"today",label:"Today"},{value:"last7",label:"Last 7 days"},{value:"last30",label:"Last 30 days"},{value:"thisMonth",label:"This month"},{value:"custom",label:"Custom"}],a=x("custom");function p(e){if(a.value=e,e==="custom")return;const n=new Date;let t,y;if(e==="today")t=n,y=n;else if(e==="last7")t=oe(n,6),y=n;else if(e==="last30")t=oe(n,29),y=n;else if(e==="thisMonth")t=A(n),y=n;else return;i.value={from:t,to:y}}const N=V(()=>i.value.from&&i.value.to&&i.value.from>i.value.to?"End date must be after start date":null),C=V(()=>i.value.from!==null&&i.value.to!==null&&!N.value),T=V(()=>{const{from:e,to:n}=o.modelValue??{};return e?!n||e.getTime()===n.getTime()?$(e,"MMM d, yyyy"):`${$(e,"MMM d")} – ${$(n,"MMM d, yyyy")}`:"Pick a date range"});function E(){C.value&&(r("update:modelValue",{from:i.value.from,to:i.value.to}),u.value=!1)}function O(){var e,n;i.value={from:((e=o.modelValue)==null?void 0:e.from)??null,to:((n=o.modelValue)==null?void 0:n.to)??null},u.value=!1}return re(()=>o.modelValue,e=>{i.value={from:(e==null?void 0:e.from)??null,to:(e==null?void 0:e.to)??null}},{deep:!0}),(e,n)=>(h(),se(v(fe),{open:u.value,"onUpdate:open":n[2]||(n[2]=t=>u.value=t)},{default:c(()=>[d(v(ue),{"as-child":""},{default:c(()=>{var t;return[d(k,{variant:"outline",class:W(v(q)("w-full justify-start gap-2 text-left font-normal",!((t=l.modelValue)!=null&&t.from)&&"text-muted-foreground"))},{default:c(()=>[d(v(ye),{class:"h-4 w-4 shrink-0"}),f("span",null,S(T.value),1)]),_:1},8,["class"])]}),_:1}),d(v(ie),null,{default:c(()=>[d(v(de),{"side-offset":8,class:"z-50 w-auto rounded-xl border border-border bg-popover p-0 shadow-xl animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95"},{default:c(()=>[f("div",Oe,[f("div",Pe,[(h(!0),_(j,null,L(v(D),t=>(h(),_("button",{key:t.value,type:"button",class:W(v(q)("rounded-md px-3 py-2 text-left text-sm transition-colors","hover:bg-accent focus-visible:ring-2 focus-visible:ring-ring focus-visible:outline-none",a.value===t.value&&"bg-primary/10 font-medium text-primary")),onClick:y=>p(t.value)},S(t.label),11,Ie))),128))]),f("div",ze,[f("div",Fe,[d(ne,{modelValue:i.value,"onUpdate:modelValue":n[0]||(n[0]=t=>i.value=t),"initial-month":g.value,mode:"range"},null,8,["modelValue","initial-month"]),f("div",Re,[d(ne,{modelValue:i.value,"onUpdate:modelValue":n[1]||(n[1]=t=>i.value=t),"initial-month":M.value,mode:"range"},null,8,["modelValue","initial-month"])])]),N.value?(h(),_("p",je,S(N.value),1)):le("",!0),f("div",Le,[d(k,{variant:"ghost",size:"sm",onClick:O},{default:c(()=>[...n[3]||(n[3]=[w("Cancel",-1)])]),_:1}),d(k,{size:"sm",disabled:!C.value,onClick:E},{default:c(()=>[...n[4]||(n[4]=[w("Apply",-1)])]),_:1},8,["disabled"])])])])]),_:1})]),_:1})]),_:1},8,["open"]))}});function Ae(l,s){const o=`/cc-dashboard/api/export/timesheet.csv?from=${l}&to=${s}`,r=document.createElement("a");r.href=o,r.download=`timesheet-${l}-${s}.csv`,r.click()}function Be(l,s){const o=`/cc-dashboard/api/export/timesheet.ics?from=${l}&to=${s}`,r=document.createElement("a");r.href=o,r.download=`timesheet-${l}-${s}.ics`,r.click()}const He={class:"p-6 space-y-8 max-w-2xl"},Ye={class:"space-y-2"},Ke={class:"space-y-2"},We={class:"flex items-center justify-between"},qe={class:"space-y-2"},Ge={class:"flex items-center gap-2"},it=G({__name:"SettingsView",setup(l){const s=ce(),o=pe(),r=x(""),u=x(0),i=x(!1),m=x(""),g=x("");me(()=>{s.user&&(r.value=s.user.username,u.value=s.user.daily_overhead_hours??0),o.fetchIntegration();const D=new Date;g.value=X(D);const a=new Date(D);a.setDate(D.getDate()-30),m.value=X(a)});async function M(){i.value=!0;try{await ve.patch("/api/auth/me",{username:r.value,daily_overhead_hours:u.value}),await s.fetchMe(),R.success("Profile saved")}catch{R.error("Failed to save profile")}finally{i.value=!1}}async function z(){try{await o.sync(),R.success("Sync complete")}catch{R.error(o.error??"Sync failed")}}return(D,a)=>(h(),_("div",He,[a[16]||(a[16]=f("h2",{class:"text-lg font-semibold text-foreground"},"Settings",-1)),d(B,null,{default:c(()=>[d(Y,null,{default:c(()=>[d(K,{class:"text-sm"},{default:c(()=>[...a[5]||(a[5]=[w("Profile",-1)])]),_:1})]),_:1}),d(H,{class:"space-y-6"},{default:c(()=>[f("div",Ye,[a[6]||(a[6]=f("label",{class:"text-sm font-medium text-foreground"},"Username",-1)),d(Q,{modelValue:r.value,"onUpdate:modelValue":a[0]||(a[0]=p=>r.value=p),placeholder:"username"},null,8,["modelValue"])]),f("div",Ke,[a[7]||(a[7]=f("label",{class:"text-sm font-medium text-foreground"},"Daily Overhead Hours",-1)),d(Q,{modelValue:u.value,"onUpdate:modelValue":a[1]||(a[1]=p=>u.value=p),type:"number",min:"0",max:"8",step:"0.25",class:"w-32"},null,8,["modelValue"]),a[8]||(a[8]=f("p",{class:"text-xs text-muted-foreground"}," Hours per day to add for overhead / meetings ",-1))]),d(k,{loading:i.value,class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:M},{default:c(()=>[...a[9]||(a[9]=[w("Save Profile",-1)])]),_:1},8,["loading"])]),_:1})]),_:1}),d(B,null,{default:c(()=>[d(Y,null,{default:c(()=>[f("div",We,[d(K,{class:"text-sm"},{default:c(()=>[...a[10]||(a[10]=[w("Azure DevOps Integration",-1)])]),_:1}),v(o).integration?(h(),se(k,{key:0,variant:"outline",size:"sm",loading:v(o).syncing,class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:z},{default:c(()=>[...a[11]||(a[11]=[w(" Sync Now ",-1)])]),_:1},8,["loading"])):le("",!0)])]),_:1}),d(H,null,{default:c(()=>[d(he)]),_:1})]),_:1}),d(B,null,{default:c(()=>[d(Y,null,{default:c(()=>[d(K,{class:"text-sm"},{default:c(()=>[...a[12]||(a[12]=[w("Export",-1)])]),_:1})]),_:1}),d(H,{class:"space-y-6"},{default:c(()=>[f("div",qe,[a[13]||(a[13]=f("label",{class:"text-sm font-medium text-foreground"},"Date range",-1)),d(Ue,{"model-value":{from:m.value?new Date(m.value):null,to:g.value?new Date(g.value):null},"onUpdate:modelValue":a[2]||(a[2]=p=>{m.value=p.from?v($)(p.from,"yyyy-MM-dd"):"",g.value=p.to?v($)(p.to,"yyyy-MM-dd"):""})},null,8,["model-value"])]),f("div",Ge,[d(k,{variant:"outline",size:"sm",class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:a[3]||(a[3]=p=>v(Ae)(m.value,g.value))},{default:c(()=>[...a[14]||(a[14]=[w(" Download CSV ",-1)])]),_:1}),d(k,{variant:"outline",size:"sm",class:"focus-visible:ring-2 focus-visible:ring-ring",onClick:a[4]||(a[4]=p=>v(Be)(m.value,g.value))},{default:c(()=>[...a[15]||(a[15]=[w(" Download ICS ",-1)])]),_:1})])]),_:1})]),_:1})]))}});export{it as default}; diff --git a/src/static/assets/Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js b/src/static/assets/Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js similarity index 77% rename from src/static/assets/Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js rename to src/static/assets/Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js index 05894c1..4412e0f 100644 --- a/src/static/assets/Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js +++ b/src/static/assets/Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js @@ -1 +1 @@ -import{c as s}from"./utils-7WVCegLb.js";import{d as r,o as t,c as n,m as o,h as a}from"./index-BiYpJJoC.js";const i=r({inheritAttrs:!1,__name:"Skeleton",setup(m){return(e,c)=>(t(),n("div",o(e.$attrs,{class:a(s)("skeleton-shimmer rounded-md",e.$attrs.class)}),null,16))}});export{i as _}; +import{c as s}from"./utils-7WVCegLb.js";import{d as r,o as t,c as n,m as o,h as a}from"./index-aIsLHJPY.js";const i=r({inheritAttrs:!1,__name:"Skeleton",setup(m){return(e,c)=>(t(),n("div",o(e.$attrs,{class:a(s)("skeleton-shimmer rounded-md",e.$attrs.class)}),null,16))}});export{i as _}; diff --git a/src/static/assets/Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js b/src/static/assets/Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js similarity index 90% rename from src/static/assets/Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js rename to src/static/assets/Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js index db14e6c..5fc9f31 100644 --- a/src/static/assets/Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js +++ b/src/static/assets/Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js @@ -1 +1 @@ -import{d as l,o as n,c as o,n as t,a as r}from"./index-BiYpJJoC.js";const i=l({__name:"Spinner",props:{size:{},class:{}},setup(s){return(a,e)=>(n(),o("svg",{class:t(["animate-spin text-current",s.size==="sm"?"h-3 w-3":s.size==="lg"?"h-6 w-6":"h-4 w-4",a.$props.class]),xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[...e[0]||(e[0]=[r("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"},null,-1),r("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"},null,-1)])],2))}});export{i as _}; +import{d as l,o as n,c as o,n as t,a as r}from"./index-aIsLHJPY.js";const i=l({__name:"Spinner",props:{size:{},class:{}},setup(s){return(a,e)=>(n(),o("svg",{class:t(["animate-spin text-current",s.size==="sm"?"h-3 w-3":s.size==="lg"?"h-6 w-6":"h-4 w-4",a.$props.class]),xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},[...e[0]||(e[0]=[r("circle",{class:"opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor","stroke-width":"4"},null,-1),r("path",{class:"opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"},null,-1)])],2))}});export{i as _}; diff --git a/src/static/assets/TaskForm.vue_vue_type_script_setup_true_lang-BWg_Q6_w.js b/src/static/assets/TaskForm.vue_vue_type_script_setup_true_lang-BWg_Q6_w.js new file mode 100644 index 0000000..cf52ca0 --- /dev/null +++ b/src/static/assets/TaskForm.vue_vue_type_script_setup_true_lang-BWg_Q6_w.js @@ -0,0 +1 @@ +import{d as C,c as r,n as U,h as c,t as _,i as x,p as z,o as n,B as D,s as y,A as T,x as N,k as B,w as u,a as l,e as i,q as V,F as j,r as S,C as I}from"./index-aIsLHJPY.js";import{_ as P}from"./Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js";import{_ as b}from"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import{p as A,_ as E}from"./projects-BYok-JQo.js";import{c as F}from"./utils-7WVCegLb.js";import{_ as $}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{u as L}from"./devops-DsTCxAug.js";const M=["id","value","disabled"],O=["selected"],k=C({__name:"Select",props:{modelValue:{},disabled:{type:Boolean},class:{},id:{},placeholder:{}},emits:["update:modelValue","change"],setup(o,{emit:m}){const s=o,v=m;return(p,f)=>(n(),r("select",{id:o.id,value:o.modelValue,disabled:o.disabled,class:U(c(F)("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm","ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50",s.class)),onChange:f[0]||(f[0]=t=>v("update:modelValue",t.target.value))},[o.placeholder?(n(),r("option",{key:0,value:"",disabled:"",selected:!o.modelValue},_(o.placeholder),9,O)):x("",!0),z(p.$slots,"default")],42,M))}}),W=D("projects",()=>{const o=y([]),m=y(!1);async function s(){if(!(o.value.length>0)){m.value=!0;try{const v=await A.list();o.value=v.data}catch{o.value=[]}finally{m.value=!1}}}return{projects:o,loading:m,fetchProjects:s}}),q={class:"space-y-1.5"},H={class:"space-y-1.5"},G={class:"grid grid-cols-2 gap-3"},J={class:"space-y-1.5"},K={class:"space-y-1.5"},Q={class:"grid grid-cols-2 gap-3"},R={class:"space-y-1.5"},X={class:"space-y-1.5"},Y={class:"grid grid-cols-2 gap-3"},Z={class:"space-y-1.5"},h={class:"space-y-1.5"},ee={key:0,class:"space-y-1.5"},te=["value"],le={key:1,class:"space-y-1.5"},ae=["value"],me=C({__name:"TaskForm",props:{open:{type:Boolean},task:{default:null},defaultDate:{}},emits:["close","save"],setup(o,{emit:m}){const s=o,v=m,p=L(),f=W();T(()=>{f.fetchProjects()});const t=y({title:"",notes:"",planned_date:"",start_time:"",end_time:"",estimate_hours:1,status:"todo",priority:3,project_id:void 0,azure_work_item_id:void 0});N(()=>s.open,g=>{g&&(s.task?t.value={title:s.task.title,notes:s.task.notes??"",planned_date:s.task.planned_date??"",start_time:"",end_time:"",estimate_hours:s.task.estimate_hours??1,status:s.task.status,priority:s.task.priority,project_id:s.task.project_id??void 0,azure_work_item_id:s.task.azure_work_item_id??void 0}:t.value={title:"",notes:"",planned_date:s.defaultDate??"",start_time:"",end_time:"",estimate_hours:1,status:"todo",priority:3,project_id:void 0,azure_work_item_id:void 0},p.integration&&!p.workItems.length&&p.fetchWorkItems("open"))},{immediate:!0});const d=y(!1);async function w(){if(t.value.title.trim()){d.value=!0;try{const g={title:t.value.title,notes:t.value.notes||void 0,planned_date:t.value.planned_date,estimate_hours:t.value.estimate_hours,status:t.value.status,priority:t.value.priority,project_id:t.value.project_id||null,azure_work_item_id:t.value.azure_work_item_id||null};let e;t.value.planned_date&&t.value.start_time&&t.value.end_time&&(e={start_at:new Date(`${t.value.planned_date}T${t.value.start_time}:00`).toISOString(),end_at:new Date(`${t.value.planned_date}T${t.value.end_time}:00`).toISOString()}),v("save",g,e)}finally{d.value=!1}}}return(g,e)=>(n(),B(P,{open:o.open,title:o.task?"Edit Task":"New Task","max-width":"max-w-md",onClose:e[11]||(e[11]=a=>v("close"))},{footer:u(()=>[i($,{variant:"outline",disabled:d.value,onClick:e[10]||(e[10]=a=>v("close"))},{default:u(()=>[...e[25]||(e[25]=[V("Cancel",-1)])]),_:1},8,["disabled"]),i($,{loading:d.value,onClick:w},{default:u(()=>[V(_(o.task?"Update":"Create"),1)]),_:1},8,["loading"])]),default:u(()=>[l("form",{class:"space-y-4",onSubmit:I(w,["prevent"])},[l("div",q,[e[12]||(e[12]=l("label",{class:"text-sm font-medium text-foreground"},"Title *",-1)),i(b,{modelValue:t.value.title,"onUpdate:modelValue":e[0]||(e[0]=a=>t.value.title=a),placeholder:"Task title...",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",H,[e[13]||(e[13]=l("label",{class:"text-sm font-medium text-foreground"},"Notes",-1)),i(E,{modelValue:t.value.notes,"onUpdate:modelValue":e[1]||(e[1]=a=>t.value.notes=a),placeholder:"Additional notes...",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",G,[l("div",J,[e[14]||(e[14]=l("label",{class:"text-sm font-medium text-foreground"},"Planned Date",-1)),i(b,{modelValue:t.value.planned_date,"onUpdate:modelValue":e[2]||(e[2]=a=>t.value.planned_date=a),type:"date",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",K,[e[15]||(e[15]=l("label",{class:"text-sm font-medium text-foreground"},"Estimate (h)",-1)),i(b,{modelValue:t.value.estimate_hours,"onUpdate:modelValue":e[3]||(e[3]=a=>t.value.estimate_hours=a),type:"number",min:"0.25",max:"24",step:"0.25",disabled:d.value},null,8,["modelValue","disabled"])])]),l("div",Q,[l("div",R,[e[16]||(e[16]=l("label",{class:"text-sm font-medium text-foreground"},[V("Start time "),l("span",{class:"text-muted-foreground font-normal"},"(optional)")],-1)),i(b,{modelValue:t.value.start_time,"onUpdate:modelValue":e[4]||(e[4]=a=>t.value.start_time=a),type:"time",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",X,[e[17]||(e[17]=l("label",{class:"text-sm font-medium text-foreground"},"End time",-1)),i(b,{modelValue:t.value.end_time,"onUpdate:modelValue":e[5]||(e[5]=a=>t.value.end_time=a),type:"time",disabled:d.value},null,8,["modelValue","disabled"])])]),l("div",Y,[l("div",Z,[e[19]||(e[19]=l("label",{class:"text-sm font-medium text-foreground"},"Status",-1)),i(k,{modelValue:t.value.status,"onUpdate:modelValue":e[6]||(e[6]=a=>t.value.status=a),disabled:d.value},{default:u(()=>[...e[18]||(e[18]=[l("option",{value:"todo"},"Todo",-1),l("option",{value:"doing"},"Doing",-1),l("option",{value:"testing"},"Testing",-1),l("option",{value:"done"},"Done",-1),l("option",{value:"cancelled"},"Cancelled",-1)])]),_:1},8,["modelValue","disabled"])]),l("div",h,[e[21]||(e[21]=l("label",{class:"text-sm font-medium text-foreground"},"Priority",-1)),i(k,{modelValue:t.value.priority,"onUpdate:modelValue":e[7]||(e[7]=a=>t.value.priority=a),disabled:d.value},{default:u(()=>[...e[20]||(e[20]=[l("option",{value:"1"},"1 - Low",-1),l("option",{value:"2"},"2 - Normal",-1),l("option",{value:"3"},"3 - Medium",-1),l("option",{value:"4"},"4 - High",-1),l("option",{value:"5"},"5 - Critical",-1)])]),_:1},8,["modelValue","disabled"])])]),c(f).projects.length?(n(),r("div",ee,[e[23]||(e[23]=l("label",{class:"text-sm font-medium text-foreground"},"Project",-1)),i(k,{modelValue:t.value.project_id,"onUpdate:modelValue":e[8]||(e[8]=a=>t.value.project_id=a),disabled:d.value,placeholder:"Select project..."},{default:u(()=>[e[22]||(e[22]=l("option",{value:""},"None",-1)),(n(!0),r(j,null,S(c(f).projects,a=>(n(),r("option",{key:a.id,value:a.id},_(a.display_name)+_(a.job_number?` (${a.job_number})`:""),9,te))),128))]),_:1},8,["modelValue","disabled"])])):x("",!0),c(p).workItems.length?(n(),r("div",le,[e[24]||(e[24]=l("label",{class:"text-sm font-medium text-foreground"},"Azure DevOps Work Item",-1)),i(k,{modelValue:t.value.azure_work_item_id,"onUpdate:modelValue":e[9]||(e[9]=a=>t.value.azure_work_item_id=a),disabled:d.value,placeholder:"Link work item..."},{default:u(()=>[(n(!0),r(j,null,S(c(p).workItems,a=>(n(),r("option",{key:a.id,value:a.id}," #"+_(a.ado_id)+" – "+_(a.title),9,ae))),128))]),_:1},8,["modelValue","disabled"])])):x("",!0)],32)]),_:1},8,["open","title"]))}});export{me as _,k as a,W as u}; diff --git a/src/static/assets/TaskForm.vue_vue_type_script_setup_true_lang-BvqRdc1Q.js b/src/static/assets/TaskForm.vue_vue_type_script_setup_true_lang-BvqRdc1Q.js deleted file mode 100644 index 0926ac8..0000000 --- a/src/static/assets/TaskForm.vue_vue_type_script_setup_true_lang-BvqRdc1Q.js +++ /dev/null @@ -1 +0,0 @@ -import{d as C,c as r,n as D,h as c,t as _,i as x,p as U,o as n,D as z,B as T,s as y,A as N,x as B,k as I,w as u,a as l,e as i,q as V,F as j,r as S,C as P}from"./index-BiYpJJoC.js";import{_ as A}from"./Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js";import{_ as b}from"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import{_ as E}from"./Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js";import{c as F}from"./utils-7WVCegLb.js";import{_ as $}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{u as L}from"./devops-y1AYKG_U.js";const M=["id","value","disabled"],O=["selected"],k=C({__name:"Select",props:{modelValue:{},disabled:{type:Boolean},class:{},id:{},placeholder:{}},emits:["update:modelValue","change"],setup(o,{emit:m}){const s=o,p=m;return(v,f)=>(n(),r("select",{id:o.id,value:o.modelValue,disabled:o.disabled,class:D(c(F)("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-sm","ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50",s.class)),onChange:f[0]||(f[0]=t=>p("update:modelValue",t.target.value))},[o.placeholder?(n(),r("option",{key:0,value:"",disabled:"",selected:!o.modelValue},_(o.placeholder),9,O)):x("",!0),U(v.$slots,"default")],42,M))}}),W={list:()=>z.get("/api/projects")},q=T("projects",()=>{const o=y([]),m=y(!1);async function s(){if(!(o.value.length>0)){m.value=!0;try{const p=await W.list();o.value=p.data}catch{o.value=[]}finally{m.value=!1}}}return{projects:o,loading:m,fetchProjects:s}}),H={class:"space-y-1.5"},G={class:"space-y-1.5"},J={class:"grid grid-cols-2 gap-3"},K={class:"space-y-1.5"},Q={class:"space-y-1.5"},R={class:"grid grid-cols-2 gap-3"},X={class:"space-y-1.5"},Y={class:"space-y-1.5"},Z={class:"grid grid-cols-2 gap-3"},h={class:"space-y-1.5"},ee={class:"space-y-1.5"},te={key:0,class:"space-y-1.5"},le=["value"],ae={key:1,class:"space-y-1.5"},oe=["value"],pe=C({__name:"TaskForm",props:{open:{type:Boolean},task:{default:null},defaultDate:{}},emits:["close","save"],setup(o,{emit:m}){const s=o,p=m,v=L(),f=q();N(()=>{f.fetchProjects()});const t=y({title:"",notes:"",planned_date:"",start_time:"",end_time:"",estimate_hours:1,status:"todo",priority:3,project_id:void 0,azure_work_item_id:void 0});B(()=>s.open,g=>{g&&(s.task?t.value={title:s.task.title,notes:s.task.notes??"",planned_date:s.task.planned_date??"",start_time:"",end_time:"",estimate_hours:s.task.estimate_hours??1,status:s.task.status,priority:s.task.priority,project_id:s.task.project_id??void 0,azure_work_item_id:s.task.azure_work_item_id??void 0}:t.value={title:"",notes:"",planned_date:s.defaultDate??"",start_time:"",end_time:"",estimate_hours:1,status:"todo",priority:3,project_id:void 0,azure_work_item_id:void 0},v.integration&&!v.workItems.length&&v.fetchWorkItems("open"))},{immediate:!0});const d=y(!1);async function w(){if(t.value.title.trim()){d.value=!0;try{const g={title:t.value.title,notes:t.value.notes||void 0,planned_date:t.value.planned_date,estimate_hours:t.value.estimate_hours,status:t.value.status,priority:t.value.priority,project_id:t.value.project_id||null,azure_work_item_id:t.value.azure_work_item_id||null};let e;t.value.planned_date&&t.value.start_time&&t.value.end_time&&(e={start_at:new Date(`${t.value.planned_date}T${t.value.start_time}:00`).toISOString(),end_at:new Date(`${t.value.planned_date}T${t.value.end_time}:00`).toISOString()}),p("save",g,e)}finally{d.value=!1}}}return(g,e)=>(n(),I(A,{open:o.open,title:o.task?"Edit Task":"New Task","max-width":"max-w-md",onClose:e[11]||(e[11]=a=>p("close"))},{footer:u(()=>[i($,{variant:"outline",disabled:d.value,onClick:e[10]||(e[10]=a=>p("close"))},{default:u(()=>[...e[25]||(e[25]=[V("Cancel",-1)])]),_:1},8,["disabled"]),i($,{loading:d.value,onClick:w},{default:u(()=>[V(_(o.task?"Update":"Create"),1)]),_:1},8,["loading"])]),default:u(()=>[l("form",{class:"space-y-4",onSubmit:P(w,["prevent"])},[l("div",H,[e[12]||(e[12]=l("label",{class:"text-sm font-medium text-foreground"},"Title *",-1)),i(b,{modelValue:t.value.title,"onUpdate:modelValue":e[0]||(e[0]=a=>t.value.title=a),placeholder:"Task title...",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",G,[e[13]||(e[13]=l("label",{class:"text-sm font-medium text-foreground"},"Notes",-1)),i(E,{modelValue:t.value.notes,"onUpdate:modelValue":e[1]||(e[1]=a=>t.value.notes=a),placeholder:"Additional notes...",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",J,[l("div",K,[e[14]||(e[14]=l("label",{class:"text-sm font-medium text-foreground"},"Planned Date",-1)),i(b,{modelValue:t.value.planned_date,"onUpdate:modelValue":e[2]||(e[2]=a=>t.value.planned_date=a),type:"date",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",Q,[e[15]||(e[15]=l("label",{class:"text-sm font-medium text-foreground"},"Estimate (h)",-1)),i(b,{modelValue:t.value.estimate_hours,"onUpdate:modelValue":e[3]||(e[3]=a=>t.value.estimate_hours=a),type:"number",min:"0.25",max:"24",step:"0.25",disabled:d.value},null,8,["modelValue","disabled"])])]),l("div",R,[l("div",X,[e[16]||(e[16]=l("label",{class:"text-sm font-medium text-foreground"},[V("Start time "),l("span",{class:"text-muted-foreground font-normal"},"(optional)")],-1)),i(b,{modelValue:t.value.start_time,"onUpdate:modelValue":e[4]||(e[4]=a=>t.value.start_time=a),type:"time",disabled:d.value},null,8,["modelValue","disabled"])]),l("div",Y,[e[17]||(e[17]=l("label",{class:"text-sm font-medium text-foreground"},"End time",-1)),i(b,{modelValue:t.value.end_time,"onUpdate:modelValue":e[5]||(e[5]=a=>t.value.end_time=a),type:"time",disabled:d.value},null,8,["modelValue","disabled"])])]),l("div",Z,[l("div",h,[e[19]||(e[19]=l("label",{class:"text-sm font-medium text-foreground"},"Status",-1)),i(k,{modelValue:t.value.status,"onUpdate:modelValue":e[6]||(e[6]=a=>t.value.status=a),disabled:d.value},{default:u(()=>[...e[18]||(e[18]=[l("option",{value:"todo"},"Todo",-1),l("option",{value:"doing"},"Doing",-1),l("option",{value:"testing"},"Testing",-1),l("option",{value:"done"},"Done",-1),l("option",{value:"cancelled"},"Cancelled",-1)])]),_:1},8,["modelValue","disabled"])]),l("div",ee,[e[21]||(e[21]=l("label",{class:"text-sm font-medium text-foreground"},"Priority",-1)),i(k,{modelValue:t.value.priority,"onUpdate:modelValue":e[7]||(e[7]=a=>t.value.priority=a),disabled:d.value},{default:u(()=>[...e[20]||(e[20]=[l("option",{value:"1"},"1 - Low",-1),l("option",{value:"2"},"2 - Normal",-1),l("option",{value:"3"},"3 - Medium",-1),l("option",{value:"4"},"4 - High",-1),l("option",{value:"5"},"5 - Critical",-1)])]),_:1},8,["modelValue","disabled"])])]),c(f).projects.length?(n(),r("div",te,[e[23]||(e[23]=l("label",{class:"text-sm font-medium text-foreground"},"Project",-1)),i(k,{modelValue:t.value.project_id,"onUpdate:modelValue":e[8]||(e[8]=a=>t.value.project_id=a),disabled:d.value,placeholder:"Select project..."},{default:u(()=>[e[22]||(e[22]=l("option",{value:""},"None",-1)),(n(!0),r(j,null,S(c(f).projects,a=>(n(),r("option",{key:a.id,value:a.id},_(a.display_name)+_(a.job_number?` (${a.job_number})`:""),9,le))),128))]),_:1},8,["modelValue","disabled"])])):x("",!0),c(v).workItems.length?(n(),r("div",ae,[e[24]||(e[24]=l("label",{class:"text-sm font-medium text-foreground"},"Azure DevOps Work Item",-1)),i(k,{modelValue:t.value.azure_work_item_id,"onUpdate:modelValue":e[9]||(e[9]=a=>t.value.azure_work_item_id=a),disabled:d.value,placeholder:"Link work item..."},{default:u(()=>[(n(!0),r(j,null,S(c(v).workItems,a=>(n(),r("option",{key:a.id,value:a.id}," #"+_(a.ado_id)+" – "+_(a.title),9,oe))),128))]),_:1},8,["modelValue","disabled"])])):x("",!0)],32)]),_:1},8,["open","title"]))}});export{pe as _,k as a,q as u}; diff --git a/src/static/assets/TasksView-D8TRKoOC.js b/src/static/assets/TasksView-D8TRKoOC.js deleted file mode 100644 index 0b788d5..0000000 --- a/src/static/assets/TasksView-D8TRKoOC.js +++ /dev/null @@ -1 +0,0 @@ -import{u as L}from"./tasks-DwSuZPNM.js";import{u as A,a as K,_ as P}from"./TaskForm.vue_vue_type_script_setup_true_lang-BvqRdc1Q.js";import{s as b,d as j,o as d,c,n as T,a as n,e as p,w as S,t as D,i as $,F as C,r as O,k as B,A as z,h as f,q as I,j as F,K as _}from"./index-BiYpJJoC.js";import{_ as M}from"./Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js";import{_ as H}from"./EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js";import{_ as U}from"./Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js";import{_ as q}from"./Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js";import"./Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js";import"./Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js";import"./utils-7WVCegLb.js";import"./Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js";import"./devops-y1AYKG_U.js";function G(){const t=L(),l=b(null),o=b(null);function u(k,g){var x;l.value=k.id,(x=g.dataTransfer)==null||x.setData("task_id",k.id),g.dataTransfer&&(g.dataTransfer.effectAllowed="move")}function m(){l.value=null,o.value=null}function a(k,g){g.preventDefault(),o.value=k,g.dataTransfer&&(g.dataTransfer.dropEffect="move")}function s(){o.value=null}async function v(k,g,x){var h;x.preventDefault(),o.value=null;const w=(h=x.dataTransfer)==null?void 0:h.getData("task_id");w&&(l.value=null,await t.update(w,{status:k,sort_index:g}))}return{draggingId:l,dragOverColumn:o,onDragStart:u,onDragEnd:m,onDragOver:a,onDragLeave:s,onDrop:v}}const J={class:"flex items-start gap-2"},Q={class:"flex-1 min-w-0"},R={class:"text-sm font-medium text-slate-800 leading-snug line-clamp-2"},W={class:"flex flex-wrap items-center gap-1.5 mt-1.5"},X=["title"],Y={key:1,class:"text-[10px] px-1.5 py-0.5 rounded-md bg-blue-50 text-blue-500 font-medium shrink-0"},Z={key:2,class:"text-[10px] text-slate-400 shrink-0"},tt=j({__name:"KanbanCard",props:{task:{},dragging:{type:Boolean}},emits:["edit"],setup(t,{emit:l}){const o=l,u={1:"bg-red-500",2:"bg-orange-400",3:"bg-slate-300",4:"bg-slate-300",5:"bg-slate-300"};return(m,a)=>(d(),c("div",{class:T(["group relative bg-white rounded-xl border border-slate-200/80 px-3 py-2.5 cursor-grab active:cursor-grabbing shadow-sm hover:shadow-md hover:border-orange-200 transition-all duration-150 select-none",t.dragging?"opacity-40 scale-95":"opacity-100"]),draggable:"true",onClick:a[0]||(a[0]=s=>o("edit",t.task))},[n("div",J,[p(M,{content:`Priority ${t.task.priority}`},{default:S(()=>[n("span",{class:T(["mt-1.5 h-2 w-2 rounded-full shrink-0",u[t.task.priority]??"bg-slate-300"])},null,2)]),_:1},8,["content"]),n("div",Q,[n("p",R,D(t.task.title),1),n("div",W,[t.task.project_name?(d(),c("span",{key:0,class:"text-[10px] px-1.5 py-0.5 rounded-md bg-slate-100 text-slate-500 font-medium truncate max-w-[100px]",title:t.task.project_name},D(t.task.project_name),9,X)):$("",!0),t.task.azure_work_item_id?(d(),c("span",Y," ADO ")):$("",!0),t.task.planned_date?(d(),c("span",Z,D(t.task.planned_date),1)):$("",!0)])])])],2))}}),et={class:"flex flex-col min-h-0 w-full"},at={class:"flex items-center justify-between px-1 mb-2"},st={class:"flex items-center gap-2"},nt={class:"text-xs font-semibold uppercase tracking-wider text-slate-500"},rt={class:"text-[10px] font-semibold bg-slate-100 text-slate-400 px-1.5 py-0.5 rounded-full leading-none"},ot=j({__name:"KanbanColumn",props:{status:{},title:{},tasks:{},draggingId:{},isDragOver:{type:Boolean}},emits:["dragStart","dragEnd","dragOver","dragLeave","drop","editTask","addTask"],setup(t,{emit:l}){const o=l,u={todo:"border-t-slate-300",doing:"border-t-orange-400",testing:"border-t-blue-400",done:"border-t-emerald-400"};return(m,a)=>(d(),c("div",et,[n("div",at,[n("div",st,[n("h3",nt,D(t.title),1),n("span",rt,D(t.tasks.length),1)]),n("button",{class:"h-5 w-5 rounded flex items-center justify-center text-slate-400 hover:text-orange-500 hover:bg-orange-50 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring","aria-label":"Add task",onClick:a[0]||(a[0]=s=>o("addTask",t.status))},[...a[5]||(a[5]=[n("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[n("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2.5",d:"M12 4v16m8-8H4"})],-1)])])]),n("div",{class:T(["flex-1 rounded-xl border-2 border-dashed transition-all duration-150 p-2 space-y-2 min-h-[120px]",`border-t-4 ${u[t.status]??"border-t-slate-300"}`,t.isDragOver?"border-orange-300 bg-orange-50/60":"border-transparent bg-slate-50/60"]),onDragover:a[2]||(a[2]=s=>o("dragOver",t.status,s)),onDragleave:a[3]||(a[3]=s=>o("dragLeave")),onDrop:a[4]||(a[4]=s=>o("drop",t.status,t.tasks.length,s))},[(d(!0),c(C,null,O(t.tasks,s=>(d(),B(tt,{key:s.id,task:s,dragging:t.draggingId===s.id,onDragstart:v=>o("dragStart",s,v),onDragend:a[1]||(a[1]=v=>o("dragEnd")),onEdit:v=>o("editTask",s)},null,8,["task","dragging","onDragstart","onEdit"]))),128)),t.tasks.length===0&&!t.isDragOver?(d(),B(H,{key:0,size:"sm",title:"No tasks here",description:"Drag a card here or click + to add"})):$("",!0)],34)]))}}),lt={class:"flex flex-col h-full overflow-hidden"},it={class:"flex items-center gap-3 px-6 py-4 border-b border-slate-100 bg-white/60 shrink-0"},dt=["value"],ut={key:0,class:"flex items-center justify-center flex-1"},ct={key:1,class:"flex-1 overflow-x-auto overflow-y-hidden"},gt={class:"grid grid-cols-4 gap-4 p-6 h-full min-w-[700px]"},_t=j({__name:"TasksView",setup(t){const l=L(),o=A(),u=G(),m=b(""),a=b(!1),s=b(null),v=b("todo"),k=[{status:"todo",title:"To Do"},{status:"doing",title:"Doing"},{status:"testing",title:"Testing"},{status:"done",title:"Done"}];z(async()=>{await Promise.all([l.fetchAll(),o.fetchProjects()])});const g=F(()=>{const i=l.tasks.filter(e=>e.status!=="cancelled");return m.value?i.filter(e=>e.project_id===m.value):i});function x(i){let e=g.value.filter(r=>r.status===i);return e=[...e].sort((r,y)=>r.sort_index-y.sort_index||r.created_at.localeCompare(y.created_at)),i==="done"&&(e=e.slice(-30)),e}function w(i){v.value=i,s.value=null,a.value=!0}function h(i){s.value=i,a.value=!0}function E(){a.value=!1,s.value=null}async function N(i,e){try{if(s.value)await l.update(s.value.id,i),e&&await l.createBlock(s.value.id,e),_.success("Task updated");else{const r={...i,status:i.status||v.value},y=await l.create(r);e&&await l.createBlock(y.id,e),_.success("Task created")}}catch{_.error("Failed to save task")}E()}const V=new Date().toISOString().split("T")[0];return(i,e)=>(d(),c("div",lt,[n("div",it,[e[4]||(e[4]=n("h2",{class:"text-sm font-semibold text-slate-800 mr-2"},"Kanban",-1)),p(K,{modelValue:m.value,"onUpdate:modelValue":e[0]||(e[0]=r=>m.value=r),class:"w-44 text-xs"},{default:S(()=>[e[2]||(e[2]=n("option",{value:""},"All projects",-1)),(d(!0),c(C,null,O(f(o).projects,r=>(d(),c("option",{key:r.id,value:r.id},D(r.display_name),9,dt))),128))]),_:1},8,["modelValue"]),e[5]||(e[5]=n("div",{class:"flex-1"},null,-1)),p(U,{size:"sm",onClick:e[1]||(e[1]=r=>w("todo"))},{default:S(()=>[...e[3]||(e[3]=[n("svg",{class:"h-3.5 w-3.5 mr-1.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[n("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2.5",d:"M12 4v16m8-8H4"})],-1),I(" New task ",-1)])]),_:1})]),f(l).loading?(d(),c("div",ut,[p(q,{size:"lg",class:"text-primary"})])):(d(),c("div",ct,[n("div",gt,[(d(),c(C,null,O(k,r=>n("div",{key:r.status,class:"flex flex-col min-h-0 overflow-y-auto"},[p(ot,{status:r.status,title:r.title,tasks:x(r.status),"dragging-id":f(u).draggingId.value,"is-drag-over":f(u).dragOverColumn.value===r.status,onDragStart:f(u).onDragStart,onDragEnd:f(u).onDragEnd,onDragOver:f(u).onDragOver,onDragLeave:f(u).onDragLeave,onDrop:f(u).onDrop,onEditTask:h,onAddTask:w},null,8,["status","title","tasks","dragging-id","is-drag-over","onDragStart","onDragEnd","onDragOver","onDragLeave","onDrop"])])),64))])])),p(P,{open:a.value,task:s.value,"default-date":f(V),onClose:E,onSave:N},null,8,["open","task","default-date"])]))}});export{_t as default}; diff --git a/src/static/assets/TasksView-v6kl3APd.js b/src/static/assets/TasksView-v6kl3APd.js new file mode 100644 index 0000000..7ef2ca9 --- /dev/null +++ b/src/static/assets/TasksView-v6kl3APd.js @@ -0,0 +1 @@ +import{u as L}from"./tasks-caOFGu41.js";import{u as A,a as K,_ as P}from"./TaskForm.vue_vue_type_script_setup_true_lang-BWg_Q6_w.js";import{s as b,d as j,o as d,c,n as T,a as n,e as p,w as S,t as D,i as $,F as C,r as O,k as B,A as z,h as f,q as I,j as F,K as _}from"./index-aIsLHJPY.js";import{_ as M}from"./Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js";import{_ as H}from"./EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js";import{_ as U}from"./Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js";import{_ as q}from"./Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js";import"./Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js";import"./Input.vue_vue_type_script_setup_true_lang-DulGPujX.js";import"./utils-7WVCegLb.js";import"./projects-BYok-JQo.js";import"./devops-DsTCxAug.js";function G(){const t=L(),l=b(null),o=b(null);function u(k,g){var x;l.value=k.id,(x=g.dataTransfer)==null||x.setData("task_id",k.id),g.dataTransfer&&(g.dataTransfer.effectAllowed="move")}function m(){l.value=null,o.value=null}function a(k,g){g.preventDefault(),o.value=k,g.dataTransfer&&(g.dataTransfer.dropEffect="move")}function s(){o.value=null}async function v(k,g,x){var h;x.preventDefault(),o.value=null;const w=(h=x.dataTransfer)==null?void 0:h.getData("task_id");w&&(l.value=null,await t.update(w,{status:k,sort_index:g}))}return{draggingId:l,dragOverColumn:o,onDragStart:u,onDragEnd:m,onDragOver:a,onDragLeave:s,onDrop:v}}const J={class:"flex items-start gap-2"},Q={class:"flex-1 min-w-0"},R={class:"text-sm font-medium text-slate-800 leading-snug line-clamp-2"},W={class:"flex flex-wrap items-center gap-1.5 mt-1.5"},X=["title"],Y={key:1,class:"text-[10px] px-1.5 py-0.5 rounded-md bg-blue-50 text-blue-500 font-medium shrink-0"},Z={key:2,class:"text-[10px] text-slate-400 shrink-0"},tt=j({__name:"KanbanCard",props:{task:{},dragging:{type:Boolean}},emits:["edit"],setup(t,{emit:l}){const o=l,u={1:"bg-red-500",2:"bg-orange-400",3:"bg-slate-300",4:"bg-slate-300",5:"bg-slate-300"};return(m,a)=>(d(),c("div",{class:T(["group relative bg-white rounded-xl border border-slate-200/80 px-3 py-2.5 cursor-grab active:cursor-grabbing shadow-sm hover:shadow-md hover:border-orange-200 transition-all duration-150 select-none",t.dragging?"opacity-40 scale-95":"opacity-100"]),draggable:"true",onClick:a[0]||(a[0]=s=>o("edit",t.task))},[n("div",J,[p(M,{content:`Priority ${t.task.priority}`},{default:S(()=>[n("span",{class:T(["mt-1.5 h-2 w-2 rounded-full shrink-0",u[t.task.priority]??"bg-slate-300"])},null,2)]),_:1},8,["content"]),n("div",Q,[n("p",R,D(t.task.title),1),n("div",W,[t.task.project_name?(d(),c("span",{key:0,class:"text-[10px] px-1.5 py-0.5 rounded-md bg-slate-100 text-slate-500 font-medium truncate max-w-[100px]",title:t.task.project_name},D(t.task.project_name),9,X)):$("",!0),t.task.azure_work_item_id?(d(),c("span",Y," ADO ")):$("",!0),t.task.planned_date?(d(),c("span",Z,D(t.task.planned_date),1)):$("",!0)])])])],2))}}),et={class:"flex flex-col min-h-0 w-full"},at={class:"flex items-center justify-between px-1 mb-2"},st={class:"flex items-center gap-2"},nt={class:"text-xs font-semibold uppercase tracking-wider text-slate-500"},rt={class:"text-[10px] font-semibold bg-slate-100 text-slate-400 px-1.5 py-0.5 rounded-full leading-none"},ot=j({__name:"KanbanColumn",props:{status:{},title:{},tasks:{},draggingId:{},isDragOver:{type:Boolean}},emits:["dragStart","dragEnd","dragOver","dragLeave","drop","editTask","addTask"],setup(t,{emit:l}){const o=l,u={todo:"border-t-slate-300",doing:"border-t-orange-400",testing:"border-t-blue-400",done:"border-t-emerald-400"};return(m,a)=>(d(),c("div",et,[n("div",at,[n("div",st,[n("h3",nt,D(t.title),1),n("span",rt,D(t.tasks.length),1)]),n("button",{class:"h-5 w-5 rounded flex items-center justify-center text-slate-400 hover:text-orange-500 hover:bg-orange-50 transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring","aria-label":"Add task",onClick:a[0]||(a[0]=s=>o("addTask",t.status))},[...a[5]||(a[5]=[n("svg",{class:"h-3.5 w-3.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[n("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2.5",d:"M12 4v16m8-8H4"})],-1)])])]),n("div",{class:T(["flex-1 rounded-xl border-2 border-dashed transition-all duration-150 p-2 space-y-2 min-h-[120px]",`border-t-4 ${u[t.status]??"border-t-slate-300"}`,t.isDragOver?"border-orange-300 bg-orange-50/60":"border-transparent bg-slate-50/60"]),onDragover:a[2]||(a[2]=s=>o("dragOver",t.status,s)),onDragleave:a[3]||(a[3]=s=>o("dragLeave")),onDrop:a[4]||(a[4]=s=>o("drop",t.status,t.tasks.length,s))},[(d(!0),c(C,null,O(t.tasks,s=>(d(),B(tt,{key:s.id,task:s,dragging:t.draggingId===s.id,onDragstart:v=>o("dragStart",s,v),onDragend:a[1]||(a[1]=v=>o("dragEnd")),onEdit:v=>o("editTask",s)},null,8,["task","dragging","onDragstart","onEdit"]))),128)),t.tasks.length===0&&!t.isDragOver?(d(),B(H,{key:0,size:"sm",title:"No tasks here",description:"Drag a card here or click + to add"})):$("",!0)],34)]))}}),lt={class:"flex flex-col h-full overflow-hidden"},it={class:"flex items-center gap-3 px-6 py-4 border-b border-slate-100 bg-white/60 shrink-0"},dt=["value"],ut={key:0,class:"flex items-center justify-center flex-1"},ct={key:1,class:"flex-1 overflow-x-auto overflow-y-hidden"},gt={class:"grid grid-cols-4 gap-4 p-6 h-full min-w-[700px]"},_t=j({__name:"TasksView",setup(t){const l=L(),o=A(),u=G(),m=b(""),a=b(!1),s=b(null),v=b("todo"),k=[{status:"todo",title:"To Do"},{status:"doing",title:"Doing"},{status:"testing",title:"Testing"},{status:"done",title:"Done"}];z(async()=>{await Promise.all([l.fetchAll(),o.fetchProjects()])});const g=F(()=>{const i=l.tasks.filter(e=>e.status!=="cancelled");return m.value?i.filter(e=>e.project_id===m.value):i});function x(i){let e=g.value.filter(r=>r.status===i);return e=[...e].sort((r,y)=>r.sort_index-y.sort_index||r.created_at.localeCompare(y.created_at)),i==="done"&&(e=e.slice(-30)),e}function w(i){v.value=i,s.value=null,a.value=!0}function h(i){s.value=i,a.value=!0}function E(){a.value=!1,s.value=null}async function N(i,e){try{if(s.value)await l.update(s.value.id,i),e&&await l.createBlock(s.value.id,e),_.success("Task updated");else{const r={...i,status:i.status||v.value},y=await l.create(r);e&&await l.createBlock(y.id,e),_.success("Task created")}}catch{_.error("Failed to save task")}E()}const V=new Date().toISOString().split("T")[0];return(i,e)=>(d(),c("div",lt,[n("div",it,[e[4]||(e[4]=n("h2",{class:"text-sm font-semibold text-slate-800 mr-2"},"Kanban",-1)),p(K,{modelValue:m.value,"onUpdate:modelValue":e[0]||(e[0]=r=>m.value=r),class:"w-44 text-xs"},{default:S(()=>[e[2]||(e[2]=n("option",{value:""},"All projects",-1)),(d(!0),c(C,null,O(f(o).projects,r=>(d(),c("option",{key:r.id,value:r.id},D(r.display_name),9,dt))),128))]),_:1},8,["modelValue"]),e[5]||(e[5]=n("div",{class:"flex-1"},null,-1)),p(U,{size:"sm",onClick:e[1]||(e[1]=r=>w("todo"))},{default:S(()=>[...e[3]||(e[3]=[n("svg",{class:"h-3.5 w-3.5 mr-1.5",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24"},[n("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2.5",d:"M12 4v16m8-8H4"})],-1),I(" New task ",-1)])]),_:1})]),f(l).loading?(d(),c("div",ut,[p(q,{size:"lg",class:"text-primary"})])):(d(),c("div",ct,[n("div",gt,[(d(),c(C,null,O(k,r=>n("div",{key:r.status,class:"flex flex-col min-h-0 overflow-y-auto"},[p(ot,{status:r.status,title:r.title,tasks:x(r.status),"dragging-id":f(u).draggingId.value,"is-drag-over":f(u).dragOverColumn.value===r.status,onDragStart:f(u).onDragStart,onDragEnd:f(u).onDragEnd,onDragOver:f(u).onDragOver,onDragLeave:f(u).onDragLeave,onDrop:f(u).onDrop,onEditTask:h,onAddTask:w},null,8,["status","title","tasks","dragging-id","is-drag-over","onDragStart","onDragEnd","onDragOver","onDragLeave","onDrop"])])),64))])])),p(P,{open:a.value,task:s.value,"default-date":f(V),onClose:E,onSave:N},null,8,["open","task","default-date"])]))}});export{_t as default}; diff --git a/src/static/assets/Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js b/src/static/assets/Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js deleted file mode 100644 index 4d491f3..0000000 --- a/src/static/assets/Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js +++ /dev/null @@ -1 +0,0 @@ -import{c as r}from"./utils-7WVCegLb.js";import{d as t,o as n,c as i,n as u,h as c}from"./index-BiYpJJoC.js";const m=["id","value","placeholder","disabled","rows"],g=t({__name:"Textarea",props:{modelValue:{},placeholder:{},disabled:{type:Boolean},rows:{},class:{},id:{}},emits:["update:modelValue"],setup(e,{emit:l}){const a=e,s=l;return(f,o)=>(n(),i("textarea",{id:e.id,value:e.modelValue,placeholder:e.placeholder,disabled:e.disabled,rows:e.rows??3,class:u(c(r)("flex w-full rounded-md border border-input bg-background px-3 py-2 text-sm","ring-offset-background placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50 resize-none",a.class)),onInput:o[0]||(o[0]=d=>s("update:modelValue",d.target.value))},null,42,m))}});export{g as _}; diff --git a/src/static/assets/Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js b/src/static/assets/Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js similarity index 93% rename from src/static/assets/Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js rename to src/static/assets/Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js index 5bd7c95..2993497 100644 --- a/src/static/assets/Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js +++ b/src/static/assets/Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js @@ -1 +1 @@ -import{d,k as i,w as t,h as e,W as r,o as l,e as s,p as n,J as f,U as m,n as c,q as u,t as p,L as g}from"./index-BiYpJJoC.js";import{c as x}from"./utils-7WVCegLb.js";const w=d({__name:"Tooltip",props:{content:{},side:{default:"top"},sideOffset:{default:6}},setup(a){return(o,h)=>(l(),i(e(r),null,{default:t(()=>[s(e(f),{"as-child":""},{default:t(()=>[n(o.$slots,"default")]),_:3}),s(e(g),null,{default:t(()=>[s(e(m),{side:a.side,"side-offset":a.sideOffset,class:c(e(x)("z-50 max-w-[280px] rounded-lg border border-border bg-popover px-3 py-1.5","text-xs text-popover-foreground shadow-md","animate-in fade-in-0 zoom-in-95","data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95","data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2","data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2"))},{default:t(()=>[u(p(a.content),1)]),_:1},8,["side","side-offset","class"])]),_:1})]),_:3}))}});export{w as _}; +import{d,k as i,w as t,h as e,W as r,o as l,e as s,p as n,J as f,U as m,n as c,q as u,t as p,L as g}from"./index-aIsLHJPY.js";import{c as x}from"./utils-7WVCegLb.js";const w=d({__name:"Tooltip",props:{content:{},side:{default:"top"},sideOffset:{default:6}},setup(a){return(o,h)=>(l(),i(e(r),null,{default:t(()=>[s(e(f),{"as-child":""},{default:t(()=>[n(o.$slots,"default")]),_:3}),s(e(g),null,{default:t(()=>[s(e(m),{side:a.side,"side-offset":a.sideOffset,class:c(e(x)("z-50 max-w-[280px] rounded-lg border border-border bg-popover px-3 py-1.5","text-xs text-popover-foreground shadow-md","animate-in fade-in-0 zoom-in-95","data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95","data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2","data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2"))},{default:t(()=>[u(p(a.content),1)]),_:1},8,["side","side-offset","class"])]),_:1})]),_:3}))}});export{w as _}; diff --git a/src/static/assets/admin-BG8iXstk.js b/src/static/assets/admin-DlFdRGBL.js similarity index 68% rename from src/static/assets/admin-BG8iXstk.js rename to src/static/assets/admin-DlFdRGBL.js index c0d467d..87f4526 100644 --- a/src/static/assets/admin-BG8iXstk.js +++ b/src/static/assets/admin-DlFdRGBL.js @@ -1 +1 @@ -import{D as e}from"./index-BiYpJJoC.js";const i={users:()=>e.get("/api/admin/users"),keys:()=>e.get("/api/keys"),createKey:s=>e.post("/api/keys",s),revokeKey:s=>e.delete(`/api/keys/${s}`)};export{i as a}; +import{D as e}from"./index-aIsLHJPY.js";const i={users:()=>e.get("/api/admin/users"),keys:()=>e.get("/api/keys"),createKey:s=>e.post("/api/keys",s),revokeKey:s=>e.delete(`/api/keys/${s}`)};export{i as a}; diff --git a/src/static/assets/calendar-C9xlMu6k.js b/src/static/assets/calendar-CF-bck6k.js similarity index 87% rename from src/static/assets/calendar-C9xlMu6k.js rename to src/static/assets/calendar-CF-bck6k.js index 69da99f..24a9927 100644 --- a/src/static/assets/calendar-C9xlMu6k.js +++ b/src/static/assets/calendar-CF-bck6k.js @@ -1,4 +1,4 @@ -import{c as e}from"./createLucideIcon-D7qP-VdO.js";/** +import{c as e}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/calendar-days-DjiBFm4u.js b/src/static/assets/calendar-days-Bx0aIed-.js similarity index 91% rename from src/static/assets/calendar-days-DjiBFm4u.js rename to src/static/assets/calendar-days-Bx0aIed-.js index ef96367..3bd1cef 100644 --- a/src/static/assets/calendar-days-DjiBFm4u.js +++ b/src/static/assets/calendar-days-Bx0aIed-.js @@ -1,4 +1,4 @@ -import{c as h}from"./createLucideIcon-D7qP-VdO.js";/** +import{c as h}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/createLucideIcon-D7qP-VdO.js b/src/static/assets/createLucideIcon-B5Z2hHtI.js similarity index 96% rename from src/static/assets/createLucideIcon-D7qP-VdO.js rename to src/static/assets/createLucideIcon-B5Z2hHtI.js index 5172b39..b3f14ca 100644 --- a/src/static/assets/createLucideIcon-D7qP-VdO.js +++ b/src/static/assets/createLucideIcon-B5Z2hHtI.js @@ -1,4 +1,4 @@ -import{a1 as a}from"./index-BiYpJJoC.js";/** +import{a1 as a}from"./index-aIsLHJPY.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/dashboard-Ca6WcfdV.js b/src/static/assets/dashboard-CdOgDJq5.js similarity index 88% rename from src/static/assets/dashboard-Ca6WcfdV.js rename to src/static/assets/dashboard-CdOgDJq5.js index 234f56f..314f492 100644 --- a/src/static/assets/dashboard-Ca6WcfdV.js +++ b/src/static/assets/dashboard-CdOgDJq5.js @@ -1 +1 @@ -import{D as t}from"./index-BiYpJJoC.js";const e={summary:a=>t.get("/api/dashboard/summary",{params:a}),projects:a=>t.get("/api/dashboard/projects",{params:a}),timeline:a=>t.get("/api/dashboard/timeline",{params:a}),monthly:a=>t.get("/api/dashboard/monthly",{params:a}),dow:a=>t.get("/api/dashboard/dow",{params:a}),tools:a=>t.get("/api/dashboard/tools",{params:a}),activity:a=>t.get("/api/dashboard/activity",{params:a}),calendar:a=>t.get("/api/dashboard/calendar",{params:a}),project:(a,o)=>t.get("/api/dashboard/project/"+a,{params:o})};export{e as d}; +import{D as t}from"./index-aIsLHJPY.js";const e={summary:a=>t.get("/api/dashboard/summary",{params:a}),projects:a=>t.get("/api/dashboard/projects",{params:a}),timeline:a=>t.get("/api/dashboard/timeline",{params:a}),monthly:a=>t.get("/api/dashboard/monthly",{params:a}),dow:a=>t.get("/api/dashboard/dow",{params:a}),tools:a=>t.get("/api/dashboard/tools",{params:a}),activity:a=>t.get("/api/dashboard/activity",{params:a}),calendar:a=>t.get("/api/dashboard/calendar",{params:a}),project:(a,o)=>t.get("/api/dashboard/project/"+a,{params:o})};export{e as d}; diff --git a/src/static/assets/devops-y1AYKG_U.js b/src/static/assets/devops-DsTCxAug.js similarity index 94% rename from src/static/assets/devops-y1AYKG_U.js rename to src/static/assets/devops-DsTCxAug.js index a527f4b..3e4fae6 100644 --- a/src/static/assets/devops-y1AYKG_U.js +++ b/src/static/assets/devops-DsTCxAug.js @@ -1 +1 @@ -import{D as n,B as I,s as o}from"./index-BiYpJJoC.js";const i={getIntegration:()=>n.get("/api/devops/integration"),saveIntegration:e=>n.put("/api/devops/integration",e),deleteIntegration:()=>n.delete("/api/devops/integration"),sync:()=>n.post("/api/devops/sync"),workItems:e=>n.get("/api/devops/work-items",{params:e?{state:e}:void 0}),cloneWorkItem:e=>n.post(`/api/devops/work-items/${e}/clone`)},m=I("devops",()=>{const e=o(null),l=o([]),r=o(!1),s=o(!1),c=o(null);async function u(){s.value=!0;try{const t=await i.getIntegration();e.value=t.data}catch{e.value=null}finally{s.value=!1}}async function d(t){const a=await i.saveIntegration(t);e.value=a.data}async function g(){await i.deleteIntegration(),e.value=null}async function f(){var t,a;r.value=!0,c.value=null;try{await i.sync(),await u()}catch(v){const p=v;throw c.value=((a=(t=p.response)==null?void 0:t.data)==null?void 0:a.detail)??p.message??"Sync failed",v}finally{r.value=!1}}async function y(t){s.value=!0;try{const a=await i.workItems(t);l.value=a.data}catch{l.value=[]}finally{s.value=!1}}return{integration:e,workItems:l,syncing:r,loading:s,error:c,fetchIntegration:u,saveIntegration:d,deleteIntegration:g,sync:f,fetchWorkItems:y}});export{i as d,m as u}; +import{D as n,B as I,s as o}from"./index-aIsLHJPY.js";const i={getIntegration:()=>n.get("/api/devops/integration"),saveIntegration:e=>n.put("/api/devops/integration",e),deleteIntegration:()=>n.delete("/api/devops/integration"),sync:()=>n.post("/api/devops/sync"),workItems:e=>n.get("/api/devops/work-items",{params:e?{state:e}:void 0}),cloneWorkItem:e=>n.post(`/api/devops/work-items/${e}/clone`)},m=I("devops",()=>{const e=o(null),l=o([]),r=o(!1),s=o(!1),c=o(null);async function u(){s.value=!0;try{const t=await i.getIntegration();e.value=t.data}catch{e.value=null}finally{s.value=!1}}async function d(t){const a=await i.saveIntegration(t);e.value=a.data}async function g(){await i.deleteIntegration(),e.value=null}async function f(){var t,a;r.value=!0,c.value=null;try{await i.sync(),await u()}catch(v){const p=v;throw c.value=((a=(t=p.response)==null?void 0:t.data)==null?void 0:a.detail)??p.message??"Sync failed",v}finally{r.value=!1}}async function y(t){s.value=!0;try{const a=await i.workItems(t);l.value=a.data}catch{l.value=[]}finally{s.value=!1}}return{integration:e,workItems:l,syncing:r,loading:s,error:c,fetchIntegration:u,saveIntegration:d,deleteIntegration:g,sync:f,fetchWorkItems:y}});export{i as d,m as u}; diff --git a/src/static/assets/file-text-C0mXX88J.js b/src/static/assets/file-text-CF0U4KSF.js similarity index 89% rename from src/static/assets/file-text-C0mXX88J.js rename to src/static/assets/file-text-CF0U4KSF.js index 7ca4c58..d5c8f8b 100644 --- a/src/static/assets/file-text-C0mXX88J.js +++ b/src/static/assets/file-text-CF0U4KSF.js @@ -1,4 +1,4 @@ -import{c as e}from"./createLucideIcon-D7qP-VdO.js";/** +import{c as e}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/format-WqwOLoqz.js b/src/static/assets/format-DDf_am8g.js similarity index 99% rename from src/static/assets/format-WqwOLoqz.js rename to src/static/assets/format-DDf_am8g.js index ee5afd4..8f2b4e7 100644 --- a/src/static/assets/format-WqwOLoqz.js +++ b/src/static/assets/format-DDf_am8g.js @@ -1,4 +1,4 @@ -import{c as X}from"./createLucideIcon-D7qP-VdO.js";/** +import{c as X}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/index-Crx9eGr0.css b/src/static/assets/index-Crx9eGr0.css new file mode 100644 index 0000000..34dabdd --- /dev/null +++ b/src/static/assets/index-Crx9eGr0.css @@ -0,0 +1 @@ +@import"https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap";*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}:root{--background: 220 33% 96%;--foreground: 222 47% 11%;--card: 0 0% 100%;--card-foreground: 222 47% 11%;--popover: 0 0% 100%;--popover-foreground: 222 47% 11%;--primary: 25 95% 53%;--primary-foreground: 0 0% 100%;--secondary: 200 85% 50%;--secondary-foreground: 0 0% 100%;--muted: 220 20% 93%;--muted-foreground: 215 20% 48%;--accent: 25 100% 96%;--accent-foreground: 25 95% 40%;--destructive: 0 84% 60%;--destructive-foreground: 0 0% 100%;--border: 220 20% 88%;--input: 220 20% 88%;--ring: 25 95% 53%;--radius: .75rem;--success: 142 71% 45%;--warning: 38 92% 50%}.dark{--background: 226 49% 8%;--foreground: 220 40% 92%;--card: 220 44% 10%;--card-foreground: 220 40% 92%;--popover: 220 44% 12%;--popover-foreground: 220 40% 92%;--primary: 25 95% 60%;--primary-foreground: 226 49% 8%;--secondary: 200 85% 55%;--secondary-foreground: 226 49% 8%;--muted: 220 30% 14%;--muted-foreground: 220 12% 52%;--accent: 220 30% 14%;--accent-foreground: 220 40% 92%;--destructive: 0 72% 51%;--destructive-foreground: 220 40% 98%;--border: 220 28% 17%;--input: 220 28% 17%;--ring: 25 95% 60%;--success: 158 64% 52%;--warning: 38 92% 60%}*{border-color:hsl(var(--border))}body{background-color:hsl(var(--background));color:hsl(var(--foreground));font-family:Inter,system-ui,-apple-system,sans-serif;font-feature-settings:"rlig" 1,"calt" 1;-webkit-font-smoothing:antialiased}.tabular-nums,[data-value],.kpi-value{font-family:JetBrains Mono,ui-monospace,monospace;font-variant-numeric:tabular-nums}::-webkit-scrollbar{width:4px;height:4px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:#c2c9d6;border-radius:9999px}::-webkit-scrollbar-thumb:hover{background:#9da8be}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.inset-y-0{top:0;bottom:0}.-right-2{right:-.5rem}.-right-6{right:-1.5rem}.-top-2{top:-.5rem}.-top-6{top:-1.5rem}.bottom-0{bottom:0}.left-0{left:0}.left-1\/2{left:50%}.right-0{right:0}.right-2{right:.5rem}.top-0{top:0}.top-1\/2{top:50%}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.mx-1{margin-left:.25rem;margin-right:.25rem}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.ml-2{margin-left:.5rem}.ml-auto{margin-left:auto}.mr-1\.5{margin-right:.375rem}.mr-2{margin-right:.5rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.mt-auto{margin-top:auto}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.\!block{display:block!important}.block{display:block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.hidden{display:none}.h-0\.5{height:.125rem}.h-1\.5{height:.375rem}.h-10{height:2.5rem}.h-11{height:2.75rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-20{height:5rem}.h-24{height:6rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-32{height:8rem}.h-4{height:1rem}.h-40{height:10rem}.h-48{height:12rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-64{height:16rem}.h-7{height:1.75rem}.h-8{height:2rem}.h-9{height:2.25rem}.h-full{height:100%}.h-screen{height:100vh}.max-h-\[85vh\]{max-height:85vh}.min-h-0{min-height:0px}.min-h-\[120px\]{min-height:120px}.min-h-screen{min-height:100vh}.w-1{width:.25rem}.w-1\.5{width:.375rem}.w-10{width:2.5rem}.w-11{width:2.75rem}.w-12{width:3rem}.w-14{width:3.5rem}.w-16{width:4rem}.w-2{width:.5rem}.w-20{width:5rem}.w-24{width:6rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-32{width:8rem}.w-36{width:9rem}.w-4{width:1rem}.w-44{width:11rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-60{width:15rem}.w-7{width:1.75rem}.w-72{width:18rem}.w-8{width:2rem}.w-9{width:2.25rem}.w-auto{width:auto}.w-full{width:100%}.w-px{width:1px}.min-w-0{min-width:0px}.min-w-\[700px\]{min-width:700px}.max-w-2xl{max-width:42rem}.max-w-\[100px\]{max-width:100px}.max-w-\[120px\]{max-width:120px}.max-w-\[160px\]{max-width:160px}.max-w-\[200px\]{max-width:200px}.max-w-\[280px\]{max-width:280px}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-none{max-width:none}.max-w-sm{max-width:24rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.table-fixed{table-layout:fixed}.border-collapse{border-collapse:collapse}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-x-full{--tw-translate-x: -100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-1{--tw-translate-y: .25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rotate-6{--tw-rotate: -6deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate: 180deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-6{--tw-rotate: 6deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.scale-95{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-col-resize{cursor:col-resize}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-s-resize{cursor:s-resize}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-none{resize:none}.resize{resize:both}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))}.grid-cols-\[1fr_1fr_120px_180px_96px\]{grid-template-columns:1fr 1fr 120px 180px 96px}.grid-cols-\[1fr_auto_auto_auto_auto\]{grid-template-columns:1fr auto auto auto auto}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.gap-px{gap:1px}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.space-y-0>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(0px * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(0px * var(--tw-space-y-reverse))}.space-y-0\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.125rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.125rem * var(--tw-space-y-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-2\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.625rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.625rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.space-y-8>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(2rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(2rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.overflow-y-hidden{overflow-y:hidden}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-none{border-radius:0}.rounded-xl{border-radius:.75rem}.rounded-l-md{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.rounded-r-full{border-top-right-radius:9999px;border-bottom-right-radius:9999px}.rounded-r-md{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-0{border-width:0px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-l{border-left-width:1px}.border-r{border-right-width:1px}.border-t{border-top-width:1px}.border-t-4{border-top-width:4px}.border-dashed{border-style:dashed}.border-amber-500\/30{border-color:#f59e0b4d}.border-blue-100{--tw-border-opacity: 1;border-color:rgb(219 234 254 / var(--tw-border-opacity, 1))}.border-border{border-color:hsl(var(--border))}.border-border\/20{border-color:hsl(var(--border) / .2)}.border-border\/30{border-color:hsl(var(--border) / .3)}.border-border\/40{border-color:hsl(var(--border) / .4)}.border-border\/50{border-color:hsl(var(--border) / .5)}.border-border\/60{border-color:hsl(var(--border) / .6)}.border-border\/70{border-color:hsl(var(--border) / .7)}.border-destructive\/30{border-color:hsl(var(--destructive) / .3)}.border-emerald-100{--tw-border-opacity: 1;border-color:rgb(209 250 229 / var(--tw-border-opacity, 1))}.border-emerald-500\/30{border-color:#10b9814d}.border-input{border-color:hsl(var(--input))}.border-muted-foreground\/30{border-color:hsl(var(--muted-foreground) / .3)}.border-orange-300{--tw-border-opacity: 1;border-color:rgb(253 186 116 / var(--tw-border-opacity, 1))}.border-primary{border-color:hsl(var(--primary))}.border-primary\/20{border-color:hsl(var(--primary) / .2)}.border-slate-100{--tw-border-opacity: 1;border-color:rgb(241 245 249 / var(--tw-border-opacity, 1))}.border-slate-200\/80{border-color:#e2e8f0cc}.border-transparent{border-color:transparent}.border-t-blue-400{--tw-border-opacity: 1;border-top-color:rgb(96 165 250 / var(--tw-border-opacity, 1))}.border-t-emerald-400{--tw-border-opacity: 1;border-top-color:rgb(52 211 153 / var(--tw-border-opacity, 1))}.border-t-orange-400{--tw-border-opacity: 1;border-top-color:rgb(251 146 60 / var(--tw-border-opacity, 1))}.border-t-slate-300{--tw-border-opacity: 1;border-top-color:rgb(203 213 225 / var(--tw-border-opacity, 1))}.bg-amber-500{--tw-bg-opacity: 1;background-color:rgb(245 158 11 / var(--tw-bg-opacity, 1))}.bg-amber-500\/10{background-color:#f59e0b1a}.bg-amber-500\/20{background-color:#f59e0b33}.bg-background{background-color:hsl(var(--background))}.bg-black\/5{background-color:#0000000d}.bg-black\/60{background-color:#0009}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.bg-border{background-color:hsl(var(--border))}.bg-card{background-color:hsl(var(--card))}.bg-destructive{background-color:hsl(var(--destructive))}.bg-destructive\/10{background-color:hsl(var(--destructive) / .1)}.bg-destructive\/20{background-color:hsl(var(--destructive) / .2)}.bg-destructive\/90{background-color:hsl(var(--destructive) / .9)}.bg-emerald-400{--tw-bg-opacity: 1;background-color:rgb(52 211 153 / var(--tw-bg-opacity, 1))}.bg-emerald-50{--tw-bg-opacity: 1;background-color:rgb(236 253 245 / var(--tw-bg-opacity, 1))}.bg-emerald-500{--tw-bg-opacity: 1;background-color:rgb(16 185 129 / var(--tw-bg-opacity, 1))}.bg-emerald-500\/10{background-color:#10b9811a}.bg-emerald-500\/20{background-color:#10b98133}.bg-muted{background-color:hsl(var(--muted))}.bg-muted-foreground\/30{background-color:hsl(var(--muted-foreground) / .3)}.bg-muted\/30{background-color:hsl(var(--muted) / .3)}.bg-muted\/40{background-color:hsl(var(--muted) / .4)}.bg-muted\/50{background-color:hsl(var(--muted) / .5)}.bg-orange-400{--tw-bg-opacity: 1;background-color:rgb(251 146 60 / var(--tw-bg-opacity, 1))}.bg-orange-50{--tw-bg-opacity: 1;background-color:rgb(255 247 237 / var(--tw-bg-opacity, 1))}.bg-orange-50\/60{background-color:#fff7ed99}.bg-orange-500{--tw-bg-opacity: 1;background-color:rgb(249 115 22 / var(--tw-bg-opacity, 1))}.bg-primary{background-color:hsl(var(--primary))}.bg-primary\/10{background-color:hsl(var(--primary) / .1)}.bg-primary\/15{background-color:hsl(var(--primary) / .15)}.bg-primary\/20{background-color:hsl(var(--primary) / .2)}.bg-primary\/5{background-color:hsl(var(--primary) / .05)}.bg-primary\/70{background-color:hsl(var(--primary) / .7)}.bg-primary\/90{background-color:hsl(var(--primary) / .9)}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-rose-500{--tw-bg-opacity: 1;background-color:rgb(244 63 94 / var(--tw-bg-opacity, 1))}.bg-rose-500\/10{background-color:#f43f5e1a}.bg-secondary{background-color:hsl(var(--secondary))}.bg-secondary\/80{background-color:hsl(var(--secondary) / .8)}.bg-slate-100{--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity, 1))}.bg-slate-300{--tw-bg-opacity: 1;background-color:rgb(203 213 225 / var(--tw-bg-opacity, 1))}.bg-slate-50{--tw-bg-opacity: 1;background-color:rgb(248 250 252 / var(--tw-bg-opacity, 1))}.bg-slate-50\/60{background-color:#f8fafc99}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\/40{background-color:#fff6}.bg-white\/60{background-color:#fff9}.bg-white\/80{background-color:#fffc}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.from-orange-400{--tw-gradient-from: #fb923c var(--tw-gradient-from-position);--tw-gradient-to: rgb(251 146 60 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.to-orange-600{--tw-gradient-to: #ea580c var(--tw-gradient-to-position)}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0{padding:0}.p-1{padding:.25rem}.p-1\.5{padding:.375rem}.p-12{padding:3rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.p-8{padding:2rem}.px-0{padding-left:0;padding-right:0}.px-1{padding-left:.25rem;padding-right:.25rem}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-0{padding-top:0;padding-bottom:0}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-8{padding-top:2rem;padding-bottom:2rem}.pb-2{padding-bottom:.5rem}.pb-4{padding-bottom:1rem}.pb-6{padding-bottom:1.5rem}.pt-0{padding-top:0}.pt-3{padding-top:.75rem}.pt-4{padding-top:1rem}.pt-6{padding-top:1.5rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\[10px\]{font-size:10px}.text-\[11px\]{font-size:11px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.italic{font-style:italic}.tabular-nums{--tw-numeric-spacing: tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.leading-none{line-height:1}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.tracking-wider{letter-spacing:.05em}.tracking-widest{letter-spacing:.1em}.text-accent-foreground{color:hsl(var(--accent-foreground))}.text-amber-400{--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.text-amber-500{--tw-text-opacity: 1;color:rgb(245 158 11 / var(--tw-text-opacity, 1))}.text-amber-700{--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity, 1))}.text-blue-400{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.text-card-foreground{color:hsl(var(--card-foreground))}.text-current{color:currentColor}.text-destructive{color:hsl(var(--destructive))}.text-destructive-foreground{color:hsl(var(--destructive-foreground))}.text-emerald-400{--tw-text-opacity: 1;color:rgb(52 211 153 / var(--tw-text-opacity, 1))}.text-emerald-600{--tw-text-opacity: 1;color:rgb(5 150 105 / var(--tw-text-opacity, 1))}.text-emerald-700{--tw-text-opacity: 1;color:rgb(4 120 87 / var(--tw-text-opacity, 1))}.text-foreground{color:hsl(var(--foreground))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-muted-foreground{color:hsl(var(--muted-foreground))}.text-muted-foreground\/20{color:hsl(var(--muted-foreground) / .2)}.text-muted-foreground\/30{color:hsl(var(--muted-foreground) / .3)}.text-muted-foreground\/40{color:hsl(var(--muted-foreground) / .4)}.text-muted-foreground\/60{color:hsl(var(--muted-foreground) / .6)}.text-orange-500{--tw-text-opacity: 1;color:rgb(249 115 22 / var(--tw-text-opacity, 1))}.text-orange-600{--tw-text-opacity: 1;color:rgb(234 88 12 / var(--tw-text-opacity, 1))}.text-primary{color:hsl(var(--primary))}.text-primary-foreground{color:hsl(var(--primary-foreground))}.text-red-400{--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-rose-600{--tw-text-opacity: 1;color:rgb(225 29 72 / var(--tw-text-opacity, 1))}.text-rose-700{--tw-text-opacity: 1;color:rgb(190 18 60 / var(--tw-text-opacity, 1))}.text-secondary-foreground{color:hsl(var(--secondary-foreground))}.text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.text-slate-500{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity, 1))}.text-slate-700{--tw-text-opacity: 1;color:rgb(51 65 85 / var(--tw-text-opacity, 1))}.text-slate-800{--tw-text-opacity: 1;color:rgb(30 41 59 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.underline-offset-4{text-underline-offset:4px}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-25{opacity:.25}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-75{opacity:.75}.opacity-80{opacity:.8}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-emerald-200{--tw-shadow-color: #a7f3d0;--tw-shadow: var(--tw-shadow-colored)}.shadow-orange-200{--tw-shadow-color: #fed7aa;--tw-shadow: var(--tw-shadow-colored)}.shadow-slate-100\/60{--tw-shadow-color: rgb(241 245 249 / .6);--tw-shadow: var(--tw-shadow-colored)}.outline{outline-style:solid}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-amber-500\/20{--tw-ring-color: rgb(245 158 11 / .2)}.ring-border{--tw-ring-color: hsl(var(--border))}.ring-emerald-500\/20{--tw-ring-color: rgb(16 185 129 / .2)}.ring-primary{--tw-ring-color: hsl(var(--primary))}.ring-primary\/20{--tw-ring-color: hsl(var(--primary) / .2)}.ring-rose-500\/20{--tw-ring-color: rgb(244 63 94 / .2)}.ring-offset-background{--tw-ring-offset-color: hsl(var(--background))}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-xl{--tw-backdrop-blur: blur(24px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}.glass-card{background:#ffffffb8;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);border:1px solid rgba(255,255,255,.85);box-shadow:0 1px 3px #0000000f,0 8px 32px #0000000f}.panel-glow{box-shadow:0 1px 3px #0000000f,0 8px 32px #0000000f;border:1px solid rgba(255,255,255,.9)}.dark .panel-glow{box-shadow:0 0 0 1px hsl(var(--border)),0 4px 24px -4px #05080f99;border-color:hsl(var(--border))}@keyframes fadeIn{0%{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}@keyframes slideUp{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}@keyframes shimmer{0%{background-position:-1000px 0}to{background-position:1000px 0}}.skeleton-shimmer{background:linear-gradient(90deg,hsl(var(--muted)),hsl(var(--accent)),hsl(var(--muted)));background-size:1000px 100%;animation:shimmer 1.6s linear infinite}.file\:border-0::file-selector-button{border-width:0px}.file\:bg-transparent::file-selector-button{background-color:transparent}.file\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\:font-medium::file-selector-button{font-weight:500}.placeholder\:text-muted-foreground::-moz-placeholder{color:hsl(var(--muted-foreground))}.placeholder\:text-muted-foreground::placeholder{color:hsl(var(--muted-foreground))}.last\:border-0:last-child{border-width:0px}.hover\:border-foreground\/30:hover{border-color:hsl(var(--foreground) / .3)}.hover\:border-orange-200:hover{--tw-border-opacity: 1;border-color:rgb(254 215 170 / var(--tw-border-opacity, 1))}.hover\:border-primary\/40:hover{border-color:hsl(var(--primary) / .4)}.hover\:border-primary\/50:hover{border-color:hsl(var(--primary) / .5)}.hover\:bg-accent:hover{background-color:hsl(var(--accent))}.hover\:bg-blue-50:hover{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.hover\:bg-destructive\/20:hover{background-color:hsl(var(--destructive) / .2)}.hover\:bg-destructive\/90:hover{background-color:hsl(var(--destructive) / .9)}.hover\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity, 1))}.hover\:bg-muted:hover{background-color:hsl(var(--muted))}.hover\:bg-muted\/10:hover{background-color:hsl(var(--muted) / .1)}.hover\:bg-muted\/20:hover{background-color:hsl(var(--muted) / .2)}.hover\:bg-muted\/30:hover{background-color:hsl(var(--muted) / .3)}.hover\:bg-muted\/40:hover{background-color:hsl(var(--muted) / .4)}.hover\:bg-muted\/50:hover{background-color:hsl(var(--muted) / .5)}.hover\:bg-muted\/80:hover{background-color:hsl(var(--muted) / .8)}.hover\:bg-orange-50:hover{--tw-bg-opacity: 1;background-color:rgb(255 247 237 / var(--tw-bg-opacity, 1))}.hover\:bg-primary:hover{background-color:hsl(var(--primary))}.hover\:bg-primary\/10:hover{background-color:hsl(var(--primary) / .1)}.hover\:bg-primary\/30:hover{background-color:hsl(var(--primary) / .3)}.hover\:bg-primary\/90:hover{background-color:hsl(var(--primary) / .9)}.hover\:bg-red-50:hover{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.hover\:bg-secondary\/80:hover{background-color:hsl(var(--secondary) / .8)}.hover\:bg-slate-50:hover{--tw-bg-opacity: 1;background-color:rgb(248 250 252 / var(--tw-bg-opacity, 1))}.hover\:text-accent-foreground:hover{color:hsl(var(--accent-foreground))}.hover\:text-blue-500:hover{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.hover\:text-foreground:hover{color:hsl(var(--foreground))}.hover\:text-orange-500:hover{--tw-text-opacity: 1;color:rgb(249 115 22 / var(--tw-text-opacity, 1))}.hover\:text-primary:hover{color:hsl(var(--primary))}.hover\:text-primary\/60:hover{color:hsl(var(--primary) / .6)}.hover\:text-red-500:hover{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.hover\:text-slate-800:hover{--tw-text-opacity: 1;color:rgb(30 41 59 / var(--tw-text-opacity, 1))}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:opacity-90:hover{opacity:.9}.hover\:shadow-md:hover{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-1:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\:ring-ring:focus{--tw-ring-color: hsl(var(--ring))}.focus\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\:ring-0:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\:ring-destructive:focus-visible{--tw-ring-color: hsl(var(--destructive))}.focus-visible\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--ring))}.focus-visible\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}.active\:cursor-grabbing:active{cursor:grabbing}.disabled\:pointer-events-none:disabled{pointer-events:none}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-50:disabled{opacity:.5}.group:hover .group-hover\:-translate-x-3{--tw-translate-x: -.75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:-translate-y-1{--tw-translate-y: -.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:-translate-y-3{--tw-translate-y: -.75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:translate-x-3{--tw-translate-x: .75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group\/btn:hover .group-hover\/btn\:rotate-90{--tw-rotate: 90deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:-rotate-12{--tw-rotate: -12deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:rotate-12{--tw-rotate: 12deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:border-primary{border-color:hsl(var(--primary))}.group:hover .group-hover\:text-primary{color:hsl(var(--primary))}.group:hover .group-hover\:text-slate-600{--tw-text-opacity: 1;color:rgb(71 85 105 / var(--tw-text-opacity, 1))}.group:hover .group-hover\:opacity-100{opacity:1}.group:hover .group-hover\:opacity-40{opacity:.4}.dark\:block:is(.dark *){display:block}.dark\:hidden:is(.dark *){display:none}.dark\:bg-white\/10:is(.dark *){background-color:#ffffff1a}.dark\:bg-white\/5:is(.dark *){background-color:#ffffff0d}.dark\:text-amber-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 211 77 / var(--tw-text-opacity, 1))}.dark\:text-emerald-300:is(.dark *){--tw-text-opacity: 1;color:rgb(110 231 183 / var(--tw-text-opacity, 1))}.dark\:text-emerald-400:is(.dark *){--tw-text-opacity: 1;color:rgb(52 211 153 / var(--tw-text-opacity, 1))}.dark\:text-rose-300:is(.dark *){--tw-text-opacity: 1;color:rgb(253 164 175 / var(--tw-text-opacity, 1))}.dark\:text-rose-400:is(.dark *){--tw-text-opacity: 1;color:rgb(251 113 133 / var(--tw-text-opacity, 1))}.dark\:hover\:bg-red-950\/30:hover:is(.dark *){background-color:#450a0a4d}@media (min-width: 640px){.sm\:block{display:block}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width: 768px){.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (min-width: 1024px){.lg\:relative{position:relative}.lg\:hidden{display:none}.lg\:translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (min-width: 1280px){.xl\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.xl\:grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}} diff --git a/src/static/assets/index-BiYpJJoC.js b/src/static/assets/index-aIsLHJPY.js similarity index 99% rename from src/static/assets/index-BiYpJJoC.js rename to src/static/assets/index-aIsLHJPY.js index cb63b91..2efbfdd 100644 --- a/src/static/assets/index-BiYpJJoC.js +++ b/src/static/assets/index-aIsLHJPY.js @@ -1,4 +1,4 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/LoginView-DmmhvYTb.js","assets/CardContent.vue_vue_type_script_setup_true_lang-BwqudhrR.js","assets/utils-7WVCegLb.js","assets/DashboardView-Cl3r92sM.js","assets/dashboard-Ca6WcfdV.js","assets/CardTitle.vue_vue_type_script_setup_true_lang-D80NEgX4.js","assets/Button.vue_vue_type_script_setup_true_lang-XB9h72-Z.js","assets/Spinner.vue_vue_type_script_setup_true_lang-CvE8XLn7.js","assets/Skeleton.vue_vue_type_script_setup_true_lang-DEDpXUzf.js","assets/createLucideIcon-D7qP-VdO.js","assets/calendar-days-DjiBFm4u.js","assets/Progress.vue_vue_type_script_setup_true_lang-CE8EWOvP.js","assets/Tooltip.vue_vue_type_script_setup_true_lang-BRjliJat.js","assets/tasks-DwSuZPNM.js","assets/devops-y1AYKG_U.js","assets/CalendarView-B0jfXKKY.js","assets/SegmentedControl.vue_vue_type_script_setup_true_lang-DN09G_1E.js","assets/format-WqwOLoqz.js","assets/_plugin-vue_export-helper-DlAUqK2U.js","assets/Badge.vue_vue_type_script_setup_true_lang-DE_UXwEf.js","assets/TaskForm.vue_vue_type_script_setup_true_lang-BvqRdc1Q.js","assets/Dialog.vue_vue_type_script_setup_true_lang-DB9Ws8sP.js","assets/Input.vue_vue_type_script_setup_true_lang-He-JgvL3.js","assets/Textarea.vue_vue_type_script_setup_true_lang-Caf3IAh-.js","assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-PZ912WSn.js","assets/CalendarView-DMz1YKbt.css","assets/TasksView-D8TRKoOC.js","assets/EmptyState.vue_vue_type_script_setup_true_lang-jNal0qhs.js","assets/OmgView-BM5Lo3rq.js","assets/file-text-C0mXX88J.js","assets/plus-PpKYs9wJ.js","assets/ProjectsView-lK4Qdm9A.js","assets/zap-CGuBGf0F.js","assets/ProjectDetailView-DmKhTvpx.js","assets/LiveView-Drr7Q-W3.js","assets/ReportsView-b-OOza6x.js","assets/calendar-C9xlMu6k.js","assets/ReportsView-CEPiE5pW.css","assets/KeysView-x4Ow5p_D.js","assets/admin-BG8iXstk.js","assets/DevopsView-O5QaTl8f.js","assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-DfDWa0N1.js","assets/SettingsView-Dx5EOob_.js","assets/AdminView-CBzT_n85.js"])))=>i.map(i=>d[i]); +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/LoginView-Dy4ecRek.js","assets/CardContent.vue_vue_type_script_setup_true_lang-BHqzU0XP.js","assets/utils-7WVCegLb.js","assets/DashboardView-Bg0DXGZC.js","assets/dashboard-CdOgDJq5.js","assets/CardTitle.vue_vue_type_script_setup_true_lang-BQRqAxRK.js","assets/Button.vue_vue_type_script_setup_true_lang-Cac8BCnu.js","assets/Spinner.vue_vue_type_script_setup_true_lang-Bmg2-wxY.js","assets/Skeleton.vue_vue_type_script_setup_true_lang-BTnjf8rc.js","assets/createLucideIcon-B5Z2hHtI.js","assets/calendar-days-Bx0aIed-.js","assets/Progress.vue_vue_type_script_setup_true_lang-Fry_ZKRI.js","assets/Tooltip.vue_vue_type_script_setup_true_lang-DyhqCfGA.js","assets/tasks-caOFGu41.js","assets/devops-DsTCxAug.js","assets/CalendarView-myth_Gpl.js","assets/SegmentedControl.vue_vue_type_script_setup_true_lang-Cbh395GM.js","assets/format-DDf_am8g.js","assets/_plugin-vue_export-helper-DlAUqK2U.js","assets/Badge.vue_vue_type_script_setup_true_lang-DBjinea9.js","assets/TaskForm.vue_vue_type_script_setup_true_lang-BWg_Q6_w.js","assets/Dialog.vue_vue_type_script_setup_true_lang-CAaEAfRs.js","assets/Input.vue_vue_type_script_setup_true_lang-DulGPujX.js","assets/projects-BYok-JQo.js","assets/ConfirmDialog.vue_vue_type_script_setup_true_lang-kyV8Xvf6.js","assets/CalendarView-DMz1YKbt.css","assets/TasksView-v6kl3APd.js","assets/EmptyState.vue_vue_type_script_setup_true_lang-BPyIye9c.js","assets/OmgView-4RQpS0NB.js","assets/file-text-CF0U4KSF.js","assets/plus-CZK8TJCO.js","assets/ProjectsView-BIEkK9YZ.js","assets/zap-BQ6FEFi3.js","assets/ProjectDetailView-ZLh0yx2w.js","assets/LiveView-DS0o7b1g.js","assets/ReportsView-C9gnodtt.js","assets/calendar-CF-bck6k.js","assets/ReportsView-CEPiE5pW.css","assets/KeysView-D20WCgag.js","assets/admin-DlFdRGBL.js","assets/DevopsView-CWz6iIis.js","assets/DevopsConnectForm.vue_vue_type_script_setup_true_lang-BoAmreBJ.js","assets/SettingsView-Di3_0rdi.js","assets/AdminView-Y8GgaF2G.js"])))=>i.map(i=>d[i]); var _d=t=>{throw TypeError(t)};var yc=(t,e,n)=>e.has(t)||_d("Cannot "+n);var x=(t,e,n)=>(yc(t,e,"read from private field"),n?n.call(t):e.get(t)),Se=(t,e,n)=>e.has(t)?_d("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,n),ve=(t,e,n,r)=>(yc(t,e,"write to private field"),r?r.call(t,n):e.set(t,n),n),Ct=(t,e,n)=>(yc(t,e,"access private method"),n);var Es=(t,e,n,r)=>({set _(o){ve(t,e,o,n)},get _(){return x(t,e,r)}});(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const s of i.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&r(s)}).observe(document,{childList:!0,subtree:!0});function n(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerPolicy&&(i.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?i.credentials="include":o.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=n(o);fetch(o.href,i)}})();/** * @vue/shared v3.5.34 * (c) 2018-present Yuxi (Evan) You and Vue contributors @@ -43,4 +43,4 @@ Error Description: ${i.errorMessage}`);else{const s=i;this.logger.error(`A non-M Error: ${s.name} Error Description: ${s.message}`)}return null}return r||(this.logger.warning("The developer's authority was not found within the CloudInstanceDiscoveryMetadata returned from the network request."),this.logger.verbose("Creating custom Authority for custom domain scenario."),r=bt.createCloudDiscoveryMetadataFromHost(this.hostnameAndPort)),r}isInKnownAuthorities(){return this.authorityOptions.knownAuthorities.filter(n=>n&&Oe.getDomainFromUrl(n).toLowerCase()===this.hostnameAndPort).length>0}static generateAuthority(e,n){let r;if(n&&n.azureCloudInstance!==ju.None){const o=n.tenant?n.tenant:P.DEFAULT_COMMON_TENANT;r=`${n.azureCloudInstance}/${o}/`}return r||e}static createCloudDiscoveryMetadataFromHost(e){return{preferred_network:e,preferred_cache:e,aliases:[e]}}getPreferredCache(){if(this.managedIdentity)return P.DEFAULT_AUTHORITY_HOST;if(this.discoveryComplete())return this.metadata.preferred_cache;throw j(Zn)}isAlias(e){return this.metadata.aliases.indexOf(e)>-1}isAliasOfKnownMicrosoftAuthority(e){return Ry.has(e)}static isPublicCloudAuthority(e){return P.KNOWN_PUBLIC_CLOUDS.indexOf(e)>=0}static buildRegionalAuthorityString(e,n,r){const o=new Oe(e);o.validateAsUri();const i=o.getUrlComponents();let s=`${n}.${i.HostNameAndPort}`;this.isPublicCloudAuthority(i.HostNameAndPort)&&(s=`${n}.${P.REGIONAL_AUTH_PUBLIC_CLOUD_SUFFIX}`);const a=Oe.constructAuthorityUriFromObject({...o.getUrlComponents(),HostNameAndPort:s}).urlString;return r?`${a}?${r}`:a}static replaceWithRegionalInformation(e,n){const r={...e};return r.authorization_endpoint=bt.buildRegionalAuthorityString(r.authorization_endpoint,n),r.token_endpoint=bt.buildRegionalAuthorityString(r.token_endpoint,n),r.end_session_endpoint&&(r.end_session_endpoint=bt.buildRegionalAuthorityString(r.end_session_endpoint,n)),r}static transformCIAMAuthority(e){let n=e;const o=new Oe(e).getUrlComponents();if(o.PathSegments.length===0&&o.HostNameAndPort.endsWith(P.CIAM_AUTH_URL)){const i=o.HostNameAndPort.split(".")[0];n=`${n}${i}${P.AAD_TENANT_DOMAIN_SUFFIX}`}return n}}bt.reservedTenantDomains=new Set(["{tenant}","{tenantid}",Hr.COMMON,Hr.CONSUMERS,Hr.ORGANIZATIONS]);function qO(t){var o;const r=(o=new Oe(t).getUrlComponents().PathSegments.slice(-1)[0])==null?void 0:o.toLowerCase();switch(r){case Hr.COMMON:case Hr.ORGANIZATIONS:case Hr.CONSUMERS:return;default:return r}}function Ny(t){return t.endsWith(P.FORWARD_SLASH)?t:`${t}${P.FORWARD_SLASH}`}function jO(t){const e=t.cloudDiscoveryMetadata;let n;if(e)try{n=JSON.parse(e)}catch{throw $e(Wu)}return{canonicalAuthority:t.authority?Ny(t.authority):void 0,knownAuthorities:t.knownAuthorities,cloudDiscoveryMetadata:n}}/*! @azure/msal-common v14.16.1 2025-08-05 */async function xy(t,e,n,r,o,i,s){s==null||s.addQueueMeasurement(_.AuthorityFactoryCreateDiscoveredInstance,i);const a=bt.transformCIAMAuthority(Ny(t)),c=new bt(a,e,n,r,o,i,s);try{return await G(c.resolveEndpointsAsync.bind(c),_.AuthorityResolveEndpointsAsync,o,s,i)(),c}catch{throw j(Zn)}}/*! @azure/msal-common v14.16.1 2025-08-05 */class $r extends We{constructor(e,n,r,o,i){super(e,n,r),this.name="ServerError",this.errorNo=o,this.status=i,Object.setPrototypeOf(this,$r.prototype)}}/*! @azure/msal-common v14.16.1 2025-08-05 */class Dn{static generateThrottlingStorageKey(e){return`${Hi.THROTTLING_PREFIX}.${JSON.stringify(e)}`}static preProcess(e,n,r){var s;const o=Dn.generateThrottlingStorageKey(n),i=e.getThrottlingCache(o);if(i){if(i.throttleTime=500&&e.status<600}static checkResponseForRetryAfter(e){return e.headers?e.headers.hasOwnProperty(xt.RETRY_AFTER)&&(e.status<200||e.status>=300):!1}static calculateThrottleTime(e){const n=e<=0?0:e,r=Date.now()/1e3;return Math.floor(Math.min(r+(n||Hi.DEFAULT_THROTTLE_TIME_SECONDS),r+Hi.DEFAULT_MAX_THROTTLE_TIME_SECONDS)*1e3)}static removeThrottle(e,n,r,o){const i={clientId:n,authority:r.authority,scopes:r.scopes,homeAccountIdentifier:o,claims:r.claims,authenticationScheme:r.authenticationScheme,resourceRequestMethod:r.resourceRequestMethod,resourceRequestUri:r.resourceRequestUri,shrClaims:r.shrClaims,sshKid:r.sshKid},s=this.generateThrottlingStorageKey(i);e.removeItem(s,r.correlationId)}}/*! @azure/msal-common v14.16.1 2025-08-05 */class uc extends We{constructor(e,n,r){super(e.errorCode,e.errorMessage,e.subError),Object.setPrototypeOf(this,uc.prototype),this.name="NetworkError",this.error=e,this.httpStatus=n,this.responseHeaders=r}}function Nf(t,e,n){return new uc(t,e,n)}/*! @azure/msal-common v14.16.1 2025-08-05 */class nd{constructor(e,n){this.config=eO(e),this.logger=new Kr(this.config.loggerOptions,cy,qu),this.cryptoUtils=this.config.cryptoInterface,this.cacheManager=this.config.storageInterface,this.networkClient=this.config.networkInterface,this.serverTelemetryManager=this.config.serverTelemetryManager,this.authority=this.config.authOptions.authority,this.performanceClient=n}createTokenRequestHeaders(e){const n={};if(n[xt.CONTENT_TYPE]=P.URL_FORM_CONTENT_TYPE,!this.config.systemOptions.preventCorsPreflight&&e)switch(e.type){case Jt.HOME_ACCOUNT_ID:try{const r=Fo(e.credential);n[xt.CCS_HEADER]=`Oid:${r.uid}@${r.utid}`}catch(r){this.logger.verbose("Could not parse home account ID for CCS Header: "+r)}break;case Jt.UPN:n[xt.CCS_HEADER]=`UPN: ${e.credential}`;break}return n}async executePostToTokenEndpoint(e,n,r,o,i,s){var c;s&&((c=this.performanceClient)==null||c.addQueueMeasurement(s,i));const a=await this.sendPostRequest(o,e,{body:n,headers:r},i);return this.config.serverTelemetryManager&&a.status<500&&a.status!==429&&this.config.serverTelemetryManager.clearTelemetryCache(),a}async sendPostRequest(e,n,r,o){var s,a,c;Dn.preProcess(this.cacheManager,e,o);let i;try{i=await G(this.networkClient.sendPostRequestAsync.bind(this.networkClient),_.NetworkClientSendPostRequestAsync,this.logger,this.performanceClient,o)(n,r);const l=i.headers||{};(a=this.performanceClient)==null||a.addFields({refreshTokenSize:((s=i.body.refresh_token)==null?void 0:s.length)||0,httpVerToken:l[xt.X_MS_HTTP_VERSION]||"",requestId:l[xt.X_MS_REQUEST_ID]||""},o)}catch(l){if(l instanceof uc){const u=l.responseHeaders;throw u&&((c=this.performanceClient)==null||c.addFields({httpVerToken:u[xt.X_MS_HTTP_VERSION]||"",requestId:u[xt.X_MS_REQUEST_ID]||"",contentTypeHeader:u[xt.CONTENT_TYPE]||void 0,contentLengthHeader:u[xt.CONTENT_LENGTH]||void 0,httpStatus:l.httpStatus},o)),l.error}throw l instanceof We?l:j(Wm)}return Dn.postProcess(this.cacheManager,e,i,o),i}async updateAuthority(e,n){var i;(i=this.performanceClient)==null||i.addQueueMeasurement(_.UpdateTokenEndpointAuthority,n);const r=`https://${e}/${this.authority.tenant}/`,o=await xy(r,this.networkClient,this.cacheManager,this.authority.options,this.logger,n,this.performanceClient);this.authority=o}createTokenQueryParameters(e){const n=new Bi(e.correlationId,this.performanceClient);return e.embeddedClientId&&n.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenQueryParameters&&n.addExtraQueryParameters(e.tokenQueryParameters),n.addCorrelationId(e.correlationId),n.createQueryString()}}/*! @azure/msal-common v14.16.1 2025-08-05 */const va="no_tokens_found",My="native_account_unavailable",rd="refresh_token_expired",VO="interaction_required",GO="consent_required",zO="login_required",dc="bad_token";/*! @azure/msal-common v14.16.1 2025-08-05 */const xf=[VO,GO,zO,dc],WO=["message_only","additional_action","basic_action","user_password_expired","consent_required","bad_token"],QO={[va]:"No refresh token found in the cache. Please sign-in.",[My]:"The requested account is not available in the native broker. It may have been deleted or logged out. Please sign-in again using an interactive API.",[rd]:"Refresh token has expired.",[dc]:"Identity provider returned bad_token due to an expired or invalid refresh token. Please invoke an interactive API to resolve."};class En extends We{constructor(e,n,r,o,i,s,a,c){super(e,n,r),Object.setPrototypeOf(this,En.prototype),this.timestamp=o||P.EMPTY_STRING,this.traceId=i||P.EMPTY_STRING,this.correlationId=s||P.EMPTY_STRING,this.claims=a||P.EMPTY_STRING,this.name="InteractionRequiredAuthError",this.errorNo=c}}function Mf(t,e,n){const r=!!t&&xf.indexOf(t)>-1,o=!!n&&WO.indexOf(n)>-1,i=!!e&&xf.some(s=>e.indexOf(s)>-1);return r||i||o}function Fl(t){return new En(t,QO[t])}/*! @azure/msal-common v14.16.1 2025-08-05 */class gn{static setRequestState(e,n,r){const o=gn.generateLibraryState(e,r);return n?`${o}${P.RESOURCE_DELIM}${n}`:o}static generateLibraryState(e,n){if(!e)throw j(Dl);const r={id:e.createNewGuid()};n&&(r.meta=n);const o=JSON.stringify(r);return e.base64Encode(o)}static parseRequestState(e,n){if(!e)throw j(Dl);if(!n)throw j(li);try{const r=n.split(P.RESOURCE_DELIM),o=r[0],i=r.length>1?r.slice(1).join(P.RESOURCE_DELIM):P.EMPTY_STRING,s=e.base64Decode(o),a=JSON.parse(s);return{userRequestState:i||P.EMPTY_STRING,libraryState:a}}catch{throw j(li)}}}/*! @azure/msal-common v14.16.1 2025-08-05 */const YO={SW:"sw"};class di{constructor(e,n){this.cryptoUtils=e,this.performanceClient=n}async generateCnf(e,n){var i;(i=this.performanceClient)==null||i.addQueueMeasurement(_.PopTokenGenerateCnf,e.correlationId);const r=await G(this.generateKid.bind(this),_.PopTokenGenerateCnf,n,this.performanceClient,e.correlationId)(e),o=this.cryptoUtils.base64UrlEncode(JSON.stringify(r));return{kid:r.kid,reqCnfString:o}}async generateKid(e){var r;return(r=this.performanceClient)==null||r.addQueueMeasurement(_.PopTokenGenerateKid,e.correlationId),{kid:await this.cryptoUtils.getPublicKeyThumbprint(e),xms_ksl:YO.SW}}async signPopToken(e,n,r){return this.signPayload(e,n,r)}async signPayload(e,n,r,o){const{resourceRequestMethod:i,resourceRequestUri:s,shrClaims:a,shrNonce:c,shrOptions:l}=r,u=s?new Oe(s):void 0,d=u==null?void 0:u.getUrlComponents();return this.cryptoUtils.signJwt({at:e,ts:qn(),m:i==null?void 0:i.toUpperCase(),u:d==null?void 0:d.HostNameAndPort,nonce:c||this.cryptoUtils.createNewGuid(),p:d==null?void 0:d.AbsolutePath,q:d!=null&&d.QueryString?[[],d.QueryString]:void 0,client_claims:a||void 0,...o},n,l,r.correlationId)}}/*! @azure/msal-common v14.16.1 2025-08-05 */class JO{constructor(e,n){this.cache=e,this.hasChanged=n}get cacheHasChanged(){return this.hasChanged}get tokenCache(){return this.cache}}/*! @azure/msal-common v14.16.1 2025-08-05 */function XO(t){var r,o;const e="code=",n=(r=t.error_uri)==null?void 0:r.lastIndexOf(e);return n&&n>=0?(o=t.error_uri)==null?void 0:o.substring(n+e.length):void 0}class Co{constructor(e,n,r,o,i,s,a){this.clientId=e,this.cacheStorage=n,this.cryptoObj=r,this.logger=o,this.serializableCache=i,this.persistencePlugin=s,this.performanceClient=a}validateServerAuthorizationCodeResponse(e,n){if(!e.state||!n)throw e.state?j(ha,"Cached State"):j(ha,"Server State");let r,o;try{r=decodeURIComponent(e.state)}catch{throw j(li,e.state)}try{o=decodeURIComponent(n)}catch{throw j(li,e.state)}if(r!==o)throw j(Jm);if(e.error||e.error_description||e.suberror){const i=XO(e);throw Mf(e.error,e.error_description,e.suberror)?new En(e.error||"",e.error_description,e.suberror,e.timestamp||"",e.trace_id||"",e.correlation_id||"",e.claims||"",i):new $r(e.error||"",e.error_description,e.suberror,i)}}validateTokenResponse(e,n){var r;if(e.error||e.error_description||e.suberror){const o=`Error(s): ${e.error_codes||P.NOT_AVAILABLE} - Timestamp: ${e.timestamp||P.NOT_AVAILABLE} - Description: ${e.error_description||P.NOT_AVAILABLE} - Correlation ID: ${e.correlation_id||P.NOT_AVAILABLE} - Trace ID: ${e.trace_id||P.NOT_AVAILABLE}`,i=(r=e.error_codes)!=null&&r.length?e.error_codes[0]:void 0,s=new $r(e.error,o,e.suberror,i,e.status);if(n&&e.status&&e.status>=Ds.SERVER_ERROR_RANGE_START&&e.status<=Ds.SERVER_ERROR_RANGE_END){this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently unavailable and the access token is unable to be refreshed. ${s}`);return}else if(n&&e.status&&e.status>=Ds.CLIENT_ERROR_RANGE_START&&e.status<=Ds.CLIENT_ERROR_RANGE_END){this.logger.warning(`executeTokenRequest:validateTokenResponse - AAD is currently available but is unable to refresh the access token. -${s}`);return}throw Mf(e.error,e.error_description,e.suberror)?new En(e.error,e.error_description,e.suberror,e.timestamp||P.EMPTY_STRING,e.trace_id||P.EMPTY_STRING,e.correlation_id||P.EMPTY_STRING,e.claims||P.EMPTY_STRING,i):s}}async handleServerTokenResponse(e,n,r,o,i,s,a,c,l){var p;(p=this.performanceClient)==null||p.addQueueMeasurement(_.HandleServerTokenResponse,e.correlation_id);let u;if(e.id_token){if(u=bo(e.id_token||P.EMPTY_STRING,this.cryptoObj.base64Decode),i&&i.nonce&&u.nonce!==i.nonce)throw j(Xm);if(o.maxAge||o.maxAge===0){const g=u.auth_time;if(!g)throw j(Bu);ly(g,o.maxAge)}}this.homeAccountIdentifier=dt.generateHomeAccountId(e.client_info||P.EMPTY_STRING,n.authorityType,this.logger,this.cryptoObj,u);let d;i&&i.state&&(d=gn.parseRequestState(this.cryptoObj,i.state)),e.key_id=e.key_id||o.sshKid||void 0;const h=this.generateCacheRecord(e,n,r,o,u,s,i);let f;try{if(this.persistencePlugin&&this.serializableCache&&(this.logger.verbose("Persistence enabled, calling beforeCacheAccess"),f=new JO(this.serializableCache,!0),await this.persistencePlugin.beforeCacheAccess(f)),a&&!c&&h.account){const g=h.account.generateAccountKey();if(!this.cacheStorage.getAccount(g,o.correlationId,this.logger))return this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache"),await Co.generateAuthenticationResult(this.cryptoObj,n,h,!1,o,u,d,void 0,l)}await this.cacheStorage.saveCacheRecord(h,o.correlationId,o.storeInCache)}finally{this.persistencePlugin&&this.serializableCache&&f&&(this.logger.verbose("Persistence enabled, calling afterCacheAccess"),await this.persistencePlugin.afterCacheAccess(f))}return Co.generateAuthenticationResult(this.cryptoObj,n,h,!1,o,u,d,e,l)}generateCacheRecord(e,n,r,o,i,s,a){const c=n.getPreferredCache();if(!c)throw j(Ku);const l=_y(i);let u,d;e.id_token&&i&&(u=sc(this.homeAccountIdentifier,c,e.id_token,this.clientId,l||""),d=od(this.cacheStorage,n,this.homeAccountIdentifier,this.cryptoObj.base64Decode,o.correlationId,i,e.client_info,c,l,a,void 0,this.logger));let h=null;if(e.access_token){const g=e.scope?rt.fromString(e.scope):new rt(o.scopes||[]),m=(typeof e.expires_in=="string"?parseInt(e.expires_in,10):e.expires_in)||0,C=(typeof e.ext_expires_in=="string"?parseInt(e.ext_expires_in,10):e.ext_expires_in)||0,T=(typeof e.refresh_in=="string"?parseInt(e.refresh_in,10):e.refresh_in)||void 0,y=r+m,w=y+C,S=T&&T>0?r+T:void 0;h=ac(this.homeAccountIdentifier,c,e.access_token,this.clientId,l||n.tenant||"",g.printScopes(),y,w,this.cryptoObj.base64Decode,S,e.token_type,s,e.key_id,o.claims,o.requestedClaimsHash)}let f=null;if(e.refresh_token){let g;if(e.refresh_token_expires_in){const m=typeof e.refresh_token_expires_in=="string"?parseInt(e.refresh_token_expires_in,10):e.refresh_token_expires_in;g=r+m}f=uy(this.homeAccountIdentifier,c,e.refresh_token,this.clientId,e.foci,s,g)}let p=null;return e.foci&&(p={clientId:this.clientId,environment:c,familyId:e.foci}),{account:d,idToken:u,accessToken:h,refreshToken:f,appMetadata:p}}static async generateAuthenticationResult(e,n,r,o,i,s,a,c,l){var y,w,S,B,N;let u=P.EMPTY_STRING,d=[],h=null,f,p,g=P.EMPTY_STRING;if(r.accessToken){if(r.accessToken.tokenType===Fe.POP&&!i.popKid){const L=new di(e),{secret:k,keyId:F}=r.accessToken;if(!F)throw j($u);u=await L.signPopToken(k,F,i)}else u=r.accessToken.secret;d=rt.fromString(r.accessToken.target).asArray(),h=new Date(Number(r.accessToken.expiresOn)*1e3),f=new Date(Number(r.accessToken.extendedExpiresOn)*1e3),r.accessToken.refreshOn&&(p=new Date(Number(r.accessToken.refreshOn)*1e3))}r.appMetadata&&(g=r.appMetadata.familyId===Ui?Ui:"");const m=(s==null?void 0:s.oid)||(s==null?void 0:s.sub)||"",C=(s==null?void 0:s.tid)||"";c!=null&&c.spa_accountid&&r.account&&(r.account.nativeAccountId=c==null?void 0:c.spa_accountid);const T=r.account?Ju(r.account.getAccountInfo(),void 0,s,(y=r.idToken)==null?void 0:y.secret):null;return{authority:n.canonicalAuthority,uniqueId:m,tenantId:C,scopes:d,account:T,idToken:((w=r==null?void 0:r.idToken)==null?void 0:w.secret)||"",idTokenClaims:s||{},accessToken:u,fromCache:o,expiresOn:h,extExpiresOn:f,refreshOn:p,correlationId:i.correlationId,requestId:l||P.EMPTY_STRING,familyId:g,tokenType:((S=r.accessToken)==null?void 0:S.tokenType)||P.EMPTY_STRING,state:a?a.userRequestState:P.EMPTY_STRING,cloudGraphHostName:((B=r.account)==null?void 0:B.cloudGraphHostName)||P.EMPTY_STRING,msGraphHost:((N=r.account)==null?void 0:N.msGraphHost)||P.EMPTY_STRING,code:c==null?void 0:c.spa_code,fromNativeBroker:!1}}}function od(t,e,n,r,o,i,s,a,c,l,u,d){d==null||d.verbose("setCachedAccount called");const f=t.getAccountKeys().find(T=>T.startsWith(n));let p=null;f&&(p=t.getAccount(f,o,d));const g=p||dt.createAccount({homeAccountId:n,idTokenClaims:i,clientInfo:s,environment:a,cloudGraphHostName:l==null?void 0:l.cloud_graph_host_name,msGraphHost:l==null?void 0:l.msgraph_host,nativeAccountId:u},e,r),m=g.tenantProfiles||[],C=c||g.realm;if(C&&!m.find(T=>T.tenantId===C)){const T=Yu(n,g.localAccountId,C,i);m.push(T)}return g.tenantProfiles=m,g}/*! @azure/msal-common v14.16.1 2025-08-05 */async function Dy(t,e,n){return typeof t=="string"?t:t({clientId:e,tokenEndpoint:n})}/*! @azure/msal-common v14.16.1 2025-08-05 */class Ly extends nd{constructor(e,n){var r;super(e,n),this.includeRedirectUri=!0,this.oidcDefaultScopes=(r=this.config.authOptions.authority.options.OIDCOptions)==null?void 0:r.defaultScopes}async getAuthCodeUrl(e){var r;(r=this.performanceClient)==null||r.addQueueMeasurement(_.GetAuthCodeUrl,e.correlationId);const n=await G(this.createAuthCodeUrlQueryString.bind(this),_.AuthClientCreateQueryString,this.logger,this.performanceClient,e.correlationId)(e);return Oe.appendQueryString(this.authority.authorizationEndpoint,n)}async acquireToken(e,n){var a,c;if((a=this.performanceClient)==null||a.addQueueMeasurement(_.AuthClientAcquireToken,e.correlationId),!e.code)throw j(ty);const r=qn(),o=await G(this.executeTokenRequest.bind(this),_.AuthClientExecuteTokenRequest,this.logger,this.performanceClient,e.correlationId)(this.authority,e),i=(c=o.headers)==null?void 0:c[xt.X_MS_REQUEST_ID],s=new Co(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin,this.performanceClient);return s.validateTokenResponse(o.body),G(s.handleServerTokenResponse.bind(s),_.HandleServerTokenResponse,this.logger,this.performanceClient,e.correlationId)(o.body,this.authority,r,e,n,void 0,void 0,void 0,i)}handleFragmentResponse(e,n){if(new Co(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,null,null).validateServerAuthorizationCodeResponse(e,n),!e.code)throw j(sy);return e}getLogoutUri(e){if(!e)throw $e(yy);const n=this.createLogoutUrlQueryString(e);return Oe.appendQueryString(this.authority.endSessionEndpoint,n)}async executeTokenRequest(e,n){var l,u;(l=this.performanceClient)==null||l.addQueueMeasurement(_.AuthClientExecuteTokenRequest,n.correlationId);const r=this.createTokenQueryParameters(n),o=Oe.appendQueryString(e.tokenEndpoint,r),i=await G(this.createTokenRequestBody.bind(this),_.AuthClientCreateTokenRequestBody,this.logger,this.performanceClient,n.correlationId)(n);let s;if(n.clientInfo)try{const d=pa(n.clientInfo,this.cryptoUtils.base64Decode);s={credential:`${d.uid}${St.CLIENT_INFO_SEPARATOR}${d.utid}`,type:Jt.HOME_ACCOUNT_ID}}catch(d){this.logger.verbose("Could not parse client info for CCS Header: "+d)}const a=this.createTokenRequestHeaders(s||n.ccsCredential),c={clientId:((u=n.tokenBodyParameters)==null?void 0:u.clientId)||this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:n.scopes,claims:n.claims,authenticationScheme:n.authenticationScheme,resourceRequestMethod:n.resourceRequestMethod,resourceRequestUri:n.resourceRequestUri,shrClaims:n.shrClaims,sshKid:n.sshKid};return G(this.executePostToTokenEndpoint.bind(this),_.AuthorizationCodeClientExecutePostToTokenEndpoint,this.logger,this.performanceClient,n.correlationId)(o,i,a,c,n.correlationId,_.AuthorizationCodeClientExecutePostToTokenEndpoint)}async createTokenRequestBody(e){var o,i;(o=this.performanceClient)==null||o.addQueueMeasurement(_.AuthClientCreateTokenRequestBody,e.correlationId);const n=new Bi(e.correlationId,this.performanceClient);if(n.addClientId(e.embeddedClientId||((i=e.tokenBodyParameters)==null?void 0:i[vo])||this.config.authOptions.clientId),this.includeRedirectUri?n.addRedirectUri(e.redirectUri):Do.validateRedirectUri(e.redirectUri),n.addScopes(e.scopes,!0,this.oidcDefaultScopes),n.addAuthorizationCode(e.code),n.addLibraryInfo(this.config.libraryInfo),n.addApplicationTelemetry(this.config.telemetry.application),n.addThrottling(),this.serverTelemetryManager&&!Hl(this.config)&&n.addServerTelemetry(this.serverTelemetryManager),e.codeVerifier&&n.addCodeVerifier(e.codeVerifier),this.config.clientCredentials.clientSecret&&n.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const s=this.config.clientCredentials.clientAssertion;n.addClientAssertion(await Dy(s.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),n.addClientAssertionType(s.assertionType)}if(n.addGrantType(jm.AUTHORIZATION_CODE_GRANT),n.addClientInfo(),e.authenticationScheme===Fe.POP){const s=new di(this.cryptoUtils,this.performanceClient);let a;e.popKid?a=this.cryptoUtils.encodeKid(e.popKid):a=(await G(s.generateCnf.bind(s),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,n.addPopToken(a)}else if(e.authenticationScheme===Fe.SSH)if(e.sshJwk)n.addSshJwk(e.sshJwk);else throw $e(cc);(!pn.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&n.addClaims(e.claims,this.config.authOptions.clientCapabilities);let r;if(e.clientInfo)try{const s=pa(e.clientInfo,this.cryptoUtils.base64Decode);r={credential:`${s.uid}${St.CLIENT_INFO_SEPARATOR}${s.utid}`,type:Jt.HOME_ACCOUNT_ID}}catch(s){this.logger.verbose("Could not parse client info for CCS Header: "+s)}else r=e.ccsCredential;if(this.config.systemOptions.preventCorsPreflight&&r)switch(r.type){case Jt.HOME_ACCOUNT_ID:try{const s=Fo(r.credential);n.addCcsOid(s)}catch(s){this.logger.verbose("Could not parse home account ID for CCS Header: "+s)}break;case Jt.UPN:n.addCcsUpn(r.credential);break}return e.embeddedClientId&&n.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenBodyParameters&&n.addExtraQueryParameters(e.tokenBodyParameters),e.enableSpaAuthorizationCode&&(!e.tokenBodyParameters||!e.tokenBodyParameters[Pf])&&n.addExtraQueryParameters({[Pf]:"1"}),n.createQueryString()}async createAuthCodeUrlQueryString(e){var i,s;const n=e.correlationId||this.config.cryptoInterface.createNewGuid();(i=this.performanceClient)==null||i.addQueueMeasurement(_.AuthClientCreateQueryString,n);const r=new Bi(n,this.performanceClient);r.addClientId(e.embeddedClientId||((s=e.extraQueryParameters)==null?void 0:s[vo])||this.config.authOptions.clientId);const o=[...e.scopes||[],...e.extraScopesToConsent||[]];if(r.addScopes(o,!0,this.oidcDefaultScopes),r.addRedirectUri(e.redirectUri),r.addCorrelationId(n),r.addResponseMode(e.responseMode),r.addResponseTypeCode(),r.addLibraryInfo(this.config.libraryInfo),Hl(this.config)||r.addApplicationTelemetry(this.config.telemetry.application),r.addClientInfo(),e.codeChallenge&&e.codeChallengeMethod&&r.addCodeChallengeParams(e.codeChallenge,e.codeChallengeMethod),e.prompt&&r.addPrompt(e.prompt),e.domainHint&&r.addDomainHint(e.domainHint),e.prompt!==gt.SELECT_ACCOUNT)if(e.sid&&e.prompt===gt.NONE)this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from request"),r.addSid(e.sid);else if(e.account){const a=this.extractAccountSid(e.account);let c=this.extractLoginHint(e.account);if(c&&e.domainHint&&(this.logger.warning('AuthorizationCodeClient.createAuthCodeUrlQueryString: "domainHint" param is set, skipping opaque "login_hint" claim. Please consider not passing domainHint'),c=null),c){this.logger.verbose("createAuthCodeUrlQueryString: login_hint claim present on account"),r.addLoginHint(c);try{const l=Fo(e.account.homeAccountId);r.addCcsOid(l)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(a&&e.prompt===gt.NONE){this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from account"),r.addSid(a);try{const l=Fo(e.account.homeAccountId);r.addCcsOid(l)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(e.loginHint)this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from request"),r.addLoginHint(e.loginHint),r.addCcsUpn(e.loginHint);else if(e.account.username){this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from account"),r.addLoginHint(e.account.username);try{const l=Fo(e.account.homeAccountId);r.addCcsOid(l)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}}else e.loginHint&&(this.logger.verbose("createAuthCodeUrlQueryString: No account, adding login_hint from request"),r.addLoginHint(e.loginHint),r.addCcsUpn(e.loginHint));else this.logger.verbose("createAuthCodeUrlQueryString: Prompt is select_account, ignoring account hints");if(e.nonce&&r.addNonce(e.nonce),e.state&&r.addState(e.state),(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),e.embeddedClientId&&r.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),this.addExtraQueryParams(e,r),e.nativeBroker&&(r.addNativeBroker(),e.authenticationScheme===Fe.POP)){const a=new di(this.cryptoUtils);let c;e.popKid?c=this.cryptoUtils.encodeKid(e.popKid):c=(await G(a.generateCnf.bind(a),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,r.addPopToken(c)}return r.createQueryString()}createLogoutUrlQueryString(e){const n=new Bi(e.correlationId,this.performanceClient);return e.postLogoutRedirectUri&&n.addPostLogoutRedirectUri(e.postLogoutRedirectUri),e.correlationId&&n.addCorrelationId(e.correlationId),e.idTokenHint&&n.addIdTokenHint(e.idTokenHint),e.state&&n.addState(e.state),e.logoutHint&&n.addLogoutHint(e.logoutHint),this.addExtraQueryParams(e,n),n.createQueryString()}addExtraQueryParams(e,n){!(e.extraQueryParameters&&e.extraQueryParameters.hasOwnProperty("instance_aware"))&&this.config.authOptions.instanceAware&&(e.extraQueryParameters=e.extraQueryParameters||{},e.extraQueryParameters.instance_aware="true"),e.extraQueryParameters&&n.addExtraQueryParameters(e.extraQueryParameters)}extractAccountSid(e){var n;return((n=e.idTokenClaims)==null?void 0:n.sid)||null}extractLoginHint(e){var n;return((n=e.idTokenClaims)==null?void 0:n.login_hint)||null}}/*! @azure/msal-common v14.16.1 2025-08-05 */const ZO=300;class Kl extends nd{constructor(e,n){super(e,n)}async acquireToken(e){var s,a;(s=this.performanceClient)==null||s.addQueueMeasurement(_.RefreshTokenClientAcquireToken,e.correlationId);const n=qn(),r=await G(this.executeTokenRequest.bind(this),_.RefreshTokenClientExecuteTokenRequest,this.logger,this.performanceClient,e.correlationId)(e,this.authority),o=(a=r.headers)==null?void 0:a[xt.X_MS_REQUEST_ID],i=new Co(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin);return i.validateTokenResponse(r.body),G(i.handleServerTokenResponse.bind(i),_.HandleServerTokenResponse,this.logger,this.performanceClient,e.correlationId)(r.body,this.authority,n,e,void 0,void 0,!0,e.forceCache,o)}async acquireTokenByRefreshToken(e){var r;if(!e)throw $e(my);if((r=this.performanceClient)==null||r.addQueueMeasurement(_.RefreshTokenClientAcquireTokenByRefreshToken,e.correlationId),!e.account)throw j(Fu);if(this.cacheManager.isAppMetadataFOCI(e.account.environment))try{return await G(this.acquireTokenWithCachedRefreshToken.bind(this),_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!0)}catch(o){const i=o instanceof En&&o.errorCode===va,s=o instanceof $r&&o.errorCode===yf.INVALID_GRANT_ERROR&&o.subError===yf.CLIENT_MISMATCH_ERROR;if(i||s)return G(this.acquireTokenWithCachedRefreshToken.bind(this),_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!1);throw o}return G(this.acquireTokenWithCachedRefreshToken.bind(this),_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!1)}async acquireTokenWithCachedRefreshToken(e,n){var i;(i=this.performanceClient)==null||i.addQueueMeasurement(_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId);const r=_o(this.cacheManager.getRefreshToken.bind(this.cacheManager),_.CacheManagerGetRefreshToken,this.logger,this.performanceClient,e.correlationId)(e.account,n,e.correlationId,void 0,this.performanceClient);if(!r)throw Fl(va);if(r.expiresOn&&Ul(r.expiresOn,e.refreshTokenExpirationOffsetSeconds||ZO))throw Fl(rd);const o={...e,refreshToken:r.secret,authenticationScheme:e.authenticationScheme||Fe.BEARER,ccsCredential:{credential:e.account.homeAccountId,type:Jt.HOME_ACCOUNT_ID}};try{return await G(this.acquireToken.bind(this),_.RefreshTokenClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(o)}catch(s){if(s instanceof En&&s.subError===dc){this.logger.verbose("acquireTokenWithRefreshToken: bad refresh token, removing from cache");const a=Bo(r);this.cacheManager.removeRefreshToken(a,e.correlationId)}throw s}}async executeTokenRequest(e,n){var c,l;(c=this.performanceClient)==null||c.addQueueMeasurement(_.RefreshTokenClientExecuteTokenRequest,e.correlationId);const r=this.createTokenQueryParameters(e),o=Oe.appendQueryString(n.tokenEndpoint,r),i=await G(this.createTokenRequestBody.bind(this),_.RefreshTokenClientCreateTokenRequestBody,this.logger,this.performanceClient,e.correlationId)(e),s=this.createTokenRequestHeaders(e.ccsCredential),a={clientId:((l=e.tokenBodyParameters)==null?void 0:l.clientId)||this.config.authOptions.clientId,authority:n.canonicalAuthority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid};return G(this.executePostToTokenEndpoint.bind(this),_.RefreshTokenClientExecutePostToTokenEndpoint,this.logger,this.performanceClient,e.correlationId)(o,i,s,a,e.correlationId,_.RefreshTokenClientExecutePostToTokenEndpoint)}async createTokenRequestBody(e){var o,i,s;(o=this.performanceClient)==null||o.addQueueMeasurement(_.RefreshTokenClientCreateTokenRequestBody,e.correlationId);const n=e.correlationId,r=new Bi(n,this.performanceClient);if(r.addClientId(e.embeddedClientId||((i=e.tokenBodyParameters)==null?void 0:i[vo])||this.config.authOptions.clientId),e.redirectUri&&r.addRedirectUri(e.redirectUri),r.addScopes(e.scopes,!0,(s=this.config.authOptions.authority.options.OIDCOptions)==null?void 0:s.defaultScopes),r.addGrantType(jm.REFRESH_TOKEN_GRANT),r.addClientInfo(),r.addLibraryInfo(this.config.libraryInfo),r.addApplicationTelemetry(this.config.telemetry.application),r.addThrottling(),this.serverTelemetryManager&&!Hl(this.config)&&r.addServerTelemetry(this.serverTelemetryManager),r.addRefreshToken(e.refreshToken),this.config.clientCredentials.clientSecret&&r.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const a=this.config.clientCredentials.clientAssertion;r.addClientAssertion(await Dy(a.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),r.addClientAssertionType(a.assertionType)}if(e.authenticationScheme===Fe.POP){const a=new di(this.cryptoUtils,this.performanceClient);let c;e.popKid?c=this.cryptoUtils.encodeKid(e.popKid):c=(await G(a.generateCnf.bind(a),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,r.addPopToken(c)}else if(e.authenticationScheme===Fe.SSH)if(e.sshJwk)r.addSshJwk(e.sshJwk);else throw $e(cc);if((!pn.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.ccsCredential)switch(e.ccsCredential.type){case Jt.HOME_ACCOUNT_ID:try{const a=Fo(e.ccsCredential.credential);r.addCcsOid(a)}catch(a){this.logger.verbose("Could not parse home account ID for CCS Header: "+a)}break;case Jt.UPN:r.addCcsUpn(e.ccsCredential.credential);break}return e.embeddedClientId&&r.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenBodyParameters&&r.addExtraQueryParameters(e.tokenBodyParameters),r.createQueryString()}}/*! @azure/msal-common v14.16.1 2025-08-05 */class ek extends nd{constructor(e,n){super(e,n)}async acquireToken(e){var n;try{const[r,o]=await this.acquireCachedToken({...e,scopes:(n=e.scopes)!=null&&n.length?e.scopes:[...mi]});return o===Ir.PROACTIVELY_REFRESHED&&(this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token's refreshOn property has been exceeded'. It's not expired, but must be refreshed."),new Kl(this.config,this.performanceClient).acquireTokenByRefreshToken(e).catch(()=>{})),r}catch(r){if(r instanceof ic&&r.errorCode===or)return new Kl(this.config,this.performanceClient).acquireTokenByRefreshToken(e);throw r}}async acquireCachedToken(e){var c;(c=this.performanceClient)==null||c.addQueueMeasurement(_.SilentFlowClientAcquireCachedToken,e.correlationId);let n=Ir.NOT_APPLICABLE;if(e.forceRefresh||!this.config.cacheOptions.claimsBasedCachingEnabled&&!pn.isEmptyObj(e.claims))throw this.setCacheOutcome(Ir.FORCE_REFRESH_OR_CLAIMS,e.correlationId),j(or);if(!e.account)throw j(Fu);const r=e.account.tenantId||qO(e.authority),o=this.cacheManager.getTokenKeys(),i=this.cacheManager.getAccessToken(e.account,e,o,r,this.performanceClient);if(i){if(OR(i.cachedAt)||Ul(i.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw this.setCacheOutcome(Ir.CACHED_ACCESS_TOKEN_EXPIRED,e.correlationId),j(or);i.refreshOn&&Ul(i.refreshOn,0)&&(n=Ir.PROACTIVELY_REFRESHED)}else throw this.setCacheOutcome(Ir.NO_CACHED_ACCESS_TOKEN,e.correlationId),j(or);const s=e.authority||this.authority.getPreferredCache(),a={account:this.cacheManager.readAccountFromCache(e.account,e.correlationId),accessToken:i,idToken:this.cacheManager.getIdToken(e.account,e.correlationId,o,r,this.performanceClient),refreshToken:null,appMetadata:this.cacheManager.readAppMetadataFromCache(s)};return this.setCacheOutcome(n,e.correlationId),this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[await G(this.generateResultFromCacheRecord.bind(this),_.SilentFlowClientGenerateResultFromCacheRecord,this.logger,this.performanceClient,e.correlationId)(a,e),n]}setCacheOutcome(e,n){var r,o;(r=this.serverTelemetryManager)==null||r.setCacheOutcome(e),(o=this.performanceClient)==null||o.addFields({cacheOutcome:e},n),e!==Ir.NOT_APPLICABLE&&this.logger.info(`Token refresh is required due to cache outcome: ${e}`)}async generateResultFromCacheRecord(e,n){var o;(o=this.performanceClient)==null||o.addQueueMeasurement(_.SilentFlowClientGenerateResultFromCacheRecord,n.correlationId);let r;if(e.idToken&&(r=bo(e.idToken.secret,this.config.cryptoInterface.base64Decode)),n.maxAge||n.maxAge===0){const i=r==null?void 0:r.auth_time;if(!i)throw j(Bu);ly(i,n.maxAge)}return Co.generateAuthenticationResult(this.cryptoUtils,this.authority,e,!0,n,r)}}/*! @azure/msal-common v14.16.1 2025-08-05 */const tk={sendGetRequestAsync:()=>Promise.reject(j(Ee)),sendPostRequestAsync:()=>Promise.reject(j(Ee))};/*! @azure/msal-common v14.16.1 2025-08-05 */const Df=",",Uy="|";function nk(t){const{skus:e,libraryName:n,libraryVersion:r,extensionName:o,extensionVersion:i}=t,s=new Map([[0,[n,r]],[2,[o,i]]]);let a=[];if(e!=null&&e.length){if(a=e.split(Df),a.length<4)return e}else a=Array.from({length:4},()=>Uy);return s.forEach((c,l)=>{var u,d;c.length===2&&((u=c[0])!=null&&u.length)&&((d=c[1])!=null&&d.length)&&rk({skuArr:a,index:l,skuName:c[0],skuVersion:c[1]})}),a.join(Df)}function rk(t){const{skuArr:e,index:n,skuName:r,skuVersion:o}=t;n>=e.length||(e[n]=[r,o].join(Uy))}class es{constructor(e,n){this.cacheOutcome=Ir.NOT_APPLICABLE,this.cacheManager=n,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||P.EMPTY_STRING,this.wrapperVer=e.wrapperVer||P.EMPTY_STRING,this.telemetryCacheKey=wt.CACHE_KEY+St.CACHE_KEY_SEPARATOR+e.clientId}generateCurrentRequestHeaderValue(){const e=`${this.apiId}${wt.VALUE_SEPARATOR}${this.cacheOutcome}`,n=[this.wrapperSKU,this.wrapperVer],r=this.getNativeBrokerErrorCode();r!=null&&r.length&&n.push(`broker_error=${r}`);const o=n.join(wt.VALUE_SEPARATOR),i=this.getRegionDiscoveryFields(),s=[e,i].join(wt.VALUE_SEPARATOR);return[wt.SCHEMA_VERSION,s,o].join(wt.CATEGORY_SEPARATOR)}generateLastRequestHeaderValue(){const e=this.getLastRequests(),n=es.maxErrorsToSend(e),r=e.failedRequests.slice(0,2*n).join(wt.VALUE_SEPARATOR),o=e.errors.slice(0,n).join(wt.VALUE_SEPARATOR),i=e.errors.length,s=n=wt.MAX_CACHED_ERRORS&&(n.failedRequests.shift(),n.failedRequests.shift(),n.errors.shift()),n.failedRequests.push(this.apiId,this.correlationId),e instanceof Error&&e&&e.toString()?e instanceof We?e.subError?n.errors.push(e.subError):e.errorCode?n.errors.push(e.errorCode):n.errors.push(e.toString()):n.errors.push(e.toString()):n.errors.push(wt.UNKNOWN_ERROR),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,n,this.correlationId)}incrementCacheHits(){const e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e,this.correlationId),e.cacheHits}getLastRequests(){const e={failedRequests:[],errors:[],cacheHits:0};return this.cacheManager.getServerTelemetry(this.telemetryCacheKey)||e}clearTelemetryCache(){const e=this.getLastRequests(),n=es.maxErrorsToSend(e),r=e.errors.length;if(n===r)this.cacheManager.removeItem(this.telemetryCacheKey,this.correlationId);else{const o={failedRequests:e.failedRequests.slice(n*2),errors:e.errors.slice(n),cacheHits:0};this.cacheManager.setServerTelemetry(this.telemetryCacheKey,o,this.correlationId)}}static maxErrorsToSend(e){let n,r=0,o=0;const i=e.errors.length;for(n=0;nnull,discard:()=>{},add:()=>{},increment:()=>{},event:{eventId:this.generateId(),status:$O.InProgress,authority:"",libraryName:"",libraryVersion:"",clientId:"",name:e,startTimeMs:Date.now(),correlationId:n||""},measurement:new Uf}}startPerformanceMeasurement(){return new Uf}calculateQueuedTime(){return 0}addQueueMeasurement(){}setPreQueueTime(){}endMeasurement(){return null}discardMeasurements(){}removePerformanceCallback(){return!0}addPerformanceCallback(){return""}emitEvents(){}addFields(){}incrementFields(){}cacheEventByCorrelationId(){}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const ad="pkce_not_created",$l="crypto_nonexistent",hc="empty_navigate_uri",Fy="hash_empty_error",cd="no_state_in_hash",Ky="hash_does_not_contain_known_properties",$y="unable_to_parse_state",qy="state_interaction_type_mismatch",jy="interaction_in_progress",Vy="popup_window_error",Gy="empty_window_error",wo="user_cancelled",sk="monitor_popup_timeout",zy="monitor_window_timeout",Wy="redirect_in_iframe",Qy="block_iframe_reload",Yy="block_nested_popups",ak="iframe_closed_prematurely",fc="silent_logout_unsupported",Jy="no_account_error",ck="silent_prompt_value_error",Xy="no_token_request_cache_error",Zy="unable_to_parse_token_request_cache_error",ld="no_cached_authority_error",lk="auth_request_not_set_error",uk="invalid_cache_type",pc="non_browser_environment",Lo="database_not_open",Ca="no_network_connectivity",ev="post_request_failed",tv="get_request_failed",ql="failed_to_parse_response",nv="unable_to_load_token",ud="crypto_key_not_found",rv="auth_code_required",ov="auth_code_or_nativeAccountId_required",iv="spa_code_and_nativeAccountId_present",dd="database_unavailable",sv="unable_to_acquire_token_from_native_platform",av="native_handshake_timeout",cv="native_extension_not_installed",As="native_connection_not_established",lv="uninitialized_public_client_application",uv="native_prompt_not_supported",dv="invalid_base64_string",hv="invalid_pop_token_request",fv="failed_to_build_headers",pv="failed_to_parse_headers";/*! @azure/msal-browser v3.30.0 2025-08-05 */const Yn="For more visit: aka.ms/msaljs/browser-errors",dk={[ad]:"The PKCE code challenge and verifier could not be generated.",[$l]:"The crypto object or function is not available.",[hc]:"Navigation URI is empty. Please check stack trace for more info.",[Fy]:`Hash value cannot be processed because it is empty. Please verify that your redirectUri is not clearing the hash. ${Yn}`,[cd]:"Hash does not contain state. Please verify that the request originated from msal.",[Ky]:`Hash does not contain known properites. Please verify that your redirectUri is not changing the hash. ${Yn}`,[$y]:"Unable to parse state. Please verify that the request originated from msal.",[qy]:"Hash contains state but the interaction type does not match the caller.",[jy]:`Interaction is currently in progress. Please ensure that this interaction has been completed before calling an interactive API. ${Yn}`,[Vy]:"Error opening popup window. This can happen if you are using IE or if popups are blocked in the browser.",[Gy]:"window.open returned null or undefined window object.",[wo]:"User cancelled the flow.",[sk]:`Token acquisition in popup failed due to timeout. ${Yn}`,[zy]:`Token acquisition in iframe failed due to timeout. ${Yn}`,[Wy]:"Redirects are not supported for iframed or brokered applications. Please ensure you are using MSAL.js in a top frame of the window if using the redirect APIs, or use the popup APIs.",[Qy]:`Request was blocked inside an iframe because MSAL detected an authentication response. ${Yn}`,[Yy]:"Request was blocked inside a popup because MSAL detected it was running in a popup.",[ak]:"The iframe being monitored was closed prematurely.",[fc]:"Silent logout not supported. Please call logoutRedirect or logoutPopup instead.",[Jy]:"No account object provided to acquireTokenSilent and no active account has been set. Please call setActiveAccount or provide an account on the request.",[ck]:"The value given for the prompt value is not valid for silent requests - must be set to 'none' or 'no_session'.",[Xy]:"No token request found in cache.",[Zy]:"The cached token request could not be parsed.",[ld]:"No cached authority found.",[lk]:"Auth Request not set. Please ensure initiateAuthRequest was called from the InteractionHandler",[uk]:"Invalid cache type",[pc]:"Login and token requests are not supported in non-browser environments.",[Lo]:"Database is not open!",[Ca]:"No network connectivity. Check your internet connection.",[ev]:"Network request failed: If the browser threw a CORS error, check that the redirectUri is registered in the Azure App Portal as type 'SPA'",[tv]:"Network request failed. Please check the network trace to determine root cause.",[ql]:"Failed to parse network response. Check network trace.",[nv]:"Error loading token to cache.",[ud]:"Cryptographic Key or Keypair not found in browser storage.",[rv]:"An authorization code must be provided (as the `code` property on the request) to this flow.",[ov]:"An authorization code or nativeAccountId must be provided to this flow.",[iv]:"Request cannot contain both spa code and native account id.",[dd]:"IndexedDB, which is required for persistent cryptographic key storage, is unavailable. This may be caused by browser privacy features which block persistent storage in third-party contexts.",[sv]:`Unable to acquire token from native platform. ${Yn}`,[av]:"Timed out while attempting to establish connection to browser extension",[cv]:"Native extension is not installed. If you think this is a mistake call the initialize function.",[As]:`Connection to native platform has not been established. Please install a compatible browser extension and run initialize(). ${Yn}`,[lv]:`You must call and await the initialize function before attempting to call any other MSAL API. ${Yn}`,[uv]:"The provided prompt is not supported by the native platform. This request should be routed to the web based flow.",[dv]:"Invalid base64 encoded string.",[hv]:"Invalid PoP token request. The request should not have both a popKid value and signPopToken set to true.",[fv]:"Failed to build request headers object.",[pv]:"Failed to parse response headers"};class Ts extends We{constructor(e,n){super(e,dk[e],n),Object.setPrototypeOf(this,Ts.prototype),this.name="BrowserAuthError"}}function te(t,e){return new Ts(t,e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const Qt={INVALID_GRANT_ERROR:"invalid_grant",POPUP_WIDTH:483,POPUP_HEIGHT:600,POPUP_NAME_PREFIX:"msal",DEFAULT_POLL_INTERVAL_MS:30,MSAL_SKU:"msal.js.browser"},Ko={CHANNEL_ID:"53ee284d-920a-4b59-9d30-a60315b26836",PREFERRED_EXTENSION_ID:"ppnbnpeolgkicgegkbkbjmhlideopiji",MATS_TELEMETRY:"MATS"},ro={HandshakeRequest:"Handshake",HandshakeResponse:"HandshakeResponse",GetToken:"GetToken",Response:"Response"},Bt={LocalStorage:"localStorage",SessionStorage:"sessionStorage",MemoryStorage:"memoryStorage"},Hf={GET:"GET",POST:"POST"},Be={AUTHORITY:"authority",ACQUIRE_TOKEN_ACCOUNT:"acquireToken.account",SESSION_STATE:"session.state",REQUEST_STATE:"request.state",NONCE_IDTOKEN:"nonce.id_token",ORIGIN_URI:"request.origin",RENEW_STATUS:"token.renew.status",URL_HASH:"urlHash",REQUEST_PARAMS:"request.params",SCOPES:"scopes",INTERACTION_STATUS_KEY:"interaction.status",CCS_CREDENTIAL:"ccs.credential",CORRELATION_ID:"request.correlationId",NATIVE_REQUEST:"request.native",REDIRECT_CONTEXT:"request.redirect.context"},on={ACCOUNT_KEYS:"msal.account.keys",TOKEN_KEYS:"msal.token.keys",VERSION:"msal.version"},Fs={WRAPPER_SKU:"wrapper.sku",WRAPPER_VER:"wrapper.version"},ze={acquireTokenRedirect:861,acquireTokenPopup:862,ssoSilent:863,acquireTokenSilent_authCode:864,handleRedirectPromise:865,acquireTokenByCode:866,acquireTokenSilent_silentFlow:61,logout:961,logoutPopup:962};var ce;(function(t){t.Redirect="redirect",t.Popup="popup",t.Silent="silent",t.None="none"})(ce||(ce={}));const Bf={scopes:mi},gv="jwk",jl="msal.db",hk=1,fk=`${jl}.keys`,jt={Default:0,AccessToken:1,AccessTokenAndRefreshToken:2,RefreshToken:3,RefreshTokenAndNetwork:4,Skip:5},pk=[jt.Default,jt.Skip,jt.RefreshTokenAndNetwork],gk="msal.browser.log.level",mk="msal.browser.log.pii";/*! @azure/msal-browser v3.30.0 2025-08-05 */function Ks(t){return encodeURIComponent(hd(t).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_"))}function gc(t){return mv(t).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}function hd(t){return mv(new TextEncoder().encode(t))}function mv(t){const e=Array.from(t,n=>String.fromCodePoint(n)).join("");return btoa(e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const yk="RSASSA-PKCS1-v1_5",yv="SHA-256",vk=2048,Ck=new Uint8Array([1,0,1]),Ff="0123456789abcdef",Kf=new Uint32Array(1),wk="crypto_subtle_undefined",fd={name:yk,hash:yv,modulusLength:vk,publicExponent:Ck};function Ak(t){if(!window)throw te(pc);if(!window.crypto)throw te($l);if(!t&&!window.crypto.subtle)throw te($l,wk)}async function vv(t,e,n){e==null||e.addQueueMeasurement(_.Sha256Digest,n);const o=new TextEncoder().encode(t);return window.crypto.subtle.digest(yv,o)}function Tk(t){return window.crypto.getRandomValues(t)}function Wc(){return window.crypto.getRandomValues(Kf),Kf[0]}function jn(){const t=Date.now(),e=Wc()*1024+(Wc()&1023),n=new Uint8Array(16),r=Math.trunc(e/2**30),o=e&2**30-1,i=Wc();n[0]=t/2**40,n[1]=t/2**32,n[2]=t/2**24,n[3]=t/2**16,n[4]=t/2**8,n[5]=t,n[6]=112|r>>>8,n[7]=r,n[8]=128|o>>>24,n[9]=o>>>16,n[10]=o>>>8,n[11]=o,n[12]=i>>>24,n[13]=i>>>16,n[14]=i>>>8,n[15]=i;let s="";for(let a=0;a>>4),s+=Ff.charAt(n[a]&15),(a===3||a===5||a===7||a===9)&&(s+="-");return s}async function Ek(t,e){return window.crypto.subtle.generateKey(fd,t,e)}async function Qc(t){return window.crypto.subtle.exportKey(gv,t)}async function bk(t,e,n){return window.crypto.subtle.importKey(gv,t,fd,e,n)}async function _k(t,e){return window.crypto.subtle.sign(fd,t,e)}async function Cv(t){const e=await vv(t),n=new Uint8Array(e);return gc(n)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const pd="storage_not_supported",Sk="stubbed_public_client_application_called",wv="in_mem_redirect_unavailable";/*! @azure/msal-browser v3.30.0 2025-08-05 */const Ik={[pd]:"Given storage configuration option was not supported.",[Sk]:"Stub instance of Public Client Application was called. If using msal-react, please ensure context is not used without a provider. For more visit: aka.ms/msaljs/browser-errors",[wv]:"Redirect cannot be supported. In-memory storage was selected and storeAuthStateInCookie=false, which would cause the library to be unable to handle the incoming hash. If you would like to use the redirect API, please use session/localStorage or set storeAuthStateInCookie=true."};class gd extends We{constructor(e,n){super(e,n),this.name="BrowserConfigurationAuthError",Object.setPrototypeOf(this,gd.prototype)}}function md(t){return new gd(t,Ik[t])}/*! @azure/msal-browser v3.30.0 2025-08-05 */function Rk(t){t.location.hash="",typeof t.history.replaceState=="function"&&t.history.replaceState(null,"",`${t.location.origin}${t.location.pathname}${t.location.search}`)}function Ok(t){const e=t.split("#");e.shift(),window.location.hash=e.length>0?e.join("#"):""}function yd(){return window.parent!==window}function kk(){return typeof window<"u"&&!!window.opener&&window.opener!==window&&typeof window.name=="string"&&window.name.indexOf(`${Qt.POPUP_NAME_PREFIX}.`)===0}function ir(){return typeof window<"u"&&window.location?window.location.href.split("?")[0].split("#")[0]:""}function Pk(){const e=new Oe(window.location.href).getUrlComponents();return`${e.Protocol}//${e.HostNameAndPort}/`}function Nk(){if(Oe.hashContainsKnownProperties(window.location.hash)&&yd())throw te(Qy)}function xk(t){if(yd()&&!t)throw te(Wy)}function Mk(){if(kk())throw te(Yy)}function Av(){if(typeof window>"u")throw te(pc)}function Tv(t){if(!t)throw te(lv)}function vd(t){Av(),Nk(),Mk(),Tv(t)}function $f(t,e){if(vd(t),xk(e.system.allowRedirectInIframe),e.cache.cacheLocation===Bt.MemoryStorage&&!e.cache.storeAuthStateInCookie)throw md(wv)}function Ev(t){const e=document.createElement("link");e.rel="preconnect",e.href=new URL(t).origin,e.crossOrigin="anonymous",document.head.appendChild(e),window.setTimeout(()=>{try{document.head.removeChild(e)}catch{}},1e4)}function Dk(){return jn()}/*! @azure/msal-browser v3.30.0 2025-08-05 */class wa{navigateInternal(e,n){return wa.defaultNavigateWindow(e,n)}navigateExternal(e,n){return wa.defaultNavigateWindow(e,n)}static defaultNavigateWindow(e,n){return n.noHistory?window.location.replace(e):window.location.assign(e),new Promise(r=>{setTimeout(()=>{r(!0)},n.timeout)})}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Lk{async sendGetRequestAsync(e,n){let r,o={},i=0;const s=qf(n);try{r=await fetch(e,{method:Hf.GET,headers:s})}catch{throw te(window.navigator.onLine?tv:Ca)}o=jf(r.headers);try{return i=r.status,{headers:o,body:await r.json(),status:i}}catch{throw Nf(te(ql),i,o)}}async sendPostRequestAsync(e,n){const r=n&&n.body||"",o=qf(n);let i,s=0,a={};try{i=await fetch(e,{method:Hf.POST,headers:o,body:r})}catch{throw te(window.navigator.onLine?ev:Ca)}a=jf(i.headers);try{return s=i.status,{headers:a,body:await i.json(),status:s}}catch{throw Nf(te(ql),s,a)}}}function qf(t){try{const e=new Headers;if(!(t&&t.headers))return e;const n=t.headers;return Object.entries(n).forEach(([r,o])=>{e.append(r,o)}),e}catch{throw te(fv)}}function jf(t){try{const e={};return t.forEach((n,r)=>{e[r]=n}),e}catch{throw te(pv)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const Uk=6e4,Vl=1e4,Hk=3e4,Bk=2e3;function Fk({auth:t,cache:e,system:n,telemetry:r},o){const i={clientId:P.EMPTY_STRING,authority:`${P.DEFAULT_AUTHORITY}`,knownAuthorities:[],cloudDiscoveryMetadata:P.EMPTY_STRING,authorityMetadata:P.EMPTY_STRING,redirectUri:typeof window<"u"?ir():"",postLogoutRedirectUri:P.EMPTY_STRING,navigateToLoginRequestUrl:!0,clientCapabilities:[],protocolMode:ar.AAD,OIDCOptions:{serverResponseType:ws.FRAGMENT,defaultScopes:[P.OPENID_SCOPE,P.PROFILE_SCOPE,P.OFFLINE_ACCESS_SCOPE]},azureCloudOptions:{azureCloudInstance:ju.None,tenant:P.EMPTY_STRING},skipAuthorityMetadataCache:!1,supportsNestedAppAuth:!1,instanceAware:!1},s={cacheLocation:Bt.SessionStorage,temporaryCacheLocation:Bt.SessionStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!!(e&&e.cacheLocation===Bt.LocalStorage),claimsBasedCachingEnabled:!1},a={loggerCallback:()=>{},logLevel:Ye.Info,piiLoggingEnabled:!1},l={...{...ky,loggerOptions:a,networkClient:o?new Lk:tk,navigationClient:new wa,loadFrameTimeout:0,windowHashTimeout:(n==null?void 0:n.loadFrameTimeout)||Uk,iframeHashTimeout:(n==null?void 0:n.loadFrameTimeout)||Vl,navigateFrameWait:0,redirectNavigationTimeout:Hk,asyncPopups:!1,allowRedirectInIframe:!1,allowNativeBroker:!1,nativeBrokerHandshakeTimeout:(n==null?void 0:n.nativeBrokerHandshakeTimeout)||Bk,pollIntervalMilliseconds:Qt.DEFAULT_POLL_INTERVAL_MS},...n,loggerOptions:(n==null?void 0:n.loggerOptions)||a},u={application:{appName:P.EMPTY_STRING,appVersion:P.EMPTY_STRING},client:new ik};if((t==null?void 0:t.protocolMode)!==ar.OIDC&&(t!=null&&t.OIDCOptions)&&new Kr(l.loggerOptions).warning(JSON.stringify($e(Ty))),t!=null&&t.protocolMode&&t.protocolMode!==ar.AAD&&(l!=null&&l.allowNativeBroker))throw $e(Ey);return{auth:{...i,...t,OIDCOptions:{...i.OIDCOptions,...t==null?void 0:t.OIDCOptions}},cache:{...s,...e},system:l,telemetry:{...u,...r}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const Kk="@azure/msal-browser",hi="3.30.0";/*! @azure/msal-browser v3.30.0 2025-08-05 */class Cd{static loggerCallback(e,n){switch(e){case Ye.Error:console.error(n);return;case Ye.Info:console.info(n);return;case Ye.Verbose:console.debug(n);return;case Ye.Warning:console.warn(n);return;default:console.log(n);return}}constructor(e){var c;this.browserEnvironment=typeof window<"u",this.config=Fk(e,this.browserEnvironment);let n;try{n=window[Bt.SessionStorage]}catch{}const r=n==null?void 0:n.getItem(gk),o=(c=n==null?void 0:n.getItem(mk))==null?void 0:c.toLowerCase(),i=o==="true"?!0:o==="false"?!1:void 0,s={...this.config.system.loggerOptions},a=r&&Object.keys(Ye).includes(r)?Ye[r]:void 0;a&&(s.loggerCallback=Cd.loggerCallback,s.logLevel=a),i!==void 0&&(s.piiLoggingEnabled=i),this.logger=new Kr(s,Kk,hi),this.available=!1}getConfig(){return this.config}getLogger(){return this.logger}isAvailable(){return this.available}isBrowserEnvironment(){return this.browserEnvironment}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Ao extends Cd{getModuleName(){return Ao.MODULE_NAME}getId(){return Ao.ID}async initialize(){return this.available=typeof window<"u",this.available}}Ao.MODULE_NAME="";Ao.ID="StandardOperatingContext";/*! @azure/msal-browser v3.30.0 2025-08-05 */function $n(t){return new TextDecoder().decode($k(t))}function $k(t){let e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw te(dv)}const n=atob(e);return Uint8Array.from(n,r=>r.codePointAt(0)||0)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class qk{constructor(){this.dbName=jl,this.version=hk,this.tableName=fk,this.dbOpen=!1}async open(){return new Promise((e,n)=>{const r=window.indexedDB.open(this.dbName,this.version);r.addEventListener("upgradeneeded",o=>{o.target.result.createObjectStore(this.tableName)}),r.addEventListener("success",o=>{const i=o;this.db=i.target.result,this.dbOpen=!0,e()}),r.addEventListener("error",()=>n(te(dd)))})}closeConnection(){const e=this.db;e&&this.dbOpen&&(e.close(),this.dbOpen=!1)}async validateDbIsOpen(){if(!this.dbOpen)return this.open()}async getItem(e){return await this.validateDbIsOpen(),new Promise((n,r)=>{if(!this.db)return r(te(Lo));const s=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).get(e);s.addEventListener("success",a=>{const c=a;this.closeConnection(),n(c.target.result)}),s.addEventListener("error",a=>{this.closeConnection(),r(a)})})}async setItem(e,n){return await this.validateDbIsOpen(),new Promise((r,o)=>{if(!this.db)return o(te(Lo));const a=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).put(n,e);a.addEventListener("success",()=>{this.closeConnection(),r()}),a.addEventListener("error",c=>{this.closeConnection(),o(c)})})}async removeItem(e){return await this.validateDbIsOpen(),new Promise((n,r)=>{if(!this.db)return r(te(Lo));const s=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).delete(e);s.addEventListener("success",()=>{this.closeConnection(),n()}),s.addEventListener("error",a=>{this.closeConnection(),r(a)})})}async getKeys(){return await this.validateDbIsOpen(),new Promise((e,n)=>{if(!this.db)return n(te(Lo));const i=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).getAllKeys();i.addEventListener("success",s=>{const a=s;this.closeConnection(),e(a.target.result)}),i.addEventListener("error",s=>{this.closeConnection(),n(s)})})}async containsKey(e){return await this.validateDbIsOpen(),new Promise((n,r)=>{if(!this.db)return r(te(Lo));const s=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).count(e);s.addEventListener("success",a=>{const c=a;this.closeConnection(),n(c.target.result===1)}),s.addEventListener("error",a=>{this.closeConnection(),r(a)})})}async deleteDatabase(){return this.db&&this.dbOpen&&this.closeConnection(),new Promise((e,n)=>{const r=window.indexedDB.deleteDatabase(jl),o=setTimeout(()=>n(!1),200);r.addEventListener("success",()=>(clearTimeout(o),e(!0))),r.addEventListener("blocked",()=>(clearTimeout(o),e(!0))),r.addEventListener("error",()=>(clearTimeout(o),n(!1)))})}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Gl{constructor(){this.cache=new Map}getItem(e){return this.cache.get(e)||null}setItem(e,n){this.cache.set(e,n)}removeItem(e){this.cache.delete(e)}getKeys(){const e=[];return this.cache.forEach((n,r)=>{e.push(r)}),e}containsKey(e){return this.cache.has(e)}clear(){this.cache.clear()}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class jk{constructor(e){this.inMemoryCache=new Gl,this.indexedDBCache=new qk,this.logger=e}handleDatabaseAccessError(e){if(e instanceof Ts&&e.errorCode===dd)this.logger.error("Could not access persistent storage. This may be caused by browser privacy features which block persistent storage in third-party contexts.");else throw e}async getItem(e){const n=this.inMemoryCache.getItem(e);if(!n)try{return this.logger.verbose("Queried item not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.getItem(e)}catch(r){this.handleDatabaseAccessError(r)}return n}async setItem(e,n){this.inMemoryCache.setItem(e,n);try{await this.indexedDBCache.setItem(e,n)}catch(r){this.handleDatabaseAccessError(r)}}async removeItem(e){this.inMemoryCache.removeItem(e);try{await this.indexedDBCache.removeItem(e)}catch(n){this.handleDatabaseAccessError(n)}}async getKeys(){const e=this.inMemoryCache.getKeys();if(e.length===0)try{return this.logger.verbose("In-memory cache is empty, now querying persistent storage."),await this.indexedDBCache.getKeys()}catch(n){this.handleDatabaseAccessError(n)}return e}async containsKey(e){const n=this.inMemoryCache.containsKey(e);if(!n)try{return this.logger.verbose("Key not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.containsKey(e)}catch(r){this.handleDatabaseAccessError(r)}return n}clearInMemory(){this.logger.verbose("Deleting in-memory keystore"),this.inMemoryCache.clear(),this.logger.verbose("In-memory keystore deleted")}async clearPersistent(){try{this.logger.verbose("Deleting persistent keystore");const e=await this.indexedDBCache.deleteDatabase();return e&&this.logger.verbose("Persistent keystore deleted"),e}catch(e){return this.handleDatabaseAccessError(e),!1}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class fi{constructor(e,n,r){this.logger=e,Ak(r??!1),this.cache=new jk(this.logger),this.performanceClient=n}createNewGuid(){return jn()}base64Encode(e){return hd(e)}base64Decode(e){return $n(e)}base64UrlEncode(e){return Ks(e)}encodeKid(e){return this.base64UrlEncode(JSON.stringify({kid:e}))}async getPublicKeyThumbprint(e){var u;const n=(u=this.performanceClient)==null?void 0:u.startMeasurement(_.CryptoOptsGetPublicKeyThumbprint,e.correlationId),r=await Ek(fi.EXTRACTABLE,fi.POP_KEY_USAGES),o=await Qc(r.publicKey),i={e:o.e,kty:o.kty,n:o.n},s=Vf(i),a=await this.hashString(s),c=await Qc(r.privateKey),l=await bk(c,!1,["sign"]);return await this.cache.setItem(a,{privateKey:l,publicKey:r.publicKey,requestMethod:e.resourceRequestMethod,requestUri:e.resourceRequestUri}),n&&n.end({success:!0}),a}async removeTokenBindingKey(e){return await this.cache.removeItem(e),!await this.cache.containsKey(e)}async clearKeystore(){this.cache.clearInMemory();try{return await this.cache.clearPersistent(),!0}catch(e){return e instanceof Error?this.logger.error(`Clearing keystore failed with error: ${e.message}`):this.logger.error("Clearing keystore failed with unknown error"),!1}}async signJwt(e,n,r,o){var y;const i=(y=this.performanceClient)==null?void 0:y.startMeasurement(_.CryptoOptsSignJwt,o),s=await this.cache.getItem(n);if(!s)throw te(ud);const a=await Qc(s.publicKey),c=Vf(a),l=Ks(JSON.stringify({kid:n})),u=sd.getShrHeaderString({...r==null?void 0:r.header,alg:a.alg,kid:l}),d=Ks(u);e.cnf={jwk:JSON.parse(c)};const h=Ks(JSON.stringify(e)),f=`${d}.${h}`,g=new TextEncoder().encode(f),m=await _k(s.privateKey,g),C=gc(new Uint8Array(m)),T=`${f}.${C}`;return i&&i.end({success:!0}),T}async hashString(e){return Cv(e)}}fi.POP_KEY_USAGES=["sign","verify"];fi.EXTRACTABLE=!0;function Vf(t){return JSON.stringify(t,Object.keys(t).sort())}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Vk{constructor(){if(!window.localStorage)throw md(pd)}getItem(e){return window.localStorage.getItem(e)}setItem(e,n){window.localStorage.setItem(e,n)}removeItem(e){window.localStorage.removeItem(e)}getKeys(){return Object.keys(window.localStorage)}containsKey(e){return window.localStorage.hasOwnProperty(e)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Gk{constructor(){if(!window.sessionStorage)throw md(pd)}getItem(e){return window.sessionStorage.getItem(e)}setItem(e,n){window.sessionStorage.setItem(e,n)}removeItem(e){window.sessionStorage.removeItem(e)}getKeys(){return Object.keys(window.sessionStorage)}containsKey(e){return window.sessionStorage.hasOwnProperty(e)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function bv(t,e){if(!e)return null;try{return gn.parseRequestState(t,e).libraryState.meta}catch{throw j(li)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const zk=24*60*60*1e3;class Wk{getItem(e){const n=`${encodeURIComponent(e)}`,r=document.cookie.split(";");for(let o=0;o{const o=decodeURIComponent(r).trim().split("=");n.push(o[0])}),n}containsKey(e){return this.getKeys().includes(e)}}function Qk(t){const e=new Date;return new Date(e.getTime()+t*zk).toUTCString()}/*! @azure/msal-browser v3.30.0 2025-08-05 */class zl extends ui{constructor(e,n,r,o,i,s){super(e,r,o,i),this.cacheConfig=n,this.logger=o,this.internalStorage=new Gl,this.browserStorage=this.setupBrowserStorage(this.cacheConfig.cacheLocation),this.temporaryCacheStorage=this.setupBrowserStorage(this.cacheConfig.temporaryCacheLocation),this.cookieStorage=new Wk,n.cacheMigrationEnabled&&(this.migrateCacheEntries(),this.createKeyMaps()),this.performanceClient=s}setupBrowserStorage(e){try{switch(e){case Bt.LocalStorage:return new Vk;case Bt.SessionStorage:return new Gk;case Bt.MemoryStorage:default:break}}catch(n){this.logger.error(n)}return this.cacheConfig.cacheLocation=Bt.MemoryStorage,new Gl}migrateCacheEntries(){const e=this.browserStorage.getItem(on.VERSION);e&&this.logger.info(`MSAL.js was last initialized with version ${e}`),e!==hi&&this.browserStorage.setItem(on.VERSION,hi);const n=`${P.CACHE_PREFIX}.${ft.ID_TOKEN}`,r=`${P.CACHE_PREFIX}.${ft.CLIENT_INFO}`,o=`${P.CACHE_PREFIX}.${ft.ERROR}`,i=`${P.CACHE_PREFIX}.${ft.ERROR_DESC}`,s=this.browserStorage.getItem(n),a=this.browserStorage.getItem(r),c=this.browserStorage.getItem(o),l=this.browserStorage.getItem(i),u=[s,a,c,l];[ft.ID_TOKEN,ft.CLIENT_INFO,ft.ERROR,ft.ERROR_DESC].forEach((h,f)=>{const p=u[f];p&&this.setTemporaryCache(h,p,!0)})}createKeyMaps(){this.logger.trace("BrowserCacheManager - createKeyMaps called.");const e=this.cryptoImpl.createNewGuid(),n=this.getItem(on.ACCOUNT_KEYS),r=this.getItem(`${on.TOKEN_KEYS}.${this.clientId}`);if(n&&r){this.logger.verbose("BrowserCacheManager:createKeyMaps - account and token key maps already exist, skipping migration.");return}this.browserStorage.getKeys().forEach(i=>{if(this.isCredentialKey(i)){const s=this.getItem(i);if(s){const a=this.validateAndParseJson(s);if(a&&a.hasOwnProperty("credentialType"))switch(a.credentialType){case Ce.ID_TOKEN:if(Tf(a)){this.logger.trace("BrowserCacheManager:createKeyMaps - idToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - idToken with key: ${i} found, saving key to token key map`);const c=a,l=this.updateCredentialCacheKey(i,c,e);this.addTokenKey(l,Ce.ID_TOKEN,e);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching idToken schema with value containing idToken credentialType field but value failed IdTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed idToken validation on key: ${i}`);break;case Ce.ACCESS_TOKEN:case Ce.ACCESS_TOKEN_WITH_AUTH_SCHEME:if(Af(a)){this.logger.trace("BrowserCacheManager:createKeyMaps - accessToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - accessToken with key: ${i} found, saving key to token key map`);const c=a,l=this.updateCredentialCacheKey(i,c,e);this.addTokenKey(l,Ce.ACCESS_TOKEN,e);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching accessToken schema with value containing accessToken credentialType field but value failed AccessTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed accessToken validation on key: ${i}`);break;case Ce.REFRESH_TOKEN:if(Ef(a)){this.logger.trace("BrowserCacheManager:createKeyMaps - refreshToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - refreshToken with key: ${i} found, saving key to token key map`);const c=a,l=this.updateCredentialCacheKey(i,c,e);this.addTokenKey(l,Ce.REFRESH_TOKEN,e);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching refreshToken schema with value containing refreshToken credentialType field but value failed RefreshTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed refreshToken validation on key: ${i}`);break}}}if(this.isAccountKey(i)){const s=this.getItem(i);if(s){const a=this.validateAndParseJson(s);a&&dt.isAccountEntity(a)&&(this.logger.trace("BrowserCacheManager:createKeyMaps - account found, saving key to account key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - account with key: ${i} found, saving key to account key map`),this.addAccountKeyToMap(i,e))}}})}validateAndParseJson(e){try{const n=JSON.parse(e);return n&&typeof n=="object"?n:null}catch{return null}}getItem(e){return this.browserStorage.getItem(e)}setItem(e,n,r){let o=[];for(let s=0;s<=20;s++)try{this.browserStorage.setItem(e,n),s>0&&this.removeAccessTokenKeys(o.slice(0,s),r);break}catch(a){const c=Oy(a);if(c.errorCode===Zu&&s<20){if(o.length||(e===`${on.TOKEN_KEYS}.${this.clientId}`?o=JSON.parse(n).accessToken:o=this.getTokenKeys().accessToken),o.length<=s)throw c;this.removeAccessToken(o[s],r,!1)}else throw c}}getAccount(e,n,r){this.logger.trace("BrowserCacheManager.getAccount called");const o=this.getCachedAccountEntity(e,n);return this.updateOutdatedCachedAccount(e,o,n,r)}getCachedAccountEntity(e,n){const r=this.getItem(e);if(!r)return this.removeAccountKeyFromMap(e,n),null;const o=this.validateAndParseJson(r);return!o||!dt.isAccountEntity(o)?null:ui.toObject(new dt,o)}setAccount(e,n){this.logger.trace("BrowserCacheManager.setAccount called");const r=e.generateAccountKey();e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addAccountKeyToMap(r,n)}getAccountKeys(){this.logger.trace("BrowserCacheManager.getAccountKeys called");const e=this.getItem(on.ACCOUNT_KEYS);return e?JSON.parse(e):(this.logger.verbose("BrowserCacheManager.getAccountKeys - No account keys found"),[])}addAccountKeyToMap(e,n){this.logger.trace("BrowserCacheManager.addAccountKeyToMap called"),this.logger.tracePii(`BrowserCacheManager.addAccountKeyToMap called with key: ${e}`);const r=this.getAccountKeys();r.indexOf(e)===-1?(r.push(e),this.setItem(on.ACCOUNT_KEYS,JSON.stringify(r),n),this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key added")):this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key already exists in map")}removeAccountKeyFromMap(e,n){this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap called"),this.logger.tracePii(`BrowserCacheManager.removeAccountKeyFromMap called with key: ${e}`);const r=this.getAccountKeys(),o=r.indexOf(e);if(o>-1){if(r.splice(o,1),r.length===0){this.removeItem(on.ACCOUNT_KEYS);return}else this.setItem(on.ACCOUNT_KEYS,JSON.stringify(r),n);this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap account key removed")}else this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap key not found in existing map")}async removeAccount(e,n){super.removeAccount(e,n),this.removeAccountKeyFromMap(e,n)}removeOutdatedAccount(e,n){this.removeItem(e),this.removeAccountKeyFromMap(e,n)}removeIdToken(e,n){super.removeIdToken(e,n),this.removeTokenKey(e,Ce.ID_TOKEN,n)}removeAccessToken(e,n,r=!0){var o;super.removeAccessToken(e,n),(o=this.performanceClient)==null||o.incrementFields({accessTokensRemoved:1},n),r&&this.removeTokenKey(e,Ce.ACCESS_TOKEN,n)}removeAccessTokenKeys(e,n){this.logger.trace("removeAccessTokenKey called");const r=this.getTokenKeys();let o=0;if(e.forEach(i=>{const s=r.accessToken.indexOf(i);s>-1&&(r.accessToken.splice(s,1),o++)}),o>0){this.logger.info(`removed ${o} accessToken keys from tokenKeys map`),this.setTokenKeys(r,n);return}}removeRefreshToken(e,n){super.removeRefreshToken(e,n),this.removeTokenKey(e,Ce.REFRESH_TOKEN,n)}getTokenKeys(){this.logger.trace("BrowserCacheManager.getTokenKeys called");const e=this.getItem(`${on.TOKEN_KEYS}.${this.clientId}`);if(e){const n=this.validateAndParseJson(e);if(n&&n.hasOwnProperty("idToken")&&n.hasOwnProperty("accessToken")&&n.hasOwnProperty("refreshToken"))return n;this.logger.error("BrowserCacheManager.getTokenKeys - Token keys found but in an unknown format. Returning empty key map.")}else this.logger.verbose("BrowserCacheManager.getTokenKeys - No token keys found");return{idToken:[],accessToken:[],refreshToken:[]}}setTokenKeys(e,n){if(e.idToken.length===0&&e.accessToken.length===0&&e.refreshToken.length===0){this.removeItem(`${on.TOKEN_KEYS}.${this.clientId}`);return}else this.setItem(`${on.TOKEN_KEYS}.${this.clientId}`,JSON.stringify(e),n)}addTokenKey(e,n,r){this.logger.trace("BrowserCacheManager addTokenKey called");const o=this.getTokenKeys();switch(n){case Ce.ID_TOKEN:o.idToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - idToken added to map"),o.idToken.push(e));break;case Ce.ACCESS_TOKEN:const i=o.accessToken.indexOf(e);i!==-1&&o.accessToken.splice(i,1),this.logger.trace(`access token ${i===-1?"added to":"updated in"} map`),o.accessToken.push(e);break;case Ce.REFRESH_TOKEN:o.refreshToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - refreshToken added to map"),o.refreshToken.push(e));break;default:throw this.logger.error(`BrowserCacheManager:addTokenKey - CredentialType provided invalid. CredentialType: ${n}`),j(Ll)}this.setTokenKeys(o,r)}removeTokenKey(e,n,r,o=this.getTokenKeys()){switch(this.logger.trace("BrowserCacheManager removeTokenKey called"),n){case Ce.ID_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove idToken with key: ${e} from map`);const i=o.idToken.indexOf(e);i>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - idToken removed from map"),o.idToken.splice(i,1)):this.logger.info("BrowserCacheManager: removeTokenKey - idToken does not exist in map. Either it was previously removed or it was never added.");break;case Ce.ACCESS_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove accessToken with key: ${e} from map`);const s=o.accessToken.indexOf(e);s>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - accessToken removed from map"),o.accessToken.splice(s,1)):this.logger.info("BrowserCacheManager: removeTokenKey - accessToken does not exist in map. Either it was previously removed or it was never added.");break;case Ce.REFRESH_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove refreshToken with key: ${e} from map`);const a=o.refreshToken.indexOf(e);a>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken removed from map"),o.refreshToken.splice(a,1)):this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken does not exist in map. Either it was previously removed or it was never added.");break;default:throw this.logger.error(`BrowserCacheManager:removeTokenKey - CredentialType provided invalid. CredentialType: ${n}`),j(Ll)}this.setTokenKeys(o,r)}getIdTokenCredential(e,n){const r=this.getItem(e);if(!r)return this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeIdToken(e,n),null;const o=this.validateAndParseJson(r);return!o||!Tf(o)?(this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getIdTokenCredential: cache hit"),o)}setIdTokenCredential(e,n){this.logger.trace("BrowserCacheManager.setIdTokenCredential called");const r=Bo(e);e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addTokenKey(r,Ce.ID_TOKEN,n)}getAccessTokenCredential(e,n){const r=this.getItem(e);if(!r)return this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(e,Ce.ACCESS_TOKEN,n),null;const o=this.validateAndParseJson(r);return!o||!Af(o)?(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: cache hit"),o)}setAccessTokenCredential(e,n){this.logger.trace("BrowserCacheManager.setAccessTokenCredential called");const r=Bo(e);e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addTokenKey(r,Ce.ACCESS_TOKEN,n)}getRefreshTokenCredential(e,n){const r=this.getItem(e);if(!r)return this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(e,Ce.REFRESH_TOKEN,n),null;const o=this.validateAndParseJson(r);return!o||!Ef(o)?(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: cache hit"),o)}setRefreshTokenCredential(e,n){this.logger.trace("BrowserCacheManager.setRefreshTokenCredential called");const r=Bo(e);e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addTokenKey(r,Ce.REFRESH_TOKEN,n)}getAppMetadata(e){const n=this.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null;const r=this.validateAndParseJson(n);return!r||!HR(e,r)?(this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getAppMetadata: cache hit"),r)}setAppMetadata(e,n){this.logger.trace("BrowserCacheManager.setAppMetadata called");const r=UR(e);this.setItem(r,JSON.stringify(e),n)}getServerTelemetry(e){const n=this.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null;const r=this.validateAndParseJson(n);return!r||!DR(e,r)?(this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getServerTelemetry: cache hit"),r)}setServerTelemetry(e,n,r){this.logger.trace("BrowserCacheManager.setServerTelemetry called"),this.setItem(e,JSON.stringify(n),r)}getAuthorityMetadata(e){const n=this.internalStorage.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getAuthorityMetadata: called, no cache hit"),null;const r=this.validateAndParseJson(n);return r&&BR(e,r)?(this.logger.trace("BrowserCacheManager.getAuthorityMetadata: cache hit"),r):null}getAuthorityMetadataKeys(){return this.internalStorage.getKeys().filter(n=>this.isAuthorityMetadata(n))}setWrapperMetadata(e,n){this.internalStorage.setItem(Fs.WRAPPER_SKU,e),this.internalStorage.setItem(Fs.WRAPPER_VER,n)}getWrapperMetadata(){const e=this.internalStorage.getItem(Fs.WRAPPER_SKU)||P.EMPTY_STRING,n=this.internalStorage.getItem(Fs.WRAPPER_VER)||P.EMPTY_STRING;return[e,n]}setAuthorityMetadata(e,n){this.logger.trace("BrowserCacheManager.setAuthorityMetadata called"),this.internalStorage.setItem(e,JSON.stringify(n))}getActiveAccount(e){const n=this.generateCacheKey(ft.ACTIVE_ACCOUNT_FILTERS),r=this.getItem(n);if(!r){this.logger.trace("BrowserCacheManager.getActiveAccount: No active account filters cache schema found, looking for legacy schema");const i=this.generateCacheKey(ft.ACTIVE_ACCOUNT),s=this.getItem(i);if(!s)return this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null;const a=this.getAccountInfoFilteredBy({localAccountId:s},e);return a?(this.logger.trace("BrowserCacheManager.getActiveAccount: Legacy active account cache schema found"),this.logger.trace("BrowserCacheManager.getActiveAccount: Adding active account filters cache schema"),this.setActiveAccount(a,e),a):null}const o=this.validateAndParseJson(r);return o?(this.logger.trace("BrowserCacheManager.getActiveAccount: Active account filters schema found"),this.getAccountInfoFilteredBy({homeAccountId:o.homeAccountId,localAccountId:o.localAccountId,tenantId:o.tenantId},e)):(this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null)}setActiveAccount(e,n){const r=this.generateCacheKey(ft.ACTIVE_ACCOUNT_FILTERS),o=this.generateCacheKey(ft.ACTIVE_ACCOUNT);if(e){this.logger.verbose("setActiveAccount: Active account set");const i={homeAccountId:e.homeAccountId,localAccountId:e.localAccountId,tenantId:e.tenantId,lastUpdatedAt:Date.now().toString()};this.setItem(r,JSON.stringify(i),n),this.setItem(o,e.localAccountId,n)}else this.logger.verbose("setActiveAccount: No account passed, active account not set"),this.browserStorage.removeItem(r),this.browserStorage.removeItem(o)}getThrottlingCache(e){const n=this.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null;const r=this.validateAndParseJson(n);return!r||!LR(e,r)?(this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getThrottlingCache: cache hit"),r)}setThrottlingCache(e,n,r){this.logger.trace("BrowserCacheManager.setThrottlingCache called"),this.setItem(e,JSON.stringify(n),r)}getTemporaryCache(e,n){const r=n?this.generateCacheKey(e):e;if(this.cacheConfig.storeAuthStateInCookie){const i=this.cookieStorage.getItem(r);if(i)return this.logger.trace("BrowserCacheManager.getTemporaryCache: storeAuthStateInCookies set to true, retrieving from cookies"),i}const o=this.temporaryCacheStorage.getItem(r);if(!o){if(this.cacheConfig.cacheLocation===Bt.LocalStorage){const i=this.browserStorage.getItem(r);if(i)return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item found in local storage"),i}return this.logger.trace("BrowserCacheManager.getTemporaryCache: No cache item found in local storage"),null}return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item returned"),o}setTemporaryCache(e,n,r){const o=r?this.generateCacheKey(e):e;this.temporaryCacheStorage.setItem(o,n),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.setTemporaryCache: storeAuthStateInCookie set to true, setting item cookie"),this.cookieStorage.setItem(o,n,void 0,this.cacheConfig.secureCookies))}removeItem(e){this.browserStorage.removeItem(e)}removeTemporaryItem(e){this.temporaryCacheStorage.removeItem(e),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.removeItem: storeAuthStateInCookie is true, clearing item cookie"),this.cookieStorage.removeItem(e))}getKeys(){return this.browserStorage.getKeys()}async clear(e){await this.removeAllAccounts(e),this.removeAppMetadata(e),this.temporaryCacheStorage.getKeys().forEach(n=>{(n.indexOf(P.CACHE_PREFIX)!==-1||n.indexOf(this.clientId)!==-1)&&this.removeTemporaryItem(n)}),this.browserStorage.getKeys().forEach(n=>{(n.indexOf(P.CACHE_PREFIX)!==-1||n.indexOf(this.clientId)!==-1)&&this.browserStorage.removeItem(n)}),this.internalStorage.clear()}async clearTokensAndKeysWithClaims(e,n){e.addQueueMeasurement(_.ClearTokensAndKeysWithClaims,n);const r=this.getTokenKeys();let o=0;r.accessToken.forEach(i=>{const s=this.getAccessTokenCredential(i,n);s!=null&&s.requestedClaimsHash&&i.includes(s.requestedClaimsHash.toLowerCase())&&(this.removeAccessToken(i,n),o++)}),o>0&&this.logger.warning(`${o} access tokens with claims in the cache keys have been removed from the cache.`)}generateCacheKey(e){return this.validateAndParseJson(e)?JSON.stringify(e):pn.startsWith(e,P.CACHE_PREFIX)||pn.startsWith(e,ft.ADAL_ID_TOKEN)?e:`${P.CACHE_PREFIX}.${this.clientId}.${e}`}generateAuthorityKey(e){const{libraryState:{id:n}}=gn.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Be.AUTHORITY}.${n}`)}generateNonceKey(e){const{libraryState:{id:n}}=gn.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Be.NONCE_IDTOKEN}.${n}`)}generateStateKey(e){const{libraryState:{id:n}}=gn.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Be.REQUEST_STATE}.${n}`)}getCachedAuthority(e){const n=this.generateStateKey(e),r=this.getTemporaryCache(n);if(!r)return null;const o=this.generateAuthorityKey(r);return this.getTemporaryCache(o)}updateCacheEntries(e,n,r,o,i){this.logger.trace("BrowserCacheManager.updateCacheEntries called");const s=this.generateStateKey(e);this.setTemporaryCache(s,e,!1);const a=this.generateNonceKey(e);this.setTemporaryCache(a,n,!1);const c=this.generateAuthorityKey(e);if(this.setTemporaryCache(c,r,!1),i){const l={credential:i.homeAccountId,type:Jt.HOME_ACCOUNT_ID};this.setTemporaryCache(Be.CCS_CREDENTIAL,JSON.stringify(l),!0)}else if(o){const l={credential:o,type:Jt.UPN};this.setTemporaryCache(Be.CCS_CREDENTIAL,JSON.stringify(l),!0)}}resetRequestCache(e){this.logger.trace("BrowserCacheManager.resetRequestCache called"),e&&(this.temporaryCacheStorage.getKeys().forEach(n=>{n.indexOf(e)!==-1&&this.removeTemporaryItem(n)}),this.removeTemporaryItem(this.generateStateKey(e)),this.removeTemporaryItem(this.generateNonceKey(e)),this.removeTemporaryItem(this.generateAuthorityKey(e))),this.removeTemporaryItem(this.generateCacheKey(Be.REQUEST_PARAMS)),this.removeTemporaryItem(this.generateCacheKey(Be.ORIGIN_URI)),this.removeTemporaryItem(this.generateCacheKey(Be.URL_HASH)),this.removeTemporaryItem(this.generateCacheKey(Be.CORRELATION_ID)),this.removeTemporaryItem(this.generateCacheKey(Be.CCS_CREDENTIAL)),this.removeTemporaryItem(this.generateCacheKey(Be.NATIVE_REQUEST)),this.setInteractionInProgress(!1)}cleanRequestByState(e){if(this.logger.trace("BrowserCacheManager.cleanRequestByState called"),e){const n=this.generateStateKey(e),r=this.temporaryCacheStorage.getItem(n);this.logger.infoPii(`BrowserCacheManager.cleanRequestByState: Removing temporary cache items for state: ${r}`),this.resetRequestCache(r||P.EMPTY_STRING)}}cleanRequestByInteractionType(e){this.logger.trace("BrowserCacheManager.cleanRequestByInteractionType called"),this.temporaryCacheStorage.getKeys().forEach(n=>{if(n.indexOf(Be.REQUEST_STATE)===-1)return;const r=this.temporaryCacheStorage.getItem(n);if(!r)return;const o=bv(this.cryptoImpl,r);o&&o.interactionType===e&&(this.logger.infoPii(`BrowserCacheManager.cleanRequestByInteractionType: Removing temporary cache items for state: ${r}`),this.resetRequestCache(r))}),this.setInteractionInProgress(!1)}cacheCodeRequest(e){this.logger.trace("BrowserCacheManager.cacheCodeRequest called");const n=hd(JSON.stringify(e));this.setTemporaryCache(Be.REQUEST_PARAMS,n,!0)}getCachedRequest(e){this.logger.trace("BrowserCacheManager.getCachedRequest called");const n=this.getTemporaryCache(Be.REQUEST_PARAMS,!0);if(!n)throw te(Xy);let r;try{r=JSON.parse($n(n))}catch(o){throw this.logger.errorPii(`Attempted to parse: ${n}`),this.logger.error(`Parsing cached token request threw with error: ${o}`),te(Zy)}if(this.removeTemporaryItem(this.generateCacheKey(Be.REQUEST_PARAMS)),!r.authority){const o=this.generateAuthorityKey(e),i=this.getTemporaryCache(o);if(!i)throw te(ld);r.authority=i}return r}getCachedNativeRequest(){this.logger.trace("BrowserCacheManager.getCachedNativeRequest called");const e=this.getTemporaryCache(Be.NATIVE_REQUEST,!0);if(!e)return this.logger.trace("BrowserCacheManager.getCachedNativeRequest: No cached native request found"),null;const n=this.validateAndParseJson(e);return n||(this.logger.error("BrowserCacheManager.getCachedNativeRequest: Unable to parse native request"),null)}isInteractionInProgress(e){const n=this.getInteractionInProgress();return e?n===this.clientId:!!n}getInteractionInProgress(){const e=`${P.CACHE_PREFIX}.${Be.INTERACTION_STATUS_KEY}`;return this.getTemporaryCache(e,!1)}setInteractionInProgress(e){const n=`${P.CACHE_PREFIX}.${Be.INTERACTION_STATUS_KEY}`;if(e){if(this.getInteractionInProgress())throw te(jy);this.setTemporaryCache(n,this.clientId,!1)}else!e&&this.getInteractionInProgress()===this.clientId&&this.removeTemporaryItem(n)}getLegacyLoginHint(){const e=this.getTemporaryCache(ft.ADAL_ID_TOKEN);e&&(this.browserStorage.removeItem(ft.ADAL_ID_TOKEN),this.logger.verbose("Cached ADAL id token retrieved."));const n=this.getTemporaryCache(ft.ID_TOKEN,!0);n&&(this.browserStorage.removeItem(this.generateCacheKey(ft.ID_TOKEN)),this.logger.verbose("Cached MSAL.js v1 id token retrieved"));const r=n||e;if(r){const o=bo(r,$n);if(o.preferred_username)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 preferred_username as loginHint"),o.preferred_username;if(o.upn)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 upn as loginHint"),o.upn;this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, however, no account hint claim found. Enable preferred_username or upn id token claim to get SSO.")}return null}updateCredentialCacheKey(e,n,r){const o=Bo(n);if(e!==o){const i=this.getItem(e);if(i)return this.browserStorage.removeItem(e),this.setItem(o,i,r),this.logger.verbose(`Updated an outdated ${n.credentialType} cache key`),o;this.logger.error(`Attempted to update an outdated ${n.credentialType} cache key but no item matching the outdated key was found in storage`)}return e}async hydrateCache(e,n){var a,c,l;const r=sc((a=e.account)==null?void 0:a.homeAccountId,(c=e.account)==null?void 0:c.environment,e.idToken,this.clientId,e.tenantId);let o;n.claims&&(o=await this.cryptoImpl.hashString(n.claims));const i=ac((l=e.account)==null?void 0:l.homeAccountId,e.account.environment,e.accessToken,this.clientId,e.tenantId,e.scopes.join(" "),e.expiresOn?e.expiresOn.getTime()/1e3:0,e.extExpiresOn?e.extExpiresOn.getTime()/1e3:0,$n,void 0,e.tokenType,void 0,n.sshKid,n.claims,o),s={idToken:r,accessToken:i};return this.saveCacheRecord(s,e.correlationId)}async saveCacheRecord(e,n,r){try{await super.saveCacheRecord(e,n,r)}catch(o){if(o instanceof zo&&this.performanceClient&&n)try{const i=this.getTokenKeys();this.performanceClient.addFields({cacheRtCount:i.refreshToken.length,cacheIdCount:i.idToken.length,cacheAtCount:i.accessToken.length},n)}catch{}throw o}}}const Yk=(t,e)=>{const n={cacheLocation:Bt.MemoryStorage,temporaryCacheLocation:Bt.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};return new zl(t,n,fa,e)};/*! @azure/msal-browser v3.30.0 2025-08-05 */function Jk(t,e,n,r,o){return t.verbose("getAllAccounts called"),n?e.getAllAccounts(r,o):[]}function Xk(t,e,n,r){if(e.trace("getAccount called"),Object.keys(t).length===0)return e.warning("getAccount: No accountFilter provided"),null;const o=n.getAccountInfoFilteredBy(t,r);return o?(e.verbose("getAccount: Account matching provided filter found, returning"),o):(e.verbose("getAccount: No matching account found, returning null"),null)}function Zk(t,e,n,r){if(e.trace("getAccountByUsername called"),!t)return e.warning("getAccountByUsername: No username provided"),null;const o=n.getAccountInfoFilteredBy({username:t},r);return o?(e.verbose("getAccountByUsername: Account matching username found, returning"),e.verbosePii(`getAccountByUsername: Returning signed-in accounts matching username: ${t}`),o):(e.verbose("getAccountByUsername: No matching account found, returning null"),null)}function eP(t,e,n,r){if(e.trace("getAccountByHomeId called"),!t)return e.warning("getAccountByHomeId: No homeAccountId provided"),null;const o=n.getAccountInfoFilteredBy({homeAccountId:t},r);return o?(e.verbose("getAccountByHomeId: Account matching homeAccountId found, returning"),e.verbosePii(`getAccountByHomeId: Returning signed-in accounts matching homeAccountId: ${t}`),o):(e.verbose("getAccountByHomeId: No matching account found, returning null"),null)}function tP(t,e,n,r){if(e.trace("getAccountByLocalId called"),!t)return e.warning("getAccountByLocalId: No localAccountId provided"),null;const o=n.getAccountInfoFilteredBy({localAccountId:t},r);return o?(e.verbose("getAccountByLocalId: Account matching localAccountId found, returning"),e.verbosePii(`getAccountByLocalId: Returning signed-in accounts matching localAccountId: ${t}`),o):(e.verbose("getAccountByLocalId: No matching account found, returning null"),null)}function nP(t,e,n){e.setActiveAccount(t,n)}function rP(t,e){return t.getActiveAccount(e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const me={INITIALIZE_START:"msal:initializeStart",INITIALIZE_END:"msal:initializeEnd",ACCOUNT_ADDED:"msal:accountAdded",ACCOUNT_REMOVED:"msal:accountRemoved",ACTIVE_ACCOUNT_CHANGED:"msal:activeAccountChanged",LOGIN_START:"msal:loginStart",LOGIN_SUCCESS:"msal:loginSuccess",LOGIN_FAILURE:"msal:loginFailure",ACQUIRE_TOKEN_START:"msal:acquireTokenStart",ACQUIRE_TOKEN_SUCCESS:"msal:acquireTokenSuccess",ACQUIRE_TOKEN_FAILURE:"msal:acquireTokenFailure",ACQUIRE_TOKEN_NETWORK_START:"msal:acquireTokenFromNetworkStart",SSO_SILENT_START:"msal:ssoSilentStart",SSO_SILENT_SUCCESS:"msal:ssoSilentSuccess",SSO_SILENT_FAILURE:"msal:ssoSilentFailure",ACQUIRE_TOKEN_BY_CODE_START:"msal:acquireTokenByCodeStart",ACQUIRE_TOKEN_BY_CODE_SUCCESS:"msal:acquireTokenByCodeSuccess",ACQUIRE_TOKEN_BY_CODE_FAILURE:"msal:acquireTokenByCodeFailure",HANDLE_REDIRECT_START:"msal:handleRedirectStart",HANDLE_REDIRECT_END:"msal:handleRedirectEnd",POPUP_OPENED:"msal:popupOpened",LOGOUT_START:"msal:logoutStart",LOGOUT_SUCCESS:"msal:logoutSuccess",LOGOUT_FAILURE:"msal:logoutFailure",LOGOUT_END:"msal:logoutEnd",RESTORE_FROM_BFCACHE:"msal:restoreFromBFCache"};/*! @azure/msal-browser v3.30.0 2025-08-05 */class oP{constructor(e){this.eventCallbacks=new Map,this.logger=e||new Kr({})}addEventCallback(e,n,r){if(typeof window<"u"){const o=r||Dk();return this.eventCallbacks.has(o)?(this.logger.error(`Event callback with id: ${o} is already registered. Please provide a unique id or remove the existing callback and try again.`),null):(this.eventCallbacks.set(o,[e,n||[]]),this.logger.verbose(`Event callback registered with id: ${o}`),o)}return null}removeEventCallback(e){this.eventCallbacks.delete(e),this.logger.verbose(`Event callback ${e} removed.`)}emitEvent(e,n,r,o){if(typeof window<"u"){const i={eventType:e,interactionType:n||null,payload:r||null,error:o||null,timestamp:Date.now()};this.eventCallbacks.forEach(([s,a],c)=>{(a.length===0||a.includes(e))&&(this.logger.verbose(`Emitting event to callback ${c}: ${e}`),s.apply(null,[i]))})}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class _v{constructor(e,n,r,o,i,s,a,c,l){this.config=e,this.browserStorage=n,this.browserCrypto=r,this.networkClient=this.config.system.networkClient,this.eventHandler=i,this.navigationClient=s,this.nativeMessageHandler=c,this.correlationId=l||jn(),this.logger=o.clone(Qt.MSAL_SKU,hi,this.correlationId),this.performanceClient=a}async clearCacheOnLogout(e){if(e){dt.accountInfoIsEqual(e,this.browserStorage.getActiveAccount(this.correlationId),!1)&&(this.logger.verbose("Setting active account to null"),this.browserStorage.setActiveAccount(null,this.correlationId));try{await this.browserStorage.removeAccount(dt.generateAccountCacheKey(e),this.correlationId),this.logger.verbose("Cleared cache items belonging to the account provided in the logout request.")}catch{this.logger.error("Account provided in logout request was not found. Local cache unchanged.")}}else try{this.logger.verbose("No account provided in logout request, clearing all cache items.",this.correlationId),await this.browserStorage.clear(this.correlationId),await this.browserCrypto.clearKeystore()}catch{this.logger.error("Attempted to clear all MSAL cache items and failed. Local cache unchanged.")}}getRedirectUri(e){this.logger.verbose("getRedirectUri called");const n=e||this.config.auth.redirectUri;return Oe.getAbsoluteUrl(n,ir())}initializeServerTelemetryManager(e,n){this.logger.verbose("initializeServerTelemetryManager called");const r={clientId:this.config.auth.clientId,correlationId:this.correlationId,apiId:e,forceRefresh:n||!1,wrapperSKU:this.browserStorage.getWrapperMetadata()[0],wrapperVer:this.browserStorage.getWrapperMetadata()[1]};return new es(r,this.browserStorage)}async getDiscoveredAuthority(e){const{account:n}=e,r=e.requestExtraQueryParameters&&e.requestExtraQueryParameters.hasOwnProperty("instance_aware")?e.requestExtraQueryParameters.instance_aware:void 0;this.performanceClient.addQueueMeasurement(_.StandardInteractionClientGetDiscoveredAuthority,this.correlationId);const o={protocolMode:this.config.auth.protocolMode,OIDCOptions:this.config.auth.OIDCOptions,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},i=e.requestAuthority||this.config.auth.authority,s=r!=null&&r.length?r==="true":this.config.auth.instanceAware,a=n&&s?this.config.auth.authority.replace(Oe.getDomainFromUrl(i),n.environment):i,c=bt.generateAuthority(a,e.requestAzureCloudOptions||this.config.auth.azureCloudOptions),l=await G(xy,_.AuthorityFactoryCreateDiscoveredInstance,this.logger,this.performanceClient,this.correlationId)(c,this.config.system.networkClient,this.browserStorage,o,this.logger,this.correlationId,this.performanceClient);if(n&&!l.isAlias(n.environment))throw $e(by);return l}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const iP=32;async function sP(t,e,n){t.addQueueMeasurement(_.GeneratePkceCodes,n);const r=_o(aP,_.GenerateCodeVerifier,e,t,n)(t,e,n),o=await G(cP,_.GenerateCodeChallengeFromVerifier,e,t,n)(r,t,e,n);return{verifier:r,challenge:o}}function aP(t,e,n){try{const r=new Uint8Array(iP);return _o(Tk,_.GetRandomValues,e,t,n)(r),gc(r)}catch{throw te(ad)}}async function cP(t,e,n,r){e.addQueueMeasurement(_.GenerateCodeChallengeFromVerifier,r);try{const o=await G(vv,_.Sha256Digest,n,e,r)(t,e,r);return gc(new Uint8Array(o))}catch{throw te(ad)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */async function wd(t,e,n,r){n.addQueueMeasurement(_.InitializeBaseRequest,t.correlationId);const o=t.authority||e.auth.authority,i=[...t&&t.scopes||[]],s={...t,correlationId:t.correlationId,authority:o,scopes:i};if(!s.authenticationScheme)s.authenticationScheme=Fe.BEARER,r.verbose(`Authentication Scheme wasn't explicitly set in request, defaulting to "Bearer" request`);else{if(s.authenticationScheme===Fe.SSH){if(!t.sshJwk)throw $e(cc);if(!t.sshKid)throw $e(Ay)}r.verbose(`Authentication Scheme set to "${s.authenticationScheme}" as configured in Auth request`)}return e.cache.claimsBasedCachingEnabled&&t.claims&&!pn.isEmptyObj(t.claims)&&(s.requestedClaimsHash=await Cv(t.claims)),s}async function lP(t,e,n,r,o){r.addQueueMeasurement(_.InitializeSilentRequest,t.correlationId);const i=await G(wd,_.InitializeBaseRequest,o,r,t.correlationId)(t,n,r,o);return{...t,...i,account:e,forceRefresh:t.forceRefresh||!1}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class yi extends _v{async initializeAuthorizationCodeRequest(e){this.performanceClient.addQueueMeasurement(_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.correlationId);const n=await G(sP,_.GeneratePkceCodes,this.logger,this.performanceClient,this.correlationId)(this.performanceClient,this.logger,this.correlationId),r={...e,redirectUri:e.redirectUri,code:P.EMPTY_STRING,codeVerifier:n.verifier};return e.codeChallenge=n.challenge,e.codeChallengeMethod=P.S256_CODE_CHALLENGE_METHOD,r}initializeLogoutRequest(e){this.logger.verbose("initializeLogoutRequest called",e==null?void 0:e.correlationId);const n={correlationId:this.correlationId||jn(),...e};if(e)if(e.logoutHint)this.logger.verbose("logoutHint has already been set in logoutRequest");else if(e.account){const r=this.getLogoutHintFromIdTokenClaims(e.account);r&&(this.logger.verbose("Setting logoutHint to login_hint ID Token Claim value for the account provided"),n.logoutHint=r)}else this.logger.verbose("logoutHint was not set and account was not passed into logout request, logoutHint will not be set");else this.logger.verbose("logoutHint will not be set since no logout request was configured");return!e||e.postLogoutRedirectUri!==null?e&&e.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to uri set on logout request",n.correlationId),n.postLogoutRedirectUri=Oe.getAbsoluteUrl(e.postLogoutRedirectUri,ir())):this.config.auth.postLogoutRedirectUri===null?this.logger.verbose("postLogoutRedirectUri configured as null and no uri set on request, not passing post logout redirect",n.correlationId):this.config.auth.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to configured uri",n.correlationId),n.postLogoutRedirectUri=Oe.getAbsoluteUrl(this.config.auth.postLogoutRedirectUri,ir())):(this.logger.verbose("Setting postLogoutRedirectUri to current page",n.correlationId),n.postLogoutRedirectUri=Oe.getAbsoluteUrl(ir(),ir())):this.logger.verbose("postLogoutRedirectUri passed as null, not setting post logout redirect uri",n.correlationId),n}getLogoutHintFromIdTokenClaims(e){const n=e.idTokenClaims;if(n){if(n.login_hint)return n.login_hint;this.logger.verbose("The ID Token Claims tied to the provided account do not contain a login_hint claim, logoutHint will not be added to logout request")}else this.logger.verbose("The provided account does not contain ID Token Claims, logoutHint will not be added to logout request");return null}async createAuthCodeClient(e){this.performanceClient.addQueueMeasurement(_.StandardInteractionClientCreateAuthCodeClient,this.correlationId);const n=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)(e);return new Ly(n,this.performanceClient)}async getClientConfiguration(e){const{serverTelemetryManager:n,requestAuthority:r,requestAzureCloudOptions:o,requestExtraQueryParameters:i,account:s}=e;this.performanceClient.addQueueMeasurement(_.StandardInteractionClientGetClientConfiguration,this.correlationId);const a=await G(this.getDiscoveredAuthority.bind(this),_.StandardInteractionClientGetDiscoveredAuthority,this.logger,this.performanceClient,this.correlationId)({requestAuthority:r,requestAzureCloudOptions:o,requestExtraQueryParameters:i,account:s}),c=this.config.system.loggerOptions;return{authOptions:{clientId:this.config.auth.clientId,authority:a,clientCapabilities:this.config.auth.clientCapabilities,redirectUri:this.config.auth.redirectUri},systemOptions:{tokenRenewalOffsetSeconds:this.config.system.tokenRenewalOffsetSeconds,preventCorsPreflight:!0},loggerOptions:{loggerCallback:c.loggerCallback,piiLoggingEnabled:c.piiLoggingEnabled,logLevel:c.logLevel,correlationId:this.correlationId},cacheOptions:{claimsBasedCachingEnabled:this.config.cache.claimsBasedCachingEnabled},cryptoInterface:this.browserCrypto,networkInterface:this.networkClient,storageInterface:this.browserStorage,serverTelemetryManager:n,libraryInfo:{sku:Qt.MSAL_SKU,version:hi,cpu:P.EMPTY_STRING,os:P.EMPTY_STRING},telemetry:this.config.telemetry}}async initializeAuthorizationRequest(e,n){this.performanceClient.addQueueMeasurement(_.StandardInteractionClientInitializeAuthorizationRequest,this.correlationId);const r=this.getRedirectUri(e.redirectUri),o={interactionType:n},i=gn.setRequestState(this.browserCrypto,e&&e.state||P.EMPTY_STRING,o),a={...await G(wd,_.InitializeBaseRequest,this.logger,this.performanceClient,this.correlationId)({...e,correlationId:this.correlationId},this.config,this.performanceClient,this.logger),redirectUri:r,state:i,nonce:e.nonce||jn(),responseMode:this.config.auth.OIDCOptions.serverResponseType};if(e.loginHint||e.sid)return a;const c=e.account||this.browserStorage.getActiveAccount(this.correlationId);if(c&&(this.logger.verbose("Setting validated request account",this.correlationId),this.logger.verbosePii(`Setting validated request account: ${c.homeAccountId}`,this.correlationId),a.account=c),!a.loginHint&&!c){const l=this.browserStorage.getLegacyLoginHint();l&&(a.loginHint=l)}return a}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const uP="ContentError",Sv="user_switch";/*! @azure/msal-browser v3.30.0 2025-08-05 */const dP="USER_INTERACTION_REQUIRED",hP="USER_CANCEL",fP="NO_NETWORK",pP="PERSISTENT_ERROR",gP="DISABLED",mP="ACCOUNT_UNAVAILABLE";/*! @azure/msal-browser v3.30.0 2025-08-05 */const yP=-2147186943,vP={[Sv]:"User attempted to switch accounts in the native broker, which is not allowed. All new accounts must sign-in through the standard web flow first, please try again."};class Ln extends We{constructor(e,n,r){super(e,n),Object.setPrototypeOf(this,Ln.prototype),this.name="NativeAuthError",this.ext=r}}function Uo(t){if(t.ext&&t.ext.status&&(t.ext.status===pP||t.ext.status===gP)||t.ext&&t.ext.error&&t.ext.error===yP)return!0;switch(t.errorCode){case uP:return!0;default:return!1}}function Wl(t,e,n){if(n&&n.status)switch(n.status){case mP:return Fl(My);case dP:return new En(t,e);case hP:return te(wo);case fP:return te(Ca)}return new Ln(t,vP[t]||e,n)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Iv extends yi{async acquireToken(e){this.performanceClient.addQueueMeasurement(_.SilentCacheClientAcquireToken,e.correlationId);const n=this.initializeServerTelemetryManager(ze.acquireTokenSilent_silentFlow),r=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:n,requestAuthority:e.authority,requestAzureCloudOptions:e.azureCloudOptions,account:e.account}),o=new ek(r,this.performanceClient);this.logger.verbose("Silent auth client created");try{const s=(await G(o.acquireCachedToken.bind(o),_.SilentFlowClientAcquireCachedToken,this.logger,this.performanceClient,e.correlationId)(e))[0];return this.performanceClient.addFields({fromCache:!0},e.correlationId),s}catch(i){throw i instanceof Ts&&i.errorCode===ud&&this.logger.verbose("Signing keypair for bound access token not found. Refreshing bound access token and generating a new crypto keypair."),i}}logout(e){this.logger.verbose("logoutRedirect called");const n=this.initializeLogoutRequest(e);return this.clearCacheOnLogout(n==null?void 0:n.account)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Wo extends _v{constructor(e,n,r,o,i,s,a,c,l,u,d,h){var p;super(e,n,r,o,i,s,c,l,h),this.apiId=a,this.accountId=u,this.nativeMessageHandler=l,this.nativeStorageManager=d,this.silentCacheClient=new Iv(e,this.nativeStorageManager,r,o,i,s,c,l,h),this.serverTelemetryManager=this.initializeServerTelemetryManager(this.apiId);const f=this.nativeMessageHandler.getExtensionId()===Ko.PREFERRED_EXTENSION_ID?"chrome":(p=this.nativeMessageHandler.getExtensionId())!=null&&p.length?"unknown":void 0;this.skus=es.makeExtraSkuString({libraryName:Qt.MSAL_SKU,libraryVersion:hi,extensionName:f,extensionVersion:this.nativeMessageHandler.getExtensionVersion()})}addRequestSKUs(e){e.extraParameters={...e.extraParameters,[UO]:this.skus}}async acquireToken(e){this.performanceClient.addQueueMeasurement(_.NativeInteractionClientAcquireToken,e.correlationId),this.logger.trace("NativeInteractionClient - acquireToken called.");const n=this.performanceClient.startMeasurement(_.NativeInteractionClientAcquireToken,e.correlationId),r=qn();try{const o=await this.initializeNativeRequest(e);try{const l=await this.acquireTokensFromCache(this.accountId,o);return n.end({success:!0,isNativeBroker:!1,fromCache:!0}),l}catch{this.logger.info("MSAL internal Cache does not contain tokens, proceed to make a native call")}const{...i}=o,s={method:ro.GetToken,request:i},a=await this.nativeMessageHandler.sendMessage(s),c=this.validateNativeResponse(a);return await this.handleNativeResponse(c,o,r).then(l=>(n.end({success:!0,isNativeBroker:!0,requestId:l.requestId}),this.serverTelemetryManager.clearNativeBrokerErrorCode(),l)).catch(l=>{throw n.end({success:!1,errorCode:l.errorCode,subErrorCode:l.subError,isNativeBroker:!0}),l})}catch(o){throw o instanceof Ln&&this.serverTelemetryManager.setNativeBrokerErrorCode(o.errorCode),o}}createSilentCacheRequest(e,n){return{authority:e.authority,correlationId:this.correlationId,scopes:rt.fromString(e.scope).asArray(),account:n,forceRefresh:!1}}async acquireTokensFromCache(e,n){if(!e)throw this.logger.warning("NativeInteractionClient:acquireTokensFromCache - No nativeAccountId provided"),j(Ml);const r=this.browserStorage.getBaseAccountInfo({nativeAccountId:e},n.correlationId);if(!r)throw j(Ml);try{const o=this.createSilentCacheRequest(n,r),i=await this.silentCacheClient.acquireToken(o),s={...r,idTokenClaims:i==null?void 0:i.idTokenClaims,idToken:i==null?void 0:i.idToken};return{...i,account:s}}catch(o){throw o}}async acquireTokenRedirect(e,n){this.logger.trace("NativeInteractionClient - acquireTokenRedirect called.");const{...r}=e;delete r.onRedirectNavigate;const o=await this.initializeNativeRequest(r),i={method:ro.GetToken,request:o};try{const c=await this.nativeMessageHandler.sendMessage(i);this.validateNativeResponse(c)}catch(c){if(c instanceof Ln&&(this.serverTelemetryManager.setNativeBrokerErrorCode(c.errorCode),Uo(c)))throw c}this.browserStorage.setTemporaryCache(Be.NATIVE_REQUEST,JSON.stringify(o),!0);const s={apiId:ze.acquireTokenRedirect,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},a=this.config.auth.navigateToLoginRequestUrl?window.location.href:this.getRedirectUri(e.redirectUri);n.end({success:!0}),await this.navigationClient.navigateExternal(a,s)}async handleRedirectPromise(e,n){if(this.logger.trace("NativeInteractionClient - handleRedirectPromise called."),!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const r=this.browserStorage.getCachedNativeRequest();if(!r)return this.logger.verbose("NativeInteractionClient - handleRedirectPromise called but there is no cached request, returning null."),e&&n&&(e==null||e.addFields({errorCode:"no_cached_request"},n)),null;const{prompt:o,...i}=r;o&&this.logger.verbose("NativeInteractionClient - handleRedirectPromise called and prompt was included in the original request, removing prompt from cached request to prevent second interaction with native broker window."),this.browserStorage.removeItem(this.browserStorage.generateCacheKey(Be.NATIVE_REQUEST));const s={method:ro.GetToken,request:i},a=qn();try{this.logger.verbose("NativeInteractionClient - handleRedirectPromise sending message to native broker.");const c=await this.nativeMessageHandler.sendMessage(s);this.validateNativeResponse(c);const l=this.handleNativeResponse(c,i,a);this.browserStorage.setInteractionInProgress(!1);const u=await l;return this.serverTelemetryManager.clearNativeBrokerErrorCode(),u}catch(c){throw this.browserStorage.setInteractionInProgress(!1),c}}logout(){return this.logger.trace("NativeInteractionClient - logout called."),Promise.reject("Logout not implemented yet")}async handleNativeResponse(e,n,r){var u;this.logger.trace("NativeInteractionClient - handleNativeResponse called.");const o=bo(e.id_token,$n),i=this.createHomeAccountIdentifier(e,o),s=(u=this.browserStorage.getAccountInfoFilteredBy({nativeAccountId:n.accountId},this.correlationId))==null?void 0:u.homeAccountId;if(i!==s&&e.account.id!==n.accountId)throw Wl(Sv);const a=await this.getDiscoveredAuthority({requestAuthority:n.authority}),c=od(this.browserStorage,a,i,$n,this.correlationId,o,e.client_info,void 0,o.tid,void 0,e.account.id,this.logger),l=await this.generateAuthenticationResult(e,n,o,c,a.canonicalAuthority,r);return this.cacheAccount(c),this.cacheNativeTokens(e,n,i,o,e.access_token,l.tenantId,r),l}createHomeAccountIdentifier(e,n){return dt.generateHomeAccountId(e.client_info||P.EMPTY_STRING,hn.Default,this.logger,this.browserCrypto,n)}generateScopes(e,n){return e.scope?rt.fromString(e.scope):rt.fromString(n.scope)}async generatePopAccessToken(e,n){if(n.tokenType===Fe.POP&&n.signPopToken){if(e.shr)return this.logger.trace("handleNativeServerResponse: SHR is enabled in native layer"),e.shr;const r=new di(this.browserCrypto),o={resourceRequestMethod:n.resourceRequestMethod,resourceRequestUri:n.resourceRequestUri,shrClaims:n.shrClaims,shrNonce:n.shrNonce};if(!n.keyId)throw j($u);return r.signPopToken(e.access_token,n.keyId,o)}else return e.access_token}async generateAuthenticationResult(e,n,r,o,i,s){const a=this.addTelemetryFromNativeResponse(e),c=e.scope?rt.fromString(e.scope):rt.fromString(n.scope),l=e.account.properties||{},u=l.UID||r.oid||r.sub||P.EMPTY_STRING,d=l.TenantId||r.tid||P.EMPTY_STRING,h=Ju(o.getAccountInfo(),void 0,r,e.id_token);h.nativeAccountId!==e.account.id&&(h.nativeAccountId=e.account.id);const f=await this.generatePopAccessToken(e,n),p=n.tokenType===Fe.POP?Fe.POP:Fe.BEARER;return{authority:i,uniqueId:u,tenantId:d,scopes:c.asArray(),account:h,idToken:e.id_token,idTokenClaims:r,accessToken:f,fromCache:a?this.isResponseFromCache(a):!1,expiresOn:new Date(Number(s+e.expires_in)*1e3),tokenType:p,correlationId:this.correlationId,state:e.state,fromNativeBroker:!0}}cacheAccount(e){this.browserStorage.setAccount(e,this.correlationId),this.browserStorage.removeAccountContext(e,this.correlationId).catch(n=>{this.logger.error(`Error occurred while removing account context from browser storage. ${n}`)})}cacheNativeTokens(e,n,r,o,i,s,a){const c=sc(r,n.authority,e.id_token||"",n.clientId,o.tid||""),l=n.tokenType===Fe.POP?P.SHR_NONCE_VALIDITY:(typeof e.expires_in=="string"?parseInt(e.expires_in,10):e.expires_in)||0,u=a+l,d=this.generateScopes(e,n),h=ac(r,n.authority,i,n.clientId,o.tid||s,d.printScopes(),u,0,$n,void 0,n.tokenType,void 0,n.keyId),f={idToken:c,accessToken:h};this.nativeStorageManager.saveCacheRecord(f,n.correlationId,n.storeInCache)}addTelemetryFromNativeResponse(e){const n=this.getMATSFromResponse(e);return n?(this.performanceClient.addFields({extensionId:this.nativeMessageHandler.getExtensionId(),extensionVersion:this.nativeMessageHandler.getExtensionVersion(),matsBrokerVersion:n.broker_version,matsAccountJoinOnStart:n.account_join_on_start,matsAccountJoinOnEnd:n.account_join_on_end,matsDeviceJoin:n.device_join,matsPromptBehavior:n.prompt_behavior,matsApiErrorCode:n.api_error_code,matsUiVisible:n.ui_visible,matsSilentCode:n.silent_code,matsSilentBiSubCode:n.silent_bi_sub_code,matsSilentMessage:n.silent_message,matsSilentStatus:n.silent_status,matsHttpStatus:n.http_status,matsHttpEventCount:n.http_event_count},this.correlationId),n):null}validateNativeResponse(e){if(e.hasOwnProperty("access_token")&&e.hasOwnProperty("id_token")&&e.hasOwnProperty("client_info")&&e.hasOwnProperty("account")&&e.hasOwnProperty("scope")&&e.hasOwnProperty("expires_in"))return e;throw Vm(Lu,"Response missing expected properties.")}getMATSFromResponse(e){if(e.properties.MATS)try{return JSON.parse(e.properties.MATS)}catch{this.logger.error("NativeInteractionClient - Error parsing MATS telemetry, returning null instead")}return null}isResponseFromCache(e){return typeof e.is_cached>"u"?(this.logger.verbose("NativeInteractionClient - MATS telemetry does not contain field indicating if response was served from cache. Returning false."),!1):!!e.is_cached}async initializeNativeRequest(e){this.logger.trace("NativeInteractionClient - initializeNativeRequest called");const n=e.authority||this.config.auth.authority;e.account&&await this.getDiscoveredAuthority({requestAuthority:n,requestAzureCloudOptions:e.azureCloudOptions,account:e.account});const r=new Oe(n);r.validateAsUri();const{scopes:o,...i}=e,s=new rt(o||[]);s.appendScopes(mi);const a=()=>{switch(this.apiId){case ze.ssoSilent:case ze.acquireTokenSilent_silentFlow:return this.logger.trace("initializeNativeRequest: silent request sets prompt to none"),gt.NONE}if(!e.prompt){this.logger.trace("initializeNativeRequest: prompt was not provided");return}switch(e.prompt){case gt.NONE:case gt.CONSENT:case gt.LOGIN:return this.logger.trace("initializeNativeRequest: prompt is compatible with native flow"),e.prompt;default:throw this.logger.trace(`initializeNativeRequest: prompt = ${e.prompt} is not compatible with native flow`),te(uv)}},c={...i,accountId:this.accountId,clientId:this.config.auth.clientId,authority:r.urlString,scope:s.printScopes(),redirectUri:this.getRedirectUri(e.redirectUri),prompt:a(),correlationId:this.correlationId,tokenType:e.authenticationScheme,windowTitleSubstring:document.title,extraParameters:{...e.extraQueryParameters,...e.tokenQueryParameters},extendedExpiryToken:!1,keyId:e.popKid};if(c.signPopToken&&e.popKid)throw te(hv);if(this.handleExtraBrokerParams(c),c.extraParameters=c.extraParameters||{},c.extraParameters.telemetry=Ko.MATS_TELEMETRY,e.authenticationScheme===Fe.POP){const l={resourceRequestUri:e.resourceRequestUri,resourceRequestMethod:e.resourceRequestMethod,shrClaims:e.shrClaims,shrNonce:e.shrNonce},u=new di(this.browserCrypto);let d;if(c.keyId)d=this.browserCrypto.base64UrlEncode(JSON.stringify({kid:c.keyId})),c.signPopToken=!1;else{const h=await G(u.generateCnf.bind(u),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(l,this.logger);d=h.reqCnfString,c.keyId=h.kid,c.signPopToken=!0}c.reqCnf=d}return this.addRequestSKUs(c),c}handleExtraBrokerParams(e){var i;const n=e.extraParameters&&e.extraParameters.hasOwnProperty(td)&&e.extraParameters.hasOwnProperty(Bl)&&e.extraParameters.hasOwnProperty(vo);if(!e.embeddedClientId&&!n)return;let r="";const o=e.redirectUri;e.embeddedClientId?(e.redirectUri=this.config.auth.redirectUri,r=e.embeddedClientId):e.extraParameters&&(e.redirectUri=e.extraParameters[Bl],r=e.extraParameters[vo]),e.extraParameters={child_client_id:r,child_redirect_uri:o},(i=this.performanceClient)==null||i.addFields({embeddedClientId:r,embeddedRedirectUri:o},e.correlationId)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Hn{constructor(e,n,r,o){this.logger=e,this.handshakeTimeoutMs=n,this.extensionId=o,this.resolvers=new Map,this.handshakeResolvers=new Map,this.messageChannel=new MessageChannel,this.windowListener=this.onWindowMessage.bind(this),this.performanceClient=r,this.handshakeEvent=r.startMeasurement(_.NativeMessageHandlerHandshake)}async sendMessage(e){this.logger.trace("NativeMessageHandler - sendMessage called.");const n={channel:Ko.CHANNEL_ID,extensionId:this.extensionId,responseId:jn(),body:e};return this.logger.trace("NativeMessageHandler - Sending request to browser extension"),this.logger.tracePii(`NativeMessageHandler - Sending request to browser extension: ${JSON.stringify(n)}`),this.messageChannel.port1.postMessage(n),new Promise((r,o)=>{this.resolvers.set(n.responseId,{resolve:r,reject:o})})}static async createProvider(e,n,r){e.trace("NativeMessageHandler - createProvider called.");try{const o=new Hn(e,n,r,Ko.PREFERRED_EXTENSION_ID);return await o.sendHandshakeRequest(),o}catch{const i=new Hn(e,n,r);return await i.sendHandshakeRequest(),i}}async sendHandshakeRequest(){this.logger.trace("NativeMessageHandler - sendHandshakeRequest called."),window.addEventListener("message",this.windowListener,!1);const e={channel:Ko.CHANNEL_ID,extensionId:this.extensionId,responseId:jn(),body:{method:ro.HandshakeRequest}};return this.handshakeEvent.add({extensionId:this.extensionId,extensionHandshakeTimeoutMs:this.handshakeTimeoutMs}),this.messageChannel.port1.onmessage=n=>{this.onChannelMessage(n)},window.postMessage(e,window.origin,[this.messageChannel.port2]),new Promise((n,r)=>{this.handshakeResolvers.set(e.responseId,{resolve:n,reject:r}),this.timeoutId=window.setTimeout(()=>{window.removeEventListener("message",this.windowListener,!1),this.messageChannel.port1.close(),this.messageChannel.port2.close(),this.handshakeEvent.end({extensionHandshakeTimedOut:!0,success:!1}),r(te(av)),this.handshakeResolvers.delete(e.responseId)},this.handshakeTimeoutMs)})}onWindowMessage(e){if(this.logger.trace("NativeMessageHandler - onWindowMessage called"),e.source!==window)return;const n=e.data;if(!(!n.channel||n.channel!==Ko.CHANNEL_ID)&&!(n.extensionId&&n.extensionId!==this.extensionId)&&n.body.method===ro.HandshakeRequest){const r=this.handshakeResolvers.get(n.responseId);if(!r){this.logger.trace(`NativeMessageHandler.onWindowMessage - resolver can't be found for request ${n.responseId}`);return}this.logger.verbose(n.extensionId?`Extension with id: ${n.extensionId} not installed`:"No extension installed"),clearTimeout(this.timeoutId),this.messageChannel.port1.close(),this.messageChannel.port2.close(),window.removeEventListener("message",this.windowListener,!1),this.handshakeEvent.end({success:!1,extensionInstalled:!1}),r.reject(te(cv))}}onChannelMessage(e){this.logger.trace("NativeMessageHandler - onChannelMessage called.");const n=e.data,r=this.resolvers.get(n.responseId),o=this.handshakeResolvers.get(n.responseId);try{const i=n.body.method;if(i===ro.Response){if(!r)return;const s=n.body.response;if(this.logger.trace("NativeMessageHandler - Received response from browser extension"),this.logger.tracePii(`NativeMessageHandler - Received response from browser extension: ${JSON.stringify(s)}`),s.status!=="Success")r.reject(Wl(s.code,s.description,s.ext));else if(s.result)s.result.code&&s.result.description?r.reject(Wl(s.result.code,s.result.description,s.result.ext)):r.resolve(s.result);else throw Vm(Lu,"Event does not contain result.");this.resolvers.delete(n.responseId)}else if(i===ro.HandshakeResponse){if(!o){this.logger.trace(`NativeMessageHandler.onChannelMessage - resolver can't be found for request ${n.responseId}`);return}clearTimeout(this.timeoutId),window.removeEventListener("message",this.windowListener,!1),this.extensionId=n.extensionId,this.extensionVersion=n.body.version,this.logger.verbose(`NativeMessageHandler - Received HandshakeResponse from extension: ${this.extensionId}`),this.handshakeEvent.end({extensionInstalled:!0,success:!0}),o.resolve(),this.handshakeResolvers.delete(n.responseId)}}catch(i){this.logger.error("Error parsing response from WAM Extension"),this.logger.errorPii(`Error parsing response from WAM Extension: ${i}`),this.logger.errorPii(`Unable to parse ${e}`),r?r.reject(i):o&&o.reject(i)}}getExtensionId(){return this.extensionId}getExtensionVersion(){return this.extensionVersion}static isNativeAvailable(e,n,r,o){if(n.trace("isNativeAvailable called"),!e.system.allowNativeBroker)return n.trace("isNativeAvailable: allowNativeBroker is not enabled, returning false"),!1;if(!r)return n.trace("isNativeAvailable: WAM extension provider is not initialized, returning false"),!1;if(o)switch(o){case Fe.BEARER:case Fe.POP:return n.trace("isNativeAvailable: authenticationScheme is supported, returning true"),!0;default:return n.trace("isNativeAvailable: authenticationScheme is not supported, returning false"),!1}return!0}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Ad{constructor(e,n,r,o,i){this.authModule=e,this.browserStorage=n,this.authCodeRequest=r,this.logger=o,this.performanceClient=i}async handleCodeResponse(e,n){this.performanceClient.addQueueMeasurement(_.HandleCodeResponse,n.correlationId);let r;try{r=this.authModule.handleFragmentResponse(e,n.state)}catch(o){throw o instanceof $r&&o.subError===wo?te(wo):o}return G(this.handleCodeResponseFromServer.bind(this),_.HandleCodeResponseFromServer,this.logger,this.performanceClient,n.correlationId)(r,n)}async handleCodeResponseFromServer(e,n,r=!0){if(this.performanceClient.addQueueMeasurement(_.HandleCodeResponseFromServer,n.correlationId),this.logger.trace("InteractionHandler.handleCodeResponseFromServer called"),this.authCodeRequest.code=e.code,e.cloud_instance_host_name&&await G(this.authModule.updateAuthority.bind(this.authModule),_.UpdateTokenEndpointAuthority,this.logger,this.performanceClient,n.correlationId)(e.cloud_instance_host_name,n.correlationId),r&&(e.nonce=n.nonce||void 0),e.state=n.state,e.client_info)this.authCodeRequest.clientInfo=e.client_info;else{const i=this.createCcsCredentials(n);i&&(this.authCodeRequest.ccsCredential=i)}return await G(this.authModule.acquireToken.bind(this.authModule),_.AuthClientAcquireToken,this.logger,this.performanceClient,n.correlationId)(this.authCodeRequest,e)}createCcsCredentials(e){return e.account?{credential:e.account.homeAccountId,type:Jt.HOME_ACCOUNT_ID}:e.loginHint?{credential:e.loginHint,type:Jt.UPN}:null}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function Rv(t,e,n){const r=ma(t);if(!r)throw Sy(t)?(n.error(`A ${e} is present in the iframe but it does not contain known properties. It's likely that the ${e} has been replaced by code running on the redirectUri page.`),n.errorPii(`The ${e} detected is: ${t}`),te(Ky)):(n.error(`The request has returned to the redirectUri but a ${e} is not present. It's likely that the ${e} has been removed or the page has been redirected by code running on the redirectUri page.`),te(Fy));return r}function CP(t,e,n){if(!t.state)throw te(cd);const r=bv(e,t.state);if(!r)throw te($y);if(r.interactionType!==n)throw te(qy)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class wP extends yi{constructor(e,n,r,o,i,s,a,c,l,u){super(e,n,r,o,i,s,a,l,u),this.unloadWindow=this.unloadWindow.bind(this),this.nativeStorage=c}acquireToken(e){try{const r={popupName:this.generatePopupName(e.scopes||mi,e.authority||this.config.auth.authority),popupWindowAttributes:e.popupWindowAttributes||{},popupWindowParent:e.popupWindowParent??window};return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true, acquiring token"),this.acquireTokenPopupAsync(e,r)):(this.logger.verbose("asyncPopup set to false, opening popup before acquiring token"),r.popup=this.openSizedPopup("about:blank",r),this.acquireTokenPopupAsync(e,r))}catch(n){return Promise.reject(n)}}logout(e){try{this.logger.verbose("logoutPopup called");const n=this.initializeLogoutRequest(e),r={popupName:this.generateLogoutPopupName(n),popupWindowAttributes:(e==null?void 0:e.popupWindowAttributes)||{},popupWindowParent:(e==null?void 0:e.popupWindowParent)??window},o=e&&e.authority,i=e&&e.mainWindowRedirectUri;return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true"),this.logoutPopupAsync(n,r,o,i)):(this.logger.verbose("asyncPopup set to false, opening popup"),r.popup=this.openSizedPopup("about:blank",r),this.logoutPopupAsync(n,r,o,i))}catch(n){return Promise.reject(n)}}async acquireTokenPopupAsync(e,n){var i;this.logger.verbose("acquireTokenPopupAsync called");const r=this.initializeServerTelemetryManager(ze.acquireTokenPopup),o=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,this.correlationId)(e,ce.Popup);Ev(o.authority);try{const s=await G(this.initializeAuthorizationCodeRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,this.correlationId)(o),a=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:o.authority,requestAzureCloudOptions:o.azureCloudOptions,requestExtraQueryParameters:o.extraQueryParameters,account:o.account}),c=Hn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme);let l;c&&(l=this.performanceClient.startMeasurement(_.FetchAccountIdWithNativeBroker,e.correlationId));const u=await a.getAuthCodeUrl({...o,nativeBroker:c}),d=new Ad(a,this.browserStorage,s,this.logger,this.performanceClient),h=this.initiateAuthRequest(u,n);this.eventHandler.emitEvent(me.POPUP_OPENED,ce.Popup,{popupWindow:h},null);const f=await this.monitorPopupForHash(h,n.popupWindowParent),p=_o(Rv,_.DeserializeResponse,this.logger,this.performanceClient,this.correlationId)(f,this.config.auth.OIDCOptions.serverResponseType,this.logger);if(Dn.removeThrottle(this.browserStorage,this.config.auth.clientId,s),p.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),l&&l.end({success:!0,isNativeBroker:!0}),!this.nativeMessageHandler)throw te(As);const m=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,p.accountId,this.nativeStorage,o.correlationId),{userRequestState:C}=gn.parseRequestState(this.browserCrypto,o.state);return await m.acquireToken({...o,state:C,prompt:void 0})}return await d.handleCodeResponse(p,o)}catch(s){throw(i=n.popup)==null||i.close(),s instanceof We&&(s.setCorrelationId(this.correlationId),r.cacheFailedRequest(s)),s}}async logoutPopupAsync(e,n,r,o){var s,a,c,l;this.logger.verbose("logoutPopupAsync called"),this.eventHandler.emitEvent(me.LOGOUT_START,ce.Popup,e);const i=this.initializeServerTelemetryManager(ze.logoutPopup);try{await this.clearCacheOnLogout(e.account);const u=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:i,requestAuthority:r,account:e.account||void 0});try{u.authority.endSessionEndpoint}catch{if((s=e.account)!=null&&s.homeAccountId&&e.postLogoutRedirectUri&&u.authority.protocolMode===ar.OIDC){if(this.browserStorage.removeAccount((a=e.account)==null?void 0:a.homeAccountId,this.correlationId),this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Popup,e),o){const f={apiId:ze.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},p=Oe.getAbsoluteUrl(o,ir());await this.navigationClient.navigateInternal(p,f)}(c=n.popup)==null||c.close();return}}const d=u.getLogoutUri(e);this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Popup,e);const h=this.openPopup(d,n);if(this.eventHandler.emitEvent(me.POPUP_OPENED,ce.Popup,{popupWindow:h},null),await this.monitorPopupForHash(h,n.popupWindowParent).catch(()=>{}),o){const f={apiId:ze.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},p=Oe.getAbsoluteUrl(o,ir());this.logger.verbose("Redirecting main window to url specified in the request"),this.logger.verbosePii(`Redirecting main window to: ${p}`),await this.navigationClient.navigateInternal(p,f)}else this.logger.verbose("No main window navigation requested")}catch(u){throw(l=n.popup)==null||l.close(),u instanceof We&&(u.setCorrelationId(this.correlationId),i.cacheFailedRequest(u)),this.browserStorage.setInteractionInProgress(!1),this.eventHandler.emitEvent(me.LOGOUT_FAILURE,ce.Popup,null,u),this.eventHandler.emitEvent(me.LOGOUT_END,ce.Popup),u}this.eventHandler.emitEvent(me.LOGOUT_END,ce.Popup)}initiateAuthRequest(e,n){if(e)return this.logger.infoPii(`Navigate to: ${e}`),this.openPopup(e,n);throw this.logger.error("Navigate url is empty"),te(hc)}monitorPopupForHash(e,n){return new Promise((r,o)=>{this.logger.verbose("PopupHandler.monitorPopupForHash - polling started");const i=setInterval(()=>{if(e.closed){this.logger.error("PopupHandler.monitorPopupForHash - window closed"),clearInterval(i),o(te(wo));return}let s="";try{s=e.location.href}catch{}if(!s||s==="about:blank")return;clearInterval(i);let a="";const c=this.config.auth.OIDCOptions.serverResponseType;e&&(c===ws.QUERY?a=e.location.search:a=e.location.hash),this.logger.verbose("PopupHandler.monitorPopupForHash - popup window is on same origin as caller"),r(a)},this.config.system.pollIntervalMilliseconds)}).finally(()=>{this.cleanPopup(e,n)})}openPopup(e,n){try{let r;if(n.popup?(r=n.popup,this.logger.verbosePii(`Navigating popup window to: ${e}`),r.location.assign(e)):typeof n.popup>"u"&&(this.logger.verbosePii(`Opening popup window to: ${e}`),r=this.openSizedPopup(e,n)),!r)throw te(Gy);return r.focus&&r.focus(),this.currentWindow=r,n.popupWindowParent.addEventListener("beforeunload",this.unloadWindow),r}catch(r){throw this.logger.error("error opening popup "+r.message),this.browserStorage.setInteractionInProgress(!1),te(Vy)}}openSizedPopup(e,{popupName:n,popupWindowAttributes:r,popupWindowParent:o}){var f,p,g,m;const i=o.screenLeft?o.screenLeft:o.screenX,s=o.screenTop?o.screenTop:o.screenY,a=o.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,c=o.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;let l=(f=r.popupSize)==null?void 0:f.width,u=(p=r.popupSize)==null?void 0:p.height,d=(g=r.popupPosition)==null?void 0:g.top,h=(m=r.popupPosition)==null?void 0:m.left;return(!l||l<0||l>a)&&(this.logger.verbose("Default popup window width used. Window width not configured or invalid."),l=Qt.POPUP_WIDTH),(!u||u<0||u>c)&&(this.logger.verbose("Default popup window height used. Window height not configured or invalid."),u=Qt.POPUP_HEIGHT),(!d||d<0||d>c)&&(this.logger.verbose("Default popup window top position used. Window top not configured or invalid."),d=Math.max(0,c/2-Qt.POPUP_HEIGHT/2+s)),(!h||h<0||h>a)&&(this.logger.verbose("Default popup window left position used. Window left not configured or invalid."),h=Math.max(0,a/2-Qt.POPUP_WIDTH/2+i)),o.open(e,n,`width=${l}, height=${u}, top=${d}, left=${h}, scrollbars=yes`)}unloadWindow(e){this.browserStorage.cleanRequestByInteractionType(ce.Popup),this.currentWindow&&this.currentWindow.close(),e.preventDefault()}cleanPopup(e,n){e.close(),n.removeEventListener("beforeunload",this.unloadWindow),this.browserStorage.setInteractionInProgress(!1)}generatePopupName(e,n){return`${Qt.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${e.join("-")}.${n}.${this.correlationId}`}generateLogoutPopupName(e){const n=e.account&&e.account.homeAccountId;return`${Qt.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${n}.${this.correlationId}`}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Gf{constructor(e,n,r,o,i){this.authModule=e,this.browserStorage=n,this.authCodeRequest=r,this.logger=o,this.performanceClient=i}async initiateAuthRequest(e,n){if(this.logger.verbose("RedirectHandler.initiateAuthRequest called"),e){n.redirectStartPage&&(this.logger.verbose("RedirectHandler.initiateAuthRequest: redirectStartPage set, caching start page"),this.browserStorage.setTemporaryCache(Be.ORIGIN_URI,n.redirectStartPage,!0)),this.browserStorage.setTemporaryCache(Be.CORRELATION_ID,this.authCodeRequest.correlationId,!0),this.browserStorage.cacheCodeRequest(this.authCodeRequest),this.logger.infoPii(`RedirectHandler.initiateAuthRequest: Navigate to: ${e}`);const r={apiId:ze.acquireTokenRedirect,timeout:n.redirectTimeout,noHistory:!1};if(typeof n.onRedirectNavigate=="function")if(this.logger.verbose("RedirectHandler.initiateAuthRequest: Invoking onRedirectNavigate callback"),n.onRedirectNavigate(e)!==!1){this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate did not return false, navigating"),await n.navigationClient.navigateExternal(e,r);return}else{this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate returned false, stopping navigation");return}else{this.logger.verbose("RedirectHandler.initiateAuthRequest: Navigating window to navigate url"),await n.navigationClient.navigateExternal(e,r);return}}else throw this.logger.info("RedirectHandler.initiateAuthRequest: Navigate url is empty"),te(hc)}async handleCodeResponse(e,n){this.logger.verbose("RedirectHandler.handleCodeResponse called"),this.browserStorage.setInteractionInProgress(!1);const r=this.browserStorage.generateStateKey(n),o=this.browserStorage.getTemporaryCache(r);if(!o)throw j(ha,"Cached State");let i;try{i=this.authModule.handleFragmentResponse(e,o)}catch(l){throw l instanceof $r&&l.subError===wo?te(wo):l}const s=this.browserStorage.generateNonceKey(o),a=this.browserStorage.getTemporaryCache(s);if(this.authCodeRequest.code=i.code,i.cloud_instance_host_name&&await G(this.authModule.updateAuthority.bind(this.authModule),_.UpdateTokenEndpointAuthority,this.logger,this.performanceClient,this.authCodeRequest.correlationId)(i.cloud_instance_host_name,this.authCodeRequest.correlationId),i.nonce=a||void 0,i.state=o,i.client_info)this.authCodeRequest.clientInfo=i.client_info;else{const l=this.checkCcsCredentials();l&&(this.authCodeRequest.ccsCredential=l)}const c=await this.authModule.acquireToken(this.authCodeRequest,i);return this.browserStorage.cleanRequestByState(n),c}checkCcsCredentials(){const e=this.browserStorage.getTemporaryCache(Be.CCS_CREDENTIAL,!0);if(e)try{return JSON.parse(e)}catch{this.authModule.logger.error("Cache credential could not be parsed"),this.authModule.logger.errorPii(`Cache credential could not be parsed: ${e}`)}return null}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function AP(){if(typeof window>"u"||typeof window.performance>"u"||typeof window.performance.getEntriesByType!="function")return;const t=window.performance.getEntriesByType("navigation"),e=t.length?t[0]:void 0;return e==null?void 0:e.type}class TP extends yi{constructor(e,n,r,o,i,s,a,c,l,u){super(e,n,r,o,i,s,a,l,u),this.nativeStorage=c}async acquireToken(e){const n=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,this.correlationId)(e,ce.Redirect);this.browserStorage.updateCacheEntries(n.state,n.nonce,n.authority,n.loginHint||"",n.account||null);const r=this.initializeServerTelemetryManager(ze.acquireTokenRedirect),o=i=>{i.persisted&&(this.logger.verbose("Page was restored from back/forward cache. Clearing temporary cache."),this.browserStorage.cleanRequestByState(n.state),this.eventHandler.emitEvent(me.RESTORE_FROM_BFCACHE,ce.Redirect))};try{const i=await G(this.initializeAuthorizationCodeRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,this.correlationId)(n),s=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:n.authority,requestAzureCloudOptions:n.azureCloudOptions,requestExtraQueryParameters:n.extraQueryParameters,account:n.account}),a=new Gf(s,this.browserStorage,i,this.logger,this.performanceClient),c=await s.getAuthCodeUrl({...n,nativeBroker:Hn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme)}),l=this.getRedirectStartPage(e.redirectStartPage);return this.logger.verbosePii(`Redirect start page: ${l}`),window.addEventListener("pageshow",o),await a.initiateAuthRequest(c,{navigationClient:this.navigationClient,redirectTimeout:this.config.system.redirectNavigationTimeout,redirectStartPage:l,onRedirectNavigate:e.onRedirectNavigate||this.config.auth.onRedirectNavigate})}catch(i){throw i instanceof We&&(i.setCorrelationId(this.correlationId),r.cacheFailedRequest(i)),window.removeEventListener("pageshow",o),this.browserStorage.cleanRequestByState(n.state),i}}async handleRedirectPromise(e="",n){const r=this.initializeServerTelemetryManager(ze.handleRedirectPromise);try{if(!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const[o,i]=this.getRedirectResponse(e||"");if(!o)return this.logger.info("handleRedirectPromise did not detect a response as a result of a redirect. Cleaning temporary cache."),this.browserStorage.cleanRequestByInteractionType(ce.Redirect),AP()!=="back_forward"?n.event.errorCode="no_server_response":this.logger.verbose("Back navigation event detected. Muting no_server_response error"),null;const s=this.browserStorage.getTemporaryCache(Be.ORIGIN_URI,!0)||P.EMPTY_STRING,a=Oe.removeHashFromUrl(s),c=Oe.removeHashFromUrl(window.location.href);if(a===c&&this.config.auth.navigateToLoginRequestUrl)return this.logger.verbose("Current page is loginRequestUrl, handling response"),s.indexOf("#")>-1&&Ok(s),await this.handleResponse(o,r);if(this.config.auth.navigateToLoginRequestUrl){if(!yd()||this.config.system.allowRedirectInIframe){this.browserStorage.setTemporaryCache(Be.URL_HASH,i,!0);const l={apiId:ze.handleRedirectPromise,timeout:this.config.system.redirectNavigationTimeout,noHistory:!0};let u=!0;if(!s||s==="null"){const d=Pk();this.browserStorage.setTemporaryCache(Be.ORIGIN_URI,d,!0),this.logger.warning("Unable to get valid login request url from cache, redirecting to home page"),u=await this.navigationClient.navigateInternal(d,l)}else this.logger.verbose(`Navigating to loginRequestUrl: ${s}`),u=await this.navigationClient.navigateInternal(s,l);if(!u)return await this.handleResponse(o,r)}}else return this.logger.verbose("NavigateToLoginRequestUrl set to false, handling response"),await this.handleResponse(o,r);return null}catch(o){throw o instanceof We&&(o.setCorrelationId(this.correlationId),r.cacheFailedRequest(o)),this.browserStorage.cleanRequestByInteractionType(ce.Redirect),o}}getRedirectResponse(e){this.logger.verbose("getRedirectResponseHash called");let n=e;n||(this.config.auth.OIDCOptions.serverResponseType===ws.QUERY?n=window.location.search:n=window.location.hash);let r=ma(n);if(r){try{CP(r,this.browserCrypto,ce.Redirect)}catch(i){return i instanceof We&&this.logger.error(`Interaction type validation failed due to ${i.errorCode}: ${i.errorMessage}`),[null,""]}return Rk(window),this.logger.verbose("Hash contains known properties, returning response hash"),[r,n]}const o=this.browserStorage.getTemporaryCache(Be.URL_HASH,!0);return this.browserStorage.removeItem(this.browserStorage.generateCacheKey(Be.URL_HASH)),o&&(r=ma(o),r)?(this.logger.verbose("Hash does not contain known properties, returning cached hash"),[r,o]):[null,""]}async handleResponse(e,n){const r=e.state;if(!r)throw te(cd);const o=this.browserStorage.getCachedRequest(r);if(this.logger.verbose("handleResponse called, retrieved cached request"),e.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw te(As);const c=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,e.accountId,this.nativeStorage,o.correlationId),{userRequestState:l}=gn.parseRequestState(this.browserCrypto,r);return c.acquireToken({...o,state:l,prompt:void 0}).finally(()=>{this.browserStorage.cleanRequestByState(r)})}const i=this.browserStorage.getCachedAuthority(r);if(!i)throw te(ld);const s=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:n,requestAuthority:i});return Dn.removeThrottle(this.browserStorage,this.config.auth.clientId,o),new Gf(s,this.browserStorage,o,this.logger,this.performanceClient).handleCodeResponse(e,r)}async logout(e){var o,i;this.logger.verbose("logoutRedirect called");const n=this.initializeLogoutRequest(e),r=this.initializeServerTelemetryManager(ze.logout);try{this.eventHandler.emitEvent(me.LOGOUT_START,ce.Redirect,e),await this.clearCacheOnLogout(n.account);const s={apiId:ze.logout,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},a=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:e&&e.authority,requestExtraQueryParameters:e==null?void 0:e.extraQueryParameters,account:e&&e.account||void 0});if(a.authority.protocolMode===ar.OIDC)try{a.authority.endSessionEndpoint}catch{if((o=n.account)!=null&&o.homeAccountId){this.browserStorage.removeAccount((i=n.account)==null?void 0:i.homeAccountId,this.correlationId),this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Redirect,n);return}}const c=a.getLogoutUri(n);if(this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Redirect,n),e&&typeof e.onRedirectNavigate=="function")if(e.onRedirectNavigate(c)!==!1){this.logger.verbose("Logout onRedirectNavigate did not return false, navigating"),this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),await this.navigationClient.navigateExternal(c,s);return}else this.browserStorage.setInteractionInProgress(!1),this.logger.verbose("Logout onRedirectNavigate returned false, stopping navigation");else{this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),await this.navigationClient.navigateExternal(c,s);return}}catch(s){throw s instanceof We&&(s.setCorrelationId(this.correlationId),r.cacheFailedRequest(s)),this.eventHandler.emitEvent(me.LOGOUT_FAILURE,ce.Redirect,null,s),this.eventHandler.emitEvent(me.LOGOUT_END,ce.Redirect),s}this.eventHandler.emitEvent(me.LOGOUT_END,ce.Redirect)}getRedirectStartPage(e){const n=e||window.location.href;return Oe.getAbsoluteUrl(n,ir())}}/*! @azure/msal-browser v3.30.0 2025-08-05 */async function EP(t,e,n,r,o){if(e.addQueueMeasurement(_.SilentHandlerInitiateAuthRequest,r),!t)throw n.info("Navigate url is empty"),te(hc);return o?G(_P,_.SilentHandlerLoadFrame,n,e,r)(t,o,e,r):_o(SP,_.SilentHandlerLoadFrameSync,n,e,r)(t)}async function bP(t,e,n,r,o,i,s){return r.addQueueMeasurement(_.SilentHandlerMonitorIframeForHash,i),new Promise((a,c)=>{e{window.clearInterval(u),c(te(zy))},e),u=window.setInterval(()=>{let d="";const h=t.contentWindow;try{d=h?h.location.href:""}catch{}if(!d||d==="about:blank")return;let f="";h&&(s===ws.QUERY?f=h.location.search:f=h.location.hash),window.clearTimeout(l),window.clearInterval(u),a(f)},n)}).finally(()=>{_o(IP,_.RemoveHiddenIframe,o,r,i)(t)})}function _P(t,e,n,r){return n.addQueueMeasurement(_.SilentHandlerLoadFrame,r),new Promise((o,i)=>{const s=Ov();window.setTimeout(()=>{if(!s){i("Unable to load iframe");return}s.src=t,o(s)},e)})}function SP(t){const e=Ov();return e.src=t,e}function Ov(){const t=document.createElement("iframe");return t.className="msalSilentIframe",t.style.visibility="hidden",t.style.position="absolute",t.style.width=t.style.height="0",t.style.border="0",t.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms"),document.body.appendChild(t),t}function IP(t){document.body===t.parentNode&&document.body.removeChild(t)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class RP extends yi{constructor(e,n,r,o,i,s,a,c,l,u,d){super(e,n,r,o,i,s,c,u,d),this.apiId=a,this.nativeStorage=l}async acquireToken(e){this.performanceClient.addQueueMeasurement(_.SilentIframeClientAcquireToken,e.correlationId),!e.loginHint&&!e.sid&&(!e.account||!e.account.username)&&this.logger.warning("No user hint provided. The authorization server may need more information to complete this request.");const n={...e};n.prompt?n.prompt!==gt.NONE&&n.prompt!==gt.NO_SESSION&&(this.logger.warning(`SilentIframeClient. Replacing invalid prompt ${n.prompt} with ${gt.NONE}`),n.prompt=gt.NONE):n.prompt=gt.NONE;const r=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(n,ce.Silent);Ev(r.authority);const o=this.initializeServerTelemetryManager(this.apiId);let i;try{return i=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:o,requestAuthority:r.authority,requestAzureCloudOptions:r.azureCloudOptions,requestExtraQueryParameters:r.extraQueryParameters,account:r.account}),await G(this.silentTokenHelper.bind(this),_.SilentIframeClientTokenHelper,this.logger,this.performanceClient,e.correlationId)(i,r)}catch(s){if(s instanceof We&&(s.setCorrelationId(this.correlationId),o.cacheFailedRequest(s)),!i||!(s instanceof We)||s.errorCode!==Qt.INVALID_GRANT_ERROR)throw s;this.performanceClient.addFields({retryError:s.errorCode},this.correlationId);const a=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(n,ce.Silent);return await G(this.silentTokenHelper.bind(this),_.SilentIframeClientTokenHelper,this.logger,this.performanceClient,this.correlationId)(i,a)}}logout(){return Promise.reject(te(fc))}async silentTokenHelper(e,n){const r=n.correlationId;this.performanceClient.addQueueMeasurement(_.SilentIframeClientTokenHelper,r);const o=await G(this.initializeAuthorizationCodeRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,r)(n),i=await G(e.getAuthCodeUrl.bind(e),_.GetAuthCodeUrl,this.logger,this.performanceClient,r)({...n,nativeBroker:Hn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,n.authenticationScheme)}),s=new Ad(e,this.browserStorage,o,this.logger,this.performanceClient),a=await G(EP,_.SilentHandlerInitiateAuthRequest,this.logger,this.performanceClient,r)(i,this.performanceClient,this.logger,r,this.config.system.navigateFrameWait),c=this.config.auth.OIDCOptions.serverResponseType,l=await G(bP,_.SilentHandlerMonitorIframeForHash,this.logger,this.performanceClient,r)(a,this.config.system.iframeHashTimeout,this.config.system.pollIntervalMilliseconds,this.performanceClient,this.logger,r,c),u=_o(Rv,_.DeserializeResponse,this.logger,this.performanceClient,this.correlationId)(l,c,this.logger);if(u.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw te(As);const d=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.apiId,this.performanceClient,this.nativeMessageHandler,u.accountId,this.browserStorage,r),{userRequestState:h}=gn.parseRequestState(this.browserCrypto,n.state);return G(d.acquireToken.bind(d),_.NativeInteractionClientAcquireToken,this.logger,this.performanceClient,r)({...n,state:h,prompt:n.prompt||gt.NONE})}return G(s.handleCodeResponse.bind(s),_.HandleCodeResponse,this.logger,this.performanceClient,r)(u,n)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class OP extends yi{async acquireToken(e){this.performanceClient.addQueueMeasurement(_.SilentRefreshClientAcquireToken,e.correlationId);const n=await G(wd,_.InitializeBaseRequest,this.logger,this.performanceClient,e.correlationId)(e,this.config,this.performanceClient,this.logger),r={...e,...n};e.redirectUri&&(r.redirectUri=this.getRedirectUri(e.redirectUri));const o=this.initializeServerTelemetryManager(ze.acquireTokenSilent_silentFlow),i=await this.createRefreshTokenClient({serverTelemetryManager:o,authorityUrl:r.authority,azureCloudOptions:r.azureCloudOptions,account:r.account});return G(i.acquireTokenByRefreshToken.bind(i),_.RefreshTokenClientAcquireTokenByRefreshToken,this.logger,this.performanceClient,e.correlationId)(r).catch(s=>{throw s.setCorrelationId(this.correlationId),o.cacheFailedRequest(s),s})}logout(){return Promise.reject(te(fc))}async createRefreshTokenClient(e){const n=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:e.serverTelemetryManager,requestAuthority:e.authorityUrl,requestAzureCloudOptions:e.azureCloudOptions,requestExtraQueryParameters:e.extraQueryParameters,account:e.account});return new Kl(n,this.performanceClient)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class kP{constructor(e,n,r,o){this.isBrowserEnvironment=typeof window<"u",this.config=e,this.storage=n,this.logger=r,this.cryptoObj=o}loadExternalTokens(e,n,r){if(!this.isBrowserEnvironment)throw te(pc);const o=e.correlationId||jn(),i=n.id_token?bo(n.id_token,$n):void 0,s={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},a=e.authority?new bt(bt.generateAuthority(e.authority,e.azureCloudOptions),this.config.system.networkClient,this.storage,s,this.logger,e.correlationId||jn()):void 0,c=this.loadAccount(e,r.clientInfo||n.client_info||"",o,i,a),l=this.loadIdToken(n,c.homeAccountId,c.environment,c.realm,o),u=this.loadAccessToken(e,n,c.homeAccountId,c.environment,c.realm,r,o),d=this.loadRefreshToken(n,c.homeAccountId,c.environment,o);return this.generateAuthenticationResult(e,{account:c,idToken:l,accessToken:u,refreshToken:d},i,a)}loadAccount(e,n,r,o,i){if(this.logger.verbose("TokenCache - loading account"),e.account){const l=dt.createFromAccountInfo(e.account);return this.storage.setAccount(l,r),l}else if(!i||!n&&!o)throw this.logger.error("TokenCache - if an account is not provided on the request, authority and either clientInfo or idToken must be provided instead."),te(nv);const s=dt.generateHomeAccountId(n,i.authorityType,this.logger,this.cryptoObj,o),a=o==null?void 0:o.tid,c=od(this.storage,i,s,$n,r,o,n,i.hostnameAndPort,a,void 0,void 0,this.logger);return this.storage.setAccount(c,r),c}loadIdToken(e,n,r,o,i){if(!e.id_token)return this.logger.verbose("TokenCache - no id token found in response"),null;this.logger.verbose("TokenCache - loading id token");const s=sc(n,r,e.id_token,this.config.auth.clientId,o);return this.storage.setIdTokenCredential(s,i),s}loadAccessToken(e,n,r,o,i,s,a){if(n.access_token)if(n.expires_in){if(!n.scope&&(!e.scopes||!e.scopes.length))return this.logger.error("TokenCache - scopes not specified in the request or response. Cannot add token to the cache."),null}else return this.logger.error("TokenCache - no expiration set on the access token. Cannot add it to the cache."),null;else return this.logger.verbose("TokenCache - no access token found in response"),null;this.logger.verbose("TokenCache - loading access token");const c=n.scope?rt.fromString(n.scope):new rt(e.scopes),l=s.expiresOn||n.expires_in+new Date().getTime()/1e3,u=s.extendedExpiresOn||(n.ext_expires_in||n.expires_in)+new Date().getTime()/1e3,d=ac(r,o,n.access_token,this.config.auth.clientId,i,c.printScopes(),l,u,$n);return this.storage.setAccessTokenCredential(d,a),d}loadRefreshToken(e,n,r,o){if(!e.refresh_token)return this.logger.verbose("TokenCache - no refresh token found in response"),null;this.logger.verbose("TokenCache - loading refresh token");const i=uy(n,r,e.refresh_token,this.config.auth.clientId,e.foci,void 0,e.refresh_token_expires_in);return this.storage.setRefreshTokenCredential(i,o),i}generateAuthenticationResult(e,n,r,o){var u,d,h;let i="",s=[],a=null,c;n!=null&&n.accessToken&&(i=n.accessToken.secret,s=rt.fromString(n.accessToken.target).asArray(),a=new Date(Number(n.accessToken.expiresOn)*1e3),c=new Date(Number(n.accessToken.extendedExpiresOn)*1e3));const l=n.account;return{authority:o?o.canonicalAuthority:"",uniqueId:n.account.localAccountId,tenantId:n.account.realm,scopes:s,account:l.getAccountInfo(),idToken:((u=n.idToken)==null?void 0:u.secret)||"",idTokenClaims:r||{},accessToken:i,fromCache:!0,expiresOn:a,correlationId:e.correlationId||"",requestId:"",extExpiresOn:c,familyId:((d=n.refreshToken)==null?void 0:d.familyId)||"",tokenType:((h=n==null?void 0:n.accessToken)==null?void 0:h.tokenType)||"",state:e.state||"",cloudGraphHostName:l.cloudGraphHostName||"",msGraphHost:l.msGraphHost||"",fromNativeBroker:!1}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class PP extends Ly{constructor(e){super(e),this.includeRedirectUri=!1}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class NP extends yi{constructor(e,n,r,o,i,s,a,c,l,u){super(e,n,r,o,i,s,c,l,u),this.apiId=a}async acquireToken(e){if(!e.code)throw te(rv);const n=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(e,ce.Silent),r=this.initializeServerTelemetryManager(this.apiId);try{const o={...n,code:e.code},i=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:r,requestAuthority:n.authority,requestAzureCloudOptions:n.azureCloudOptions,requestExtraQueryParameters:n.extraQueryParameters,account:n.account}),s=new PP(i);this.logger.verbose("Auth code client created");const a=new Ad(s,this.browserStorage,o,this.logger,this.performanceClient);return await G(a.handleCodeResponseFromServer.bind(a),_.HandleCodeResponseFromServer,this.logger,this.performanceClient,e.correlationId)({code:e.code,msgraph_host:e.msGraphHost,cloud_graph_host_name:e.cloudGraphHostName,cloud_instance_host_name:e.cloudInstanceHostName},n,!1)}catch(o){throw o instanceof We&&(o.setCorrelationId(this.correlationId),r.cacheFailedRequest(o)),o}}logout(){return Promise.reject(te(fc))}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function Sn(t){const e=t==null?void 0:t.idTokenClaims;if(e!=null&&e.tfp||e!=null&&e.acr)return"B2C";if(e!=null&&e.tid){if((e==null?void 0:e.tid)==="9188040d-6c67-4c5b-b112-36a304b66dad")return"MSA"}else return;return"AAD"}function $s(t,e){try{vd(t)}catch(n){throw e.end({success:!1},n),n}}class mc{constructor(e){this.operatingContext=e,this.isBrowserEnvironment=this.operatingContext.isBrowserEnvironment(),this.config=e.getConfig(),this.initialized=!1,this.logger=this.operatingContext.getLogger(),this.networkClient=this.config.system.networkClient,this.navigationClient=this.config.system.navigationClient,this.redirectResponse=new Map,this.hybridAuthCodeResponses=new Map,this.performanceClient=this.config.telemetry.client,this.browserCrypto=this.isBrowserEnvironment?new fi(this.logger,this.performanceClient):fa,this.eventHandler=new oP(this.logger),this.browserStorage=this.isBrowserEnvironment?new zl(this.config.auth.clientId,this.config.cache,this.browserCrypto,this.logger,jO(this.config.auth),this.performanceClient):Yk(this.config.auth.clientId,this.logger);const n={cacheLocation:Bt.MemoryStorage,temporaryCacheLocation:Bt.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};this.nativeInternalStorage=new zl(this.config.auth.clientId,n,this.browserCrypto,this.logger,void 0,this.performanceClient),this.tokenCache=new kP(this.config,this.browserStorage,this.logger,this.browserCrypto),this.activeSilentTokenRequests=new Map,this.trackPageVisibility=this.trackPageVisibility.bind(this),this.trackPageVisibilityWithMeasurement=this.trackPageVisibilityWithMeasurement.bind(this),this.listeningToStorageEvents=!1,this.handleAccountCacheChange=this.handleAccountCacheChange.bind(this)}static async createController(e,n){const r=new mc(e);return await r.initialize(n),r}trackPageVisibility(e){e&&(this.logger.info("Perf: Visibility change detected"),this.performanceClient.incrementFields({visibilityChangeCount:1},e))}async initialize(e){if(this.logger.trace("initialize called"),this.initialized){this.logger.info("initialize has already been called, exiting early.");return}if(!this.isBrowserEnvironment){this.logger.info("in non-browser environment, exiting early."),this.initialized=!0,this.eventHandler.emitEvent(me.INITIALIZE_END);return}const n=(e==null?void 0:e.correlationId)||this.getRequestCorrelationId(),r=this.config.system.allowNativeBroker,o=this.performanceClient.startMeasurement(_.InitializeClientApplication,n);if(this.eventHandler.emitEvent(me.INITIALIZE_START),r)try{this.nativeExtensionProvider=await Hn.createProvider(this.logger,this.config.system.nativeBrokerHandshakeTimeout,this.performanceClient)}catch(i){this.logger.verbose(i)}this.config.cache.claimsBasedCachingEnabled||(this.logger.verbose("Claims-based caching is disabled. Clearing the previous cache with claims"),await G(this.browserStorage.clearTokensAndKeysWithClaims.bind(this.browserStorage),_.ClearTokensAndKeysWithClaims,this.logger,this.performanceClient,n)(this.performanceClient,n)),this.initialized=!0,this.eventHandler.emitEvent(me.INITIALIZE_END),o.end({allowNativeBroker:r,success:!0})}async handleRedirectPromise(e){if(this.logger.verbose("handleRedirectPromise called"),Tv(this.initialized),this.isBrowserEnvironment){const n=e||"";let r=this.redirectResponse.get(n);return typeof r>"u"?(r=this.handleRedirectPromiseInternal(e),this.redirectResponse.set(n,r),this.logger.verbose("handleRedirectPromise has been called for the first time, storing the promise")):this.logger.verbose("handleRedirectPromise has been called previously, returning the result from the first call"),r}return this.logger.verbose("handleRedirectPromise returns null, not browser environment"),null}async handleRedirectPromiseInternal(e){const n=this.getAllAccounts(),r=this.browserStorage.getCachedNativeRequest(),o=r&&Hn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider)&&this.nativeExtensionProvider&&!e,i=o?r==null?void 0:r.correlationId:this.browserStorage.getTemporaryCache(Be.CORRELATION_ID,!0)||"",s=this.performanceClient.startMeasurement(_.AcquireTokenRedirect,i);this.eventHandler.emitEvent(me.HANDLE_REDIRECT_START,ce.Redirect);let a;if(o&&this.nativeExtensionProvider){this.logger.trace("handleRedirectPromise - acquiring token from native platform");const c=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.handleRedirectPromise,this.performanceClient,this.nativeExtensionProvider,r.accountId,this.nativeInternalStorage,r.correlationId);a=G(c.handleRedirectPromise.bind(c),_.HandleNativeRedirectPromiseMeasurement,this.logger,this.performanceClient,s.event.correlationId)(this.performanceClient,s.event.correlationId)}else{this.logger.trace("handleRedirectPromise - acquiring token from web flow");const c=this.createRedirectClient(i);a=G(c.handleRedirectPromise.bind(c),_.HandleRedirectPromiseMeasurement,this.logger,this.performanceClient,s.event.correlationId)(e,s)}return a.then(c=>(c?(n.length{const l=c;throw n.length>0?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Redirect,null,l):this.eventHandler.emitEvent(me.LOGIN_FAILURE,ce.Redirect,null,l),this.eventHandler.emitEvent(me.HANDLE_REDIRECT_END,ce.Redirect),s.end({success:!1},l),c})}async acquireTokenRedirect(e){const n=this.getRequestCorrelationId(e);this.logger.verbose("acquireTokenRedirect called",n);const r=this.performanceClient.startMeasurement(_.AcquireTokenPreRedirect,n);r.add({accountType:Sn(e.account),scenarioId:e.scenarioId});const o=e.onRedirectNavigate;if(o)e.onRedirectNavigate=s=>{const a=typeof o=="function"?o(s):void 0;return a!==!1?r.end({success:!0}):r.discard(),a};else{const s=this.config.auth.onRedirectNavigate;this.config.auth.onRedirectNavigate=a=>{const c=typeof s=="function"?s(a):void 0;return c!==!1?r.end({success:!0}):r.discard(),c}}const i=this.getAllAccounts().length>0;try{$f(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),i?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_START,ce.Redirect,e):this.eventHandler.emitEvent(me.LOGIN_START,ce.Redirect,e);let s;return this.nativeExtensionProvider&&this.canUseNative(e)?s=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenRedirect,this.performanceClient,this.nativeExtensionProvider,this.getNativeAccountId(e),this.nativeInternalStorage,n).acquireTokenRedirect(e,r).catch(c=>{if(c instanceof Ln&&Uo(c))return this.nativeExtensionProvider=void 0,this.createRedirectClient(n).acquireToken(e);if(c instanceof En)return this.logger.verbose("acquireTokenRedirect - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createRedirectClient(n).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),c}):s=this.createRedirectClient(n).acquireToken(e),await s}catch(s){throw r.end({success:!1},s),i?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Redirect,null,s):this.eventHandler.emitEvent(me.LOGIN_FAILURE,ce.Redirect,null,s),s}}acquireTokenPopup(e){const n=this.getRequestCorrelationId(e),r=this.performanceClient.startMeasurement(_.AcquireTokenPopup,n);r.add({scenarioId:e.scenarioId,accountType:Sn(e.account)});try{this.logger.verbose("acquireTokenPopup called",n),$s(this.initialized,r),this.browserStorage.setInteractionInProgress(!0)}catch(s){return Promise.reject(s)}const o=this.getAllAccounts();o.length>0?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_START,ce.Popup,e):this.eventHandler.emitEvent(me.LOGIN_START,ce.Popup,e);let i;return this.canUseNative(e)?i=this.acquireTokenNative({...e,correlationId:n},ze.acquireTokenPopup).then(s=>(this.browserStorage.setInteractionInProgress(!1),r.end({success:!0,isNativeBroker:!0,accountType:Sn(s.account)}),s)).catch(s=>{if(s instanceof Ln&&Uo(s))return this.nativeExtensionProvider=void 0,this.createPopupClient(n).acquireToken(e);if(s instanceof En)return this.logger.verbose("acquireTokenPopup - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createPopupClient(n).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),s}):i=this.createPopupClient(n).acquireToken(e),i.then(s=>(o.length(o.length>0?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Popup,null,s):this.eventHandler.emitEvent(me.LOGIN_FAILURE,ce.Popup,null,s),r.end({success:!1},s),Promise.reject(s)))}trackPageVisibilityWithMeasurement(){const e=this.ssoSilentMeasurement||this.acquireTokenByCodeAsyncMeasurement;e&&(this.logger.info("Perf: Visibility change detected in ",e.event.name),e.increment({visibilityChangeCount:1}))}async ssoSilent(e){var i,s;const n=this.getRequestCorrelationId(e),r={...e,prompt:e.prompt,correlationId:n};this.ssoSilentMeasurement=this.performanceClient.startMeasurement(_.SsoSilent,n),(i=this.ssoSilentMeasurement)==null||i.add({scenarioId:e.scenarioId,accountType:Sn(e.account)}),$s(this.initialized,this.ssoSilentMeasurement),(s=this.ssoSilentMeasurement)==null||s.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),this.logger.verbose("ssoSilent called",n),this.eventHandler.emitEvent(me.SSO_SILENT_START,ce.Silent,r);let o;return this.canUseNative(r)?o=this.acquireTokenNative(r,ze.ssoSilent).catch(a=>{if(a instanceof Ln&&Uo(a))return this.nativeExtensionProvider=void 0,this.createSilentIframeClient(r.correlationId).acquireToken(r);throw a}):o=this.createSilentIframeClient(r.correlationId).acquireToken(r),o.then(a=>{var c;return this.eventHandler.emitEvent(me.SSO_SILENT_SUCCESS,ce.Silent,a),(c=this.ssoSilentMeasurement)==null||c.end({success:!0,isNativeBroker:a.fromNativeBroker,accessTokenSize:a.accessToken.length,idTokenSize:a.idToken.length,accountType:Sn(a.account)}),a}).catch(a=>{var c;throw this.eventHandler.emitEvent(me.SSO_SILENT_FAILURE,ce.Silent,null,a),(c=this.ssoSilentMeasurement)==null||c.end({success:!1},a),a}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenByCode(e){const n=this.getRequestCorrelationId(e);this.logger.trace("acquireTokenByCode called",n);const r=this.performanceClient.startMeasurement(_.AcquireTokenByCode,n);$s(this.initialized,r),this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_START,ce.Silent,e),r.add({scenarioId:e.scenarioId});try{if(e.code&&e.nativeAccountId)throw te(iv);if(e.code){const o=e.code;let i=this.hybridAuthCodeResponses.get(o);return i?(this.logger.verbose("Existing acquireTokenByCode request found",n),r.discard()):(this.logger.verbose("Initiating new acquireTokenByCode request",n),i=this.acquireTokenByCodeAsync({...e,correlationId:n}).then(s=>(this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_SUCCESS,ce.Silent,s),this.hybridAuthCodeResponses.delete(o),r.end({success:!0,isNativeBroker:s.fromNativeBroker,accessTokenSize:s.accessToken.length,idTokenSize:s.idToken.length,accountType:Sn(s.account)}),s)).catch(s=>{throw this.hybridAuthCodeResponses.delete(o),this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_FAILURE,ce.Silent,null,s),r.end({success:!1},s),s}),this.hybridAuthCodeResponses.set(o,i)),await i}else if(e.nativeAccountId)if(this.canUseNative(e,e.nativeAccountId)){const o=await this.acquireTokenNative({...e,correlationId:n},ze.acquireTokenByCode,e.nativeAccountId).catch(i=>{throw i instanceof Ln&&Uo(i)&&(this.nativeExtensionProvider=void 0),i});return r.end({accountType:Sn(o.account),success:!0}),o}else throw te(sv);else throw te(ov)}catch(o){throw this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_FAILURE,ce.Silent,null,o),r.end({success:!1},o),o}}async acquireTokenByCodeAsync(e){var o;return this.logger.trace("acquireTokenByCodeAsync called",e.correlationId),this.acquireTokenByCodeAsyncMeasurement=this.performanceClient.startMeasurement(_.AcquireTokenByCodeAsync,e.correlationId),(o=this.acquireTokenByCodeAsyncMeasurement)==null||o.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),await this.createSilentAuthCodeClient(e.correlationId).acquireToken(e).then(i=>{var s;return(s=this.acquireTokenByCodeAsyncMeasurement)==null||s.end({success:!0,fromCache:i.fromCache,isNativeBroker:i.fromNativeBroker}),i}).catch(i=>{var s;throw(s=this.acquireTokenByCodeAsyncMeasurement)==null||s.end({success:!1},i),i}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenFromCache(e,n){switch(this.performanceClient.addQueueMeasurement(_.AcquireTokenFromCache,e.correlationId),n){case jt.Default:case jt.AccessToken:case jt.AccessTokenAndRefreshToken:const r=this.createSilentCacheClient(e.correlationId);return G(r.acquireToken.bind(r),_.SilentCacheClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e);default:throw j(or)}}async acquireTokenByRefreshToken(e,n){switch(this.performanceClient.addQueueMeasurement(_.AcquireTokenByRefreshToken,e.correlationId),n){case jt.Default:case jt.AccessTokenAndRefreshToken:case jt.RefreshToken:case jt.RefreshTokenAndNetwork:const r=this.createSilentRefreshClient(e.correlationId);return G(r.acquireToken.bind(r),_.SilentRefreshClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e);default:throw j(or)}}async acquireTokenBySilentIframe(e){this.performanceClient.addQueueMeasurement(_.AcquireTokenBySilentIframe,e.correlationId);const n=this.createSilentIframeClient(e.correlationId);return G(n.acquireToken.bind(n),_.SilentIframeClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e)}async logout(e){const n=this.getRequestCorrelationId(e);return this.logger.warning("logout API is deprecated and will be removed in msal-browser v3.0.0. Use logoutRedirect instead.",n),this.logoutRedirect({correlationId:n,...e})}async logoutRedirect(e){const n=this.getRequestCorrelationId(e);return $f(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),this.createRedirectClient(n).logout(e)}logoutPopup(e){try{const n=this.getRequestCorrelationId(e);return vd(this.initialized),this.browserStorage.setInteractionInProgress(!0),this.createPopupClient(n).logout(e)}catch(n){return Promise.reject(n)}}async clearCache(e){if(!this.isBrowserEnvironment){this.logger.info("in non-browser environment, returning early.");return}const n=this.getRequestCorrelationId(e);return this.createSilentCacheClient(n).logout(e)}getAllAccounts(e){const n=this.getRequestCorrelationId();return Jk(this.logger,this.browserStorage,this.isBrowserEnvironment,n,e)}getAccount(e){const n=this.getRequestCorrelationId();return Xk(e,this.logger,this.browserStorage,n)}getAccountByUsername(e){const n=this.getRequestCorrelationId();return Zk(e,this.logger,this.browserStorage,n)}getAccountByHomeId(e){const n=this.getRequestCorrelationId();return eP(e,this.logger,this.browserStorage,n)}getAccountByLocalId(e){const n=this.getRequestCorrelationId();return tP(e,this.logger,this.browserStorage,n)}setActiveAccount(e){const n=this.getRequestCorrelationId();nP(e,this.browserStorage,n)}getActiveAccount(){const e=this.getRequestCorrelationId();return rP(this.browserStorage,e)}async hydrateCache(e,n){this.logger.verbose("hydrateCache called");const r=dt.createFromAccountInfo(e.account,e.cloudGraphHostName,e.msGraphHost);return this.browserStorage.setAccount(r,e.correlationId),e.fromNativeBroker?(this.logger.verbose("Response was from native broker, storing in-memory"),this.nativeInternalStorage.hydrateCache(e,n)):this.browserStorage.hydrateCache(e,n)}async acquireTokenNative(e,n,r){if(this.logger.trace("acquireTokenNative called"),!this.nativeExtensionProvider)throw te(As);return new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,n,this.performanceClient,this.nativeExtensionProvider,r||this.getNativeAccountId(e),this.nativeInternalStorage,e.correlationId).acquireToken(e)}canUseNative(e,n){if(this.logger.trace("canUseNative called"),!Hn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme))return this.logger.trace("canUseNative: isNativeAvailable returned false, returning false"),!1;if(e.prompt)switch(e.prompt){case gt.NONE:case gt.CONSENT:case gt.LOGIN:this.logger.trace("canUseNative: prompt is compatible with native flow");break;default:return this.logger.trace(`canUseNative: prompt = ${e.prompt} is not compatible with native flow, returning false`),!1}return!n&&!this.getNativeAccountId(e)?(this.logger.trace("canUseNative: nativeAccountId is not available, returning false"),!1):!0}getNativeAccountId(e){const n=e.account||this.getAccount({loginHint:e.loginHint,sid:e.sid})||this.getActiveAccount();return n&&n.nativeAccountId||""}createPopupClient(e){return new wP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createRedirectClient(e){return new TP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentIframeClient(e){return new RP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.ssoSilent,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentCacheClient(e){return new Iv(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentRefreshClient(e){return new OP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentAuthCodeClient(e){return new NP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenByCode,this.performanceClient,this.nativeExtensionProvider,e)}addEventCallback(e,n){return this.eventHandler.addEventCallback(e,n)}removeEventCallback(e){this.eventHandler.removeEventCallback(e)}addPerformanceCallback(e){return Av(),this.performanceClient.addPerformanceCallback(e)}removePerformanceCallback(e){return this.performanceClient.removePerformanceCallback(e)}enableAccountStorageEvents(){typeof window>"u"||(this.listeningToStorageEvents?this.logger.verbose("Account storage listener already registered."):(this.logger.verbose("Adding account storage listener."),this.listeningToStorageEvents=!0,window.addEventListener("storage",this.handleAccountCacheChange)))}disableAccountStorageEvents(){typeof window>"u"||(this.listeningToStorageEvents?(this.logger.verbose("Removing account storage listener."),window.removeEventListener("storage",this.handleAccountCacheChange),this.listeningToStorageEvents=!1):this.logger.verbose("No account storage listener registered."))}handleAccountCacheChange(e){var n;try{(n=e.key)!=null&&n.includes(ft.ACTIVE_ACCOUNT_FILTERS)&&this.eventHandler.emitEvent(me.ACTIVE_ACCOUNT_CHANGED);const r=e.newValue||e.oldValue;if(!r)return;const o=JSON.parse(r);if(typeof o!="object"||!dt.isAccountEntity(o))return;const s=ui.toObject(new dt,o).getAccountInfo();!e.oldValue&&e.newValue?(this.logger.info("Account was added to cache in a different window"),this.eventHandler.emitEvent(me.ACCOUNT_ADDED,void 0,s)):!e.newValue&&e.oldValue&&(this.logger.info("Account was removed from cache in a different window"),this.eventHandler.emitEvent(me.ACCOUNT_REMOVED,void 0,s))}catch{return}}getTokenCache(){return this.tokenCache}getLogger(){return this.logger}setLogger(e){this.logger=e}initializeWrapperLibrary(e,n){this.browserStorage.setWrapperMetadata(e,n)}setNavigationClient(e){this.navigationClient=e}getConfiguration(){return this.config}getPerformanceClient(){return this.performanceClient}isBrowserEnv(){return this.isBrowserEnvironment}getRequestCorrelationId(e){return e!=null&&e.correlationId?e.correlationId:this.isBrowserEnvironment?jn():P.EMPTY_STRING}async loginRedirect(e){const n=this.getRequestCorrelationId(e);return this.logger.verbose("loginRedirect called",n),this.acquireTokenRedirect({correlationId:n,...e||Bf})}loginPopup(e){const n=this.getRequestCorrelationId(e);return this.logger.verbose("loginPopup called",n),this.acquireTokenPopup({correlationId:n,...e||Bf})}async acquireTokenSilent(e){const n=this.getRequestCorrelationId(e),r=this.performanceClient.startMeasurement(_.AcquireTokenSilent,n);r.add({cacheLookupPolicy:e.cacheLookupPolicy,scenarioId:e.scenarioId}),$s(this.initialized,r),this.logger.verbose("acquireTokenSilent called",n);const o=e.account||this.getActiveAccount();if(!o)throw te(Jy);r.add({accountType:Sn(o)});const i={clientId:this.config.auth.clientId,authority:e.authority||P.EMPTY_STRING,scopes:e.scopes,homeAccountIdentifier:o.homeAccountId,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid,shrOptions:e.shrOptions},s=JSON.stringify(i),a=this.activeSilentTokenRequests.get(s);if(typeof a>"u"){this.logger.verbose("acquireTokenSilent called for the first time, storing active request",n);const c=G(this.acquireTokenSilentAsync.bind(this),_.AcquireTokenSilentAsync,this.logger,this.performanceClient,n)({...e,correlationId:n},o).then(l=>(this.activeSilentTokenRequests.delete(s),r.end({success:!0,fromCache:l.fromCache,isNativeBroker:l.fromNativeBroker,cacheLookupPolicy:e.cacheLookupPolicy,accessTokenSize:l.accessToken.length,idTokenSize:l.idToken.length}),l)).catch(l=>{throw this.activeSilentTokenRequests.delete(s),r.end({success:!1},l),l});return this.activeSilentTokenRequests.set(s,c),{...await c,state:e.state}}else return this.logger.verbose("acquireTokenSilent has been called previously, returning the result from the first call",n),r.discard(),{...await a,state:e.state}}async acquireTokenSilentAsync(e,n){const r=()=>this.trackPageVisibility(e.correlationId);this.performanceClient.addQueueMeasurement(_.AcquireTokenSilentAsync,e.correlationId),this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_START,ce.Silent,e),e.correlationId&&this.performanceClient.incrementFields({visibilityChangeCount:0},e.correlationId),document.addEventListener("visibilitychange",r);const o=await G(lP,_.InitializeSilentRequest,this.logger,this.performanceClient,e.correlationId)(e,n,this.config,this.performanceClient,this.logger),i=e.cacheLookupPolicy||jt.Default;return this.acquireTokenSilentNoIframe(o,i).catch(async a=>{if(xP(a,i))if(this.activeIframeRequest)if(i!==jt.Skip){const[l,u]=this.activeIframeRequest;this.logger.verbose(`Iframe request is already in progress, awaiting resolution for request with correlationId: ${u}`,o.correlationId);const d=this.performanceClient.startMeasurement(_.AwaitConcurrentIframe,o.correlationId);d.add({awaitIframeCorrelationId:u});const h=await l;if(d.end({success:h}),h)return this.logger.verbose(`Parallel iframe request with correlationId: ${u} succeeded. Retrying cache and/or RT redemption`,o.correlationId),this.acquireTokenSilentNoIframe(o,i);throw this.logger.info(`Iframe request with correlationId: ${u} failed. Interaction is required.`),a}else return this.logger.warning("Another iframe request is currently in progress and CacheLookupPolicy is set to Skip. This may result in degraded performance and/or reliability for both calls. Please consider changing the CacheLookupPolicy to take advantage of request queuing and token cache.",o.correlationId),G(this.acquireTokenBySilentIframe.bind(this),_.AcquireTokenBySilentIframe,this.logger,this.performanceClient,o.correlationId)(o);else{let l;return this.activeIframeRequest=[new Promise(u=>{l=u}),o.correlationId],this.logger.verbose("Refresh token expired/invalid or CacheLookupPolicy is set to Skip, attempting acquire token by iframe.",o.correlationId),G(this.acquireTokenBySilentIframe.bind(this),_.AcquireTokenBySilentIframe,this.logger,this.performanceClient,o.correlationId)(o).then(u=>(l(!0),u)).catch(u=>{throw l(!1),u}).finally(()=>{this.activeIframeRequest=void 0})}else throw a}).then(a=>(this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_SUCCESS,ce.Silent,a),e.correlationId&&this.performanceClient.addFields({fromCache:a.fromCache,isNativeBroker:a.fromNativeBroker},e.correlationId),a)).catch(a=>{throw this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Silent,null,a),a}).finally(()=>{document.removeEventListener("visibilitychange",r)})}async acquireTokenSilentNoIframe(e,n){return Hn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme)&&e.account.nativeAccountId?(this.logger.verbose("acquireTokenSilent - attempting to acquire token from native platform"),this.acquireTokenNative(e,ze.acquireTokenSilent_silentFlow).catch(async r=>{throw r instanceof Ln&&Uo(r)?(this.logger.verbose("acquireTokenSilent - native platform unavailable, falling back to web flow"),this.nativeExtensionProvider=void 0,j(or)):r})):(this.logger.verbose("acquireTokenSilent - attempting to acquire token from web flow"),G(this.acquireTokenFromCache.bind(this),_.AcquireTokenFromCache,this.logger,this.performanceClient,e.correlationId)(e,n).catch(r=>{if(n===jt.AccessToken)throw r;return this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_NETWORK_START,ce.Silent,e),G(this.acquireTokenByRefreshToken.bind(this),_.AcquireTokenByRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,n)}))}}function xP(t,e){const n=!(t instanceof En&&t.subError!==dc),r=t.errorCode===Qt.INVALID_GRANT_ERROR||t.errorCode===or,o=n&&r||t.errorCode===va||t.errorCode===rd,i=pk.includes(e);return o&&i}/*! @azure/msal-browser v3.30.0 2025-08-05 */async function MP(t,e){const n=new Ao(t);return await n.initialize(),mc.createController(n,e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Td{static async createPublicClientApplication(e){const n=await MP(e);return new Td(e,n)}constructor(e,n){this.controller=n||new mc(new Ao(e))}async initialize(e){return this.controller.initialize(e)}async acquireTokenPopup(e){return this.controller.acquireTokenPopup(e)}acquireTokenRedirect(e){return this.controller.acquireTokenRedirect(e)}acquireTokenSilent(e){return this.controller.acquireTokenSilent(e)}acquireTokenByCode(e){return this.controller.acquireTokenByCode(e)}addEventCallback(e,n){return this.controller.addEventCallback(e,n)}removeEventCallback(e){return this.controller.removeEventCallback(e)}addPerformanceCallback(e){return this.controller.addPerformanceCallback(e)}removePerformanceCallback(e){return this.controller.removePerformanceCallback(e)}enableAccountStorageEvents(){this.controller.enableAccountStorageEvents()}disableAccountStorageEvents(){this.controller.disableAccountStorageEvents()}getAccount(e){return this.controller.getAccount(e)}getAccountByHomeId(e){return this.controller.getAccountByHomeId(e)}getAccountByLocalId(e){return this.controller.getAccountByLocalId(e)}getAccountByUsername(e){return this.controller.getAccountByUsername(e)}getAllAccounts(e){return this.controller.getAllAccounts(e)}handleRedirectPromise(e){return this.controller.handleRedirectPromise(e)}loginPopup(e){return this.controller.loginPopup(e)}loginRedirect(e){return this.controller.loginRedirect(e)}logout(e){return this.controller.logout(e)}logoutRedirect(e){return this.controller.logoutRedirect(e)}logoutPopup(e){return this.controller.logoutPopup(e)}ssoSilent(e){return this.controller.ssoSilent(e)}getTokenCache(){return this.controller.getTokenCache()}getLogger(){return this.controller.getLogger()}setLogger(e){this.controller.setLogger(e)}setActiveAccount(e){this.controller.setActiveAccount(e)}getActiveAccount(){return this.controller.getActiveAccount()}initializeWrapperLibrary(e,n){return this.controller.initializeWrapperLibrary(e,n)}setNavigationClient(e){this.controller.setNavigationClient(e)}getConfiguration(){return this.controller.getConfiguration()}async hydrateCache(e,n){return this.controller.hydrateCache(e,n)}clearCache(e){return this.controller.clearCache(e)}}const Aa=new Td({auth:{clientId:"9079054c-9620-4757-a256-23413042f1ef",authority:"https://login.microsoftonline.com/e519c2e6-bc6d-4fdf-8d9c-923c2f002385",redirectUri:"https://optical-dev.oliver.solutions/cc-dashboard/"},cache:{cacheLocation:"sessionStorage",storeAuthStateInCookie:!1}}),DP=["openid","profile","email"];async function LP(){await Aa.initialize(),await Aa.handleRedirectPromise()}const kv=wA("auth",()=>{const t=J(null),e=J(null),n=J(!1),r=J(null),o=Q(()=>t.value!==null),i=Q(()=>{var u;return((u=e.value)==null?void 0:u.role)==="admin"});async function s(){var u,d;n.value=!0,r.value=null;try{const f=(await Aa.loginPopup({scopes:DP})).idToken,p=await ua.post("/api/auth/microsoft",{id_token:f});t.value=p.data.access_token,await c()}catch(h){const f=h;throw r.value=((d=(u=f.response)==null?void 0:u.data)==null?void 0:d.detail)??f.message??"Login failed",h}finally{n.value=!1}}async function a(){t.value=null,e.value=null;try{await Aa.clearCache()}catch{}}async function c(){const u=await ua.get("/api/auth/me");e.value=u.data}function l(){return t.value}return{token:t,user:e,loading:n,error:r,isAuthenticated:o,isAdmin:i,loginWithMicrosoft:s,logout:a,fetchMe:c,getToken:l}}),UP=[{path:"/login",name:"login",component:()=>Ht(()=>import("./LoginView-DmmhvYTb.js"),__vite__mapDeps([0,1,2])),meta:{public:!0}},{path:"/",component:()=>Ht(()=>import("./AppLayout-CNLTau4W.js"),[]),children:[{path:"",name:"dashboard",component:()=>Ht(()=>import("./DashboardView-Cl3r92sM.js"),__vite__mapDeps([3,4,1,2,5,6,7,8,9,10,11,12,13,14]))},{path:"calendar",name:"calendar",component:()=>Ht(()=>import("./CalendarView-B0jfXKKY.js"),__vite__mapDeps([15,4,2,6,7,16,17,9,13,18,19,20,21,22,23,14,24,25]))},{path:"tasks",name:"tasks",component:()=>Ht(()=>import("./TasksView-D8TRKoOC.js"),__vite__mapDeps([26,13,20,21,6,7,2,22,23,14,12,27]))},{path:"omg",name:"omg",component:()=>Ht(()=>import("./OmgView-BM5Lo3rq.js"),__vite__mapDeps([28,21,6,7,2,22,23,24,9,12,27,29,30]))},{path:"projects",name:"projects",component:()=>Ht(()=>import("./ProjectsView-lK4Qdm9A.js"),__vite__mapDeps([31,4,1,2,11,9,7,16,27,6,32]))},{path:"projects/:id/:date?",name:"project-detail",component:()=>Ht(()=>import("./ProjectDetailView-DmKhTvpx.js"),__vite__mapDeps([33,4,1,2,5,8,22,6,7,27,12,29,9,10]))},{path:"live",name:"live",component:()=>Ht(()=>import("./LiveView-Drr7Q-W3.js"),__vite__mapDeps([34,1,2,6,7,8,27,9,32]))},{path:"reports",name:"reports",component:()=>Ht(()=>import("./ReportsView-b-OOza6x.js"),__vite__mapDeps([35,1,2,19,6,7,16,27,29,9,36,18,37]))},{path:"keys",name:"keys",component:()=>Ht(()=>import("./KeysView-x4Ow5p_D.js"),__vite__mapDeps([38,39,1,2,6,7,21,22,24,9,27,30]))},{path:"devops",name:"devops",component:()=>Ht(()=>import("./DevopsView-O5QaTl8f.js"),__vite__mapDeps([40,14,1,2,5,6,7,22,27,16,12,41,24,9]))},{path:"settings",name:"settings",component:()=>Ht(()=>import("./SettingsView-Dx5EOob_.js"),__vite__mapDeps([42,14,1,2,5,22,6,7,17,9,36,41,24]))},{path:"admin",name:"admin",component:()=>Ht(()=>import("./AdminView-CBzT_n85.js"),__vite__mapDeps([43,39,1,2,19,7])),meta:{adminOnly:!0}}]},{path:"/:pathMatch(.*)*",redirect:"/"}],Ql=AS({history:Z_("/cc-dashboard/"),routes:UP});Ql.beforeEach((t,e,n)=>{const r=kv();if(t.meta.public){n();return}if(!r.isAuthenticated){n({name:"login",query:{redirect:t.fullPath}});return}if(t.meta.adminOnly&&!r.isAdmin){n({name:"dashboard"});return}n()});LP().then(()=>{const t=dA(f_),e=pA();t.use(e),t.use(Ql),t.use(tT);const n=kv();lR(()=>n.getToken(),()=>{n.logout(),Ql.push({name:"login"})}),t.mount("#app")});export{ZP as $,vn as A,wA as B,Qi as C,ua as D,KP as E,nt as F,To as G,PC as H,gC as I,s0 as J,VP as K,c0 as L,n0 as M,r0 as N,t0 as O,GP as P,QP as Q,mS as R,o0 as S,FP as T,a0 as U,WP as V,i0 as W,JP as X,XP as Y,YP as Z,Ht as _,Cn as a,zP as a0,fo as a1,BP as b,Xe as c,ye as d,Pe as e,l0 as f,u0 as g,I as h,er as i,Q as j,fe as k,Zr as l,Ke as m,Gt as n,Y as o,le as p,ta as q,nl as r,J as s,Ho as t,kv as u,VC as v,se as w,ut as x,Fa as y,Fn as z}; +${s}`);return}throw Mf(e.error,e.error_description,e.suberror)?new En(e.error,e.error_description,e.suberror,e.timestamp||P.EMPTY_STRING,e.trace_id||P.EMPTY_STRING,e.correlation_id||P.EMPTY_STRING,e.claims||P.EMPTY_STRING,i):s}}async handleServerTokenResponse(e,n,r,o,i,s,a,c,l){var p;(p=this.performanceClient)==null||p.addQueueMeasurement(_.HandleServerTokenResponse,e.correlation_id);let u;if(e.id_token){if(u=bo(e.id_token||P.EMPTY_STRING,this.cryptoObj.base64Decode),i&&i.nonce&&u.nonce!==i.nonce)throw j(Xm);if(o.maxAge||o.maxAge===0){const g=u.auth_time;if(!g)throw j(Bu);ly(g,o.maxAge)}}this.homeAccountIdentifier=dt.generateHomeAccountId(e.client_info||P.EMPTY_STRING,n.authorityType,this.logger,this.cryptoObj,u);let d;i&&i.state&&(d=gn.parseRequestState(this.cryptoObj,i.state)),e.key_id=e.key_id||o.sshKid||void 0;const h=this.generateCacheRecord(e,n,r,o,u,s,i);let f;try{if(this.persistencePlugin&&this.serializableCache&&(this.logger.verbose("Persistence enabled, calling beforeCacheAccess"),f=new JO(this.serializableCache,!0),await this.persistencePlugin.beforeCacheAccess(f)),a&&!c&&h.account){const g=h.account.generateAccountKey();if(!this.cacheStorage.getAccount(g,o.correlationId,this.logger))return this.logger.warning("Account used to refresh tokens not in persistence, refreshed tokens will not be stored in the cache"),await Co.generateAuthenticationResult(this.cryptoObj,n,h,!1,o,u,d,void 0,l)}await this.cacheStorage.saveCacheRecord(h,o.correlationId,o.storeInCache)}finally{this.persistencePlugin&&this.serializableCache&&f&&(this.logger.verbose("Persistence enabled, calling afterCacheAccess"),await this.persistencePlugin.afterCacheAccess(f))}return Co.generateAuthenticationResult(this.cryptoObj,n,h,!1,o,u,d,e,l)}generateCacheRecord(e,n,r,o,i,s,a){const c=n.getPreferredCache();if(!c)throw j(Ku);const l=_y(i);let u,d;e.id_token&&i&&(u=sc(this.homeAccountIdentifier,c,e.id_token,this.clientId,l||""),d=od(this.cacheStorage,n,this.homeAccountIdentifier,this.cryptoObj.base64Decode,o.correlationId,i,e.client_info,c,l,a,void 0,this.logger));let h=null;if(e.access_token){const g=e.scope?rt.fromString(e.scope):new rt(o.scopes||[]),m=(typeof e.expires_in=="string"?parseInt(e.expires_in,10):e.expires_in)||0,C=(typeof e.ext_expires_in=="string"?parseInt(e.ext_expires_in,10):e.ext_expires_in)||0,T=(typeof e.refresh_in=="string"?parseInt(e.refresh_in,10):e.refresh_in)||void 0,y=r+m,w=y+C,S=T&&T>0?r+T:void 0;h=ac(this.homeAccountIdentifier,c,e.access_token,this.clientId,l||n.tenant||"",g.printScopes(),y,w,this.cryptoObj.base64Decode,S,e.token_type,s,e.key_id,o.claims,o.requestedClaimsHash)}let f=null;if(e.refresh_token){let g;if(e.refresh_token_expires_in){const m=typeof e.refresh_token_expires_in=="string"?parseInt(e.refresh_token_expires_in,10):e.refresh_token_expires_in;g=r+m}f=uy(this.homeAccountIdentifier,c,e.refresh_token,this.clientId,e.foci,s,g)}let p=null;return e.foci&&(p={clientId:this.clientId,environment:c,familyId:e.foci}),{account:d,idToken:u,accessToken:h,refreshToken:f,appMetadata:p}}static async generateAuthenticationResult(e,n,r,o,i,s,a,c,l){var y,w,S,B,N;let u=P.EMPTY_STRING,d=[],h=null,f,p,g=P.EMPTY_STRING;if(r.accessToken){if(r.accessToken.tokenType===Fe.POP&&!i.popKid){const L=new di(e),{secret:k,keyId:F}=r.accessToken;if(!F)throw j($u);u=await L.signPopToken(k,F,i)}else u=r.accessToken.secret;d=rt.fromString(r.accessToken.target).asArray(),h=new Date(Number(r.accessToken.expiresOn)*1e3),f=new Date(Number(r.accessToken.extendedExpiresOn)*1e3),r.accessToken.refreshOn&&(p=new Date(Number(r.accessToken.refreshOn)*1e3))}r.appMetadata&&(g=r.appMetadata.familyId===Ui?Ui:"");const m=(s==null?void 0:s.oid)||(s==null?void 0:s.sub)||"",C=(s==null?void 0:s.tid)||"";c!=null&&c.spa_accountid&&r.account&&(r.account.nativeAccountId=c==null?void 0:c.spa_accountid);const T=r.account?Ju(r.account.getAccountInfo(),void 0,s,(y=r.idToken)==null?void 0:y.secret):null;return{authority:n.canonicalAuthority,uniqueId:m,tenantId:C,scopes:d,account:T,idToken:((w=r==null?void 0:r.idToken)==null?void 0:w.secret)||"",idTokenClaims:s||{},accessToken:u,fromCache:o,expiresOn:h,extExpiresOn:f,refreshOn:p,correlationId:i.correlationId,requestId:l||P.EMPTY_STRING,familyId:g,tokenType:((S=r.accessToken)==null?void 0:S.tokenType)||P.EMPTY_STRING,state:a?a.userRequestState:P.EMPTY_STRING,cloudGraphHostName:((B=r.account)==null?void 0:B.cloudGraphHostName)||P.EMPTY_STRING,msGraphHost:((N=r.account)==null?void 0:N.msGraphHost)||P.EMPTY_STRING,code:c==null?void 0:c.spa_code,fromNativeBroker:!1}}}function od(t,e,n,r,o,i,s,a,c,l,u,d){d==null||d.verbose("setCachedAccount called");const f=t.getAccountKeys().find(T=>T.startsWith(n));let p=null;f&&(p=t.getAccount(f,o,d));const g=p||dt.createAccount({homeAccountId:n,idTokenClaims:i,clientInfo:s,environment:a,cloudGraphHostName:l==null?void 0:l.cloud_graph_host_name,msGraphHost:l==null?void 0:l.msgraph_host,nativeAccountId:u},e,r),m=g.tenantProfiles||[],C=c||g.realm;if(C&&!m.find(T=>T.tenantId===C)){const T=Yu(n,g.localAccountId,C,i);m.push(T)}return g.tenantProfiles=m,g}/*! @azure/msal-common v14.16.1 2025-08-05 */async function Dy(t,e,n){return typeof t=="string"?t:t({clientId:e,tokenEndpoint:n})}/*! @azure/msal-common v14.16.1 2025-08-05 */class Ly extends nd{constructor(e,n){var r;super(e,n),this.includeRedirectUri=!0,this.oidcDefaultScopes=(r=this.config.authOptions.authority.options.OIDCOptions)==null?void 0:r.defaultScopes}async getAuthCodeUrl(e){var r;(r=this.performanceClient)==null||r.addQueueMeasurement(_.GetAuthCodeUrl,e.correlationId);const n=await G(this.createAuthCodeUrlQueryString.bind(this),_.AuthClientCreateQueryString,this.logger,this.performanceClient,e.correlationId)(e);return Oe.appendQueryString(this.authority.authorizationEndpoint,n)}async acquireToken(e,n){var a,c;if((a=this.performanceClient)==null||a.addQueueMeasurement(_.AuthClientAcquireToken,e.correlationId),!e.code)throw j(ty);const r=qn(),o=await G(this.executeTokenRequest.bind(this),_.AuthClientExecuteTokenRequest,this.logger,this.performanceClient,e.correlationId)(this.authority,e),i=(c=o.headers)==null?void 0:c[xt.X_MS_REQUEST_ID],s=new Co(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin,this.performanceClient);return s.validateTokenResponse(o.body),G(s.handleServerTokenResponse.bind(s),_.HandleServerTokenResponse,this.logger,this.performanceClient,e.correlationId)(o.body,this.authority,r,e,n,void 0,void 0,void 0,i)}handleFragmentResponse(e,n){if(new Co(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,null,null).validateServerAuthorizationCodeResponse(e,n),!e.code)throw j(sy);return e}getLogoutUri(e){if(!e)throw $e(yy);const n=this.createLogoutUrlQueryString(e);return Oe.appendQueryString(this.authority.endSessionEndpoint,n)}async executeTokenRequest(e,n){var l,u;(l=this.performanceClient)==null||l.addQueueMeasurement(_.AuthClientExecuteTokenRequest,n.correlationId);const r=this.createTokenQueryParameters(n),o=Oe.appendQueryString(e.tokenEndpoint,r),i=await G(this.createTokenRequestBody.bind(this),_.AuthClientCreateTokenRequestBody,this.logger,this.performanceClient,n.correlationId)(n);let s;if(n.clientInfo)try{const d=pa(n.clientInfo,this.cryptoUtils.base64Decode);s={credential:`${d.uid}${St.CLIENT_INFO_SEPARATOR}${d.utid}`,type:Jt.HOME_ACCOUNT_ID}}catch(d){this.logger.verbose("Could not parse client info for CCS Header: "+d)}const a=this.createTokenRequestHeaders(s||n.ccsCredential),c={clientId:((u=n.tokenBodyParameters)==null?void 0:u.clientId)||this.config.authOptions.clientId,authority:e.canonicalAuthority,scopes:n.scopes,claims:n.claims,authenticationScheme:n.authenticationScheme,resourceRequestMethod:n.resourceRequestMethod,resourceRequestUri:n.resourceRequestUri,shrClaims:n.shrClaims,sshKid:n.sshKid};return G(this.executePostToTokenEndpoint.bind(this),_.AuthorizationCodeClientExecutePostToTokenEndpoint,this.logger,this.performanceClient,n.correlationId)(o,i,a,c,n.correlationId,_.AuthorizationCodeClientExecutePostToTokenEndpoint)}async createTokenRequestBody(e){var o,i;(o=this.performanceClient)==null||o.addQueueMeasurement(_.AuthClientCreateTokenRequestBody,e.correlationId);const n=new Bi(e.correlationId,this.performanceClient);if(n.addClientId(e.embeddedClientId||((i=e.tokenBodyParameters)==null?void 0:i[vo])||this.config.authOptions.clientId),this.includeRedirectUri?n.addRedirectUri(e.redirectUri):Do.validateRedirectUri(e.redirectUri),n.addScopes(e.scopes,!0,this.oidcDefaultScopes),n.addAuthorizationCode(e.code),n.addLibraryInfo(this.config.libraryInfo),n.addApplicationTelemetry(this.config.telemetry.application),n.addThrottling(),this.serverTelemetryManager&&!Hl(this.config)&&n.addServerTelemetry(this.serverTelemetryManager),e.codeVerifier&&n.addCodeVerifier(e.codeVerifier),this.config.clientCredentials.clientSecret&&n.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const s=this.config.clientCredentials.clientAssertion;n.addClientAssertion(await Dy(s.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),n.addClientAssertionType(s.assertionType)}if(n.addGrantType(jm.AUTHORIZATION_CODE_GRANT),n.addClientInfo(),e.authenticationScheme===Fe.POP){const s=new di(this.cryptoUtils,this.performanceClient);let a;e.popKid?a=this.cryptoUtils.encodeKid(e.popKid):a=(await G(s.generateCnf.bind(s),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,n.addPopToken(a)}else if(e.authenticationScheme===Fe.SSH)if(e.sshJwk)n.addSshJwk(e.sshJwk);else throw $e(cc);(!pn.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&n.addClaims(e.claims,this.config.authOptions.clientCapabilities);let r;if(e.clientInfo)try{const s=pa(e.clientInfo,this.cryptoUtils.base64Decode);r={credential:`${s.uid}${St.CLIENT_INFO_SEPARATOR}${s.utid}`,type:Jt.HOME_ACCOUNT_ID}}catch(s){this.logger.verbose("Could not parse client info for CCS Header: "+s)}else r=e.ccsCredential;if(this.config.systemOptions.preventCorsPreflight&&r)switch(r.type){case Jt.HOME_ACCOUNT_ID:try{const s=Fo(r.credential);n.addCcsOid(s)}catch(s){this.logger.verbose("Could not parse home account ID for CCS Header: "+s)}break;case Jt.UPN:n.addCcsUpn(r.credential);break}return e.embeddedClientId&&n.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenBodyParameters&&n.addExtraQueryParameters(e.tokenBodyParameters),e.enableSpaAuthorizationCode&&(!e.tokenBodyParameters||!e.tokenBodyParameters[Pf])&&n.addExtraQueryParameters({[Pf]:"1"}),n.createQueryString()}async createAuthCodeUrlQueryString(e){var i,s;const n=e.correlationId||this.config.cryptoInterface.createNewGuid();(i=this.performanceClient)==null||i.addQueueMeasurement(_.AuthClientCreateQueryString,n);const r=new Bi(n,this.performanceClient);r.addClientId(e.embeddedClientId||((s=e.extraQueryParameters)==null?void 0:s[vo])||this.config.authOptions.clientId);const o=[...e.scopes||[],...e.extraScopesToConsent||[]];if(r.addScopes(o,!0,this.oidcDefaultScopes),r.addRedirectUri(e.redirectUri),r.addCorrelationId(n),r.addResponseMode(e.responseMode),r.addResponseTypeCode(),r.addLibraryInfo(this.config.libraryInfo),Hl(this.config)||r.addApplicationTelemetry(this.config.telemetry.application),r.addClientInfo(),e.codeChallenge&&e.codeChallengeMethod&&r.addCodeChallengeParams(e.codeChallenge,e.codeChallengeMethod),e.prompt&&r.addPrompt(e.prompt),e.domainHint&&r.addDomainHint(e.domainHint),e.prompt!==gt.SELECT_ACCOUNT)if(e.sid&&e.prompt===gt.NONE)this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from request"),r.addSid(e.sid);else if(e.account){const a=this.extractAccountSid(e.account);let c=this.extractLoginHint(e.account);if(c&&e.domainHint&&(this.logger.warning('AuthorizationCodeClient.createAuthCodeUrlQueryString: "domainHint" param is set, skipping opaque "login_hint" claim. Please consider not passing domainHint'),c=null),c){this.logger.verbose("createAuthCodeUrlQueryString: login_hint claim present on account"),r.addLoginHint(c);try{const l=Fo(e.account.homeAccountId);r.addCcsOid(l)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(a&&e.prompt===gt.NONE){this.logger.verbose("createAuthCodeUrlQueryString: Prompt is none, adding sid from account"),r.addSid(a);try{const l=Fo(e.account.homeAccountId);r.addCcsOid(l)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}else if(e.loginHint)this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from request"),r.addLoginHint(e.loginHint),r.addCcsUpn(e.loginHint);else if(e.account.username){this.logger.verbose("createAuthCodeUrlQueryString: Adding login_hint from account"),r.addLoginHint(e.account.username);try{const l=Fo(e.account.homeAccountId);r.addCcsOid(l)}catch{this.logger.verbose("createAuthCodeUrlQueryString: Could not parse home account ID for CCS Header")}}}else e.loginHint&&(this.logger.verbose("createAuthCodeUrlQueryString: No account, adding login_hint from request"),r.addLoginHint(e.loginHint),r.addCcsUpn(e.loginHint));else this.logger.verbose("createAuthCodeUrlQueryString: Prompt is select_account, ignoring account hints");if(e.nonce&&r.addNonce(e.nonce),e.state&&r.addState(e.state),(e.claims||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),e.embeddedClientId&&r.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),this.addExtraQueryParams(e,r),e.nativeBroker&&(r.addNativeBroker(),e.authenticationScheme===Fe.POP)){const a=new di(this.cryptoUtils);let c;e.popKid?c=this.cryptoUtils.encodeKid(e.popKid):c=(await G(a.generateCnf.bind(a),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,r.addPopToken(c)}return r.createQueryString()}createLogoutUrlQueryString(e){const n=new Bi(e.correlationId,this.performanceClient);return e.postLogoutRedirectUri&&n.addPostLogoutRedirectUri(e.postLogoutRedirectUri),e.correlationId&&n.addCorrelationId(e.correlationId),e.idTokenHint&&n.addIdTokenHint(e.idTokenHint),e.state&&n.addState(e.state),e.logoutHint&&n.addLogoutHint(e.logoutHint),this.addExtraQueryParams(e,n),n.createQueryString()}addExtraQueryParams(e,n){!(e.extraQueryParameters&&e.extraQueryParameters.hasOwnProperty("instance_aware"))&&this.config.authOptions.instanceAware&&(e.extraQueryParameters=e.extraQueryParameters||{},e.extraQueryParameters.instance_aware="true"),e.extraQueryParameters&&n.addExtraQueryParameters(e.extraQueryParameters)}extractAccountSid(e){var n;return((n=e.idTokenClaims)==null?void 0:n.sid)||null}extractLoginHint(e){var n;return((n=e.idTokenClaims)==null?void 0:n.login_hint)||null}}/*! @azure/msal-common v14.16.1 2025-08-05 */const ZO=300;class Kl extends nd{constructor(e,n){super(e,n)}async acquireToken(e){var s,a;(s=this.performanceClient)==null||s.addQueueMeasurement(_.RefreshTokenClientAcquireToken,e.correlationId);const n=qn(),r=await G(this.executeTokenRequest.bind(this),_.RefreshTokenClientExecuteTokenRequest,this.logger,this.performanceClient,e.correlationId)(e,this.authority),o=(a=r.headers)==null?void 0:a[xt.X_MS_REQUEST_ID],i=new Co(this.config.authOptions.clientId,this.cacheManager,this.cryptoUtils,this.logger,this.config.serializableCache,this.config.persistencePlugin);return i.validateTokenResponse(r.body),G(i.handleServerTokenResponse.bind(i),_.HandleServerTokenResponse,this.logger,this.performanceClient,e.correlationId)(r.body,this.authority,n,e,void 0,void 0,!0,e.forceCache,o)}async acquireTokenByRefreshToken(e){var r;if(!e)throw $e(my);if((r=this.performanceClient)==null||r.addQueueMeasurement(_.RefreshTokenClientAcquireTokenByRefreshToken,e.correlationId),!e.account)throw j(Fu);if(this.cacheManager.isAppMetadataFOCI(e.account.environment))try{return await G(this.acquireTokenWithCachedRefreshToken.bind(this),_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!0)}catch(o){const i=o instanceof En&&o.errorCode===va,s=o instanceof $r&&o.errorCode===yf.INVALID_GRANT_ERROR&&o.subError===yf.CLIENT_MISMATCH_ERROR;if(i||s)return G(this.acquireTokenWithCachedRefreshToken.bind(this),_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!1);throw o}return G(this.acquireTokenWithCachedRefreshToken.bind(this),_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,!1)}async acquireTokenWithCachedRefreshToken(e,n){var i;(i=this.performanceClient)==null||i.addQueueMeasurement(_.RefreshTokenClientAcquireTokenWithCachedRefreshToken,e.correlationId);const r=_o(this.cacheManager.getRefreshToken.bind(this.cacheManager),_.CacheManagerGetRefreshToken,this.logger,this.performanceClient,e.correlationId)(e.account,n,e.correlationId,void 0,this.performanceClient);if(!r)throw Fl(va);if(r.expiresOn&&Ul(r.expiresOn,e.refreshTokenExpirationOffsetSeconds||ZO))throw Fl(rd);const o={...e,refreshToken:r.secret,authenticationScheme:e.authenticationScheme||Fe.BEARER,ccsCredential:{credential:e.account.homeAccountId,type:Jt.HOME_ACCOUNT_ID}};try{return await G(this.acquireToken.bind(this),_.RefreshTokenClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(o)}catch(s){if(s instanceof En&&s.subError===dc){this.logger.verbose("acquireTokenWithRefreshToken: bad refresh token, removing from cache");const a=Bo(r);this.cacheManager.removeRefreshToken(a,e.correlationId)}throw s}}async executeTokenRequest(e,n){var c,l;(c=this.performanceClient)==null||c.addQueueMeasurement(_.RefreshTokenClientExecuteTokenRequest,e.correlationId);const r=this.createTokenQueryParameters(e),o=Oe.appendQueryString(n.tokenEndpoint,r),i=await G(this.createTokenRequestBody.bind(this),_.RefreshTokenClientCreateTokenRequestBody,this.logger,this.performanceClient,e.correlationId)(e),s=this.createTokenRequestHeaders(e.ccsCredential),a={clientId:((l=e.tokenBodyParameters)==null?void 0:l.clientId)||this.config.authOptions.clientId,authority:n.canonicalAuthority,scopes:e.scopes,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid};return G(this.executePostToTokenEndpoint.bind(this),_.RefreshTokenClientExecutePostToTokenEndpoint,this.logger,this.performanceClient,e.correlationId)(o,i,s,a,e.correlationId,_.RefreshTokenClientExecutePostToTokenEndpoint)}async createTokenRequestBody(e){var o,i,s;(o=this.performanceClient)==null||o.addQueueMeasurement(_.RefreshTokenClientCreateTokenRequestBody,e.correlationId);const n=e.correlationId,r=new Bi(n,this.performanceClient);if(r.addClientId(e.embeddedClientId||((i=e.tokenBodyParameters)==null?void 0:i[vo])||this.config.authOptions.clientId),e.redirectUri&&r.addRedirectUri(e.redirectUri),r.addScopes(e.scopes,!0,(s=this.config.authOptions.authority.options.OIDCOptions)==null?void 0:s.defaultScopes),r.addGrantType(jm.REFRESH_TOKEN_GRANT),r.addClientInfo(),r.addLibraryInfo(this.config.libraryInfo),r.addApplicationTelemetry(this.config.telemetry.application),r.addThrottling(),this.serverTelemetryManager&&!Hl(this.config)&&r.addServerTelemetry(this.serverTelemetryManager),r.addRefreshToken(e.refreshToken),this.config.clientCredentials.clientSecret&&r.addClientSecret(this.config.clientCredentials.clientSecret),this.config.clientCredentials.clientAssertion){const a=this.config.clientCredentials.clientAssertion;r.addClientAssertion(await Dy(a.assertion,this.config.authOptions.clientId,e.resourceRequestUri)),r.addClientAssertionType(a.assertionType)}if(e.authenticationScheme===Fe.POP){const a=new di(this.cryptoUtils,this.performanceClient);let c;e.popKid?c=this.cryptoUtils.encodeKid(e.popKid):c=(await G(a.generateCnf.bind(a),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(e,this.logger)).reqCnfString,r.addPopToken(c)}else if(e.authenticationScheme===Fe.SSH)if(e.sshJwk)r.addSshJwk(e.sshJwk);else throw $e(cc);if((!pn.isEmptyObj(e.claims)||this.config.authOptions.clientCapabilities&&this.config.authOptions.clientCapabilities.length>0)&&r.addClaims(e.claims,this.config.authOptions.clientCapabilities),this.config.systemOptions.preventCorsPreflight&&e.ccsCredential)switch(e.ccsCredential.type){case Jt.HOME_ACCOUNT_ID:try{const a=Fo(e.ccsCredential.credential);r.addCcsOid(a)}catch(a){this.logger.verbose("Could not parse home account ID for CCS Header: "+a)}break;case Jt.UPN:r.addCcsUpn(e.ccsCredential.credential);break}return e.embeddedClientId&&r.addBrokerParameters({brokerClientId:this.config.authOptions.clientId,brokerRedirectUri:this.config.authOptions.redirectUri}),e.tokenBodyParameters&&r.addExtraQueryParameters(e.tokenBodyParameters),r.createQueryString()}}/*! @azure/msal-common v14.16.1 2025-08-05 */class ek extends nd{constructor(e,n){super(e,n)}async acquireToken(e){var n;try{const[r,o]=await this.acquireCachedToken({...e,scopes:(n=e.scopes)!=null&&n.length?e.scopes:[...mi]});return o===Ir.PROACTIVELY_REFRESHED&&(this.logger.info("SilentFlowClient:acquireCachedToken - Cached access token's refreshOn property has been exceeded'. It's not expired, but must be refreshed."),new Kl(this.config,this.performanceClient).acquireTokenByRefreshToken(e).catch(()=>{})),r}catch(r){if(r instanceof ic&&r.errorCode===or)return new Kl(this.config,this.performanceClient).acquireTokenByRefreshToken(e);throw r}}async acquireCachedToken(e){var c;(c=this.performanceClient)==null||c.addQueueMeasurement(_.SilentFlowClientAcquireCachedToken,e.correlationId);let n=Ir.NOT_APPLICABLE;if(e.forceRefresh||!this.config.cacheOptions.claimsBasedCachingEnabled&&!pn.isEmptyObj(e.claims))throw this.setCacheOutcome(Ir.FORCE_REFRESH_OR_CLAIMS,e.correlationId),j(or);if(!e.account)throw j(Fu);const r=e.account.tenantId||qO(e.authority),o=this.cacheManager.getTokenKeys(),i=this.cacheManager.getAccessToken(e.account,e,o,r,this.performanceClient);if(i){if(OR(i.cachedAt)||Ul(i.expiresOn,this.config.systemOptions.tokenRenewalOffsetSeconds))throw this.setCacheOutcome(Ir.CACHED_ACCESS_TOKEN_EXPIRED,e.correlationId),j(or);i.refreshOn&&Ul(i.refreshOn,0)&&(n=Ir.PROACTIVELY_REFRESHED)}else throw this.setCacheOutcome(Ir.NO_CACHED_ACCESS_TOKEN,e.correlationId),j(or);const s=e.authority||this.authority.getPreferredCache(),a={account:this.cacheManager.readAccountFromCache(e.account,e.correlationId),accessToken:i,idToken:this.cacheManager.getIdToken(e.account,e.correlationId,o,r,this.performanceClient),refreshToken:null,appMetadata:this.cacheManager.readAppMetadataFromCache(s)};return this.setCacheOutcome(n,e.correlationId),this.config.serverTelemetryManager&&this.config.serverTelemetryManager.incrementCacheHits(),[await G(this.generateResultFromCacheRecord.bind(this),_.SilentFlowClientGenerateResultFromCacheRecord,this.logger,this.performanceClient,e.correlationId)(a,e),n]}setCacheOutcome(e,n){var r,o;(r=this.serverTelemetryManager)==null||r.setCacheOutcome(e),(o=this.performanceClient)==null||o.addFields({cacheOutcome:e},n),e!==Ir.NOT_APPLICABLE&&this.logger.info(`Token refresh is required due to cache outcome: ${e}`)}async generateResultFromCacheRecord(e,n){var o;(o=this.performanceClient)==null||o.addQueueMeasurement(_.SilentFlowClientGenerateResultFromCacheRecord,n.correlationId);let r;if(e.idToken&&(r=bo(e.idToken.secret,this.config.cryptoInterface.base64Decode)),n.maxAge||n.maxAge===0){const i=r==null?void 0:r.auth_time;if(!i)throw j(Bu);ly(i,n.maxAge)}return Co.generateAuthenticationResult(this.cryptoUtils,this.authority,e,!0,n,r)}}/*! @azure/msal-common v14.16.1 2025-08-05 */const tk={sendGetRequestAsync:()=>Promise.reject(j(Ee)),sendPostRequestAsync:()=>Promise.reject(j(Ee))};/*! @azure/msal-common v14.16.1 2025-08-05 */const Df=",",Uy="|";function nk(t){const{skus:e,libraryName:n,libraryVersion:r,extensionName:o,extensionVersion:i}=t,s=new Map([[0,[n,r]],[2,[o,i]]]);let a=[];if(e!=null&&e.length){if(a=e.split(Df),a.length<4)return e}else a=Array.from({length:4},()=>Uy);return s.forEach((c,l)=>{var u,d;c.length===2&&((u=c[0])!=null&&u.length)&&((d=c[1])!=null&&d.length)&&rk({skuArr:a,index:l,skuName:c[0],skuVersion:c[1]})}),a.join(Df)}function rk(t){const{skuArr:e,index:n,skuName:r,skuVersion:o}=t;n>=e.length||(e[n]=[r,o].join(Uy))}class es{constructor(e,n){this.cacheOutcome=Ir.NOT_APPLICABLE,this.cacheManager=n,this.apiId=e.apiId,this.correlationId=e.correlationId,this.wrapperSKU=e.wrapperSKU||P.EMPTY_STRING,this.wrapperVer=e.wrapperVer||P.EMPTY_STRING,this.telemetryCacheKey=wt.CACHE_KEY+St.CACHE_KEY_SEPARATOR+e.clientId}generateCurrentRequestHeaderValue(){const e=`${this.apiId}${wt.VALUE_SEPARATOR}${this.cacheOutcome}`,n=[this.wrapperSKU,this.wrapperVer],r=this.getNativeBrokerErrorCode();r!=null&&r.length&&n.push(`broker_error=${r}`);const o=n.join(wt.VALUE_SEPARATOR),i=this.getRegionDiscoveryFields(),s=[e,i].join(wt.VALUE_SEPARATOR);return[wt.SCHEMA_VERSION,s,o].join(wt.CATEGORY_SEPARATOR)}generateLastRequestHeaderValue(){const e=this.getLastRequests(),n=es.maxErrorsToSend(e),r=e.failedRequests.slice(0,2*n).join(wt.VALUE_SEPARATOR),o=e.errors.slice(0,n).join(wt.VALUE_SEPARATOR),i=e.errors.length,s=n=wt.MAX_CACHED_ERRORS&&(n.failedRequests.shift(),n.failedRequests.shift(),n.errors.shift()),n.failedRequests.push(this.apiId,this.correlationId),e instanceof Error&&e&&e.toString()?e instanceof We?e.subError?n.errors.push(e.subError):e.errorCode?n.errors.push(e.errorCode):n.errors.push(e.toString()):n.errors.push(e.toString()):n.errors.push(wt.UNKNOWN_ERROR),this.cacheManager.setServerTelemetry(this.telemetryCacheKey,n,this.correlationId)}incrementCacheHits(){const e=this.getLastRequests();return e.cacheHits+=1,this.cacheManager.setServerTelemetry(this.telemetryCacheKey,e,this.correlationId),e.cacheHits}getLastRequests(){const e={failedRequests:[],errors:[],cacheHits:0};return this.cacheManager.getServerTelemetry(this.telemetryCacheKey)||e}clearTelemetryCache(){const e=this.getLastRequests(),n=es.maxErrorsToSend(e),r=e.errors.length;if(n===r)this.cacheManager.removeItem(this.telemetryCacheKey,this.correlationId);else{const o={failedRequests:e.failedRequests.slice(n*2),errors:e.errors.slice(n),cacheHits:0};this.cacheManager.setServerTelemetry(this.telemetryCacheKey,o,this.correlationId)}}static maxErrorsToSend(e){let n,r=0,o=0;const i=e.errors.length;for(n=0;nnull,discard:()=>{},add:()=>{},increment:()=>{},event:{eventId:this.generateId(),status:$O.InProgress,authority:"",libraryName:"",libraryVersion:"",clientId:"",name:e,startTimeMs:Date.now(),correlationId:n||""},measurement:new Uf}}startPerformanceMeasurement(){return new Uf}calculateQueuedTime(){return 0}addQueueMeasurement(){}setPreQueueTime(){}endMeasurement(){return null}discardMeasurements(){}removePerformanceCallback(){return!0}addPerformanceCallback(){return""}emitEvents(){}addFields(){}incrementFields(){}cacheEventByCorrelationId(){}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const ad="pkce_not_created",$l="crypto_nonexistent",hc="empty_navigate_uri",Fy="hash_empty_error",cd="no_state_in_hash",Ky="hash_does_not_contain_known_properties",$y="unable_to_parse_state",qy="state_interaction_type_mismatch",jy="interaction_in_progress",Vy="popup_window_error",Gy="empty_window_error",wo="user_cancelled",sk="monitor_popup_timeout",zy="monitor_window_timeout",Wy="redirect_in_iframe",Qy="block_iframe_reload",Yy="block_nested_popups",ak="iframe_closed_prematurely",fc="silent_logout_unsupported",Jy="no_account_error",ck="silent_prompt_value_error",Xy="no_token_request_cache_error",Zy="unable_to_parse_token_request_cache_error",ld="no_cached_authority_error",lk="auth_request_not_set_error",uk="invalid_cache_type",pc="non_browser_environment",Lo="database_not_open",Ca="no_network_connectivity",ev="post_request_failed",tv="get_request_failed",ql="failed_to_parse_response",nv="unable_to_load_token",ud="crypto_key_not_found",rv="auth_code_required",ov="auth_code_or_nativeAccountId_required",iv="spa_code_and_nativeAccountId_present",dd="database_unavailable",sv="unable_to_acquire_token_from_native_platform",av="native_handshake_timeout",cv="native_extension_not_installed",As="native_connection_not_established",lv="uninitialized_public_client_application",uv="native_prompt_not_supported",dv="invalid_base64_string",hv="invalid_pop_token_request",fv="failed_to_build_headers",pv="failed_to_parse_headers";/*! @azure/msal-browser v3.30.0 2025-08-05 */const Yn="For more visit: aka.ms/msaljs/browser-errors",dk={[ad]:"The PKCE code challenge and verifier could not be generated.",[$l]:"The crypto object or function is not available.",[hc]:"Navigation URI is empty. Please check stack trace for more info.",[Fy]:`Hash value cannot be processed because it is empty. Please verify that your redirectUri is not clearing the hash. ${Yn}`,[cd]:"Hash does not contain state. Please verify that the request originated from msal.",[Ky]:`Hash does not contain known properites. Please verify that your redirectUri is not changing the hash. ${Yn}`,[$y]:"Unable to parse state. Please verify that the request originated from msal.",[qy]:"Hash contains state but the interaction type does not match the caller.",[jy]:`Interaction is currently in progress. Please ensure that this interaction has been completed before calling an interactive API. ${Yn}`,[Vy]:"Error opening popup window. This can happen if you are using IE or if popups are blocked in the browser.",[Gy]:"window.open returned null or undefined window object.",[wo]:"User cancelled the flow.",[sk]:`Token acquisition in popup failed due to timeout. ${Yn}`,[zy]:`Token acquisition in iframe failed due to timeout. ${Yn}`,[Wy]:"Redirects are not supported for iframed or brokered applications. Please ensure you are using MSAL.js in a top frame of the window if using the redirect APIs, or use the popup APIs.",[Qy]:`Request was blocked inside an iframe because MSAL detected an authentication response. ${Yn}`,[Yy]:"Request was blocked inside a popup because MSAL detected it was running in a popup.",[ak]:"The iframe being monitored was closed prematurely.",[fc]:"Silent logout not supported. Please call logoutRedirect or logoutPopup instead.",[Jy]:"No account object provided to acquireTokenSilent and no active account has been set. Please call setActiveAccount or provide an account on the request.",[ck]:"The value given for the prompt value is not valid for silent requests - must be set to 'none' or 'no_session'.",[Xy]:"No token request found in cache.",[Zy]:"The cached token request could not be parsed.",[ld]:"No cached authority found.",[lk]:"Auth Request not set. Please ensure initiateAuthRequest was called from the InteractionHandler",[uk]:"Invalid cache type",[pc]:"Login and token requests are not supported in non-browser environments.",[Lo]:"Database is not open!",[Ca]:"No network connectivity. Check your internet connection.",[ev]:"Network request failed: If the browser threw a CORS error, check that the redirectUri is registered in the Azure App Portal as type 'SPA'",[tv]:"Network request failed. Please check the network trace to determine root cause.",[ql]:"Failed to parse network response. Check network trace.",[nv]:"Error loading token to cache.",[ud]:"Cryptographic Key or Keypair not found in browser storage.",[rv]:"An authorization code must be provided (as the `code` property on the request) to this flow.",[ov]:"An authorization code or nativeAccountId must be provided to this flow.",[iv]:"Request cannot contain both spa code and native account id.",[dd]:"IndexedDB, which is required for persistent cryptographic key storage, is unavailable. This may be caused by browser privacy features which block persistent storage in third-party contexts.",[sv]:`Unable to acquire token from native platform. ${Yn}`,[av]:"Timed out while attempting to establish connection to browser extension",[cv]:"Native extension is not installed. If you think this is a mistake call the initialize function.",[As]:`Connection to native platform has not been established. Please install a compatible browser extension and run initialize(). ${Yn}`,[lv]:`You must call and await the initialize function before attempting to call any other MSAL API. ${Yn}`,[uv]:"The provided prompt is not supported by the native platform. This request should be routed to the web based flow.",[dv]:"Invalid base64 encoded string.",[hv]:"Invalid PoP token request. The request should not have both a popKid value and signPopToken set to true.",[fv]:"Failed to build request headers object.",[pv]:"Failed to parse response headers"};class Ts extends We{constructor(e,n){super(e,dk[e],n),Object.setPrototypeOf(this,Ts.prototype),this.name="BrowserAuthError"}}function te(t,e){return new Ts(t,e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const Qt={INVALID_GRANT_ERROR:"invalid_grant",POPUP_WIDTH:483,POPUP_HEIGHT:600,POPUP_NAME_PREFIX:"msal",DEFAULT_POLL_INTERVAL_MS:30,MSAL_SKU:"msal.js.browser"},Ko={CHANNEL_ID:"53ee284d-920a-4b59-9d30-a60315b26836",PREFERRED_EXTENSION_ID:"ppnbnpeolgkicgegkbkbjmhlideopiji",MATS_TELEMETRY:"MATS"},ro={HandshakeRequest:"Handshake",HandshakeResponse:"HandshakeResponse",GetToken:"GetToken",Response:"Response"},Bt={LocalStorage:"localStorage",SessionStorage:"sessionStorage",MemoryStorage:"memoryStorage"},Hf={GET:"GET",POST:"POST"},Be={AUTHORITY:"authority",ACQUIRE_TOKEN_ACCOUNT:"acquireToken.account",SESSION_STATE:"session.state",REQUEST_STATE:"request.state",NONCE_IDTOKEN:"nonce.id_token",ORIGIN_URI:"request.origin",RENEW_STATUS:"token.renew.status",URL_HASH:"urlHash",REQUEST_PARAMS:"request.params",SCOPES:"scopes",INTERACTION_STATUS_KEY:"interaction.status",CCS_CREDENTIAL:"ccs.credential",CORRELATION_ID:"request.correlationId",NATIVE_REQUEST:"request.native",REDIRECT_CONTEXT:"request.redirect.context"},on={ACCOUNT_KEYS:"msal.account.keys",TOKEN_KEYS:"msal.token.keys",VERSION:"msal.version"},Fs={WRAPPER_SKU:"wrapper.sku",WRAPPER_VER:"wrapper.version"},ze={acquireTokenRedirect:861,acquireTokenPopup:862,ssoSilent:863,acquireTokenSilent_authCode:864,handleRedirectPromise:865,acquireTokenByCode:866,acquireTokenSilent_silentFlow:61,logout:961,logoutPopup:962};var ce;(function(t){t.Redirect="redirect",t.Popup="popup",t.Silent="silent",t.None="none"})(ce||(ce={}));const Bf={scopes:mi},gv="jwk",jl="msal.db",hk=1,fk=`${jl}.keys`,jt={Default:0,AccessToken:1,AccessTokenAndRefreshToken:2,RefreshToken:3,RefreshTokenAndNetwork:4,Skip:5},pk=[jt.Default,jt.Skip,jt.RefreshTokenAndNetwork],gk="msal.browser.log.level",mk="msal.browser.log.pii";/*! @azure/msal-browser v3.30.0 2025-08-05 */function Ks(t){return encodeURIComponent(hd(t).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_"))}function gc(t){return mv(t).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}function hd(t){return mv(new TextEncoder().encode(t))}function mv(t){const e=Array.from(t,n=>String.fromCodePoint(n)).join("");return btoa(e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const yk="RSASSA-PKCS1-v1_5",yv="SHA-256",vk=2048,Ck=new Uint8Array([1,0,1]),Ff="0123456789abcdef",Kf=new Uint32Array(1),wk="crypto_subtle_undefined",fd={name:yk,hash:yv,modulusLength:vk,publicExponent:Ck};function Ak(t){if(!window)throw te(pc);if(!window.crypto)throw te($l);if(!t&&!window.crypto.subtle)throw te($l,wk)}async function vv(t,e,n){e==null||e.addQueueMeasurement(_.Sha256Digest,n);const o=new TextEncoder().encode(t);return window.crypto.subtle.digest(yv,o)}function Tk(t){return window.crypto.getRandomValues(t)}function Wc(){return window.crypto.getRandomValues(Kf),Kf[0]}function jn(){const t=Date.now(),e=Wc()*1024+(Wc()&1023),n=new Uint8Array(16),r=Math.trunc(e/2**30),o=e&2**30-1,i=Wc();n[0]=t/2**40,n[1]=t/2**32,n[2]=t/2**24,n[3]=t/2**16,n[4]=t/2**8,n[5]=t,n[6]=112|r>>>8,n[7]=r,n[8]=128|o>>>24,n[9]=o>>>16,n[10]=o>>>8,n[11]=o,n[12]=i>>>24,n[13]=i>>>16,n[14]=i>>>8,n[15]=i;let s="";for(let a=0;a>>4),s+=Ff.charAt(n[a]&15),(a===3||a===5||a===7||a===9)&&(s+="-");return s}async function Ek(t,e){return window.crypto.subtle.generateKey(fd,t,e)}async function Qc(t){return window.crypto.subtle.exportKey(gv,t)}async function bk(t,e,n){return window.crypto.subtle.importKey(gv,t,fd,e,n)}async function _k(t,e){return window.crypto.subtle.sign(fd,t,e)}async function Cv(t){const e=await vv(t),n=new Uint8Array(e);return gc(n)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const pd="storage_not_supported",Sk="stubbed_public_client_application_called",wv="in_mem_redirect_unavailable";/*! @azure/msal-browser v3.30.0 2025-08-05 */const Ik={[pd]:"Given storage configuration option was not supported.",[Sk]:"Stub instance of Public Client Application was called. If using msal-react, please ensure context is not used without a provider. For more visit: aka.ms/msaljs/browser-errors",[wv]:"Redirect cannot be supported. In-memory storage was selected and storeAuthStateInCookie=false, which would cause the library to be unable to handle the incoming hash. If you would like to use the redirect API, please use session/localStorage or set storeAuthStateInCookie=true."};class gd extends We{constructor(e,n){super(e,n),this.name="BrowserConfigurationAuthError",Object.setPrototypeOf(this,gd.prototype)}}function md(t){return new gd(t,Ik[t])}/*! @azure/msal-browser v3.30.0 2025-08-05 */function Rk(t){t.location.hash="",typeof t.history.replaceState=="function"&&t.history.replaceState(null,"",`${t.location.origin}${t.location.pathname}${t.location.search}`)}function Ok(t){const e=t.split("#");e.shift(),window.location.hash=e.length>0?e.join("#"):""}function yd(){return window.parent!==window}function kk(){return typeof window<"u"&&!!window.opener&&window.opener!==window&&typeof window.name=="string"&&window.name.indexOf(`${Qt.POPUP_NAME_PREFIX}.`)===0}function ir(){return typeof window<"u"&&window.location?window.location.href.split("?")[0].split("#")[0]:""}function Pk(){const e=new Oe(window.location.href).getUrlComponents();return`${e.Protocol}//${e.HostNameAndPort}/`}function Nk(){if(Oe.hashContainsKnownProperties(window.location.hash)&&yd())throw te(Qy)}function xk(t){if(yd()&&!t)throw te(Wy)}function Mk(){if(kk())throw te(Yy)}function Av(){if(typeof window>"u")throw te(pc)}function Tv(t){if(!t)throw te(lv)}function vd(t){Av(),Nk(),Mk(),Tv(t)}function $f(t,e){if(vd(t),xk(e.system.allowRedirectInIframe),e.cache.cacheLocation===Bt.MemoryStorage&&!e.cache.storeAuthStateInCookie)throw md(wv)}function Ev(t){const e=document.createElement("link");e.rel="preconnect",e.href=new URL(t).origin,e.crossOrigin="anonymous",document.head.appendChild(e),window.setTimeout(()=>{try{document.head.removeChild(e)}catch{}},1e4)}function Dk(){return jn()}/*! @azure/msal-browser v3.30.0 2025-08-05 */class wa{navigateInternal(e,n){return wa.defaultNavigateWindow(e,n)}navigateExternal(e,n){return wa.defaultNavigateWindow(e,n)}static defaultNavigateWindow(e,n){return n.noHistory?window.location.replace(e):window.location.assign(e),new Promise(r=>{setTimeout(()=>{r(!0)},n.timeout)})}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Lk{async sendGetRequestAsync(e,n){let r,o={},i=0;const s=qf(n);try{r=await fetch(e,{method:Hf.GET,headers:s})}catch{throw te(window.navigator.onLine?tv:Ca)}o=jf(r.headers);try{return i=r.status,{headers:o,body:await r.json(),status:i}}catch{throw Nf(te(ql),i,o)}}async sendPostRequestAsync(e,n){const r=n&&n.body||"",o=qf(n);let i,s=0,a={};try{i=await fetch(e,{method:Hf.POST,headers:o,body:r})}catch{throw te(window.navigator.onLine?ev:Ca)}a=jf(i.headers);try{return s=i.status,{headers:a,body:await i.json(),status:s}}catch{throw Nf(te(ql),s,a)}}}function qf(t){try{const e=new Headers;if(!(t&&t.headers))return e;const n=t.headers;return Object.entries(n).forEach(([r,o])=>{e.append(r,o)}),e}catch{throw te(fv)}}function jf(t){try{const e={};return t.forEach((n,r)=>{e[r]=n}),e}catch{throw te(pv)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const Uk=6e4,Vl=1e4,Hk=3e4,Bk=2e3;function Fk({auth:t,cache:e,system:n,telemetry:r},o){const i={clientId:P.EMPTY_STRING,authority:`${P.DEFAULT_AUTHORITY}`,knownAuthorities:[],cloudDiscoveryMetadata:P.EMPTY_STRING,authorityMetadata:P.EMPTY_STRING,redirectUri:typeof window<"u"?ir():"",postLogoutRedirectUri:P.EMPTY_STRING,navigateToLoginRequestUrl:!0,clientCapabilities:[],protocolMode:ar.AAD,OIDCOptions:{serverResponseType:ws.FRAGMENT,defaultScopes:[P.OPENID_SCOPE,P.PROFILE_SCOPE,P.OFFLINE_ACCESS_SCOPE]},azureCloudOptions:{azureCloudInstance:ju.None,tenant:P.EMPTY_STRING},skipAuthorityMetadataCache:!1,supportsNestedAppAuth:!1,instanceAware:!1},s={cacheLocation:Bt.SessionStorage,temporaryCacheLocation:Bt.SessionStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!!(e&&e.cacheLocation===Bt.LocalStorage),claimsBasedCachingEnabled:!1},a={loggerCallback:()=>{},logLevel:Ye.Info,piiLoggingEnabled:!1},l={...{...ky,loggerOptions:a,networkClient:o?new Lk:tk,navigationClient:new wa,loadFrameTimeout:0,windowHashTimeout:(n==null?void 0:n.loadFrameTimeout)||Uk,iframeHashTimeout:(n==null?void 0:n.loadFrameTimeout)||Vl,navigateFrameWait:0,redirectNavigationTimeout:Hk,asyncPopups:!1,allowRedirectInIframe:!1,allowNativeBroker:!1,nativeBrokerHandshakeTimeout:(n==null?void 0:n.nativeBrokerHandshakeTimeout)||Bk,pollIntervalMilliseconds:Qt.DEFAULT_POLL_INTERVAL_MS},...n,loggerOptions:(n==null?void 0:n.loggerOptions)||a},u={application:{appName:P.EMPTY_STRING,appVersion:P.EMPTY_STRING},client:new ik};if((t==null?void 0:t.protocolMode)!==ar.OIDC&&(t!=null&&t.OIDCOptions)&&new Kr(l.loggerOptions).warning(JSON.stringify($e(Ty))),t!=null&&t.protocolMode&&t.protocolMode!==ar.AAD&&(l!=null&&l.allowNativeBroker))throw $e(Ey);return{auth:{...i,...t,OIDCOptions:{...i.OIDCOptions,...t==null?void 0:t.OIDCOptions}},cache:{...s,...e},system:l,telemetry:{...u,...r}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const Kk="@azure/msal-browser",hi="3.30.0";/*! @azure/msal-browser v3.30.0 2025-08-05 */class Cd{static loggerCallback(e,n){switch(e){case Ye.Error:console.error(n);return;case Ye.Info:console.info(n);return;case Ye.Verbose:console.debug(n);return;case Ye.Warning:console.warn(n);return;default:console.log(n);return}}constructor(e){var c;this.browserEnvironment=typeof window<"u",this.config=Fk(e,this.browserEnvironment);let n;try{n=window[Bt.SessionStorage]}catch{}const r=n==null?void 0:n.getItem(gk),o=(c=n==null?void 0:n.getItem(mk))==null?void 0:c.toLowerCase(),i=o==="true"?!0:o==="false"?!1:void 0,s={...this.config.system.loggerOptions},a=r&&Object.keys(Ye).includes(r)?Ye[r]:void 0;a&&(s.loggerCallback=Cd.loggerCallback,s.logLevel=a),i!==void 0&&(s.piiLoggingEnabled=i),this.logger=new Kr(s,Kk,hi),this.available=!1}getConfig(){return this.config}getLogger(){return this.logger}isAvailable(){return this.available}isBrowserEnvironment(){return this.browserEnvironment}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Ao extends Cd{getModuleName(){return Ao.MODULE_NAME}getId(){return Ao.ID}async initialize(){return this.available=typeof window<"u",this.available}}Ao.MODULE_NAME="";Ao.ID="StandardOperatingContext";/*! @azure/msal-browser v3.30.0 2025-08-05 */function $n(t){return new TextDecoder().decode($k(t))}function $k(t){let e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw te(dv)}const n=atob(e);return Uint8Array.from(n,r=>r.codePointAt(0)||0)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class qk{constructor(){this.dbName=jl,this.version=hk,this.tableName=fk,this.dbOpen=!1}async open(){return new Promise((e,n)=>{const r=window.indexedDB.open(this.dbName,this.version);r.addEventListener("upgradeneeded",o=>{o.target.result.createObjectStore(this.tableName)}),r.addEventListener("success",o=>{const i=o;this.db=i.target.result,this.dbOpen=!0,e()}),r.addEventListener("error",()=>n(te(dd)))})}closeConnection(){const e=this.db;e&&this.dbOpen&&(e.close(),this.dbOpen=!1)}async validateDbIsOpen(){if(!this.dbOpen)return this.open()}async getItem(e){return await this.validateDbIsOpen(),new Promise((n,r)=>{if(!this.db)return r(te(Lo));const s=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).get(e);s.addEventListener("success",a=>{const c=a;this.closeConnection(),n(c.target.result)}),s.addEventListener("error",a=>{this.closeConnection(),r(a)})})}async setItem(e,n){return await this.validateDbIsOpen(),new Promise((r,o)=>{if(!this.db)return o(te(Lo));const a=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).put(n,e);a.addEventListener("success",()=>{this.closeConnection(),r()}),a.addEventListener("error",c=>{this.closeConnection(),o(c)})})}async removeItem(e){return await this.validateDbIsOpen(),new Promise((n,r)=>{if(!this.db)return r(te(Lo));const s=this.db.transaction([this.tableName],"readwrite").objectStore(this.tableName).delete(e);s.addEventListener("success",()=>{this.closeConnection(),n()}),s.addEventListener("error",a=>{this.closeConnection(),r(a)})})}async getKeys(){return await this.validateDbIsOpen(),new Promise((e,n)=>{if(!this.db)return n(te(Lo));const i=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).getAllKeys();i.addEventListener("success",s=>{const a=s;this.closeConnection(),e(a.target.result)}),i.addEventListener("error",s=>{this.closeConnection(),n(s)})})}async containsKey(e){return await this.validateDbIsOpen(),new Promise((n,r)=>{if(!this.db)return r(te(Lo));const s=this.db.transaction([this.tableName],"readonly").objectStore(this.tableName).count(e);s.addEventListener("success",a=>{const c=a;this.closeConnection(),n(c.target.result===1)}),s.addEventListener("error",a=>{this.closeConnection(),r(a)})})}async deleteDatabase(){return this.db&&this.dbOpen&&this.closeConnection(),new Promise((e,n)=>{const r=window.indexedDB.deleteDatabase(jl),o=setTimeout(()=>n(!1),200);r.addEventListener("success",()=>(clearTimeout(o),e(!0))),r.addEventListener("blocked",()=>(clearTimeout(o),e(!0))),r.addEventListener("error",()=>(clearTimeout(o),n(!1)))})}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Gl{constructor(){this.cache=new Map}getItem(e){return this.cache.get(e)||null}setItem(e,n){this.cache.set(e,n)}removeItem(e){this.cache.delete(e)}getKeys(){const e=[];return this.cache.forEach((n,r)=>{e.push(r)}),e}containsKey(e){return this.cache.has(e)}clear(){this.cache.clear()}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class jk{constructor(e){this.inMemoryCache=new Gl,this.indexedDBCache=new qk,this.logger=e}handleDatabaseAccessError(e){if(e instanceof Ts&&e.errorCode===dd)this.logger.error("Could not access persistent storage. This may be caused by browser privacy features which block persistent storage in third-party contexts.");else throw e}async getItem(e){const n=this.inMemoryCache.getItem(e);if(!n)try{return this.logger.verbose("Queried item not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.getItem(e)}catch(r){this.handleDatabaseAccessError(r)}return n}async setItem(e,n){this.inMemoryCache.setItem(e,n);try{await this.indexedDBCache.setItem(e,n)}catch(r){this.handleDatabaseAccessError(r)}}async removeItem(e){this.inMemoryCache.removeItem(e);try{await this.indexedDBCache.removeItem(e)}catch(n){this.handleDatabaseAccessError(n)}}async getKeys(){const e=this.inMemoryCache.getKeys();if(e.length===0)try{return this.logger.verbose("In-memory cache is empty, now querying persistent storage."),await this.indexedDBCache.getKeys()}catch(n){this.handleDatabaseAccessError(n)}return e}async containsKey(e){const n=this.inMemoryCache.containsKey(e);if(!n)try{return this.logger.verbose("Key not found in in-memory cache, now querying persistent storage."),await this.indexedDBCache.containsKey(e)}catch(r){this.handleDatabaseAccessError(r)}return n}clearInMemory(){this.logger.verbose("Deleting in-memory keystore"),this.inMemoryCache.clear(),this.logger.verbose("In-memory keystore deleted")}async clearPersistent(){try{this.logger.verbose("Deleting persistent keystore");const e=await this.indexedDBCache.deleteDatabase();return e&&this.logger.verbose("Persistent keystore deleted"),e}catch(e){return this.handleDatabaseAccessError(e),!1}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class fi{constructor(e,n,r){this.logger=e,Ak(r??!1),this.cache=new jk(this.logger),this.performanceClient=n}createNewGuid(){return jn()}base64Encode(e){return hd(e)}base64Decode(e){return $n(e)}base64UrlEncode(e){return Ks(e)}encodeKid(e){return this.base64UrlEncode(JSON.stringify({kid:e}))}async getPublicKeyThumbprint(e){var u;const n=(u=this.performanceClient)==null?void 0:u.startMeasurement(_.CryptoOptsGetPublicKeyThumbprint,e.correlationId),r=await Ek(fi.EXTRACTABLE,fi.POP_KEY_USAGES),o=await Qc(r.publicKey),i={e:o.e,kty:o.kty,n:o.n},s=Vf(i),a=await this.hashString(s),c=await Qc(r.privateKey),l=await bk(c,!1,["sign"]);return await this.cache.setItem(a,{privateKey:l,publicKey:r.publicKey,requestMethod:e.resourceRequestMethod,requestUri:e.resourceRequestUri}),n&&n.end({success:!0}),a}async removeTokenBindingKey(e){return await this.cache.removeItem(e),!await this.cache.containsKey(e)}async clearKeystore(){this.cache.clearInMemory();try{return await this.cache.clearPersistent(),!0}catch(e){return e instanceof Error?this.logger.error(`Clearing keystore failed with error: ${e.message}`):this.logger.error("Clearing keystore failed with unknown error"),!1}}async signJwt(e,n,r,o){var y;const i=(y=this.performanceClient)==null?void 0:y.startMeasurement(_.CryptoOptsSignJwt,o),s=await this.cache.getItem(n);if(!s)throw te(ud);const a=await Qc(s.publicKey),c=Vf(a),l=Ks(JSON.stringify({kid:n})),u=sd.getShrHeaderString({...r==null?void 0:r.header,alg:a.alg,kid:l}),d=Ks(u);e.cnf={jwk:JSON.parse(c)};const h=Ks(JSON.stringify(e)),f=`${d}.${h}`,g=new TextEncoder().encode(f),m=await _k(s.privateKey,g),C=gc(new Uint8Array(m)),T=`${f}.${C}`;return i&&i.end({success:!0}),T}async hashString(e){return Cv(e)}}fi.POP_KEY_USAGES=["sign","verify"];fi.EXTRACTABLE=!0;function Vf(t){return JSON.stringify(t,Object.keys(t).sort())}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Vk{constructor(){if(!window.localStorage)throw md(pd)}getItem(e){return window.localStorage.getItem(e)}setItem(e,n){window.localStorage.setItem(e,n)}removeItem(e){window.localStorage.removeItem(e)}getKeys(){return Object.keys(window.localStorage)}containsKey(e){return window.localStorage.hasOwnProperty(e)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Gk{constructor(){if(!window.sessionStorage)throw md(pd)}getItem(e){return window.sessionStorage.getItem(e)}setItem(e,n){window.sessionStorage.setItem(e,n)}removeItem(e){window.sessionStorage.removeItem(e)}getKeys(){return Object.keys(window.sessionStorage)}containsKey(e){return window.sessionStorage.hasOwnProperty(e)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function bv(t,e){if(!e)return null;try{return gn.parseRequestState(t,e).libraryState.meta}catch{throw j(li)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const zk=24*60*60*1e3;class Wk{getItem(e){const n=`${encodeURIComponent(e)}`,r=document.cookie.split(";");for(let o=0;o{const o=decodeURIComponent(r).trim().split("=");n.push(o[0])}),n}containsKey(e){return this.getKeys().includes(e)}}function Qk(t){const e=new Date;return new Date(e.getTime()+t*zk).toUTCString()}/*! @azure/msal-browser v3.30.0 2025-08-05 */class zl extends ui{constructor(e,n,r,o,i,s){super(e,r,o,i),this.cacheConfig=n,this.logger=o,this.internalStorage=new Gl,this.browserStorage=this.setupBrowserStorage(this.cacheConfig.cacheLocation),this.temporaryCacheStorage=this.setupBrowserStorage(this.cacheConfig.temporaryCacheLocation),this.cookieStorage=new Wk,n.cacheMigrationEnabled&&(this.migrateCacheEntries(),this.createKeyMaps()),this.performanceClient=s}setupBrowserStorage(e){try{switch(e){case Bt.LocalStorage:return new Vk;case Bt.SessionStorage:return new Gk;case Bt.MemoryStorage:default:break}}catch(n){this.logger.error(n)}return this.cacheConfig.cacheLocation=Bt.MemoryStorage,new Gl}migrateCacheEntries(){const e=this.browserStorage.getItem(on.VERSION);e&&this.logger.info(`MSAL.js was last initialized with version ${e}`),e!==hi&&this.browserStorage.setItem(on.VERSION,hi);const n=`${P.CACHE_PREFIX}.${ft.ID_TOKEN}`,r=`${P.CACHE_PREFIX}.${ft.CLIENT_INFO}`,o=`${P.CACHE_PREFIX}.${ft.ERROR}`,i=`${P.CACHE_PREFIX}.${ft.ERROR_DESC}`,s=this.browserStorage.getItem(n),a=this.browserStorage.getItem(r),c=this.browserStorage.getItem(o),l=this.browserStorage.getItem(i),u=[s,a,c,l];[ft.ID_TOKEN,ft.CLIENT_INFO,ft.ERROR,ft.ERROR_DESC].forEach((h,f)=>{const p=u[f];p&&this.setTemporaryCache(h,p,!0)})}createKeyMaps(){this.logger.trace("BrowserCacheManager - createKeyMaps called.");const e=this.cryptoImpl.createNewGuid(),n=this.getItem(on.ACCOUNT_KEYS),r=this.getItem(`${on.TOKEN_KEYS}.${this.clientId}`);if(n&&r){this.logger.verbose("BrowserCacheManager:createKeyMaps - account and token key maps already exist, skipping migration.");return}this.browserStorage.getKeys().forEach(i=>{if(this.isCredentialKey(i)){const s=this.getItem(i);if(s){const a=this.validateAndParseJson(s);if(a&&a.hasOwnProperty("credentialType"))switch(a.credentialType){case Ce.ID_TOKEN:if(Tf(a)){this.logger.trace("BrowserCacheManager:createKeyMaps - idToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - idToken with key: ${i} found, saving key to token key map`);const c=a,l=this.updateCredentialCacheKey(i,c,e);this.addTokenKey(l,Ce.ID_TOKEN,e);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching idToken schema with value containing idToken credentialType field but value failed IdTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed idToken validation on key: ${i}`);break;case Ce.ACCESS_TOKEN:case Ce.ACCESS_TOKEN_WITH_AUTH_SCHEME:if(Af(a)){this.logger.trace("BrowserCacheManager:createKeyMaps - accessToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - accessToken with key: ${i} found, saving key to token key map`);const c=a,l=this.updateCredentialCacheKey(i,c,e);this.addTokenKey(l,Ce.ACCESS_TOKEN,e);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching accessToken schema with value containing accessToken credentialType field but value failed AccessTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed accessToken validation on key: ${i}`);break;case Ce.REFRESH_TOKEN:if(Ef(a)){this.logger.trace("BrowserCacheManager:createKeyMaps - refreshToken found, saving key to token key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - refreshToken with key: ${i} found, saving key to token key map`);const c=a,l=this.updateCredentialCacheKey(i,c,e);this.addTokenKey(l,Ce.REFRESH_TOKEN,e);return}else this.logger.trace("BrowserCacheManager:createKeyMaps - key found matching refreshToken schema with value containing refreshToken credentialType field but value failed RefreshTokenEntity validation, skipping."),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - failed refreshToken validation on key: ${i}`);break}}}if(this.isAccountKey(i)){const s=this.getItem(i);if(s){const a=this.validateAndParseJson(s);a&&dt.isAccountEntity(a)&&(this.logger.trace("BrowserCacheManager:createKeyMaps - account found, saving key to account key map"),this.logger.tracePii(`BrowserCacheManager:createKeyMaps - account with key: ${i} found, saving key to account key map`),this.addAccountKeyToMap(i,e))}}})}validateAndParseJson(e){try{const n=JSON.parse(e);return n&&typeof n=="object"?n:null}catch{return null}}getItem(e){return this.browserStorage.getItem(e)}setItem(e,n,r){let o=[];for(let s=0;s<=20;s++)try{this.browserStorage.setItem(e,n),s>0&&this.removeAccessTokenKeys(o.slice(0,s),r);break}catch(a){const c=Oy(a);if(c.errorCode===Zu&&s<20){if(o.length||(e===`${on.TOKEN_KEYS}.${this.clientId}`?o=JSON.parse(n).accessToken:o=this.getTokenKeys().accessToken),o.length<=s)throw c;this.removeAccessToken(o[s],r,!1)}else throw c}}getAccount(e,n,r){this.logger.trace("BrowserCacheManager.getAccount called");const o=this.getCachedAccountEntity(e,n);return this.updateOutdatedCachedAccount(e,o,n,r)}getCachedAccountEntity(e,n){const r=this.getItem(e);if(!r)return this.removeAccountKeyFromMap(e,n),null;const o=this.validateAndParseJson(r);return!o||!dt.isAccountEntity(o)?null:ui.toObject(new dt,o)}setAccount(e,n){this.logger.trace("BrowserCacheManager.setAccount called");const r=e.generateAccountKey();e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addAccountKeyToMap(r,n)}getAccountKeys(){this.logger.trace("BrowserCacheManager.getAccountKeys called");const e=this.getItem(on.ACCOUNT_KEYS);return e?JSON.parse(e):(this.logger.verbose("BrowserCacheManager.getAccountKeys - No account keys found"),[])}addAccountKeyToMap(e,n){this.logger.trace("BrowserCacheManager.addAccountKeyToMap called"),this.logger.tracePii(`BrowserCacheManager.addAccountKeyToMap called with key: ${e}`);const r=this.getAccountKeys();r.indexOf(e)===-1?(r.push(e),this.setItem(on.ACCOUNT_KEYS,JSON.stringify(r),n),this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key added")):this.logger.verbose("BrowserCacheManager.addAccountKeyToMap account key already exists in map")}removeAccountKeyFromMap(e,n){this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap called"),this.logger.tracePii(`BrowserCacheManager.removeAccountKeyFromMap called with key: ${e}`);const r=this.getAccountKeys(),o=r.indexOf(e);if(o>-1){if(r.splice(o,1),r.length===0){this.removeItem(on.ACCOUNT_KEYS);return}else this.setItem(on.ACCOUNT_KEYS,JSON.stringify(r),n);this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap account key removed")}else this.logger.trace("BrowserCacheManager.removeAccountKeyFromMap key not found in existing map")}async removeAccount(e,n){super.removeAccount(e,n),this.removeAccountKeyFromMap(e,n)}removeOutdatedAccount(e,n){this.removeItem(e),this.removeAccountKeyFromMap(e,n)}removeIdToken(e,n){super.removeIdToken(e,n),this.removeTokenKey(e,Ce.ID_TOKEN,n)}removeAccessToken(e,n,r=!0){var o;super.removeAccessToken(e,n),(o=this.performanceClient)==null||o.incrementFields({accessTokensRemoved:1},n),r&&this.removeTokenKey(e,Ce.ACCESS_TOKEN,n)}removeAccessTokenKeys(e,n){this.logger.trace("removeAccessTokenKey called");const r=this.getTokenKeys();let o=0;if(e.forEach(i=>{const s=r.accessToken.indexOf(i);s>-1&&(r.accessToken.splice(s,1),o++)}),o>0){this.logger.info(`removed ${o} accessToken keys from tokenKeys map`),this.setTokenKeys(r,n);return}}removeRefreshToken(e,n){super.removeRefreshToken(e,n),this.removeTokenKey(e,Ce.REFRESH_TOKEN,n)}getTokenKeys(){this.logger.trace("BrowserCacheManager.getTokenKeys called");const e=this.getItem(`${on.TOKEN_KEYS}.${this.clientId}`);if(e){const n=this.validateAndParseJson(e);if(n&&n.hasOwnProperty("idToken")&&n.hasOwnProperty("accessToken")&&n.hasOwnProperty("refreshToken"))return n;this.logger.error("BrowserCacheManager.getTokenKeys - Token keys found but in an unknown format. Returning empty key map.")}else this.logger.verbose("BrowserCacheManager.getTokenKeys - No token keys found");return{idToken:[],accessToken:[],refreshToken:[]}}setTokenKeys(e,n){if(e.idToken.length===0&&e.accessToken.length===0&&e.refreshToken.length===0){this.removeItem(`${on.TOKEN_KEYS}.${this.clientId}`);return}else this.setItem(`${on.TOKEN_KEYS}.${this.clientId}`,JSON.stringify(e),n)}addTokenKey(e,n,r){this.logger.trace("BrowserCacheManager addTokenKey called");const o=this.getTokenKeys();switch(n){case Ce.ID_TOKEN:o.idToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - idToken added to map"),o.idToken.push(e));break;case Ce.ACCESS_TOKEN:const i=o.accessToken.indexOf(e);i!==-1&&o.accessToken.splice(i,1),this.logger.trace(`access token ${i===-1?"added to":"updated in"} map`),o.accessToken.push(e);break;case Ce.REFRESH_TOKEN:o.refreshToken.indexOf(e)===-1&&(this.logger.info("BrowserCacheManager: addTokenKey - refreshToken added to map"),o.refreshToken.push(e));break;default:throw this.logger.error(`BrowserCacheManager:addTokenKey - CredentialType provided invalid. CredentialType: ${n}`),j(Ll)}this.setTokenKeys(o,r)}removeTokenKey(e,n,r,o=this.getTokenKeys()){switch(this.logger.trace("BrowserCacheManager removeTokenKey called"),n){case Ce.ID_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove idToken with key: ${e} from map`);const i=o.idToken.indexOf(e);i>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - idToken removed from map"),o.idToken.splice(i,1)):this.logger.info("BrowserCacheManager: removeTokenKey - idToken does not exist in map. Either it was previously removed or it was never added.");break;case Ce.ACCESS_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove accessToken with key: ${e} from map`);const s=o.accessToken.indexOf(e);s>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - accessToken removed from map"),o.accessToken.splice(s,1)):this.logger.info("BrowserCacheManager: removeTokenKey - accessToken does not exist in map. Either it was previously removed or it was never added.");break;case Ce.REFRESH_TOKEN:this.logger.infoPii(`BrowserCacheManager: removeTokenKey - attempting to remove refreshToken with key: ${e} from map`);const a=o.refreshToken.indexOf(e);a>-1?(this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken removed from map"),o.refreshToken.splice(a,1)):this.logger.info("BrowserCacheManager: removeTokenKey - refreshToken does not exist in map. Either it was previously removed or it was never added.");break;default:throw this.logger.error(`BrowserCacheManager:removeTokenKey - CredentialType provided invalid. CredentialType: ${n}`),j(Ll)}this.setTokenKeys(o,r)}getIdTokenCredential(e,n){const r=this.getItem(e);if(!r)return this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),this.removeIdToken(e,n),null;const o=this.validateAndParseJson(r);return!o||!Tf(o)?(this.logger.trace("BrowserCacheManager.getIdTokenCredential: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getIdTokenCredential: cache hit"),o)}setIdTokenCredential(e,n){this.logger.trace("BrowserCacheManager.setIdTokenCredential called");const r=Bo(e);e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addTokenKey(r,Ce.ID_TOKEN,n)}getAccessTokenCredential(e,n){const r=this.getItem(e);if(!r)return this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),this.removeTokenKey(e,Ce.ACCESS_TOKEN,n),null;const o=this.validateAndParseJson(r);return!o||!Af(o)?(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getAccessTokenCredential: cache hit"),o)}setAccessTokenCredential(e,n){this.logger.trace("BrowserCacheManager.setAccessTokenCredential called");const r=Bo(e);e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addTokenKey(r,Ce.ACCESS_TOKEN,n)}getRefreshTokenCredential(e,n){const r=this.getItem(e);if(!r)return this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),this.removeTokenKey(e,Ce.REFRESH_TOKEN,n),null;const o=this.validateAndParseJson(r);return!o||!Ef(o)?(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getRefreshTokenCredential: cache hit"),o)}setRefreshTokenCredential(e,n){this.logger.trace("BrowserCacheManager.setRefreshTokenCredential called");const r=Bo(e);e.lastUpdatedAt=Date.now().toString(),this.setItem(r,JSON.stringify(e),n),this.addTokenKey(r,Ce.REFRESH_TOKEN,n)}getAppMetadata(e){const n=this.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null;const r=this.validateAndParseJson(n);return!r||!HR(e,r)?(this.logger.trace("BrowserCacheManager.getAppMetadata: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getAppMetadata: cache hit"),r)}setAppMetadata(e,n){this.logger.trace("BrowserCacheManager.setAppMetadata called");const r=UR(e);this.setItem(r,JSON.stringify(e),n)}getServerTelemetry(e){const n=this.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null;const r=this.validateAndParseJson(n);return!r||!DR(e,r)?(this.logger.trace("BrowserCacheManager.getServerTelemetry: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getServerTelemetry: cache hit"),r)}setServerTelemetry(e,n,r){this.logger.trace("BrowserCacheManager.setServerTelemetry called"),this.setItem(e,JSON.stringify(n),r)}getAuthorityMetadata(e){const n=this.internalStorage.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getAuthorityMetadata: called, no cache hit"),null;const r=this.validateAndParseJson(n);return r&&BR(e,r)?(this.logger.trace("BrowserCacheManager.getAuthorityMetadata: cache hit"),r):null}getAuthorityMetadataKeys(){return this.internalStorage.getKeys().filter(n=>this.isAuthorityMetadata(n))}setWrapperMetadata(e,n){this.internalStorage.setItem(Fs.WRAPPER_SKU,e),this.internalStorage.setItem(Fs.WRAPPER_VER,n)}getWrapperMetadata(){const e=this.internalStorage.getItem(Fs.WRAPPER_SKU)||P.EMPTY_STRING,n=this.internalStorage.getItem(Fs.WRAPPER_VER)||P.EMPTY_STRING;return[e,n]}setAuthorityMetadata(e,n){this.logger.trace("BrowserCacheManager.setAuthorityMetadata called"),this.internalStorage.setItem(e,JSON.stringify(n))}getActiveAccount(e){const n=this.generateCacheKey(ft.ACTIVE_ACCOUNT_FILTERS),r=this.getItem(n);if(!r){this.logger.trace("BrowserCacheManager.getActiveAccount: No active account filters cache schema found, looking for legacy schema");const i=this.generateCacheKey(ft.ACTIVE_ACCOUNT),s=this.getItem(i);if(!s)return this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null;const a=this.getAccountInfoFilteredBy({localAccountId:s},e);return a?(this.logger.trace("BrowserCacheManager.getActiveAccount: Legacy active account cache schema found"),this.logger.trace("BrowserCacheManager.getActiveAccount: Adding active account filters cache schema"),this.setActiveAccount(a,e),a):null}const o=this.validateAndParseJson(r);return o?(this.logger.trace("BrowserCacheManager.getActiveAccount: Active account filters schema found"),this.getAccountInfoFilteredBy({homeAccountId:o.homeAccountId,localAccountId:o.localAccountId,tenantId:o.tenantId},e)):(this.logger.trace("BrowserCacheManager.getActiveAccount: No active account found"),null)}setActiveAccount(e,n){const r=this.generateCacheKey(ft.ACTIVE_ACCOUNT_FILTERS),o=this.generateCacheKey(ft.ACTIVE_ACCOUNT);if(e){this.logger.verbose("setActiveAccount: Active account set");const i={homeAccountId:e.homeAccountId,localAccountId:e.localAccountId,tenantId:e.tenantId,lastUpdatedAt:Date.now().toString()};this.setItem(r,JSON.stringify(i),n),this.setItem(o,e.localAccountId,n)}else this.logger.verbose("setActiveAccount: No account passed, active account not set"),this.browserStorage.removeItem(r),this.browserStorage.removeItem(o)}getThrottlingCache(e){const n=this.getItem(e);if(!n)return this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null;const r=this.validateAndParseJson(n);return!r||!LR(e,r)?(this.logger.trace("BrowserCacheManager.getThrottlingCache: called, no cache hit"),null):(this.logger.trace("BrowserCacheManager.getThrottlingCache: cache hit"),r)}setThrottlingCache(e,n,r){this.logger.trace("BrowserCacheManager.setThrottlingCache called"),this.setItem(e,JSON.stringify(n),r)}getTemporaryCache(e,n){const r=n?this.generateCacheKey(e):e;if(this.cacheConfig.storeAuthStateInCookie){const i=this.cookieStorage.getItem(r);if(i)return this.logger.trace("BrowserCacheManager.getTemporaryCache: storeAuthStateInCookies set to true, retrieving from cookies"),i}const o=this.temporaryCacheStorage.getItem(r);if(!o){if(this.cacheConfig.cacheLocation===Bt.LocalStorage){const i=this.browserStorage.getItem(r);if(i)return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item found in local storage"),i}return this.logger.trace("BrowserCacheManager.getTemporaryCache: No cache item found in local storage"),null}return this.logger.trace("BrowserCacheManager.getTemporaryCache: Temporary cache item returned"),o}setTemporaryCache(e,n,r){const o=r?this.generateCacheKey(e):e;this.temporaryCacheStorage.setItem(o,n),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.setTemporaryCache: storeAuthStateInCookie set to true, setting item cookie"),this.cookieStorage.setItem(o,n,void 0,this.cacheConfig.secureCookies))}removeItem(e){this.browserStorage.removeItem(e)}removeTemporaryItem(e){this.temporaryCacheStorage.removeItem(e),this.cacheConfig.storeAuthStateInCookie&&(this.logger.trace("BrowserCacheManager.removeItem: storeAuthStateInCookie is true, clearing item cookie"),this.cookieStorage.removeItem(e))}getKeys(){return this.browserStorage.getKeys()}async clear(e){await this.removeAllAccounts(e),this.removeAppMetadata(e),this.temporaryCacheStorage.getKeys().forEach(n=>{(n.indexOf(P.CACHE_PREFIX)!==-1||n.indexOf(this.clientId)!==-1)&&this.removeTemporaryItem(n)}),this.browserStorage.getKeys().forEach(n=>{(n.indexOf(P.CACHE_PREFIX)!==-1||n.indexOf(this.clientId)!==-1)&&this.browserStorage.removeItem(n)}),this.internalStorage.clear()}async clearTokensAndKeysWithClaims(e,n){e.addQueueMeasurement(_.ClearTokensAndKeysWithClaims,n);const r=this.getTokenKeys();let o=0;r.accessToken.forEach(i=>{const s=this.getAccessTokenCredential(i,n);s!=null&&s.requestedClaimsHash&&i.includes(s.requestedClaimsHash.toLowerCase())&&(this.removeAccessToken(i,n),o++)}),o>0&&this.logger.warning(`${o} access tokens with claims in the cache keys have been removed from the cache.`)}generateCacheKey(e){return this.validateAndParseJson(e)?JSON.stringify(e):pn.startsWith(e,P.CACHE_PREFIX)||pn.startsWith(e,ft.ADAL_ID_TOKEN)?e:`${P.CACHE_PREFIX}.${this.clientId}.${e}`}generateAuthorityKey(e){const{libraryState:{id:n}}=gn.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Be.AUTHORITY}.${n}`)}generateNonceKey(e){const{libraryState:{id:n}}=gn.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Be.NONCE_IDTOKEN}.${n}`)}generateStateKey(e){const{libraryState:{id:n}}=gn.parseRequestState(this.cryptoImpl,e);return this.generateCacheKey(`${Be.REQUEST_STATE}.${n}`)}getCachedAuthority(e){const n=this.generateStateKey(e),r=this.getTemporaryCache(n);if(!r)return null;const o=this.generateAuthorityKey(r);return this.getTemporaryCache(o)}updateCacheEntries(e,n,r,o,i){this.logger.trace("BrowserCacheManager.updateCacheEntries called");const s=this.generateStateKey(e);this.setTemporaryCache(s,e,!1);const a=this.generateNonceKey(e);this.setTemporaryCache(a,n,!1);const c=this.generateAuthorityKey(e);if(this.setTemporaryCache(c,r,!1),i){const l={credential:i.homeAccountId,type:Jt.HOME_ACCOUNT_ID};this.setTemporaryCache(Be.CCS_CREDENTIAL,JSON.stringify(l),!0)}else if(o){const l={credential:o,type:Jt.UPN};this.setTemporaryCache(Be.CCS_CREDENTIAL,JSON.stringify(l),!0)}}resetRequestCache(e){this.logger.trace("BrowserCacheManager.resetRequestCache called"),e&&(this.temporaryCacheStorage.getKeys().forEach(n=>{n.indexOf(e)!==-1&&this.removeTemporaryItem(n)}),this.removeTemporaryItem(this.generateStateKey(e)),this.removeTemporaryItem(this.generateNonceKey(e)),this.removeTemporaryItem(this.generateAuthorityKey(e))),this.removeTemporaryItem(this.generateCacheKey(Be.REQUEST_PARAMS)),this.removeTemporaryItem(this.generateCacheKey(Be.ORIGIN_URI)),this.removeTemporaryItem(this.generateCacheKey(Be.URL_HASH)),this.removeTemporaryItem(this.generateCacheKey(Be.CORRELATION_ID)),this.removeTemporaryItem(this.generateCacheKey(Be.CCS_CREDENTIAL)),this.removeTemporaryItem(this.generateCacheKey(Be.NATIVE_REQUEST)),this.setInteractionInProgress(!1)}cleanRequestByState(e){if(this.logger.trace("BrowserCacheManager.cleanRequestByState called"),e){const n=this.generateStateKey(e),r=this.temporaryCacheStorage.getItem(n);this.logger.infoPii(`BrowserCacheManager.cleanRequestByState: Removing temporary cache items for state: ${r}`),this.resetRequestCache(r||P.EMPTY_STRING)}}cleanRequestByInteractionType(e){this.logger.trace("BrowserCacheManager.cleanRequestByInteractionType called"),this.temporaryCacheStorage.getKeys().forEach(n=>{if(n.indexOf(Be.REQUEST_STATE)===-1)return;const r=this.temporaryCacheStorage.getItem(n);if(!r)return;const o=bv(this.cryptoImpl,r);o&&o.interactionType===e&&(this.logger.infoPii(`BrowserCacheManager.cleanRequestByInteractionType: Removing temporary cache items for state: ${r}`),this.resetRequestCache(r))}),this.setInteractionInProgress(!1)}cacheCodeRequest(e){this.logger.trace("BrowserCacheManager.cacheCodeRequest called");const n=hd(JSON.stringify(e));this.setTemporaryCache(Be.REQUEST_PARAMS,n,!0)}getCachedRequest(e){this.logger.trace("BrowserCacheManager.getCachedRequest called");const n=this.getTemporaryCache(Be.REQUEST_PARAMS,!0);if(!n)throw te(Xy);let r;try{r=JSON.parse($n(n))}catch(o){throw this.logger.errorPii(`Attempted to parse: ${n}`),this.logger.error(`Parsing cached token request threw with error: ${o}`),te(Zy)}if(this.removeTemporaryItem(this.generateCacheKey(Be.REQUEST_PARAMS)),!r.authority){const o=this.generateAuthorityKey(e),i=this.getTemporaryCache(o);if(!i)throw te(ld);r.authority=i}return r}getCachedNativeRequest(){this.logger.trace("BrowserCacheManager.getCachedNativeRequest called");const e=this.getTemporaryCache(Be.NATIVE_REQUEST,!0);if(!e)return this.logger.trace("BrowserCacheManager.getCachedNativeRequest: No cached native request found"),null;const n=this.validateAndParseJson(e);return n||(this.logger.error("BrowserCacheManager.getCachedNativeRequest: Unable to parse native request"),null)}isInteractionInProgress(e){const n=this.getInteractionInProgress();return e?n===this.clientId:!!n}getInteractionInProgress(){const e=`${P.CACHE_PREFIX}.${Be.INTERACTION_STATUS_KEY}`;return this.getTemporaryCache(e,!1)}setInteractionInProgress(e){const n=`${P.CACHE_PREFIX}.${Be.INTERACTION_STATUS_KEY}`;if(e){if(this.getInteractionInProgress())throw te(jy);this.setTemporaryCache(n,this.clientId,!1)}else!e&&this.getInteractionInProgress()===this.clientId&&this.removeTemporaryItem(n)}getLegacyLoginHint(){const e=this.getTemporaryCache(ft.ADAL_ID_TOKEN);e&&(this.browserStorage.removeItem(ft.ADAL_ID_TOKEN),this.logger.verbose("Cached ADAL id token retrieved."));const n=this.getTemporaryCache(ft.ID_TOKEN,!0);n&&(this.browserStorage.removeItem(this.generateCacheKey(ft.ID_TOKEN)),this.logger.verbose("Cached MSAL.js v1 id token retrieved"));const r=n||e;if(r){const o=bo(r,$n);if(o.preferred_username)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 preferred_username as loginHint"),o.preferred_username;if(o.upn)return this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, setting ADAL/MSAL v1 upn as loginHint"),o.upn;this.logger.verbose("No SSO params used and ADAL/MSAL v1 token retrieved, however, no account hint claim found. Enable preferred_username or upn id token claim to get SSO.")}return null}updateCredentialCacheKey(e,n,r){const o=Bo(n);if(e!==o){const i=this.getItem(e);if(i)return this.browserStorage.removeItem(e),this.setItem(o,i,r),this.logger.verbose(`Updated an outdated ${n.credentialType} cache key`),o;this.logger.error(`Attempted to update an outdated ${n.credentialType} cache key but no item matching the outdated key was found in storage`)}return e}async hydrateCache(e,n){var a,c,l;const r=sc((a=e.account)==null?void 0:a.homeAccountId,(c=e.account)==null?void 0:c.environment,e.idToken,this.clientId,e.tenantId);let o;n.claims&&(o=await this.cryptoImpl.hashString(n.claims));const i=ac((l=e.account)==null?void 0:l.homeAccountId,e.account.environment,e.accessToken,this.clientId,e.tenantId,e.scopes.join(" "),e.expiresOn?e.expiresOn.getTime()/1e3:0,e.extExpiresOn?e.extExpiresOn.getTime()/1e3:0,$n,void 0,e.tokenType,void 0,n.sshKid,n.claims,o),s={idToken:r,accessToken:i};return this.saveCacheRecord(s,e.correlationId)}async saveCacheRecord(e,n,r){try{await super.saveCacheRecord(e,n,r)}catch(o){if(o instanceof zo&&this.performanceClient&&n)try{const i=this.getTokenKeys();this.performanceClient.addFields({cacheRtCount:i.refreshToken.length,cacheIdCount:i.idToken.length,cacheAtCount:i.accessToken.length},n)}catch{}throw o}}}const Yk=(t,e)=>{const n={cacheLocation:Bt.MemoryStorage,temporaryCacheLocation:Bt.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};return new zl(t,n,fa,e)};/*! @azure/msal-browser v3.30.0 2025-08-05 */function Jk(t,e,n,r,o){return t.verbose("getAllAccounts called"),n?e.getAllAccounts(r,o):[]}function Xk(t,e,n,r){if(e.trace("getAccount called"),Object.keys(t).length===0)return e.warning("getAccount: No accountFilter provided"),null;const o=n.getAccountInfoFilteredBy(t,r);return o?(e.verbose("getAccount: Account matching provided filter found, returning"),o):(e.verbose("getAccount: No matching account found, returning null"),null)}function Zk(t,e,n,r){if(e.trace("getAccountByUsername called"),!t)return e.warning("getAccountByUsername: No username provided"),null;const o=n.getAccountInfoFilteredBy({username:t},r);return o?(e.verbose("getAccountByUsername: Account matching username found, returning"),e.verbosePii(`getAccountByUsername: Returning signed-in accounts matching username: ${t}`),o):(e.verbose("getAccountByUsername: No matching account found, returning null"),null)}function eP(t,e,n,r){if(e.trace("getAccountByHomeId called"),!t)return e.warning("getAccountByHomeId: No homeAccountId provided"),null;const o=n.getAccountInfoFilteredBy({homeAccountId:t},r);return o?(e.verbose("getAccountByHomeId: Account matching homeAccountId found, returning"),e.verbosePii(`getAccountByHomeId: Returning signed-in accounts matching homeAccountId: ${t}`),o):(e.verbose("getAccountByHomeId: No matching account found, returning null"),null)}function tP(t,e,n,r){if(e.trace("getAccountByLocalId called"),!t)return e.warning("getAccountByLocalId: No localAccountId provided"),null;const o=n.getAccountInfoFilteredBy({localAccountId:t},r);return o?(e.verbose("getAccountByLocalId: Account matching localAccountId found, returning"),e.verbosePii(`getAccountByLocalId: Returning signed-in accounts matching localAccountId: ${t}`),o):(e.verbose("getAccountByLocalId: No matching account found, returning null"),null)}function nP(t,e,n){e.setActiveAccount(t,n)}function rP(t,e){return t.getActiveAccount(e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */const me={INITIALIZE_START:"msal:initializeStart",INITIALIZE_END:"msal:initializeEnd",ACCOUNT_ADDED:"msal:accountAdded",ACCOUNT_REMOVED:"msal:accountRemoved",ACTIVE_ACCOUNT_CHANGED:"msal:activeAccountChanged",LOGIN_START:"msal:loginStart",LOGIN_SUCCESS:"msal:loginSuccess",LOGIN_FAILURE:"msal:loginFailure",ACQUIRE_TOKEN_START:"msal:acquireTokenStart",ACQUIRE_TOKEN_SUCCESS:"msal:acquireTokenSuccess",ACQUIRE_TOKEN_FAILURE:"msal:acquireTokenFailure",ACQUIRE_TOKEN_NETWORK_START:"msal:acquireTokenFromNetworkStart",SSO_SILENT_START:"msal:ssoSilentStart",SSO_SILENT_SUCCESS:"msal:ssoSilentSuccess",SSO_SILENT_FAILURE:"msal:ssoSilentFailure",ACQUIRE_TOKEN_BY_CODE_START:"msal:acquireTokenByCodeStart",ACQUIRE_TOKEN_BY_CODE_SUCCESS:"msal:acquireTokenByCodeSuccess",ACQUIRE_TOKEN_BY_CODE_FAILURE:"msal:acquireTokenByCodeFailure",HANDLE_REDIRECT_START:"msal:handleRedirectStart",HANDLE_REDIRECT_END:"msal:handleRedirectEnd",POPUP_OPENED:"msal:popupOpened",LOGOUT_START:"msal:logoutStart",LOGOUT_SUCCESS:"msal:logoutSuccess",LOGOUT_FAILURE:"msal:logoutFailure",LOGOUT_END:"msal:logoutEnd",RESTORE_FROM_BFCACHE:"msal:restoreFromBFCache"};/*! @azure/msal-browser v3.30.0 2025-08-05 */class oP{constructor(e){this.eventCallbacks=new Map,this.logger=e||new Kr({})}addEventCallback(e,n,r){if(typeof window<"u"){const o=r||Dk();return this.eventCallbacks.has(o)?(this.logger.error(`Event callback with id: ${o} is already registered. Please provide a unique id or remove the existing callback and try again.`),null):(this.eventCallbacks.set(o,[e,n||[]]),this.logger.verbose(`Event callback registered with id: ${o}`),o)}return null}removeEventCallback(e){this.eventCallbacks.delete(e),this.logger.verbose(`Event callback ${e} removed.`)}emitEvent(e,n,r,o){if(typeof window<"u"){const i={eventType:e,interactionType:n||null,payload:r||null,error:o||null,timestamp:Date.now()};this.eventCallbacks.forEach(([s,a],c)=>{(a.length===0||a.includes(e))&&(this.logger.verbose(`Emitting event to callback ${c}: ${e}`),s.apply(null,[i]))})}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class _v{constructor(e,n,r,o,i,s,a,c,l){this.config=e,this.browserStorage=n,this.browserCrypto=r,this.networkClient=this.config.system.networkClient,this.eventHandler=i,this.navigationClient=s,this.nativeMessageHandler=c,this.correlationId=l||jn(),this.logger=o.clone(Qt.MSAL_SKU,hi,this.correlationId),this.performanceClient=a}async clearCacheOnLogout(e){if(e){dt.accountInfoIsEqual(e,this.browserStorage.getActiveAccount(this.correlationId),!1)&&(this.logger.verbose("Setting active account to null"),this.browserStorage.setActiveAccount(null,this.correlationId));try{await this.browserStorage.removeAccount(dt.generateAccountCacheKey(e),this.correlationId),this.logger.verbose("Cleared cache items belonging to the account provided in the logout request.")}catch{this.logger.error("Account provided in logout request was not found. Local cache unchanged.")}}else try{this.logger.verbose("No account provided in logout request, clearing all cache items.",this.correlationId),await this.browserStorage.clear(this.correlationId),await this.browserCrypto.clearKeystore()}catch{this.logger.error("Attempted to clear all MSAL cache items and failed. Local cache unchanged.")}}getRedirectUri(e){this.logger.verbose("getRedirectUri called");const n=e||this.config.auth.redirectUri;return Oe.getAbsoluteUrl(n,ir())}initializeServerTelemetryManager(e,n){this.logger.verbose("initializeServerTelemetryManager called");const r={clientId:this.config.auth.clientId,correlationId:this.correlationId,apiId:e,forceRefresh:n||!1,wrapperSKU:this.browserStorage.getWrapperMetadata()[0],wrapperVer:this.browserStorage.getWrapperMetadata()[1]};return new es(r,this.browserStorage)}async getDiscoveredAuthority(e){const{account:n}=e,r=e.requestExtraQueryParameters&&e.requestExtraQueryParameters.hasOwnProperty("instance_aware")?e.requestExtraQueryParameters.instance_aware:void 0;this.performanceClient.addQueueMeasurement(_.StandardInteractionClientGetDiscoveredAuthority,this.correlationId);const o={protocolMode:this.config.auth.protocolMode,OIDCOptions:this.config.auth.OIDCOptions,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},i=e.requestAuthority||this.config.auth.authority,s=r!=null&&r.length?r==="true":this.config.auth.instanceAware,a=n&&s?this.config.auth.authority.replace(Oe.getDomainFromUrl(i),n.environment):i,c=bt.generateAuthority(a,e.requestAzureCloudOptions||this.config.auth.azureCloudOptions),l=await G(xy,_.AuthorityFactoryCreateDiscoveredInstance,this.logger,this.performanceClient,this.correlationId)(c,this.config.system.networkClient,this.browserStorage,o,this.logger,this.correlationId,this.performanceClient);if(n&&!l.isAlias(n.environment))throw $e(by);return l}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const iP=32;async function sP(t,e,n){t.addQueueMeasurement(_.GeneratePkceCodes,n);const r=_o(aP,_.GenerateCodeVerifier,e,t,n)(t,e,n),o=await G(cP,_.GenerateCodeChallengeFromVerifier,e,t,n)(r,t,e,n);return{verifier:r,challenge:o}}function aP(t,e,n){try{const r=new Uint8Array(iP);return _o(Tk,_.GetRandomValues,e,t,n)(r),gc(r)}catch{throw te(ad)}}async function cP(t,e,n,r){e.addQueueMeasurement(_.GenerateCodeChallengeFromVerifier,r);try{const o=await G(vv,_.Sha256Digest,n,e,r)(t,e,r);return gc(new Uint8Array(o))}catch{throw te(ad)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */async function wd(t,e,n,r){n.addQueueMeasurement(_.InitializeBaseRequest,t.correlationId);const o=t.authority||e.auth.authority,i=[...t&&t.scopes||[]],s={...t,correlationId:t.correlationId,authority:o,scopes:i};if(!s.authenticationScheme)s.authenticationScheme=Fe.BEARER,r.verbose(`Authentication Scheme wasn't explicitly set in request, defaulting to "Bearer" request`);else{if(s.authenticationScheme===Fe.SSH){if(!t.sshJwk)throw $e(cc);if(!t.sshKid)throw $e(Ay)}r.verbose(`Authentication Scheme set to "${s.authenticationScheme}" as configured in Auth request`)}return e.cache.claimsBasedCachingEnabled&&t.claims&&!pn.isEmptyObj(t.claims)&&(s.requestedClaimsHash=await Cv(t.claims)),s}async function lP(t,e,n,r,o){r.addQueueMeasurement(_.InitializeSilentRequest,t.correlationId);const i=await G(wd,_.InitializeBaseRequest,o,r,t.correlationId)(t,n,r,o);return{...t,...i,account:e,forceRefresh:t.forceRefresh||!1}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class yi extends _v{async initializeAuthorizationCodeRequest(e){this.performanceClient.addQueueMeasurement(_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.correlationId);const n=await G(sP,_.GeneratePkceCodes,this.logger,this.performanceClient,this.correlationId)(this.performanceClient,this.logger,this.correlationId),r={...e,redirectUri:e.redirectUri,code:P.EMPTY_STRING,codeVerifier:n.verifier};return e.codeChallenge=n.challenge,e.codeChallengeMethod=P.S256_CODE_CHALLENGE_METHOD,r}initializeLogoutRequest(e){this.logger.verbose("initializeLogoutRequest called",e==null?void 0:e.correlationId);const n={correlationId:this.correlationId||jn(),...e};if(e)if(e.logoutHint)this.logger.verbose("logoutHint has already been set in logoutRequest");else if(e.account){const r=this.getLogoutHintFromIdTokenClaims(e.account);r&&(this.logger.verbose("Setting logoutHint to login_hint ID Token Claim value for the account provided"),n.logoutHint=r)}else this.logger.verbose("logoutHint was not set and account was not passed into logout request, logoutHint will not be set");else this.logger.verbose("logoutHint will not be set since no logout request was configured");return!e||e.postLogoutRedirectUri!==null?e&&e.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to uri set on logout request",n.correlationId),n.postLogoutRedirectUri=Oe.getAbsoluteUrl(e.postLogoutRedirectUri,ir())):this.config.auth.postLogoutRedirectUri===null?this.logger.verbose("postLogoutRedirectUri configured as null and no uri set on request, not passing post logout redirect",n.correlationId):this.config.auth.postLogoutRedirectUri?(this.logger.verbose("Setting postLogoutRedirectUri to configured uri",n.correlationId),n.postLogoutRedirectUri=Oe.getAbsoluteUrl(this.config.auth.postLogoutRedirectUri,ir())):(this.logger.verbose("Setting postLogoutRedirectUri to current page",n.correlationId),n.postLogoutRedirectUri=Oe.getAbsoluteUrl(ir(),ir())):this.logger.verbose("postLogoutRedirectUri passed as null, not setting post logout redirect uri",n.correlationId),n}getLogoutHintFromIdTokenClaims(e){const n=e.idTokenClaims;if(n){if(n.login_hint)return n.login_hint;this.logger.verbose("The ID Token Claims tied to the provided account do not contain a login_hint claim, logoutHint will not be added to logout request")}else this.logger.verbose("The provided account does not contain ID Token Claims, logoutHint will not be added to logout request");return null}async createAuthCodeClient(e){this.performanceClient.addQueueMeasurement(_.StandardInteractionClientCreateAuthCodeClient,this.correlationId);const n=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)(e);return new Ly(n,this.performanceClient)}async getClientConfiguration(e){const{serverTelemetryManager:n,requestAuthority:r,requestAzureCloudOptions:o,requestExtraQueryParameters:i,account:s}=e;this.performanceClient.addQueueMeasurement(_.StandardInteractionClientGetClientConfiguration,this.correlationId);const a=await G(this.getDiscoveredAuthority.bind(this),_.StandardInteractionClientGetDiscoveredAuthority,this.logger,this.performanceClient,this.correlationId)({requestAuthority:r,requestAzureCloudOptions:o,requestExtraQueryParameters:i,account:s}),c=this.config.system.loggerOptions;return{authOptions:{clientId:this.config.auth.clientId,authority:a,clientCapabilities:this.config.auth.clientCapabilities,redirectUri:this.config.auth.redirectUri},systemOptions:{tokenRenewalOffsetSeconds:this.config.system.tokenRenewalOffsetSeconds,preventCorsPreflight:!0},loggerOptions:{loggerCallback:c.loggerCallback,piiLoggingEnabled:c.piiLoggingEnabled,logLevel:c.logLevel,correlationId:this.correlationId},cacheOptions:{claimsBasedCachingEnabled:this.config.cache.claimsBasedCachingEnabled},cryptoInterface:this.browserCrypto,networkInterface:this.networkClient,storageInterface:this.browserStorage,serverTelemetryManager:n,libraryInfo:{sku:Qt.MSAL_SKU,version:hi,cpu:P.EMPTY_STRING,os:P.EMPTY_STRING},telemetry:this.config.telemetry}}async initializeAuthorizationRequest(e,n){this.performanceClient.addQueueMeasurement(_.StandardInteractionClientInitializeAuthorizationRequest,this.correlationId);const r=this.getRedirectUri(e.redirectUri),o={interactionType:n},i=gn.setRequestState(this.browserCrypto,e&&e.state||P.EMPTY_STRING,o),a={...await G(wd,_.InitializeBaseRequest,this.logger,this.performanceClient,this.correlationId)({...e,correlationId:this.correlationId},this.config,this.performanceClient,this.logger),redirectUri:r,state:i,nonce:e.nonce||jn(),responseMode:this.config.auth.OIDCOptions.serverResponseType};if(e.loginHint||e.sid)return a;const c=e.account||this.browserStorage.getActiveAccount(this.correlationId);if(c&&(this.logger.verbose("Setting validated request account",this.correlationId),this.logger.verbosePii(`Setting validated request account: ${c.homeAccountId}`,this.correlationId),a.account=c),!a.loginHint&&!c){const l=this.browserStorage.getLegacyLoginHint();l&&(a.loginHint=l)}return a}}/*! @azure/msal-browser v3.30.0 2025-08-05 */const uP="ContentError",Sv="user_switch";/*! @azure/msal-browser v3.30.0 2025-08-05 */const dP="USER_INTERACTION_REQUIRED",hP="USER_CANCEL",fP="NO_NETWORK",pP="PERSISTENT_ERROR",gP="DISABLED",mP="ACCOUNT_UNAVAILABLE";/*! @azure/msal-browser v3.30.0 2025-08-05 */const yP=-2147186943,vP={[Sv]:"User attempted to switch accounts in the native broker, which is not allowed. All new accounts must sign-in through the standard web flow first, please try again."};class Ln extends We{constructor(e,n,r){super(e,n),Object.setPrototypeOf(this,Ln.prototype),this.name="NativeAuthError",this.ext=r}}function Uo(t){if(t.ext&&t.ext.status&&(t.ext.status===pP||t.ext.status===gP)||t.ext&&t.ext.error&&t.ext.error===yP)return!0;switch(t.errorCode){case uP:return!0;default:return!1}}function Wl(t,e,n){if(n&&n.status)switch(n.status){case mP:return Fl(My);case dP:return new En(t,e);case hP:return te(wo);case fP:return te(Ca)}return new Ln(t,vP[t]||e,n)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Iv extends yi{async acquireToken(e){this.performanceClient.addQueueMeasurement(_.SilentCacheClientAcquireToken,e.correlationId);const n=this.initializeServerTelemetryManager(ze.acquireTokenSilent_silentFlow),r=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:n,requestAuthority:e.authority,requestAzureCloudOptions:e.azureCloudOptions,account:e.account}),o=new ek(r,this.performanceClient);this.logger.verbose("Silent auth client created");try{const s=(await G(o.acquireCachedToken.bind(o),_.SilentFlowClientAcquireCachedToken,this.logger,this.performanceClient,e.correlationId)(e))[0];return this.performanceClient.addFields({fromCache:!0},e.correlationId),s}catch(i){throw i instanceof Ts&&i.errorCode===ud&&this.logger.verbose("Signing keypair for bound access token not found. Refreshing bound access token and generating a new crypto keypair."),i}}logout(e){this.logger.verbose("logoutRedirect called");const n=this.initializeLogoutRequest(e);return this.clearCacheOnLogout(n==null?void 0:n.account)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Wo extends _v{constructor(e,n,r,o,i,s,a,c,l,u,d,h){var p;super(e,n,r,o,i,s,c,l,h),this.apiId=a,this.accountId=u,this.nativeMessageHandler=l,this.nativeStorageManager=d,this.silentCacheClient=new Iv(e,this.nativeStorageManager,r,o,i,s,c,l,h),this.serverTelemetryManager=this.initializeServerTelemetryManager(this.apiId);const f=this.nativeMessageHandler.getExtensionId()===Ko.PREFERRED_EXTENSION_ID?"chrome":(p=this.nativeMessageHandler.getExtensionId())!=null&&p.length?"unknown":void 0;this.skus=es.makeExtraSkuString({libraryName:Qt.MSAL_SKU,libraryVersion:hi,extensionName:f,extensionVersion:this.nativeMessageHandler.getExtensionVersion()})}addRequestSKUs(e){e.extraParameters={...e.extraParameters,[UO]:this.skus}}async acquireToken(e){this.performanceClient.addQueueMeasurement(_.NativeInteractionClientAcquireToken,e.correlationId),this.logger.trace("NativeInteractionClient - acquireToken called.");const n=this.performanceClient.startMeasurement(_.NativeInteractionClientAcquireToken,e.correlationId),r=qn();try{const o=await this.initializeNativeRequest(e);try{const l=await this.acquireTokensFromCache(this.accountId,o);return n.end({success:!0,isNativeBroker:!1,fromCache:!0}),l}catch{this.logger.info("MSAL internal Cache does not contain tokens, proceed to make a native call")}const{...i}=o,s={method:ro.GetToken,request:i},a=await this.nativeMessageHandler.sendMessage(s),c=this.validateNativeResponse(a);return await this.handleNativeResponse(c,o,r).then(l=>(n.end({success:!0,isNativeBroker:!0,requestId:l.requestId}),this.serverTelemetryManager.clearNativeBrokerErrorCode(),l)).catch(l=>{throw n.end({success:!1,errorCode:l.errorCode,subErrorCode:l.subError,isNativeBroker:!0}),l})}catch(o){throw o instanceof Ln&&this.serverTelemetryManager.setNativeBrokerErrorCode(o.errorCode),o}}createSilentCacheRequest(e,n){return{authority:e.authority,correlationId:this.correlationId,scopes:rt.fromString(e.scope).asArray(),account:n,forceRefresh:!1}}async acquireTokensFromCache(e,n){if(!e)throw this.logger.warning("NativeInteractionClient:acquireTokensFromCache - No nativeAccountId provided"),j(Ml);const r=this.browserStorage.getBaseAccountInfo({nativeAccountId:e},n.correlationId);if(!r)throw j(Ml);try{const o=this.createSilentCacheRequest(n,r),i=await this.silentCacheClient.acquireToken(o),s={...r,idTokenClaims:i==null?void 0:i.idTokenClaims,idToken:i==null?void 0:i.idToken};return{...i,account:s}}catch(o){throw o}}async acquireTokenRedirect(e,n){this.logger.trace("NativeInteractionClient - acquireTokenRedirect called.");const{...r}=e;delete r.onRedirectNavigate;const o=await this.initializeNativeRequest(r),i={method:ro.GetToken,request:o};try{const c=await this.nativeMessageHandler.sendMessage(i);this.validateNativeResponse(c)}catch(c){if(c instanceof Ln&&(this.serverTelemetryManager.setNativeBrokerErrorCode(c.errorCode),Uo(c)))throw c}this.browserStorage.setTemporaryCache(Be.NATIVE_REQUEST,JSON.stringify(o),!0);const s={apiId:ze.acquireTokenRedirect,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},a=this.config.auth.navigateToLoginRequestUrl?window.location.href:this.getRedirectUri(e.redirectUri);n.end({success:!0}),await this.navigationClient.navigateExternal(a,s)}async handleRedirectPromise(e,n){if(this.logger.trace("NativeInteractionClient - handleRedirectPromise called."),!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const r=this.browserStorage.getCachedNativeRequest();if(!r)return this.logger.verbose("NativeInteractionClient - handleRedirectPromise called but there is no cached request, returning null."),e&&n&&(e==null||e.addFields({errorCode:"no_cached_request"},n)),null;const{prompt:o,...i}=r;o&&this.logger.verbose("NativeInteractionClient - handleRedirectPromise called and prompt was included in the original request, removing prompt from cached request to prevent second interaction with native broker window."),this.browserStorage.removeItem(this.browserStorage.generateCacheKey(Be.NATIVE_REQUEST));const s={method:ro.GetToken,request:i},a=qn();try{this.logger.verbose("NativeInteractionClient - handleRedirectPromise sending message to native broker.");const c=await this.nativeMessageHandler.sendMessage(s);this.validateNativeResponse(c);const l=this.handleNativeResponse(c,i,a);this.browserStorage.setInteractionInProgress(!1);const u=await l;return this.serverTelemetryManager.clearNativeBrokerErrorCode(),u}catch(c){throw this.browserStorage.setInteractionInProgress(!1),c}}logout(){return this.logger.trace("NativeInteractionClient - logout called."),Promise.reject("Logout not implemented yet")}async handleNativeResponse(e,n,r){var u;this.logger.trace("NativeInteractionClient - handleNativeResponse called.");const o=bo(e.id_token,$n),i=this.createHomeAccountIdentifier(e,o),s=(u=this.browserStorage.getAccountInfoFilteredBy({nativeAccountId:n.accountId},this.correlationId))==null?void 0:u.homeAccountId;if(i!==s&&e.account.id!==n.accountId)throw Wl(Sv);const a=await this.getDiscoveredAuthority({requestAuthority:n.authority}),c=od(this.browserStorage,a,i,$n,this.correlationId,o,e.client_info,void 0,o.tid,void 0,e.account.id,this.logger),l=await this.generateAuthenticationResult(e,n,o,c,a.canonicalAuthority,r);return this.cacheAccount(c),this.cacheNativeTokens(e,n,i,o,e.access_token,l.tenantId,r),l}createHomeAccountIdentifier(e,n){return dt.generateHomeAccountId(e.client_info||P.EMPTY_STRING,hn.Default,this.logger,this.browserCrypto,n)}generateScopes(e,n){return e.scope?rt.fromString(e.scope):rt.fromString(n.scope)}async generatePopAccessToken(e,n){if(n.tokenType===Fe.POP&&n.signPopToken){if(e.shr)return this.logger.trace("handleNativeServerResponse: SHR is enabled in native layer"),e.shr;const r=new di(this.browserCrypto),o={resourceRequestMethod:n.resourceRequestMethod,resourceRequestUri:n.resourceRequestUri,shrClaims:n.shrClaims,shrNonce:n.shrNonce};if(!n.keyId)throw j($u);return r.signPopToken(e.access_token,n.keyId,o)}else return e.access_token}async generateAuthenticationResult(e,n,r,o,i,s){const a=this.addTelemetryFromNativeResponse(e),c=e.scope?rt.fromString(e.scope):rt.fromString(n.scope),l=e.account.properties||{},u=l.UID||r.oid||r.sub||P.EMPTY_STRING,d=l.TenantId||r.tid||P.EMPTY_STRING,h=Ju(o.getAccountInfo(),void 0,r,e.id_token);h.nativeAccountId!==e.account.id&&(h.nativeAccountId=e.account.id);const f=await this.generatePopAccessToken(e,n),p=n.tokenType===Fe.POP?Fe.POP:Fe.BEARER;return{authority:i,uniqueId:u,tenantId:d,scopes:c.asArray(),account:h,idToken:e.id_token,idTokenClaims:r,accessToken:f,fromCache:a?this.isResponseFromCache(a):!1,expiresOn:new Date(Number(s+e.expires_in)*1e3),tokenType:p,correlationId:this.correlationId,state:e.state,fromNativeBroker:!0}}cacheAccount(e){this.browserStorage.setAccount(e,this.correlationId),this.browserStorage.removeAccountContext(e,this.correlationId).catch(n=>{this.logger.error(`Error occurred while removing account context from browser storage. ${n}`)})}cacheNativeTokens(e,n,r,o,i,s,a){const c=sc(r,n.authority,e.id_token||"",n.clientId,o.tid||""),l=n.tokenType===Fe.POP?P.SHR_NONCE_VALIDITY:(typeof e.expires_in=="string"?parseInt(e.expires_in,10):e.expires_in)||0,u=a+l,d=this.generateScopes(e,n),h=ac(r,n.authority,i,n.clientId,o.tid||s,d.printScopes(),u,0,$n,void 0,n.tokenType,void 0,n.keyId),f={idToken:c,accessToken:h};this.nativeStorageManager.saveCacheRecord(f,n.correlationId,n.storeInCache)}addTelemetryFromNativeResponse(e){const n=this.getMATSFromResponse(e);return n?(this.performanceClient.addFields({extensionId:this.nativeMessageHandler.getExtensionId(),extensionVersion:this.nativeMessageHandler.getExtensionVersion(),matsBrokerVersion:n.broker_version,matsAccountJoinOnStart:n.account_join_on_start,matsAccountJoinOnEnd:n.account_join_on_end,matsDeviceJoin:n.device_join,matsPromptBehavior:n.prompt_behavior,matsApiErrorCode:n.api_error_code,matsUiVisible:n.ui_visible,matsSilentCode:n.silent_code,matsSilentBiSubCode:n.silent_bi_sub_code,matsSilentMessage:n.silent_message,matsSilentStatus:n.silent_status,matsHttpStatus:n.http_status,matsHttpEventCount:n.http_event_count},this.correlationId),n):null}validateNativeResponse(e){if(e.hasOwnProperty("access_token")&&e.hasOwnProperty("id_token")&&e.hasOwnProperty("client_info")&&e.hasOwnProperty("account")&&e.hasOwnProperty("scope")&&e.hasOwnProperty("expires_in"))return e;throw Vm(Lu,"Response missing expected properties.")}getMATSFromResponse(e){if(e.properties.MATS)try{return JSON.parse(e.properties.MATS)}catch{this.logger.error("NativeInteractionClient - Error parsing MATS telemetry, returning null instead")}return null}isResponseFromCache(e){return typeof e.is_cached>"u"?(this.logger.verbose("NativeInteractionClient - MATS telemetry does not contain field indicating if response was served from cache. Returning false."),!1):!!e.is_cached}async initializeNativeRequest(e){this.logger.trace("NativeInteractionClient - initializeNativeRequest called");const n=e.authority||this.config.auth.authority;e.account&&await this.getDiscoveredAuthority({requestAuthority:n,requestAzureCloudOptions:e.azureCloudOptions,account:e.account});const r=new Oe(n);r.validateAsUri();const{scopes:o,...i}=e,s=new rt(o||[]);s.appendScopes(mi);const a=()=>{switch(this.apiId){case ze.ssoSilent:case ze.acquireTokenSilent_silentFlow:return this.logger.trace("initializeNativeRequest: silent request sets prompt to none"),gt.NONE}if(!e.prompt){this.logger.trace("initializeNativeRequest: prompt was not provided");return}switch(e.prompt){case gt.NONE:case gt.CONSENT:case gt.LOGIN:return this.logger.trace("initializeNativeRequest: prompt is compatible with native flow"),e.prompt;default:throw this.logger.trace(`initializeNativeRequest: prompt = ${e.prompt} is not compatible with native flow`),te(uv)}},c={...i,accountId:this.accountId,clientId:this.config.auth.clientId,authority:r.urlString,scope:s.printScopes(),redirectUri:this.getRedirectUri(e.redirectUri),prompt:a(),correlationId:this.correlationId,tokenType:e.authenticationScheme,windowTitleSubstring:document.title,extraParameters:{...e.extraQueryParameters,...e.tokenQueryParameters},extendedExpiryToken:!1,keyId:e.popKid};if(c.signPopToken&&e.popKid)throw te(hv);if(this.handleExtraBrokerParams(c),c.extraParameters=c.extraParameters||{},c.extraParameters.telemetry=Ko.MATS_TELEMETRY,e.authenticationScheme===Fe.POP){const l={resourceRequestUri:e.resourceRequestUri,resourceRequestMethod:e.resourceRequestMethod,shrClaims:e.shrClaims,shrNonce:e.shrNonce},u=new di(this.browserCrypto);let d;if(c.keyId)d=this.browserCrypto.base64UrlEncode(JSON.stringify({kid:c.keyId})),c.signPopToken=!1;else{const h=await G(u.generateCnf.bind(u),_.PopTokenGenerateCnf,this.logger,this.performanceClient,e.correlationId)(l,this.logger);d=h.reqCnfString,c.keyId=h.kid,c.signPopToken=!0}c.reqCnf=d}return this.addRequestSKUs(c),c}handleExtraBrokerParams(e){var i;const n=e.extraParameters&&e.extraParameters.hasOwnProperty(td)&&e.extraParameters.hasOwnProperty(Bl)&&e.extraParameters.hasOwnProperty(vo);if(!e.embeddedClientId&&!n)return;let r="";const o=e.redirectUri;e.embeddedClientId?(e.redirectUri=this.config.auth.redirectUri,r=e.embeddedClientId):e.extraParameters&&(e.redirectUri=e.extraParameters[Bl],r=e.extraParameters[vo]),e.extraParameters={child_client_id:r,child_redirect_uri:o},(i=this.performanceClient)==null||i.addFields({embeddedClientId:r,embeddedRedirectUri:o},e.correlationId)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Hn{constructor(e,n,r,o){this.logger=e,this.handshakeTimeoutMs=n,this.extensionId=o,this.resolvers=new Map,this.handshakeResolvers=new Map,this.messageChannel=new MessageChannel,this.windowListener=this.onWindowMessage.bind(this),this.performanceClient=r,this.handshakeEvent=r.startMeasurement(_.NativeMessageHandlerHandshake)}async sendMessage(e){this.logger.trace("NativeMessageHandler - sendMessage called.");const n={channel:Ko.CHANNEL_ID,extensionId:this.extensionId,responseId:jn(),body:e};return this.logger.trace("NativeMessageHandler - Sending request to browser extension"),this.logger.tracePii(`NativeMessageHandler - Sending request to browser extension: ${JSON.stringify(n)}`),this.messageChannel.port1.postMessage(n),new Promise((r,o)=>{this.resolvers.set(n.responseId,{resolve:r,reject:o})})}static async createProvider(e,n,r){e.trace("NativeMessageHandler - createProvider called.");try{const o=new Hn(e,n,r,Ko.PREFERRED_EXTENSION_ID);return await o.sendHandshakeRequest(),o}catch{const i=new Hn(e,n,r);return await i.sendHandshakeRequest(),i}}async sendHandshakeRequest(){this.logger.trace("NativeMessageHandler - sendHandshakeRequest called."),window.addEventListener("message",this.windowListener,!1);const e={channel:Ko.CHANNEL_ID,extensionId:this.extensionId,responseId:jn(),body:{method:ro.HandshakeRequest}};return this.handshakeEvent.add({extensionId:this.extensionId,extensionHandshakeTimeoutMs:this.handshakeTimeoutMs}),this.messageChannel.port1.onmessage=n=>{this.onChannelMessage(n)},window.postMessage(e,window.origin,[this.messageChannel.port2]),new Promise((n,r)=>{this.handshakeResolvers.set(e.responseId,{resolve:n,reject:r}),this.timeoutId=window.setTimeout(()=>{window.removeEventListener("message",this.windowListener,!1),this.messageChannel.port1.close(),this.messageChannel.port2.close(),this.handshakeEvent.end({extensionHandshakeTimedOut:!0,success:!1}),r(te(av)),this.handshakeResolvers.delete(e.responseId)},this.handshakeTimeoutMs)})}onWindowMessage(e){if(this.logger.trace("NativeMessageHandler - onWindowMessage called"),e.source!==window)return;const n=e.data;if(!(!n.channel||n.channel!==Ko.CHANNEL_ID)&&!(n.extensionId&&n.extensionId!==this.extensionId)&&n.body.method===ro.HandshakeRequest){const r=this.handshakeResolvers.get(n.responseId);if(!r){this.logger.trace(`NativeMessageHandler.onWindowMessage - resolver can't be found for request ${n.responseId}`);return}this.logger.verbose(n.extensionId?`Extension with id: ${n.extensionId} not installed`:"No extension installed"),clearTimeout(this.timeoutId),this.messageChannel.port1.close(),this.messageChannel.port2.close(),window.removeEventListener("message",this.windowListener,!1),this.handshakeEvent.end({success:!1,extensionInstalled:!1}),r.reject(te(cv))}}onChannelMessage(e){this.logger.trace("NativeMessageHandler - onChannelMessage called.");const n=e.data,r=this.resolvers.get(n.responseId),o=this.handshakeResolvers.get(n.responseId);try{const i=n.body.method;if(i===ro.Response){if(!r)return;const s=n.body.response;if(this.logger.trace("NativeMessageHandler - Received response from browser extension"),this.logger.tracePii(`NativeMessageHandler - Received response from browser extension: ${JSON.stringify(s)}`),s.status!=="Success")r.reject(Wl(s.code,s.description,s.ext));else if(s.result)s.result.code&&s.result.description?r.reject(Wl(s.result.code,s.result.description,s.result.ext)):r.resolve(s.result);else throw Vm(Lu,"Event does not contain result.");this.resolvers.delete(n.responseId)}else if(i===ro.HandshakeResponse){if(!o){this.logger.trace(`NativeMessageHandler.onChannelMessage - resolver can't be found for request ${n.responseId}`);return}clearTimeout(this.timeoutId),window.removeEventListener("message",this.windowListener,!1),this.extensionId=n.extensionId,this.extensionVersion=n.body.version,this.logger.verbose(`NativeMessageHandler - Received HandshakeResponse from extension: ${this.extensionId}`),this.handshakeEvent.end({extensionInstalled:!0,success:!0}),o.resolve(),this.handshakeResolvers.delete(n.responseId)}}catch(i){this.logger.error("Error parsing response from WAM Extension"),this.logger.errorPii(`Error parsing response from WAM Extension: ${i}`),this.logger.errorPii(`Unable to parse ${e}`),r?r.reject(i):o&&o.reject(i)}}getExtensionId(){return this.extensionId}getExtensionVersion(){return this.extensionVersion}static isNativeAvailable(e,n,r,o){if(n.trace("isNativeAvailable called"),!e.system.allowNativeBroker)return n.trace("isNativeAvailable: allowNativeBroker is not enabled, returning false"),!1;if(!r)return n.trace("isNativeAvailable: WAM extension provider is not initialized, returning false"),!1;if(o)switch(o){case Fe.BEARER:case Fe.POP:return n.trace("isNativeAvailable: authenticationScheme is supported, returning true"),!0;default:return n.trace("isNativeAvailable: authenticationScheme is not supported, returning false"),!1}return!0}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Ad{constructor(e,n,r,o,i){this.authModule=e,this.browserStorage=n,this.authCodeRequest=r,this.logger=o,this.performanceClient=i}async handleCodeResponse(e,n){this.performanceClient.addQueueMeasurement(_.HandleCodeResponse,n.correlationId);let r;try{r=this.authModule.handleFragmentResponse(e,n.state)}catch(o){throw o instanceof $r&&o.subError===wo?te(wo):o}return G(this.handleCodeResponseFromServer.bind(this),_.HandleCodeResponseFromServer,this.logger,this.performanceClient,n.correlationId)(r,n)}async handleCodeResponseFromServer(e,n,r=!0){if(this.performanceClient.addQueueMeasurement(_.HandleCodeResponseFromServer,n.correlationId),this.logger.trace("InteractionHandler.handleCodeResponseFromServer called"),this.authCodeRequest.code=e.code,e.cloud_instance_host_name&&await G(this.authModule.updateAuthority.bind(this.authModule),_.UpdateTokenEndpointAuthority,this.logger,this.performanceClient,n.correlationId)(e.cloud_instance_host_name,n.correlationId),r&&(e.nonce=n.nonce||void 0),e.state=n.state,e.client_info)this.authCodeRequest.clientInfo=e.client_info;else{const i=this.createCcsCredentials(n);i&&(this.authCodeRequest.ccsCredential=i)}return await G(this.authModule.acquireToken.bind(this.authModule),_.AuthClientAcquireToken,this.logger,this.performanceClient,n.correlationId)(this.authCodeRequest,e)}createCcsCredentials(e){return e.account?{credential:e.account.homeAccountId,type:Jt.HOME_ACCOUNT_ID}:e.loginHint?{credential:e.loginHint,type:Jt.UPN}:null}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function Rv(t,e,n){const r=ma(t);if(!r)throw Sy(t)?(n.error(`A ${e} is present in the iframe but it does not contain known properties. It's likely that the ${e} has been replaced by code running on the redirectUri page.`),n.errorPii(`The ${e} detected is: ${t}`),te(Ky)):(n.error(`The request has returned to the redirectUri but a ${e} is not present. It's likely that the ${e} has been removed or the page has been redirected by code running on the redirectUri page.`),te(Fy));return r}function CP(t,e,n){if(!t.state)throw te(cd);const r=bv(e,t.state);if(!r)throw te($y);if(r.interactionType!==n)throw te(qy)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class wP extends yi{constructor(e,n,r,o,i,s,a,c,l,u){super(e,n,r,o,i,s,a,l,u),this.unloadWindow=this.unloadWindow.bind(this),this.nativeStorage=c}acquireToken(e){try{const r={popupName:this.generatePopupName(e.scopes||mi,e.authority||this.config.auth.authority),popupWindowAttributes:e.popupWindowAttributes||{},popupWindowParent:e.popupWindowParent??window};return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true, acquiring token"),this.acquireTokenPopupAsync(e,r)):(this.logger.verbose("asyncPopup set to false, opening popup before acquiring token"),r.popup=this.openSizedPopup("about:blank",r),this.acquireTokenPopupAsync(e,r))}catch(n){return Promise.reject(n)}}logout(e){try{this.logger.verbose("logoutPopup called");const n=this.initializeLogoutRequest(e),r={popupName:this.generateLogoutPopupName(n),popupWindowAttributes:(e==null?void 0:e.popupWindowAttributes)||{},popupWindowParent:(e==null?void 0:e.popupWindowParent)??window},o=e&&e.authority,i=e&&e.mainWindowRedirectUri;return this.config.system.asyncPopups?(this.logger.verbose("asyncPopups set to true"),this.logoutPopupAsync(n,r,o,i)):(this.logger.verbose("asyncPopup set to false, opening popup"),r.popup=this.openSizedPopup("about:blank",r),this.logoutPopupAsync(n,r,o,i))}catch(n){return Promise.reject(n)}}async acquireTokenPopupAsync(e,n){var i;this.logger.verbose("acquireTokenPopupAsync called");const r=this.initializeServerTelemetryManager(ze.acquireTokenPopup),o=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,this.correlationId)(e,ce.Popup);Ev(o.authority);try{const s=await G(this.initializeAuthorizationCodeRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,this.correlationId)(o),a=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:o.authority,requestAzureCloudOptions:o.azureCloudOptions,requestExtraQueryParameters:o.extraQueryParameters,account:o.account}),c=Hn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme);let l;c&&(l=this.performanceClient.startMeasurement(_.FetchAccountIdWithNativeBroker,e.correlationId));const u=await a.getAuthCodeUrl({...o,nativeBroker:c}),d=new Ad(a,this.browserStorage,s,this.logger,this.performanceClient),h=this.initiateAuthRequest(u,n);this.eventHandler.emitEvent(me.POPUP_OPENED,ce.Popup,{popupWindow:h},null);const f=await this.monitorPopupForHash(h,n.popupWindowParent),p=_o(Rv,_.DeserializeResponse,this.logger,this.performanceClient,this.correlationId)(f,this.config.auth.OIDCOptions.serverResponseType,this.logger);if(Dn.removeThrottle(this.browserStorage,this.config.auth.clientId,s),p.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),l&&l.end({success:!0,isNativeBroker:!0}),!this.nativeMessageHandler)throw te(As);const m=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,p.accountId,this.nativeStorage,o.correlationId),{userRequestState:C}=gn.parseRequestState(this.browserCrypto,o.state);return await m.acquireToken({...o,state:C,prompt:void 0})}return await d.handleCodeResponse(p,o)}catch(s){throw(i=n.popup)==null||i.close(),s instanceof We&&(s.setCorrelationId(this.correlationId),r.cacheFailedRequest(s)),s}}async logoutPopupAsync(e,n,r,o){var s,a,c,l;this.logger.verbose("logoutPopupAsync called"),this.eventHandler.emitEvent(me.LOGOUT_START,ce.Popup,e);const i=this.initializeServerTelemetryManager(ze.logoutPopup);try{await this.clearCacheOnLogout(e.account);const u=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:i,requestAuthority:r,account:e.account||void 0});try{u.authority.endSessionEndpoint}catch{if((s=e.account)!=null&&s.homeAccountId&&e.postLogoutRedirectUri&&u.authority.protocolMode===ar.OIDC){if(this.browserStorage.removeAccount((a=e.account)==null?void 0:a.homeAccountId,this.correlationId),this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Popup,e),o){const f={apiId:ze.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},p=Oe.getAbsoluteUrl(o,ir());await this.navigationClient.navigateInternal(p,f)}(c=n.popup)==null||c.close();return}}const d=u.getLogoutUri(e);this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Popup,e);const h=this.openPopup(d,n);if(this.eventHandler.emitEvent(me.POPUP_OPENED,ce.Popup,{popupWindow:h},null),await this.monitorPopupForHash(h,n.popupWindowParent).catch(()=>{}),o){const f={apiId:ze.logoutPopup,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},p=Oe.getAbsoluteUrl(o,ir());this.logger.verbose("Redirecting main window to url specified in the request"),this.logger.verbosePii(`Redirecting main window to: ${p}`),await this.navigationClient.navigateInternal(p,f)}else this.logger.verbose("No main window navigation requested")}catch(u){throw(l=n.popup)==null||l.close(),u instanceof We&&(u.setCorrelationId(this.correlationId),i.cacheFailedRequest(u)),this.browserStorage.setInteractionInProgress(!1),this.eventHandler.emitEvent(me.LOGOUT_FAILURE,ce.Popup,null,u),this.eventHandler.emitEvent(me.LOGOUT_END,ce.Popup),u}this.eventHandler.emitEvent(me.LOGOUT_END,ce.Popup)}initiateAuthRequest(e,n){if(e)return this.logger.infoPii(`Navigate to: ${e}`),this.openPopup(e,n);throw this.logger.error("Navigate url is empty"),te(hc)}monitorPopupForHash(e,n){return new Promise((r,o)=>{this.logger.verbose("PopupHandler.monitorPopupForHash - polling started");const i=setInterval(()=>{if(e.closed){this.logger.error("PopupHandler.monitorPopupForHash - window closed"),clearInterval(i),o(te(wo));return}let s="";try{s=e.location.href}catch{}if(!s||s==="about:blank")return;clearInterval(i);let a="";const c=this.config.auth.OIDCOptions.serverResponseType;e&&(c===ws.QUERY?a=e.location.search:a=e.location.hash),this.logger.verbose("PopupHandler.monitorPopupForHash - popup window is on same origin as caller"),r(a)},this.config.system.pollIntervalMilliseconds)}).finally(()=>{this.cleanPopup(e,n)})}openPopup(e,n){try{let r;if(n.popup?(r=n.popup,this.logger.verbosePii(`Navigating popup window to: ${e}`),r.location.assign(e)):typeof n.popup>"u"&&(this.logger.verbosePii(`Opening popup window to: ${e}`),r=this.openSizedPopup(e,n)),!r)throw te(Gy);return r.focus&&r.focus(),this.currentWindow=r,n.popupWindowParent.addEventListener("beforeunload",this.unloadWindow),r}catch(r){throw this.logger.error("error opening popup "+r.message),this.browserStorage.setInteractionInProgress(!1),te(Vy)}}openSizedPopup(e,{popupName:n,popupWindowAttributes:r,popupWindowParent:o}){var f,p,g,m;const i=o.screenLeft?o.screenLeft:o.screenX,s=o.screenTop?o.screenTop:o.screenY,a=o.innerWidth||document.documentElement.clientWidth||document.body.clientWidth,c=o.innerHeight||document.documentElement.clientHeight||document.body.clientHeight;let l=(f=r.popupSize)==null?void 0:f.width,u=(p=r.popupSize)==null?void 0:p.height,d=(g=r.popupPosition)==null?void 0:g.top,h=(m=r.popupPosition)==null?void 0:m.left;return(!l||l<0||l>a)&&(this.logger.verbose("Default popup window width used. Window width not configured or invalid."),l=Qt.POPUP_WIDTH),(!u||u<0||u>c)&&(this.logger.verbose("Default popup window height used. Window height not configured or invalid."),u=Qt.POPUP_HEIGHT),(!d||d<0||d>c)&&(this.logger.verbose("Default popup window top position used. Window top not configured or invalid."),d=Math.max(0,c/2-Qt.POPUP_HEIGHT/2+s)),(!h||h<0||h>a)&&(this.logger.verbose("Default popup window left position used. Window left not configured or invalid."),h=Math.max(0,a/2-Qt.POPUP_WIDTH/2+i)),o.open(e,n,`width=${l}, height=${u}, top=${d}, left=${h}, scrollbars=yes`)}unloadWindow(e){this.browserStorage.cleanRequestByInteractionType(ce.Popup),this.currentWindow&&this.currentWindow.close(),e.preventDefault()}cleanPopup(e,n){e.close(),n.removeEventListener("beforeunload",this.unloadWindow),this.browserStorage.setInteractionInProgress(!1)}generatePopupName(e,n){return`${Qt.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${e.join("-")}.${n}.${this.correlationId}`}generateLogoutPopupName(e){const n=e.account&&e.account.homeAccountId;return`${Qt.POPUP_NAME_PREFIX}.${this.config.auth.clientId}.${n}.${this.correlationId}`}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Gf{constructor(e,n,r,o,i){this.authModule=e,this.browserStorage=n,this.authCodeRequest=r,this.logger=o,this.performanceClient=i}async initiateAuthRequest(e,n){if(this.logger.verbose("RedirectHandler.initiateAuthRequest called"),e){n.redirectStartPage&&(this.logger.verbose("RedirectHandler.initiateAuthRequest: redirectStartPage set, caching start page"),this.browserStorage.setTemporaryCache(Be.ORIGIN_URI,n.redirectStartPage,!0)),this.browserStorage.setTemporaryCache(Be.CORRELATION_ID,this.authCodeRequest.correlationId,!0),this.browserStorage.cacheCodeRequest(this.authCodeRequest),this.logger.infoPii(`RedirectHandler.initiateAuthRequest: Navigate to: ${e}`);const r={apiId:ze.acquireTokenRedirect,timeout:n.redirectTimeout,noHistory:!1};if(typeof n.onRedirectNavigate=="function")if(this.logger.verbose("RedirectHandler.initiateAuthRequest: Invoking onRedirectNavigate callback"),n.onRedirectNavigate(e)!==!1){this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate did not return false, navigating"),await n.navigationClient.navigateExternal(e,r);return}else{this.logger.verbose("RedirectHandler.initiateAuthRequest: onRedirectNavigate returned false, stopping navigation");return}else{this.logger.verbose("RedirectHandler.initiateAuthRequest: Navigating window to navigate url"),await n.navigationClient.navigateExternal(e,r);return}}else throw this.logger.info("RedirectHandler.initiateAuthRequest: Navigate url is empty"),te(hc)}async handleCodeResponse(e,n){this.logger.verbose("RedirectHandler.handleCodeResponse called"),this.browserStorage.setInteractionInProgress(!1);const r=this.browserStorage.generateStateKey(n),o=this.browserStorage.getTemporaryCache(r);if(!o)throw j(ha,"Cached State");let i;try{i=this.authModule.handleFragmentResponse(e,o)}catch(l){throw l instanceof $r&&l.subError===wo?te(wo):l}const s=this.browserStorage.generateNonceKey(o),a=this.browserStorage.getTemporaryCache(s);if(this.authCodeRequest.code=i.code,i.cloud_instance_host_name&&await G(this.authModule.updateAuthority.bind(this.authModule),_.UpdateTokenEndpointAuthority,this.logger,this.performanceClient,this.authCodeRequest.correlationId)(i.cloud_instance_host_name,this.authCodeRequest.correlationId),i.nonce=a||void 0,i.state=o,i.client_info)this.authCodeRequest.clientInfo=i.client_info;else{const l=this.checkCcsCredentials();l&&(this.authCodeRequest.ccsCredential=l)}const c=await this.authModule.acquireToken(this.authCodeRequest,i);return this.browserStorage.cleanRequestByState(n),c}checkCcsCredentials(){const e=this.browserStorage.getTemporaryCache(Be.CCS_CREDENTIAL,!0);if(e)try{return JSON.parse(e)}catch{this.authModule.logger.error("Cache credential could not be parsed"),this.authModule.logger.errorPii(`Cache credential could not be parsed: ${e}`)}return null}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function AP(){if(typeof window>"u"||typeof window.performance>"u"||typeof window.performance.getEntriesByType!="function")return;const t=window.performance.getEntriesByType("navigation"),e=t.length?t[0]:void 0;return e==null?void 0:e.type}class TP extends yi{constructor(e,n,r,o,i,s,a,c,l,u){super(e,n,r,o,i,s,a,l,u),this.nativeStorage=c}async acquireToken(e){const n=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,this.correlationId)(e,ce.Redirect);this.browserStorage.updateCacheEntries(n.state,n.nonce,n.authority,n.loginHint||"",n.account||null);const r=this.initializeServerTelemetryManager(ze.acquireTokenRedirect),o=i=>{i.persisted&&(this.logger.verbose("Page was restored from back/forward cache. Clearing temporary cache."),this.browserStorage.cleanRequestByState(n.state),this.eventHandler.emitEvent(me.RESTORE_FROM_BFCACHE,ce.Redirect))};try{const i=await G(this.initializeAuthorizationCodeRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,this.correlationId)(n),s=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:n.authority,requestAzureCloudOptions:n.azureCloudOptions,requestExtraQueryParameters:n.extraQueryParameters,account:n.account}),a=new Gf(s,this.browserStorage,i,this.logger,this.performanceClient),c=await s.getAuthCodeUrl({...n,nativeBroker:Hn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,e.authenticationScheme)}),l=this.getRedirectStartPage(e.redirectStartPage);return this.logger.verbosePii(`Redirect start page: ${l}`),window.addEventListener("pageshow",o),await a.initiateAuthRequest(c,{navigationClient:this.navigationClient,redirectTimeout:this.config.system.redirectNavigationTimeout,redirectStartPage:l,onRedirectNavigate:e.onRedirectNavigate||this.config.auth.onRedirectNavigate})}catch(i){throw i instanceof We&&(i.setCorrelationId(this.correlationId),r.cacheFailedRequest(i)),window.removeEventListener("pageshow",o),this.browserStorage.cleanRequestByState(n.state),i}}async handleRedirectPromise(e="",n){const r=this.initializeServerTelemetryManager(ze.handleRedirectPromise);try{if(!this.browserStorage.isInteractionInProgress(!0))return this.logger.info("handleRedirectPromise called but there is no interaction in progress, returning null."),null;const[o,i]=this.getRedirectResponse(e||"");if(!o)return this.logger.info("handleRedirectPromise did not detect a response as a result of a redirect. Cleaning temporary cache."),this.browserStorage.cleanRequestByInteractionType(ce.Redirect),AP()!=="back_forward"?n.event.errorCode="no_server_response":this.logger.verbose("Back navigation event detected. Muting no_server_response error"),null;const s=this.browserStorage.getTemporaryCache(Be.ORIGIN_URI,!0)||P.EMPTY_STRING,a=Oe.removeHashFromUrl(s),c=Oe.removeHashFromUrl(window.location.href);if(a===c&&this.config.auth.navigateToLoginRequestUrl)return this.logger.verbose("Current page is loginRequestUrl, handling response"),s.indexOf("#")>-1&&Ok(s),await this.handleResponse(o,r);if(this.config.auth.navigateToLoginRequestUrl){if(!yd()||this.config.system.allowRedirectInIframe){this.browserStorage.setTemporaryCache(Be.URL_HASH,i,!0);const l={apiId:ze.handleRedirectPromise,timeout:this.config.system.redirectNavigationTimeout,noHistory:!0};let u=!0;if(!s||s==="null"){const d=Pk();this.browserStorage.setTemporaryCache(Be.ORIGIN_URI,d,!0),this.logger.warning("Unable to get valid login request url from cache, redirecting to home page"),u=await this.navigationClient.navigateInternal(d,l)}else this.logger.verbose(`Navigating to loginRequestUrl: ${s}`),u=await this.navigationClient.navigateInternal(s,l);if(!u)return await this.handleResponse(o,r)}}else return this.logger.verbose("NavigateToLoginRequestUrl set to false, handling response"),await this.handleResponse(o,r);return null}catch(o){throw o instanceof We&&(o.setCorrelationId(this.correlationId),r.cacheFailedRequest(o)),this.browserStorage.cleanRequestByInteractionType(ce.Redirect),o}}getRedirectResponse(e){this.logger.verbose("getRedirectResponseHash called");let n=e;n||(this.config.auth.OIDCOptions.serverResponseType===ws.QUERY?n=window.location.search:n=window.location.hash);let r=ma(n);if(r){try{CP(r,this.browserCrypto,ce.Redirect)}catch(i){return i instanceof We&&this.logger.error(`Interaction type validation failed due to ${i.errorCode}: ${i.errorMessage}`),[null,""]}return Rk(window),this.logger.verbose("Hash contains known properties, returning response hash"),[r,n]}const o=this.browserStorage.getTemporaryCache(Be.URL_HASH,!0);return this.browserStorage.removeItem(this.browserStorage.generateCacheKey(Be.URL_HASH)),o&&(r=ma(o),r)?(this.logger.verbose("Hash does not contain known properties, returning cached hash"),[r,o]):[null,""]}async handleResponse(e,n){const r=e.state;if(!r)throw te(cd);const o=this.browserStorage.getCachedRequest(r);if(this.logger.verbose("handleResponse called, retrieved cached request"),e.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw te(As);const c=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenPopup,this.performanceClient,this.nativeMessageHandler,e.accountId,this.nativeStorage,o.correlationId),{userRequestState:l}=gn.parseRequestState(this.browserCrypto,r);return c.acquireToken({...o,state:l,prompt:void 0}).finally(()=>{this.browserStorage.cleanRequestByState(r)})}const i=this.browserStorage.getCachedAuthority(r);if(!i)throw te(ld);const s=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:n,requestAuthority:i});return Dn.removeThrottle(this.browserStorage,this.config.auth.clientId,o),new Gf(s,this.browserStorage,o,this.logger,this.performanceClient).handleCodeResponse(e,r)}async logout(e){var o,i;this.logger.verbose("logoutRedirect called");const n=this.initializeLogoutRequest(e),r=this.initializeServerTelemetryManager(ze.logout);try{this.eventHandler.emitEvent(me.LOGOUT_START,ce.Redirect,e),await this.clearCacheOnLogout(n.account);const s={apiId:ze.logout,timeout:this.config.system.redirectNavigationTimeout,noHistory:!1},a=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:r,requestAuthority:e&&e.authority,requestExtraQueryParameters:e==null?void 0:e.extraQueryParameters,account:e&&e.account||void 0});if(a.authority.protocolMode===ar.OIDC)try{a.authority.endSessionEndpoint}catch{if((o=n.account)!=null&&o.homeAccountId){this.browserStorage.removeAccount((i=n.account)==null?void 0:i.homeAccountId,this.correlationId),this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Redirect,n);return}}const c=a.getLogoutUri(n);if(this.eventHandler.emitEvent(me.LOGOUT_SUCCESS,ce.Redirect,n),e&&typeof e.onRedirectNavigate=="function")if(e.onRedirectNavigate(c)!==!1){this.logger.verbose("Logout onRedirectNavigate did not return false, navigating"),this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),await this.navigationClient.navigateExternal(c,s);return}else this.browserStorage.setInteractionInProgress(!1),this.logger.verbose("Logout onRedirectNavigate returned false, stopping navigation");else{this.browserStorage.getInteractionInProgress()||this.browserStorage.setInteractionInProgress(!0),await this.navigationClient.navigateExternal(c,s);return}}catch(s){throw s instanceof We&&(s.setCorrelationId(this.correlationId),r.cacheFailedRequest(s)),this.eventHandler.emitEvent(me.LOGOUT_FAILURE,ce.Redirect,null,s),this.eventHandler.emitEvent(me.LOGOUT_END,ce.Redirect),s}this.eventHandler.emitEvent(me.LOGOUT_END,ce.Redirect)}getRedirectStartPage(e){const n=e||window.location.href;return Oe.getAbsoluteUrl(n,ir())}}/*! @azure/msal-browser v3.30.0 2025-08-05 */async function EP(t,e,n,r,o){if(e.addQueueMeasurement(_.SilentHandlerInitiateAuthRequest,r),!t)throw n.info("Navigate url is empty"),te(hc);return o?G(_P,_.SilentHandlerLoadFrame,n,e,r)(t,o,e,r):_o(SP,_.SilentHandlerLoadFrameSync,n,e,r)(t)}async function bP(t,e,n,r,o,i,s){return r.addQueueMeasurement(_.SilentHandlerMonitorIframeForHash,i),new Promise((a,c)=>{e{window.clearInterval(u),c(te(zy))},e),u=window.setInterval(()=>{let d="";const h=t.contentWindow;try{d=h?h.location.href:""}catch{}if(!d||d==="about:blank")return;let f="";h&&(s===ws.QUERY?f=h.location.search:f=h.location.hash),window.clearTimeout(l),window.clearInterval(u),a(f)},n)}).finally(()=>{_o(IP,_.RemoveHiddenIframe,o,r,i)(t)})}function _P(t,e,n,r){return n.addQueueMeasurement(_.SilentHandlerLoadFrame,r),new Promise((o,i)=>{const s=Ov();window.setTimeout(()=>{if(!s){i("Unable to load iframe");return}s.src=t,o(s)},e)})}function SP(t){const e=Ov();return e.src=t,e}function Ov(){const t=document.createElement("iframe");return t.className="msalSilentIframe",t.style.visibility="hidden",t.style.position="absolute",t.style.width=t.style.height="0",t.style.border="0",t.setAttribute("sandbox","allow-scripts allow-same-origin allow-forms"),document.body.appendChild(t),t}function IP(t){document.body===t.parentNode&&document.body.removeChild(t)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class RP extends yi{constructor(e,n,r,o,i,s,a,c,l,u,d){super(e,n,r,o,i,s,c,u,d),this.apiId=a,this.nativeStorage=l}async acquireToken(e){this.performanceClient.addQueueMeasurement(_.SilentIframeClientAcquireToken,e.correlationId),!e.loginHint&&!e.sid&&(!e.account||!e.account.username)&&this.logger.warning("No user hint provided. The authorization server may need more information to complete this request.");const n={...e};n.prompt?n.prompt!==gt.NONE&&n.prompt!==gt.NO_SESSION&&(this.logger.warning(`SilentIframeClient. Replacing invalid prompt ${n.prompt} with ${gt.NONE}`),n.prompt=gt.NONE):n.prompt=gt.NONE;const r=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(n,ce.Silent);Ev(r.authority);const o=this.initializeServerTelemetryManager(this.apiId);let i;try{return i=await G(this.createAuthCodeClient.bind(this),_.StandardInteractionClientCreateAuthCodeClient,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:o,requestAuthority:r.authority,requestAzureCloudOptions:r.azureCloudOptions,requestExtraQueryParameters:r.extraQueryParameters,account:r.account}),await G(this.silentTokenHelper.bind(this),_.SilentIframeClientTokenHelper,this.logger,this.performanceClient,e.correlationId)(i,r)}catch(s){if(s instanceof We&&(s.setCorrelationId(this.correlationId),o.cacheFailedRequest(s)),!i||!(s instanceof We)||s.errorCode!==Qt.INVALID_GRANT_ERROR)throw s;this.performanceClient.addFields({retryError:s.errorCode},this.correlationId);const a=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(n,ce.Silent);return await G(this.silentTokenHelper.bind(this),_.SilentIframeClientTokenHelper,this.logger,this.performanceClient,this.correlationId)(i,a)}}logout(){return Promise.reject(te(fc))}async silentTokenHelper(e,n){const r=n.correlationId;this.performanceClient.addQueueMeasurement(_.SilentIframeClientTokenHelper,r);const o=await G(this.initializeAuthorizationCodeRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationCodeRequest,this.logger,this.performanceClient,r)(n),i=await G(e.getAuthCodeUrl.bind(e),_.GetAuthCodeUrl,this.logger,this.performanceClient,r)({...n,nativeBroker:Hn.isNativeAvailable(this.config,this.logger,this.nativeMessageHandler,n.authenticationScheme)}),s=new Ad(e,this.browserStorage,o,this.logger,this.performanceClient),a=await G(EP,_.SilentHandlerInitiateAuthRequest,this.logger,this.performanceClient,r)(i,this.performanceClient,this.logger,r,this.config.system.navigateFrameWait),c=this.config.auth.OIDCOptions.serverResponseType,l=await G(bP,_.SilentHandlerMonitorIframeForHash,this.logger,this.performanceClient,r)(a,this.config.system.iframeHashTimeout,this.config.system.pollIntervalMilliseconds,this.performanceClient,this.logger,r,c),u=_o(Rv,_.DeserializeResponse,this.logger,this.performanceClient,this.correlationId)(l,c,this.logger);if(u.accountId){if(this.logger.verbose("Account id found in hash, calling WAM for token"),!this.nativeMessageHandler)throw te(As);const d=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.apiId,this.performanceClient,this.nativeMessageHandler,u.accountId,this.browserStorage,r),{userRequestState:h}=gn.parseRequestState(this.browserCrypto,n.state);return G(d.acquireToken.bind(d),_.NativeInteractionClientAcquireToken,this.logger,this.performanceClient,r)({...n,state:h,prompt:n.prompt||gt.NONE})}return G(s.handleCodeResponse.bind(s),_.HandleCodeResponse,this.logger,this.performanceClient,r)(u,n)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class OP extends yi{async acquireToken(e){this.performanceClient.addQueueMeasurement(_.SilentRefreshClientAcquireToken,e.correlationId);const n=await G(wd,_.InitializeBaseRequest,this.logger,this.performanceClient,e.correlationId)(e,this.config,this.performanceClient,this.logger),r={...e,...n};e.redirectUri&&(r.redirectUri=this.getRedirectUri(e.redirectUri));const o=this.initializeServerTelemetryManager(ze.acquireTokenSilent_silentFlow),i=await this.createRefreshTokenClient({serverTelemetryManager:o,authorityUrl:r.authority,azureCloudOptions:r.azureCloudOptions,account:r.account});return G(i.acquireTokenByRefreshToken.bind(i),_.RefreshTokenClientAcquireTokenByRefreshToken,this.logger,this.performanceClient,e.correlationId)(r).catch(s=>{throw s.setCorrelationId(this.correlationId),o.cacheFailedRequest(s),s})}logout(){return Promise.reject(te(fc))}async createRefreshTokenClient(e){const n=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,this.correlationId)({serverTelemetryManager:e.serverTelemetryManager,requestAuthority:e.authorityUrl,requestAzureCloudOptions:e.azureCloudOptions,requestExtraQueryParameters:e.extraQueryParameters,account:e.account});return new Kl(n,this.performanceClient)}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class kP{constructor(e,n,r,o){this.isBrowserEnvironment=typeof window<"u",this.config=e,this.storage=n,this.logger=r,this.cryptoObj=o}loadExternalTokens(e,n,r){if(!this.isBrowserEnvironment)throw te(pc);const o=e.correlationId||jn(),i=n.id_token?bo(n.id_token,$n):void 0,s={protocolMode:this.config.auth.protocolMode,knownAuthorities:this.config.auth.knownAuthorities,cloudDiscoveryMetadata:this.config.auth.cloudDiscoveryMetadata,authorityMetadata:this.config.auth.authorityMetadata,skipAuthorityMetadataCache:this.config.auth.skipAuthorityMetadataCache},a=e.authority?new bt(bt.generateAuthority(e.authority,e.azureCloudOptions),this.config.system.networkClient,this.storage,s,this.logger,e.correlationId||jn()):void 0,c=this.loadAccount(e,r.clientInfo||n.client_info||"",o,i,a),l=this.loadIdToken(n,c.homeAccountId,c.environment,c.realm,o),u=this.loadAccessToken(e,n,c.homeAccountId,c.environment,c.realm,r,o),d=this.loadRefreshToken(n,c.homeAccountId,c.environment,o);return this.generateAuthenticationResult(e,{account:c,idToken:l,accessToken:u,refreshToken:d},i,a)}loadAccount(e,n,r,o,i){if(this.logger.verbose("TokenCache - loading account"),e.account){const l=dt.createFromAccountInfo(e.account);return this.storage.setAccount(l,r),l}else if(!i||!n&&!o)throw this.logger.error("TokenCache - if an account is not provided on the request, authority and either clientInfo or idToken must be provided instead."),te(nv);const s=dt.generateHomeAccountId(n,i.authorityType,this.logger,this.cryptoObj,o),a=o==null?void 0:o.tid,c=od(this.storage,i,s,$n,r,o,n,i.hostnameAndPort,a,void 0,void 0,this.logger);return this.storage.setAccount(c,r),c}loadIdToken(e,n,r,o,i){if(!e.id_token)return this.logger.verbose("TokenCache - no id token found in response"),null;this.logger.verbose("TokenCache - loading id token");const s=sc(n,r,e.id_token,this.config.auth.clientId,o);return this.storage.setIdTokenCredential(s,i),s}loadAccessToken(e,n,r,o,i,s,a){if(n.access_token)if(n.expires_in){if(!n.scope&&(!e.scopes||!e.scopes.length))return this.logger.error("TokenCache - scopes not specified in the request or response. Cannot add token to the cache."),null}else return this.logger.error("TokenCache - no expiration set on the access token. Cannot add it to the cache."),null;else return this.logger.verbose("TokenCache - no access token found in response"),null;this.logger.verbose("TokenCache - loading access token");const c=n.scope?rt.fromString(n.scope):new rt(e.scopes),l=s.expiresOn||n.expires_in+new Date().getTime()/1e3,u=s.extendedExpiresOn||(n.ext_expires_in||n.expires_in)+new Date().getTime()/1e3,d=ac(r,o,n.access_token,this.config.auth.clientId,i,c.printScopes(),l,u,$n);return this.storage.setAccessTokenCredential(d,a),d}loadRefreshToken(e,n,r,o){if(!e.refresh_token)return this.logger.verbose("TokenCache - no refresh token found in response"),null;this.logger.verbose("TokenCache - loading refresh token");const i=uy(n,r,e.refresh_token,this.config.auth.clientId,e.foci,void 0,e.refresh_token_expires_in);return this.storage.setRefreshTokenCredential(i,o),i}generateAuthenticationResult(e,n,r,o){var u,d,h;let i="",s=[],a=null,c;n!=null&&n.accessToken&&(i=n.accessToken.secret,s=rt.fromString(n.accessToken.target).asArray(),a=new Date(Number(n.accessToken.expiresOn)*1e3),c=new Date(Number(n.accessToken.extendedExpiresOn)*1e3));const l=n.account;return{authority:o?o.canonicalAuthority:"",uniqueId:n.account.localAccountId,tenantId:n.account.realm,scopes:s,account:l.getAccountInfo(),idToken:((u=n.idToken)==null?void 0:u.secret)||"",idTokenClaims:r||{},accessToken:i,fromCache:!0,expiresOn:a,correlationId:e.correlationId||"",requestId:"",extExpiresOn:c,familyId:((d=n.refreshToken)==null?void 0:d.familyId)||"",tokenType:((h=n==null?void 0:n.accessToken)==null?void 0:h.tokenType)||"",state:e.state||"",cloudGraphHostName:l.cloudGraphHostName||"",msGraphHost:l.msGraphHost||"",fromNativeBroker:!1}}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class PP extends Ly{constructor(e){super(e),this.includeRedirectUri=!1}}/*! @azure/msal-browser v3.30.0 2025-08-05 */class NP extends yi{constructor(e,n,r,o,i,s,a,c,l,u){super(e,n,r,o,i,s,c,l,u),this.apiId=a}async acquireToken(e){if(!e.code)throw te(rv);const n=await G(this.initializeAuthorizationRequest.bind(this),_.StandardInteractionClientInitializeAuthorizationRequest,this.logger,this.performanceClient,e.correlationId)(e,ce.Silent),r=this.initializeServerTelemetryManager(this.apiId);try{const o={...n,code:e.code},i=await G(this.getClientConfiguration.bind(this),_.StandardInteractionClientGetClientConfiguration,this.logger,this.performanceClient,e.correlationId)({serverTelemetryManager:r,requestAuthority:n.authority,requestAzureCloudOptions:n.azureCloudOptions,requestExtraQueryParameters:n.extraQueryParameters,account:n.account}),s=new PP(i);this.logger.verbose("Auth code client created");const a=new Ad(s,this.browserStorage,o,this.logger,this.performanceClient);return await G(a.handleCodeResponseFromServer.bind(a),_.HandleCodeResponseFromServer,this.logger,this.performanceClient,e.correlationId)({code:e.code,msgraph_host:e.msGraphHost,cloud_graph_host_name:e.cloudGraphHostName,cloud_instance_host_name:e.cloudInstanceHostName},n,!1)}catch(o){throw o instanceof We&&(o.setCorrelationId(this.correlationId),r.cacheFailedRequest(o)),o}}logout(){return Promise.reject(te(fc))}}/*! @azure/msal-browser v3.30.0 2025-08-05 */function Sn(t){const e=t==null?void 0:t.idTokenClaims;if(e!=null&&e.tfp||e!=null&&e.acr)return"B2C";if(e!=null&&e.tid){if((e==null?void 0:e.tid)==="9188040d-6c67-4c5b-b112-36a304b66dad")return"MSA"}else return;return"AAD"}function $s(t,e){try{vd(t)}catch(n){throw e.end({success:!1},n),n}}class mc{constructor(e){this.operatingContext=e,this.isBrowserEnvironment=this.operatingContext.isBrowserEnvironment(),this.config=e.getConfig(),this.initialized=!1,this.logger=this.operatingContext.getLogger(),this.networkClient=this.config.system.networkClient,this.navigationClient=this.config.system.navigationClient,this.redirectResponse=new Map,this.hybridAuthCodeResponses=new Map,this.performanceClient=this.config.telemetry.client,this.browserCrypto=this.isBrowserEnvironment?new fi(this.logger,this.performanceClient):fa,this.eventHandler=new oP(this.logger),this.browserStorage=this.isBrowserEnvironment?new zl(this.config.auth.clientId,this.config.cache,this.browserCrypto,this.logger,jO(this.config.auth),this.performanceClient):Yk(this.config.auth.clientId,this.logger);const n={cacheLocation:Bt.MemoryStorage,temporaryCacheLocation:Bt.MemoryStorage,storeAuthStateInCookie:!1,secureCookies:!1,cacheMigrationEnabled:!1,claimsBasedCachingEnabled:!1};this.nativeInternalStorage=new zl(this.config.auth.clientId,n,this.browserCrypto,this.logger,void 0,this.performanceClient),this.tokenCache=new kP(this.config,this.browserStorage,this.logger,this.browserCrypto),this.activeSilentTokenRequests=new Map,this.trackPageVisibility=this.trackPageVisibility.bind(this),this.trackPageVisibilityWithMeasurement=this.trackPageVisibilityWithMeasurement.bind(this),this.listeningToStorageEvents=!1,this.handleAccountCacheChange=this.handleAccountCacheChange.bind(this)}static async createController(e,n){const r=new mc(e);return await r.initialize(n),r}trackPageVisibility(e){e&&(this.logger.info("Perf: Visibility change detected"),this.performanceClient.incrementFields({visibilityChangeCount:1},e))}async initialize(e){if(this.logger.trace("initialize called"),this.initialized){this.logger.info("initialize has already been called, exiting early.");return}if(!this.isBrowserEnvironment){this.logger.info("in non-browser environment, exiting early."),this.initialized=!0,this.eventHandler.emitEvent(me.INITIALIZE_END);return}const n=(e==null?void 0:e.correlationId)||this.getRequestCorrelationId(),r=this.config.system.allowNativeBroker,o=this.performanceClient.startMeasurement(_.InitializeClientApplication,n);if(this.eventHandler.emitEvent(me.INITIALIZE_START),r)try{this.nativeExtensionProvider=await Hn.createProvider(this.logger,this.config.system.nativeBrokerHandshakeTimeout,this.performanceClient)}catch(i){this.logger.verbose(i)}this.config.cache.claimsBasedCachingEnabled||(this.logger.verbose("Claims-based caching is disabled. Clearing the previous cache with claims"),await G(this.browserStorage.clearTokensAndKeysWithClaims.bind(this.browserStorage),_.ClearTokensAndKeysWithClaims,this.logger,this.performanceClient,n)(this.performanceClient,n)),this.initialized=!0,this.eventHandler.emitEvent(me.INITIALIZE_END),o.end({allowNativeBroker:r,success:!0})}async handleRedirectPromise(e){if(this.logger.verbose("handleRedirectPromise called"),Tv(this.initialized),this.isBrowserEnvironment){const n=e||"";let r=this.redirectResponse.get(n);return typeof r>"u"?(r=this.handleRedirectPromiseInternal(e),this.redirectResponse.set(n,r),this.logger.verbose("handleRedirectPromise has been called for the first time, storing the promise")):this.logger.verbose("handleRedirectPromise has been called previously, returning the result from the first call"),r}return this.logger.verbose("handleRedirectPromise returns null, not browser environment"),null}async handleRedirectPromiseInternal(e){const n=this.getAllAccounts(),r=this.browserStorage.getCachedNativeRequest(),o=r&&Hn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider)&&this.nativeExtensionProvider&&!e,i=o?r==null?void 0:r.correlationId:this.browserStorage.getTemporaryCache(Be.CORRELATION_ID,!0)||"",s=this.performanceClient.startMeasurement(_.AcquireTokenRedirect,i);this.eventHandler.emitEvent(me.HANDLE_REDIRECT_START,ce.Redirect);let a;if(o&&this.nativeExtensionProvider){this.logger.trace("handleRedirectPromise - acquiring token from native platform");const c=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.handleRedirectPromise,this.performanceClient,this.nativeExtensionProvider,r.accountId,this.nativeInternalStorage,r.correlationId);a=G(c.handleRedirectPromise.bind(c),_.HandleNativeRedirectPromiseMeasurement,this.logger,this.performanceClient,s.event.correlationId)(this.performanceClient,s.event.correlationId)}else{this.logger.trace("handleRedirectPromise - acquiring token from web flow");const c=this.createRedirectClient(i);a=G(c.handleRedirectPromise.bind(c),_.HandleRedirectPromiseMeasurement,this.logger,this.performanceClient,s.event.correlationId)(e,s)}return a.then(c=>(c?(n.length{const l=c;throw n.length>0?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Redirect,null,l):this.eventHandler.emitEvent(me.LOGIN_FAILURE,ce.Redirect,null,l),this.eventHandler.emitEvent(me.HANDLE_REDIRECT_END,ce.Redirect),s.end({success:!1},l),c})}async acquireTokenRedirect(e){const n=this.getRequestCorrelationId(e);this.logger.verbose("acquireTokenRedirect called",n);const r=this.performanceClient.startMeasurement(_.AcquireTokenPreRedirect,n);r.add({accountType:Sn(e.account),scenarioId:e.scenarioId});const o=e.onRedirectNavigate;if(o)e.onRedirectNavigate=s=>{const a=typeof o=="function"?o(s):void 0;return a!==!1?r.end({success:!0}):r.discard(),a};else{const s=this.config.auth.onRedirectNavigate;this.config.auth.onRedirectNavigate=a=>{const c=typeof s=="function"?s(a):void 0;return c!==!1?r.end({success:!0}):r.discard(),c}}const i=this.getAllAccounts().length>0;try{$f(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),i?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_START,ce.Redirect,e):this.eventHandler.emitEvent(me.LOGIN_START,ce.Redirect,e);let s;return this.nativeExtensionProvider&&this.canUseNative(e)?s=new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenRedirect,this.performanceClient,this.nativeExtensionProvider,this.getNativeAccountId(e),this.nativeInternalStorage,n).acquireTokenRedirect(e,r).catch(c=>{if(c instanceof Ln&&Uo(c))return this.nativeExtensionProvider=void 0,this.createRedirectClient(n).acquireToken(e);if(c instanceof En)return this.logger.verbose("acquireTokenRedirect - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createRedirectClient(n).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),c}):s=this.createRedirectClient(n).acquireToken(e),await s}catch(s){throw r.end({success:!1},s),i?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Redirect,null,s):this.eventHandler.emitEvent(me.LOGIN_FAILURE,ce.Redirect,null,s),s}}acquireTokenPopup(e){const n=this.getRequestCorrelationId(e),r=this.performanceClient.startMeasurement(_.AcquireTokenPopup,n);r.add({scenarioId:e.scenarioId,accountType:Sn(e.account)});try{this.logger.verbose("acquireTokenPopup called",n),$s(this.initialized,r),this.browserStorage.setInteractionInProgress(!0)}catch(s){return Promise.reject(s)}const o=this.getAllAccounts();o.length>0?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_START,ce.Popup,e):this.eventHandler.emitEvent(me.LOGIN_START,ce.Popup,e);let i;return this.canUseNative(e)?i=this.acquireTokenNative({...e,correlationId:n},ze.acquireTokenPopup).then(s=>(this.browserStorage.setInteractionInProgress(!1),r.end({success:!0,isNativeBroker:!0,accountType:Sn(s.account)}),s)).catch(s=>{if(s instanceof Ln&&Uo(s))return this.nativeExtensionProvider=void 0,this.createPopupClient(n).acquireToken(e);if(s instanceof En)return this.logger.verbose("acquireTokenPopup - Resolving interaction required error thrown by native broker by falling back to web flow"),this.createPopupClient(n).acquireToken(e);throw this.browserStorage.setInteractionInProgress(!1),s}):i=this.createPopupClient(n).acquireToken(e),i.then(s=>(o.length(o.length>0?this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Popup,null,s):this.eventHandler.emitEvent(me.LOGIN_FAILURE,ce.Popup,null,s),r.end({success:!1},s),Promise.reject(s)))}trackPageVisibilityWithMeasurement(){const e=this.ssoSilentMeasurement||this.acquireTokenByCodeAsyncMeasurement;e&&(this.logger.info("Perf: Visibility change detected in ",e.event.name),e.increment({visibilityChangeCount:1}))}async ssoSilent(e){var i,s;const n=this.getRequestCorrelationId(e),r={...e,prompt:e.prompt,correlationId:n};this.ssoSilentMeasurement=this.performanceClient.startMeasurement(_.SsoSilent,n),(i=this.ssoSilentMeasurement)==null||i.add({scenarioId:e.scenarioId,accountType:Sn(e.account)}),$s(this.initialized,this.ssoSilentMeasurement),(s=this.ssoSilentMeasurement)==null||s.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),this.logger.verbose("ssoSilent called",n),this.eventHandler.emitEvent(me.SSO_SILENT_START,ce.Silent,r);let o;return this.canUseNative(r)?o=this.acquireTokenNative(r,ze.ssoSilent).catch(a=>{if(a instanceof Ln&&Uo(a))return this.nativeExtensionProvider=void 0,this.createSilentIframeClient(r.correlationId).acquireToken(r);throw a}):o=this.createSilentIframeClient(r.correlationId).acquireToken(r),o.then(a=>{var c;return this.eventHandler.emitEvent(me.SSO_SILENT_SUCCESS,ce.Silent,a),(c=this.ssoSilentMeasurement)==null||c.end({success:!0,isNativeBroker:a.fromNativeBroker,accessTokenSize:a.accessToken.length,idTokenSize:a.idToken.length,accountType:Sn(a.account)}),a}).catch(a=>{var c;throw this.eventHandler.emitEvent(me.SSO_SILENT_FAILURE,ce.Silent,null,a),(c=this.ssoSilentMeasurement)==null||c.end({success:!1},a),a}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenByCode(e){const n=this.getRequestCorrelationId(e);this.logger.trace("acquireTokenByCode called",n);const r=this.performanceClient.startMeasurement(_.AcquireTokenByCode,n);$s(this.initialized,r),this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_START,ce.Silent,e),r.add({scenarioId:e.scenarioId});try{if(e.code&&e.nativeAccountId)throw te(iv);if(e.code){const o=e.code;let i=this.hybridAuthCodeResponses.get(o);return i?(this.logger.verbose("Existing acquireTokenByCode request found",n),r.discard()):(this.logger.verbose("Initiating new acquireTokenByCode request",n),i=this.acquireTokenByCodeAsync({...e,correlationId:n}).then(s=>(this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_SUCCESS,ce.Silent,s),this.hybridAuthCodeResponses.delete(o),r.end({success:!0,isNativeBroker:s.fromNativeBroker,accessTokenSize:s.accessToken.length,idTokenSize:s.idToken.length,accountType:Sn(s.account)}),s)).catch(s=>{throw this.hybridAuthCodeResponses.delete(o),this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_FAILURE,ce.Silent,null,s),r.end({success:!1},s),s}),this.hybridAuthCodeResponses.set(o,i)),await i}else if(e.nativeAccountId)if(this.canUseNative(e,e.nativeAccountId)){const o=await this.acquireTokenNative({...e,correlationId:n},ze.acquireTokenByCode,e.nativeAccountId).catch(i=>{throw i instanceof Ln&&Uo(i)&&(this.nativeExtensionProvider=void 0),i});return r.end({accountType:Sn(o.account),success:!0}),o}else throw te(sv);else throw te(ov)}catch(o){throw this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_BY_CODE_FAILURE,ce.Silent,null,o),r.end({success:!1},o),o}}async acquireTokenByCodeAsync(e){var o;return this.logger.trace("acquireTokenByCodeAsync called",e.correlationId),this.acquireTokenByCodeAsyncMeasurement=this.performanceClient.startMeasurement(_.AcquireTokenByCodeAsync,e.correlationId),(o=this.acquireTokenByCodeAsyncMeasurement)==null||o.increment({visibilityChangeCount:0}),document.addEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement),await this.createSilentAuthCodeClient(e.correlationId).acquireToken(e).then(i=>{var s;return(s=this.acquireTokenByCodeAsyncMeasurement)==null||s.end({success:!0,fromCache:i.fromCache,isNativeBroker:i.fromNativeBroker}),i}).catch(i=>{var s;throw(s=this.acquireTokenByCodeAsyncMeasurement)==null||s.end({success:!1},i),i}).finally(()=>{document.removeEventListener("visibilitychange",this.trackPageVisibilityWithMeasurement)})}async acquireTokenFromCache(e,n){switch(this.performanceClient.addQueueMeasurement(_.AcquireTokenFromCache,e.correlationId),n){case jt.Default:case jt.AccessToken:case jt.AccessTokenAndRefreshToken:const r=this.createSilentCacheClient(e.correlationId);return G(r.acquireToken.bind(r),_.SilentCacheClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e);default:throw j(or)}}async acquireTokenByRefreshToken(e,n){switch(this.performanceClient.addQueueMeasurement(_.AcquireTokenByRefreshToken,e.correlationId),n){case jt.Default:case jt.AccessTokenAndRefreshToken:case jt.RefreshToken:case jt.RefreshTokenAndNetwork:const r=this.createSilentRefreshClient(e.correlationId);return G(r.acquireToken.bind(r),_.SilentRefreshClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e);default:throw j(or)}}async acquireTokenBySilentIframe(e){this.performanceClient.addQueueMeasurement(_.AcquireTokenBySilentIframe,e.correlationId);const n=this.createSilentIframeClient(e.correlationId);return G(n.acquireToken.bind(n),_.SilentIframeClientAcquireToken,this.logger,this.performanceClient,e.correlationId)(e)}async logout(e){const n=this.getRequestCorrelationId(e);return this.logger.warning("logout API is deprecated and will be removed in msal-browser v3.0.0. Use logoutRedirect instead.",n),this.logoutRedirect({correlationId:n,...e})}async logoutRedirect(e){const n=this.getRequestCorrelationId(e);return $f(this.initialized,this.config),this.browserStorage.setInteractionInProgress(!0),this.createRedirectClient(n).logout(e)}logoutPopup(e){try{const n=this.getRequestCorrelationId(e);return vd(this.initialized),this.browserStorage.setInteractionInProgress(!0),this.createPopupClient(n).logout(e)}catch(n){return Promise.reject(n)}}async clearCache(e){if(!this.isBrowserEnvironment){this.logger.info("in non-browser environment, returning early.");return}const n=this.getRequestCorrelationId(e);return this.createSilentCacheClient(n).logout(e)}getAllAccounts(e){const n=this.getRequestCorrelationId();return Jk(this.logger,this.browserStorage,this.isBrowserEnvironment,n,e)}getAccount(e){const n=this.getRequestCorrelationId();return Xk(e,this.logger,this.browserStorage,n)}getAccountByUsername(e){const n=this.getRequestCorrelationId();return Zk(e,this.logger,this.browserStorage,n)}getAccountByHomeId(e){const n=this.getRequestCorrelationId();return eP(e,this.logger,this.browserStorage,n)}getAccountByLocalId(e){const n=this.getRequestCorrelationId();return tP(e,this.logger,this.browserStorage,n)}setActiveAccount(e){const n=this.getRequestCorrelationId();nP(e,this.browserStorage,n)}getActiveAccount(){const e=this.getRequestCorrelationId();return rP(this.browserStorage,e)}async hydrateCache(e,n){this.logger.verbose("hydrateCache called");const r=dt.createFromAccountInfo(e.account,e.cloudGraphHostName,e.msGraphHost);return this.browserStorage.setAccount(r,e.correlationId),e.fromNativeBroker?(this.logger.verbose("Response was from native broker, storing in-memory"),this.nativeInternalStorage.hydrateCache(e,n)):this.browserStorage.hydrateCache(e,n)}async acquireTokenNative(e,n,r){if(this.logger.trace("acquireTokenNative called"),!this.nativeExtensionProvider)throw te(As);return new Wo(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,n,this.performanceClient,this.nativeExtensionProvider,r||this.getNativeAccountId(e),this.nativeInternalStorage,e.correlationId).acquireToken(e)}canUseNative(e,n){if(this.logger.trace("canUseNative called"),!Hn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme))return this.logger.trace("canUseNative: isNativeAvailable returned false, returning false"),!1;if(e.prompt)switch(e.prompt){case gt.NONE:case gt.CONSENT:case gt.LOGIN:this.logger.trace("canUseNative: prompt is compatible with native flow");break;default:return this.logger.trace(`canUseNative: prompt = ${e.prompt} is not compatible with native flow, returning false`),!1}return!n&&!this.getNativeAccountId(e)?(this.logger.trace("canUseNative: nativeAccountId is not available, returning false"),!1):!0}getNativeAccountId(e){const n=e.account||this.getAccount({loginHint:e.loginHint,sid:e.sid})||this.getActiveAccount();return n&&n.nativeAccountId||""}createPopupClient(e){return new wP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createRedirectClient(e){return new TP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentIframeClient(e){return new RP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.ssoSilent,this.performanceClient,this.nativeInternalStorage,this.nativeExtensionProvider,e)}createSilentCacheClient(e){return new Iv(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentRefreshClient(e){return new OP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,this.performanceClient,this.nativeExtensionProvider,e)}createSilentAuthCodeClient(e){return new NP(this.config,this.browserStorage,this.browserCrypto,this.logger,this.eventHandler,this.navigationClient,ze.acquireTokenByCode,this.performanceClient,this.nativeExtensionProvider,e)}addEventCallback(e,n){return this.eventHandler.addEventCallback(e,n)}removeEventCallback(e){this.eventHandler.removeEventCallback(e)}addPerformanceCallback(e){return Av(),this.performanceClient.addPerformanceCallback(e)}removePerformanceCallback(e){return this.performanceClient.removePerformanceCallback(e)}enableAccountStorageEvents(){typeof window>"u"||(this.listeningToStorageEvents?this.logger.verbose("Account storage listener already registered."):(this.logger.verbose("Adding account storage listener."),this.listeningToStorageEvents=!0,window.addEventListener("storage",this.handleAccountCacheChange)))}disableAccountStorageEvents(){typeof window>"u"||(this.listeningToStorageEvents?(this.logger.verbose("Removing account storage listener."),window.removeEventListener("storage",this.handleAccountCacheChange),this.listeningToStorageEvents=!1):this.logger.verbose("No account storage listener registered."))}handleAccountCacheChange(e){var n;try{(n=e.key)!=null&&n.includes(ft.ACTIVE_ACCOUNT_FILTERS)&&this.eventHandler.emitEvent(me.ACTIVE_ACCOUNT_CHANGED);const r=e.newValue||e.oldValue;if(!r)return;const o=JSON.parse(r);if(typeof o!="object"||!dt.isAccountEntity(o))return;const s=ui.toObject(new dt,o).getAccountInfo();!e.oldValue&&e.newValue?(this.logger.info("Account was added to cache in a different window"),this.eventHandler.emitEvent(me.ACCOUNT_ADDED,void 0,s)):!e.newValue&&e.oldValue&&(this.logger.info("Account was removed from cache in a different window"),this.eventHandler.emitEvent(me.ACCOUNT_REMOVED,void 0,s))}catch{return}}getTokenCache(){return this.tokenCache}getLogger(){return this.logger}setLogger(e){this.logger=e}initializeWrapperLibrary(e,n){this.browserStorage.setWrapperMetadata(e,n)}setNavigationClient(e){this.navigationClient=e}getConfiguration(){return this.config}getPerformanceClient(){return this.performanceClient}isBrowserEnv(){return this.isBrowserEnvironment}getRequestCorrelationId(e){return e!=null&&e.correlationId?e.correlationId:this.isBrowserEnvironment?jn():P.EMPTY_STRING}async loginRedirect(e){const n=this.getRequestCorrelationId(e);return this.logger.verbose("loginRedirect called",n),this.acquireTokenRedirect({correlationId:n,...e||Bf})}loginPopup(e){const n=this.getRequestCorrelationId(e);return this.logger.verbose("loginPopup called",n),this.acquireTokenPopup({correlationId:n,...e||Bf})}async acquireTokenSilent(e){const n=this.getRequestCorrelationId(e),r=this.performanceClient.startMeasurement(_.AcquireTokenSilent,n);r.add({cacheLookupPolicy:e.cacheLookupPolicy,scenarioId:e.scenarioId}),$s(this.initialized,r),this.logger.verbose("acquireTokenSilent called",n);const o=e.account||this.getActiveAccount();if(!o)throw te(Jy);r.add({accountType:Sn(o)});const i={clientId:this.config.auth.clientId,authority:e.authority||P.EMPTY_STRING,scopes:e.scopes,homeAccountIdentifier:o.homeAccountId,claims:e.claims,authenticationScheme:e.authenticationScheme,resourceRequestMethod:e.resourceRequestMethod,resourceRequestUri:e.resourceRequestUri,shrClaims:e.shrClaims,sshKid:e.sshKid,shrOptions:e.shrOptions},s=JSON.stringify(i),a=this.activeSilentTokenRequests.get(s);if(typeof a>"u"){this.logger.verbose("acquireTokenSilent called for the first time, storing active request",n);const c=G(this.acquireTokenSilentAsync.bind(this),_.AcquireTokenSilentAsync,this.logger,this.performanceClient,n)({...e,correlationId:n},o).then(l=>(this.activeSilentTokenRequests.delete(s),r.end({success:!0,fromCache:l.fromCache,isNativeBroker:l.fromNativeBroker,cacheLookupPolicy:e.cacheLookupPolicy,accessTokenSize:l.accessToken.length,idTokenSize:l.idToken.length}),l)).catch(l=>{throw this.activeSilentTokenRequests.delete(s),r.end({success:!1},l),l});return this.activeSilentTokenRequests.set(s,c),{...await c,state:e.state}}else return this.logger.verbose("acquireTokenSilent has been called previously, returning the result from the first call",n),r.discard(),{...await a,state:e.state}}async acquireTokenSilentAsync(e,n){const r=()=>this.trackPageVisibility(e.correlationId);this.performanceClient.addQueueMeasurement(_.AcquireTokenSilentAsync,e.correlationId),this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_START,ce.Silent,e),e.correlationId&&this.performanceClient.incrementFields({visibilityChangeCount:0},e.correlationId),document.addEventListener("visibilitychange",r);const o=await G(lP,_.InitializeSilentRequest,this.logger,this.performanceClient,e.correlationId)(e,n,this.config,this.performanceClient,this.logger),i=e.cacheLookupPolicy||jt.Default;return this.acquireTokenSilentNoIframe(o,i).catch(async a=>{if(xP(a,i))if(this.activeIframeRequest)if(i!==jt.Skip){const[l,u]=this.activeIframeRequest;this.logger.verbose(`Iframe request is already in progress, awaiting resolution for request with correlationId: ${u}`,o.correlationId);const d=this.performanceClient.startMeasurement(_.AwaitConcurrentIframe,o.correlationId);d.add({awaitIframeCorrelationId:u});const h=await l;if(d.end({success:h}),h)return this.logger.verbose(`Parallel iframe request with correlationId: ${u} succeeded. Retrying cache and/or RT redemption`,o.correlationId),this.acquireTokenSilentNoIframe(o,i);throw this.logger.info(`Iframe request with correlationId: ${u} failed. Interaction is required.`),a}else return this.logger.warning("Another iframe request is currently in progress and CacheLookupPolicy is set to Skip. This may result in degraded performance and/or reliability for both calls. Please consider changing the CacheLookupPolicy to take advantage of request queuing and token cache.",o.correlationId),G(this.acquireTokenBySilentIframe.bind(this),_.AcquireTokenBySilentIframe,this.logger,this.performanceClient,o.correlationId)(o);else{let l;return this.activeIframeRequest=[new Promise(u=>{l=u}),o.correlationId],this.logger.verbose("Refresh token expired/invalid or CacheLookupPolicy is set to Skip, attempting acquire token by iframe.",o.correlationId),G(this.acquireTokenBySilentIframe.bind(this),_.AcquireTokenBySilentIframe,this.logger,this.performanceClient,o.correlationId)(o).then(u=>(l(!0),u)).catch(u=>{throw l(!1),u}).finally(()=>{this.activeIframeRequest=void 0})}else throw a}).then(a=>(this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_SUCCESS,ce.Silent,a),e.correlationId&&this.performanceClient.addFields({fromCache:a.fromCache,isNativeBroker:a.fromNativeBroker},e.correlationId),a)).catch(a=>{throw this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_FAILURE,ce.Silent,null,a),a}).finally(()=>{document.removeEventListener("visibilitychange",r)})}async acquireTokenSilentNoIframe(e,n){return Hn.isNativeAvailable(this.config,this.logger,this.nativeExtensionProvider,e.authenticationScheme)&&e.account.nativeAccountId?(this.logger.verbose("acquireTokenSilent - attempting to acquire token from native platform"),this.acquireTokenNative(e,ze.acquireTokenSilent_silentFlow).catch(async r=>{throw r instanceof Ln&&Uo(r)?(this.logger.verbose("acquireTokenSilent - native platform unavailable, falling back to web flow"),this.nativeExtensionProvider=void 0,j(or)):r})):(this.logger.verbose("acquireTokenSilent - attempting to acquire token from web flow"),G(this.acquireTokenFromCache.bind(this),_.AcquireTokenFromCache,this.logger,this.performanceClient,e.correlationId)(e,n).catch(r=>{if(n===jt.AccessToken)throw r;return this.eventHandler.emitEvent(me.ACQUIRE_TOKEN_NETWORK_START,ce.Silent,e),G(this.acquireTokenByRefreshToken.bind(this),_.AcquireTokenByRefreshToken,this.logger,this.performanceClient,e.correlationId)(e,n)}))}}function xP(t,e){const n=!(t instanceof En&&t.subError!==dc),r=t.errorCode===Qt.INVALID_GRANT_ERROR||t.errorCode===or,o=n&&r||t.errorCode===va||t.errorCode===rd,i=pk.includes(e);return o&&i}/*! @azure/msal-browser v3.30.0 2025-08-05 */async function MP(t,e){const n=new Ao(t);return await n.initialize(),mc.createController(n,e)}/*! @azure/msal-browser v3.30.0 2025-08-05 */class Td{static async createPublicClientApplication(e){const n=await MP(e);return new Td(e,n)}constructor(e,n){this.controller=n||new mc(new Ao(e))}async initialize(e){return this.controller.initialize(e)}async acquireTokenPopup(e){return this.controller.acquireTokenPopup(e)}acquireTokenRedirect(e){return this.controller.acquireTokenRedirect(e)}acquireTokenSilent(e){return this.controller.acquireTokenSilent(e)}acquireTokenByCode(e){return this.controller.acquireTokenByCode(e)}addEventCallback(e,n){return this.controller.addEventCallback(e,n)}removeEventCallback(e){return this.controller.removeEventCallback(e)}addPerformanceCallback(e){return this.controller.addPerformanceCallback(e)}removePerformanceCallback(e){return this.controller.removePerformanceCallback(e)}enableAccountStorageEvents(){this.controller.enableAccountStorageEvents()}disableAccountStorageEvents(){this.controller.disableAccountStorageEvents()}getAccount(e){return this.controller.getAccount(e)}getAccountByHomeId(e){return this.controller.getAccountByHomeId(e)}getAccountByLocalId(e){return this.controller.getAccountByLocalId(e)}getAccountByUsername(e){return this.controller.getAccountByUsername(e)}getAllAccounts(e){return this.controller.getAllAccounts(e)}handleRedirectPromise(e){return this.controller.handleRedirectPromise(e)}loginPopup(e){return this.controller.loginPopup(e)}loginRedirect(e){return this.controller.loginRedirect(e)}logout(e){return this.controller.logout(e)}logoutRedirect(e){return this.controller.logoutRedirect(e)}logoutPopup(e){return this.controller.logoutPopup(e)}ssoSilent(e){return this.controller.ssoSilent(e)}getTokenCache(){return this.controller.getTokenCache()}getLogger(){return this.controller.getLogger()}setLogger(e){this.controller.setLogger(e)}setActiveAccount(e){this.controller.setActiveAccount(e)}getActiveAccount(){return this.controller.getActiveAccount()}initializeWrapperLibrary(e,n){return this.controller.initializeWrapperLibrary(e,n)}setNavigationClient(e){this.controller.setNavigationClient(e)}getConfiguration(){return this.controller.getConfiguration()}async hydrateCache(e,n){return this.controller.hydrateCache(e,n)}clearCache(e){return this.controller.clearCache(e)}}const Aa=new Td({auth:{clientId:"9079054c-9620-4757-a256-23413042f1ef",authority:"https://login.microsoftonline.com/e519c2e6-bc6d-4fdf-8d9c-923c2f002385",redirectUri:"https://optical-dev.oliver.solutions/cc-dashboard/"},cache:{cacheLocation:"sessionStorage",storeAuthStateInCookie:!1}}),DP=["openid","profile","email"];async function LP(){await Aa.initialize(),await Aa.handleRedirectPromise()}const kv=wA("auth",()=>{const t=J(null),e=J(null),n=J(!1),r=J(null),o=Q(()=>t.value!==null),i=Q(()=>{var u;return((u=e.value)==null?void 0:u.role)==="admin"});async function s(){var u,d;n.value=!0,r.value=null;try{const f=(await Aa.loginPopup({scopes:DP})).idToken,p=await ua.post("/api/auth/microsoft",{id_token:f});t.value=p.data.access_token,await c()}catch(h){const f=h;throw r.value=((d=(u=f.response)==null?void 0:u.data)==null?void 0:d.detail)??f.message??"Login failed",h}finally{n.value=!1}}async function a(){t.value=null,e.value=null;try{await Aa.clearCache()}catch{}}async function c(){const u=await ua.get("/api/auth/me");e.value=u.data}function l(){return t.value}return{token:t,user:e,loading:n,error:r,isAuthenticated:o,isAdmin:i,loginWithMicrosoft:s,logout:a,fetchMe:c,getToken:l}}),UP=[{path:"/login",name:"login",component:()=>Ht(()=>import("./LoginView-Dy4ecRek.js"),__vite__mapDeps([0,1,2])),meta:{public:!0}},{path:"/",component:()=>Ht(()=>import("./AppLayout-9kXWPrU9.js"),[]),children:[{path:"",name:"dashboard",component:()=>Ht(()=>import("./DashboardView-Bg0DXGZC.js"),__vite__mapDeps([3,4,1,2,5,6,7,8,9,10,11,12,13,14]))},{path:"calendar",name:"calendar",component:()=>Ht(()=>import("./CalendarView-myth_Gpl.js"),__vite__mapDeps([15,4,2,6,7,16,17,9,13,18,19,20,21,22,23,14,24,25]))},{path:"tasks",name:"tasks",component:()=>Ht(()=>import("./TasksView-v6kl3APd.js"),__vite__mapDeps([26,13,20,21,6,7,2,22,23,14,12,27]))},{path:"omg",name:"omg",component:()=>Ht(()=>import("./OmgView-4RQpS0NB.js"),__vite__mapDeps([28,23,2,21,6,7,22,24,9,12,27,29,30]))},{path:"projects",name:"projects",component:()=>Ht(()=>import("./ProjectsView-BIEkK9YZ.js"),__vite__mapDeps([31,4,1,2,11,9,7,16,27,6,32]))},{path:"projects/:id/:date?",name:"project-detail",component:()=>Ht(()=>import("./ProjectDetailView-ZLh0yx2w.js"),__vite__mapDeps([33,4,1,2,5,8,22,6,7,27,12,29,9,10]))},{path:"live",name:"live",component:()=>Ht(()=>import("./LiveView-DS0o7b1g.js"),__vite__mapDeps([34,1,2,6,7,8,27,9,32]))},{path:"reports",name:"reports",component:()=>Ht(()=>import("./ReportsView-C9gnodtt.js"),__vite__mapDeps([35,1,2,19,6,7,16,27,29,9,36,18,37]))},{path:"keys",name:"keys",component:()=>Ht(()=>import("./KeysView-D20WCgag.js"),__vite__mapDeps([38,39,1,2,6,7,21,22,24,9,27,30]))},{path:"devops",name:"devops",component:()=>Ht(()=>import("./DevopsView-CWz6iIis.js"),__vite__mapDeps([40,14,1,2,5,6,7,22,27,16,12,41,24,9]))},{path:"settings",name:"settings",component:()=>Ht(()=>import("./SettingsView-Di3_0rdi.js"),__vite__mapDeps([42,14,1,2,5,22,6,7,17,9,36,41,24]))},{path:"admin",name:"admin",component:()=>Ht(()=>import("./AdminView-Y8GgaF2G.js"),__vite__mapDeps([43,39,1,2,19,7])),meta:{adminOnly:!0}}]},{path:"/:pathMatch(.*)*",redirect:"/"}],Ql=AS({history:Z_("/cc-dashboard/"),routes:UP});Ql.beforeEach((t,e,n)=>{const r=kv();if(t.meta.public){n();return}if(!r.isAuthenticated){n({name:"login",query:{redirect:t.fullPath}});return}if(t.meta.adminOnly&&!r.isAdmin){n({name:"dashboard"});return}n()});LP().then(()=>{const t=dA(f_),e=pA();t.use(e),t.use(Ql),t.use(tT);const n=kv();lR(()=>n.getToken(),()=>{n.logout(),Ql.push({name:"login"})}),t.mount("#app")});export{ZP as $,vn as A,wA as B,Qi as C,ua as D,KP as E,nt as F,To as G,PC as H,gC as I,s0 as J,VP as K,c0 as L,n0 as M,r0 as N,t0 as O,GP as P,QP as Q,mS as R,o0 as S,FP as T,a0 as U,WP as V,i0 as W,JP as X,XP as Y,YP as Z,Ht as _,Cn as a,zP as a0,fo as a1,BP as b,Xe as c,ye as d,Pe as e,l0 as f,u0 as g,I as h,er as i,Q as j,fe as k,Zr as l,Ke as m,Gt as n,Y as o,le as p,ta as q,nl as r,J as s,Ho as t,kv as u,VC as v,se as w,ut as x,Fa as y,Fn as z}; diff --git a/src/static/assets/index-bBdb_PCl.css b/src/static/assets/index-bBdb_PCl.css deleted file mode 100644 index e1c36a1..0000000 --- a/src/static/assets/index-bBdb_PCl.css +++ /dev/null @@ -1 +0,0 @@ -@import"https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap";*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-pan-x: ;--tw-pan-y: ;--tw-pinch-zoom: ;--tw-scroll-snap-strictness: proximity;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*,:before,:after{box-sizing:border-box;border-width:0;border-style:solid;border-color:#e5e7eb}:before,:after{--tw-content: ""}html,:host{line-height:1.5;-webkit-text-size-adjust:100%;-moz-tab-size:4;-o-tab-size:4;tab-size:4;font-family:ui-sans-serif,system-ui,sans-serif,"Apple Color Emoji","Segoe UI Emoji",Segoe UI Symbol,"Noto Color Emoji";font-feature-settings:normal;font-variation-settings:normal;-webkit-tap-highlight-color:transparent}body{margin:0;line-height:inherit}hr{height:0;color:inherit;border-top-width:1px}abbr:where([title]){-webkit-text-decoration:underline dotted;text-decoration:underline dotted}h1,h2,h3,h4,h5,h6{font-size:inherit;font-weight:inherit}a{color:inherit;text-decoration:inherit}b,strong{font-weight:bolder}code,kbd,samp,pre{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace;font-feature-settings:normal;font-variation-settings:normal;font-size:1em}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-.25em}sup{top:-.5em}table{text-indent:0;border-color:inherit;border-collapse:collapse}button,input,optgroup,select,textarea{font-family:inherit;font-feature-settings:inherit;font-variation-settings:inherit;font-size:100%;font-weight:inherit;line-height:inherit;letter-spacing:inherit;color:inherit;margin:0;padding:0}button,select{text-transform:none}button,input:where([type=button]),input:where([type=reset]),input:where([type=submit]){-webkit-appearance:button;background-color:transparent;background-image:none}:-moz-focusring{outline:auto}:-moz-ui-invalid{box-shadow:none}progress{vertical-align:baseline}::-webkit-inner-spin-button,::-webkit-outer-spin-button{height:auto}[type=search]{-webkit-appearance:textfield;outline-offset:-2px}::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}summary{display:list-item}blockquote,dl,dd,h1,h2,h3,h4,h5,h6,hr,figure,p,pre{margin:0}fieldset{margin:0;padding:0}legend{padding:0}ol,ul,menu{list-style:none;margin:0;padding:0}dialog{padding:0}textarea{resize:vertical}input::-moz-placeholder,textarea::-moz-placeholder{opacity:1;color:#9ca3af}input::placeholder,textarea::placeholder{opacity:1;color:#9ca3af}button,[role=button]{cursor:pointer}:disabled{cursor:default}img,svg,video,canvas,audio,iframe,embed,object{display:block;vertical-align:middle}img,video{max-width:100%;height:auto}[hidden]:where(:not([hidden=until-found])){display:none}:root{--background: 220 33% 96%;--foreground: 222 47% 11%;--card: 0 0% 100%;--card-foreground: 222 47% 11%;--popover: 0 0% 100%;--popover-foreground: 222 47% 11%;--primary: 25 95% 53%;--primary-foreground: 0 0% 100%;--secondary: 200 85% 50%;--secondary-foreground: 0 0% 100%;--muted: 220 20% 93%;--muted-foreground: 215 20% 48%;--accent: 25 100% 96%;--accent-foreground: 25 95% 40%;--destructive: 0 84% 60%;--destructive-foreground: 0 0% 100%;--border: 220 20% 88%;--input: 220 20% 88%;--ring: 25 95% 53%;--radius: .75rem;--success: 142 71% 45%;--warning: 38 92% 50%}.dark{--background: 226 49% 8%;--foreground: 220 40% 92%;--card: 220 44% 10%;--card-foreground: 220 40% 92%;--popover: 220 44% 12%;--popover-foreground: 220 40% 92%;--primary: 25 95% 60%;--primary-foreground: 226 49% 8%;--secondary: 200 85% 55%;--secondary-foreground: 226 49% 8%;--muted: 220 30% 14%;--muted-foreground: 220 12% 52%;--accent: 220 30% 14%;--accent-foreground: 220 40% 92%;--destructive: 0 72% 51%;--destructive-foreground: 220 40% 98%;--border: 220 28% 17%;--input: 220 28% 17%;--ring: 25 95% 60%;--success: 158 64% 52%;--warning: 38 92% 60%}*{border-color:hsl(var(--border))}body{background-color:hsl(var(--background));color:hsl(var(--foreground));font-family:Inter,system-ui,-apple-system,sans-serif;font-feature-settings:"rlig" 1,"calt" 1;-webkit-font-smoothing:antialiased}.tabular-nums,[data-value],.kpi-value{font-family:JetBrains Mono,ui-monospace,monospace;font-variant-numeric:tabular-nums}::-webkit-scrollbar{width:4px;height:4px}::-webkit-scrollbar-track{background:transparent}::-webkit-scrollbar-thumb{background:#c2c9d6;border-radius:9999px}::-webkit-scrollbar-thumb:hover{background:#9da8be}.container{width:100%}@media (min-width: 640px){.container{max-width:640px}}@media (min-width: 768px){.container{max-width:768px}}@media (min-width: 1024px){.container{max-width:1024px}}@media (min-width: 1280px){.container{max-width:1280px}}@media (min-width: 1536px){.container{max-width:1536px}}.pointer-events-none{pointer-events:none}.visible{visibility:visible}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.sticky{position:sticky}.inset-0{top:0;right:0;bottom:0;left:0}.inset-y-0{top:0;bottom:0}.-right-2{right:-.5rem}.-right-6{right:-1.5rem}.-top-2{top:-.5rem}.-top-6{top:-1.5rem}.bottom-0{bottom:0}.left-0{left:0}.left-1\/2{left:50%}.right-0{right:0}.right-2{right:.5rem}.top-0{top:0}.top-1\/2{top:50%}.z-0{z-index:0}.z-10{z-index:10}.z-20{z-index:20}.z-30{z-index:30}.z-40{z-index:40}.z-50{z-index:50}.mx-1{margin-left:.25rem;margin-right:.25rem}.mx-auto{margin-left:auto;margin-right:auto}.mb-1{margin-bottom:.25rem}.mb-1\.5{margin-bottom:.375rem}.mb-2{margin-bottom:.5rem}.mb-3{margin-bottom:.75rem}.mb-4{margin-bottom:1rem}.mb-6{margin-bottom:1.5rem}.mb-8{margin-bottom:2rem}.ml-2{margin-left:.5rem}.ml-auto{margin-left:auto}.mr-1\.5{margin-right:.375rem}.mr-2{margin-right:.5rem}.mt-0\.5{margin-top:.125rem}.mt-1{margin-top:.25rem}.mt-1\.5{margin-top:.375rem}.mt-2{margin-top:.5rem}.mt-3{margin-top:.75rem}.mt-4{margin-top:1rem}.mt-6{margin-top:1.5rem}.mt-auto{margin-top:auto}.line-clamp-2{overflow:hidden;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2}.\!block{display:block!important}.block{display:block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.table{display:table}.grid{display:grid}.hidden{display:none}.h-0\.5{height:.125rem}.h-1\.5{height:.375rem}.h-10{height:2.5rem}.h-11{height:2.75rem}.h-12{height:3rem}.h-14{height:3.5rem}.h-16{height:4rem}.h-2{height:.5rem}.h-20{height:5rem}.h-24{height:6rem}.h-3{height:.75rem}.h-3\.5{height:.875rem}.h-32{height:8rem}.h-4{height:1rem}.h-40{height:10rem}.h-48{height:12rem}.h-5{height:1.25rem}.h-6{height:1.5rem}.h-64{height:16rem}.h-7{height:1.75rem}.h-8{height:2rem}.h-9{height:2.25rem}.h-full{height:100%}.h-screen{height:100vh}.max-h-\[85vh\]{max-height:85vh}.min-h-0{min-height:0px}.min-h-\[120px\]{min-height:120px}.min-h-screen{min-height:100vh}.w-1{width:.25rem}.w-1\.5{width:.375rem}.w-10{width:2.5rem}.w-11{width:2.75rem}.w-12{width:3rem}.w-14{width:3.5rem}.w-16{width:4rem}.w-2{width:.5rem}.w-20{width:5rem}.w-24{width:6rem}.w-3{width:.75rem}.w-3\.5{width:.875rem}.w-32{width:8rem}.w-36{width:9rem}.w-4{width:1rem}.w-44{width:11rem}.w-5{width:1.25rem}.w-56{width:14rem}.w-6{width:1.5rem}.w-60{width:15rem}.w-7{width:1.75rem}.w-72{width:18rem}.w-8{width:2rem}.w-9{width:2.25rem}.w-auto{width:auto}.w-full{width:100%}.w-px{width:1px}.min-w-0{min-width:0px}.min-w-\[700px\]{min-width:700px}.max-w-2xl{max-width:42rem}.max-w-\[100px\]{max-width:100px}.max-w-\[120px\]{max-width:120px}.max-w-\[160px\]{max-width:160px}.max-w-\[200px\]{max-width:200px}.max-w-\[280px\]{max-width:280px}.max-w-lg{max-width:32rem}.max-w-md{max-width:28rem}.max-w-none{max-width:none}.max-w-sm{max-width:24rem}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.table-fixed{table-layout:fixed}.border-collapse{border-collapse:collapse}.-translate-x-1\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-x-full{--tw-translate-x: -100%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-translate-y-1\/2{--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.translate-y-1{--tw-translate-y: .25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.-rotate-6{--tw-rotate: -6deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-180{--tw-rotate: 180deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.rotate-6{--tw-rotate: 6deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.scale-95{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes pulse{50%{opacity:.5}}.animate-pulse{animation:pulse 2s cubic-bezier(.4,0,.6,1) infinite}@keyframes spin{to{transform:rotate(360deg)}}.animate-spin{animation:spin 1s linear infinite}.cursor-col-resize{cursor:col-resize}.cursor-default{cursor:default}.cursor-grab{cursor:grab}.cursor-not-allowed{cursor:not-allowed}.cursor-pointer{cursor:pointer}.cursor-s-resize{cursor:s-resize}.select-none{-webkit-user-select:none;-moz-user-select:none;user-select:none}.resize-none{resize:none}.resize{resize:both}.grid-cols-1{grid-template-columns:repeat(1,minmax(0,1fr))}.grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.grid-cols-7{grid-template-columns:repeat(7,minmax(0,1fr))}.grid-cols-\[1fr_1fr_140px_96px\]{grid-template-columns:1fr 1fr 140px 96px}.grid-cols-\[1fr_auto_auto_auto_auto\]{grid-template-columns:1fr auto auto auto auto}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-start{align-items:flex-start}.items-end{align-items:flex-end}.items-center{align-items:center}.justify-start{justify-content:flex-start}.justify-end{justify-content:flex-end}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-2\.5{gap:.625rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.gap-6{gap:1.5rem}.gap-px{gap:1px}.space-x-2>:not([hidden])~:not([hidden]){--tw-space-x-reverse: 0;margin-right:calc(.5rem * var(--tw-space-x-reverse));margin-left:calc(.5rem * calc(1 - var(--tw-space-x-reverse)))}.space-y-0>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(0px * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(0px * var(--tw-space-y-reverse))}.space-y-0\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.125rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.125rem * var(--tw-space-y-reverse))}.space-y-1>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.25rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.25rem * var(--tw-space-y-reverse))}.space-y-1\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.375rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.375rem * var(--tw-space-y-reverse))}.space-y-2>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.5rem * var(--tw-space-y-reverse))}.space-y-2\.5>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.625rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.625rem * var(--tw-space-y-reverse))}.space-y-3>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(.75rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(.75rem * var(--tw-space-y-reverse))}.space-y-4>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1rem * var(--tw-space-y-reverse))}.space-y-6>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(1.5rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(1.5rem * var(--tw-space-y-reverse))}.space-y-8>:not([hidden])~:not([hidden]){--tw-space-y-reverse: 0;margin-top:calc(2rem * calc(1 - var(--tw-space-y-reverse)));margin-bottom:calc(2rem * var(--tw-space-y-reverse))}.overflow-auto{overflow:auto}.overflow-hidden{overflow:hidden}.overflow-x-auto{overflow-x:auto}.overflow-y-auto{overflow-y:auto}.overflow-y-hidden{overflow-y:hidden}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.break-words{overflow-wrap:break-word}.break-all{word-break:break-all}.rounded{border-radius:.25rem}.rounded-2xl{border-radius:1rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:var(--radius)}.rounded-md{border-radius:calc(var(--radius) - 2px)}.rounded-none{border-radius:0}.rounded-xl{border-radius:.75rem}.rounded-l-md{border-top-left-radius:calc(var(--radius) - 2px);border-bottom-left-radius:calc(var(--radius) - 2px)}.rounded-r-full{border-top-right-radius:9999px;border-bottom-right-radius:9999px}.rounded-r-md{border-top-right-radius:calc(var(--radius) - 2px);border-bottom-right-radius:calc(var(--radius) - 2px)}.rounded-t{border-top-left-radius:.25rem;border-top-right-radius:.25rem}.border{border-width:1px}.border-0{border-width:0px}.border-2{border-width:2px}.border-b{border-bottom-width:1px}.border-l{border-left-width:1px}.border-r{border-right-width:1px}.border-t{border-top-width:1px}.border-t-4{border-top-width:4px}.border-dashed{border-style:dashed}.border-amber-500\/30{border-color:#f59e0b4d}.border-blue-100{--tw-border-opacity: 1;border-color:rgb(219 234 254 / var(--tw-border-opacity, 1))}.border-border{border-color:hsl(var(--border))}.border-border\/20{border-color:hsl(var(--border) / .2)}.border-border\/30{border-color:hsl(var(--border) / .3)}.border-border\/40{border-color:hsl(var(--border) / .4)}.border-border\/50{border-color:hsl(var(--border) / .5)}.border-border\/60{border-color:hsl(var(--border) / .6)}.border-border\/70{border-color:hsl(var(--border) / .7)}.border-destructive\/30{border-color:hsl(var(--destructive) / .3)}.border-emerald-100{--tw-border-opacity: 1;border-color:rgb(209 250 229 / var(--tw-border-opacity, 1))}.border-emerald-500\/30{border-color:#10b9814d}.border-input{border-color:hsl(var(--input))}.border-muted-foreground\/30{border-color:hsl(var(--muted-foreground) / .3)}.border-orange-300{--tw-border-opacity: 1;border-color:rgb(253 186 116 / var(--tw-border-opacity, 1))}.border-primary{border-color:hsl(var(--primary))}.border-primary\/20{border-color:hsl(var(--primary) / .2)}.border-slate-100{--tw-border-opacity: 1;border-color:rgb(241 245 249 / var(--tw-border-opacity, 1))}.border-slate-200\/80{border-color:#e2e8f0cc}.border-transparent{border-color:transparent}.border-t-blue-400{--tw-border-opacity: 1;border-top-color:rgb(96 165 250 / var(--tw-border-opacity, 1))}.border-t-emerald-400{--tw-border-opacity: 1;border-top-color:rgb(52 211 153 / var(--tw-border-opacity, 1))}.border-t-orange-400{--tw-border-opacity: 1;border-top-color:rgb(251 146 60 / var(--tw-border-opacity, 1))}.border-t-slate-300{--tw-border-opacity: 1;border-top-color:rgb(203 213 225 / var(--tw-border-opacity, 1))}.bg-amber-500{--tw-bg-opacity: 1;background-color:rgb(245 158 11 / var(--tw-bg-opacity, 1))}.bg-amber-500\/10{background-color:#f59e0b1a}.bg-amber-500\/20{background-color:#f59e0b33}.bg-background{background-color:hsl(var(--background))}.bg-black\/5{background-color:#0000000d}.bg-black\/60{background-color:#0009}.bg-blue-50{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.bg-border{background-color:hsl(var(--border))}.bg-card{background-color:hsl(var(--card))}.bg-destructive{background-color:hsl(var(--destructive))}.bg-destructive\/10{background-color:hsl(var(--destructive) / .1)}.bg-destructive\/20{background-color:hsl(var(--destructive) / .2)}.bg-destructive\/90{background-color:hsl(var(--destructive) / .9)}.bg-emerald-400{--tw-bg-opacity: 1;background-color:rgb(52 211 153 / var(--tw-bg-opacity, 1))}.bg-emerald-50{--tw-bg-opacity: 1;background-color:rgb(236 253 245 / var(--tw-bg-opacity, 1))}.bg-emerald-500{--tw-bg-opacity: 1;background-color:rgb(16 185 129 / var(--tw-bg-opacity, 1))}.bg-emerald-500\/10{background-color:#10b9811a}.bg-emerald-500\/20{background-color:#10b98133}.bg-muted{background-color:hsl(var(--muted))}.bg-muted-foreground\/30{background-color:hsl(var(--muted-foreground) / .3)}.bg-muted\/30{background-color:hsl(var(--muted) / .3)}.bg-muted\/40{background-color:hsl(var(--muted) / .4)}.bg-muted\/50{background-color:hsl(var(--muted) / .5)}.bg-orange-400{--tw-bg-opacity: 1;background-color:rgb(251 146 60 / var(--tw-bg-opacity, 1))}.bg-orange-50{--tw-bg-opacity: 1;background-color:rgb(255 247 237 / var(--tw-bg-opacity, 1))}.bg-orange-50\/60{background-color:#fff7ed99}.bg-orange-500{--tw-bg-opacity: 1;background-color:rgb(249 115 22 / var(--tw-bg-opacity, 1))}.bg-primary{background-color:hsl(var(--primary))}.bg-primary\/10{background-color:hsl(var(--primary) / .1)}.bg-primary\/15{background-color:hsl(var(--primary) / .15)}.bg-primary\/20{background-color:hsl(var(--primary) / .2)}.bg-primary\/5{background-color:hsl(var(--primary) / .05)}.bg-primary\/70{background-color:hsl(var(--primary) / .7)}.bg-primary\/90{background-color:hsl(var(--primary) / .9)}.bg-red-500{--tw-bg-opacity: 1;background-color:rgb(239 68 68 / var(--tw-bg-opacity, 1))}.bg-rose-500{--tw-bg-opacity: 1;background-color:rgb(244 63 94 / var(--tw-bg-opacity, 1))}.bg-rose-500\/10{background-color:#f43f5e1a}.bg-secondary{background-color:hsl(var(--secondary))}.bg-secondary\/80{background-color:hsl(var(--secondary) / .8)}.bg-slate-100{--tw-bg-opacity: 1;background-color:rgb(241 245 249 / var(--tw-bg-opacity, 1))}.bg-slate-300{--tw-bg-opacity: 1;background-color:rgb(203 213 225 / var(--tw-bg-opacity, 1))}.bg-slate-50{--tw-bg-opacity: 1;background-color:rgb(248 250 252 / var(--tw-bg-opacity, 1))}.bg-slate-50\/60{background-color:#f8fafc99}.bg-transparent{background-color:transparent}.bg-white{--tw-bg-opacity: 1;background-color:rgb(255 255 255 / var(--tw-bg-opacity, 1))}.bg-white\/40{background-color:#fff6}.bg-white\/60{background-color:#fff9}.bg-white\/80{background-color:#fffc}.bg-gradient-to-br{background-image:linear-gradient(to bottom right,var(--tw-gradient-stops))}.from-orange-400{--tw-gradient-from: #fb923c var(--tw-gradient-from-position);--tw-gradient-to: rgb(251 146 60 / 0) var(--tw-gradient-to-position);--tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to)}.to-orange-600{--tw-gradient-to: #ea580c var(--tw-gradient-to-position)}.object-cover{-o-object-fit:cover;object-fit:cover}.p-0{padding:0}.p-1{padding:.25rem}.p-1\.5{padding:.375rem}.p-12{padding:3rem}.p-2{padding:.5rem}.p-3{padding:.75rem}.p-4{padding:1rem}.p-5{padding:1.25rem}.p-6{padding:1.5rem}.p-8{padding:2rem}.px-0{padding-left:0;padding-right:0}.px-1{padding-left:.25rem;padding-right:.25rem}.px-1\.5{padding-left:.375rem;padding-right:.375rem}.px-2{padding-left:.5rem;padding-right:.5rem}.px-2\.5{padding-left:.625rem;padding-right:.625rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-4{padding-left:1rem;padding-right:1rem}.px-5{padding-left:1.25rem;padding-right:1.25rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.px-8{padding-left:2rem;padding-right:2rem}.py-0{padding-top:0;padding-bottom:0}.py-0\.5{padding-top:.125rem;padding-bottom:.125rem}.py-1{padding-top:.25rem;padding-bottom:.25rem}.py-1\.5{padding-top:.375rem;padding-bottom:.375rem}.py-10{padding-top:2.5rem;padding-bottom:2.5rem}.py-12{padding-top:3rem;padding-bottom:3rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-4{padding-top:1rem;padding-bottom:1rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.py-8{padding-top:2rem;padding-bottom:2rem}.pb-2{padding-bottom:.5rem}.pb-4{padding-bottom:1rem}.pb-6{padding-bottom:1.5rem}.pt-0{padding-top:0}.pt-3{padding-top:.75rem}.pt-4{padding-top:1rem}.pt-6{padding-top:1.5rem}.text-left{text-align:left}.text-center{text-align:center}.text-right{text-align:right}.font-mono{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.text-2xl{font-size:1.5rem;line-height:2rem}.text-\[10px\]{font-size:10px}.text-\[11px\]{font-size:11px}.text-base{font-size:1rem;line-height:1.5rem}.text-lg{font-size:1.125rem;line-height:1.75rem}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xl{font-size:1.25rem;line-height:1.75rem}.text-xs{font-size:.75rem;line-height:1rem}.font-bold{font-weight:700}.font-medium{font-weight:500}.font-normal{font-weight:400}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.italic{font-style:italic}.tabular-nums{--tw-numeric-spacing: tabular-nums;font-variant-numeric:var(--tw-ordinal) var(--tw-slashed-zero) var(--tw-numeric-figure) var(--tw-numeric-spacing) var(--tw-numeric-fraction)}.leading-none{line-height:1}.leading-snug{line-height:1.375}.leading-tight{line-height:1.25}.tracking-tight{letter-spacing:-.025em}.tracking-wide{letter-spacing:.025em}.tracking-wider{letter-spacing:.05em}.tracking-widest{letter-spacing:.1em}.text-accent-foreground{color:hsl(var(--accent-foreground))}.text-amber-400{--tw-text-opacity: 1;color:rgb(251 191 36 / var(--tw-text-opacity, 1))}.text-amber-500{--tw-text-opacity: 1;color:rgb(245 158 11 / var(--tw-text-opacity, 1))}.text-amber-700{--tw-text-opacity: 1;color:rgb(180 83 9 / var(--tw-text-opacity, 1))}.text-blue-400{--tw-text-opacity: 1;color:rgb(96 165 250 / var(--tw-text-opacity, 1))}.text-blue-500{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.text-blue-600{--tw-text-opacity: 1;color:rgb(37 99 235 / var(--tw-text-opacity, 1))}.text-card-foreground{color:hsl(var(--card-foreground))}.text-current{color:currentColor}.text-destructive{color:hsl(var(--destructive))}.text-destructive-foreground{color:hsl(var(--destructive-foreground))}.text-emerald-400{--tw-text-opacity: 1;color:rgb(52 211 153 / var(--tw-text-opacity, 1))}.text-emerald-600{--tw-text-opacity: 1;color:rgb(5 150 105 / var(--tw-text-opacity, 1))}.text-emerald-700{--tw-text-opacity: 1;color:rgb(4 120 87 / var(--tw-text-opacity, 1))}.text-foreground{color:hsl(var(--foreground))}.text-gray-700{--tw-text-opacity: 1;color:rgb(55 65 81 / var(--tw-text-opacity, 1))}.text-muted-foreground{color:hsl(var(--muted-foreground))}.text-muted-foreground\/20{color:hsl(var(--muted-foreground) / .2)}.text-muted-foreground\/30{color:hsl(var(--muted-foreground) / .3)}.text-muted-foreground\/40{color:hsl(var(--muted-foreground) / .4)}.text-muted-foreground\/60{color:hsl(var(--muted-foreground) / .6)}.text-orange-500{--tw-text-opacity: 1;color:rgb(249 115 22 / var(--tw-text-opacity, 1))}.text-orange-600{--tw-text-opacity: 1;color:rgb(234 88 12 / var(--tw-text-opacity, 1))}.text-primary{color:hsl(var(--primary))}.text-primary-foreground{color:hsl(var(--primary-foreground))}.text-red-400{--tw-text-opacity: 1;color:rgb(248 113 113 / var(--tw-text-opacity, 1))}.text-red-500{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.text-rose-600{--tw-text-opacity: 1;color:rgb(225 29 72 / var(--tw-text-opacity, 1))}.text-rose-700{--tw-text-opacity: 1;color:rgb(190 18 60 / var(--tw-text-opacity, 1))}.text-secondary-foreground{color:hsl(var(--secondary-foreground))}.text-slate-400{--tw-text-opacity: 1;color:rgb(148 163 184 / var(--tw-text-opacity, 1))}.text-slate-500{--tw-text-opacity: 1;color:rgb(100 116 139 / var(--tw-text-opacity, 1))}.text-slate-700{--tw-text-opacity: 1;color:rgb(51 65 85 / var(--tw-text-opacity, 1))}.text-slate-800{--tw-text-opacity: 1;color:rgb(30 41 59 / var(--tw-text-opacity, 1))}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.underline-offset-4{text-underline-offset:4px}.opacity-0{opacity:0}.opacity-100{opacity:1}.opacity-25{opacity:.25}.opacity-40{opacity:.4}.opacity-50{opacity:.5}.opacity-60{opacity:.6}.opacity-75{opacity:.75}.opacity-80{opacity:.8}.shadow-md{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-sm{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-xl{--tw-shadow: 0 20px 25px -5px rgb(0 0 0 / .1), 0 8px 10px -6px rgb(0 0 0 / .1);--tw-shadow-colored: 0 20px 25px -5px var(--tw-shadow-color), 0 8px 10px -6px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-emerald-200{--tw-shadow-color: #a7f3d0;--tw-shadow: var(--tw-shadow-colored)}.shadow-orange-200{--tw-shadow-color: #fed7aa;--tw-shadow: var(--tw-shadow-colored)}.shadow-slate-100\/60{--tw-shadow-color: rgb(241 245 249 / .6);--tw-shadow: var(--tw-shadow-colored)}.outline{outline-style:solid}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-amber-500\/20{--tw-ring-color: rgb(245 158 11 / .2)}.ring-border{--tw-ring-color: hsl(var(--border))}.ring-emerald-500\/20{--tw-ring-color: rgb(16 185 129 / .2)}.ring-primary{--tw-ring-color: hsl(var(--primary))}.ring-primary\/20{--tw-ring-color: hsl(var(--primary) / .2)}.ring-rose-500\/20{--tw-ring-color: rgb(244 63 94 / .2)}.ring-offset-background{--tw-ring-offset-color: hsl(var(--background))}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.backdrop-blur-sm{--tw-backdrop-blur: blur(4px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.backdrop-blur-xl{--tw-backdrop-blur: blur(24px);-webkit-backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia);backdrop-filter:var(--tw-backdrop-blur) var(--tw-backdrop-brightness) var(--tw-backdrop-contrast) var(--tw-backdrop-grayscale) var(--tw-backdrop-hue-rotate) var(--tw-backdrop-invert) var(--tw-backdrop-opacity) var(--tw-backdrop-saturate) var(--tw-backdrop-sepia)}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-opacity{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-transform{transition-property:transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.duration-300{transition-duration:.3s}.glass-card{background:#ffffffb8;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px);border:1px solid rgba(255,255,255,.85);box-shadow:0 1px 3px #0000000f,0 8px 32px #0000000f}.panel-glow{box-shadow:0 1px 3px #0000000f,0 8px 32px #0000000f;border:1px solid rgba(255,255,255,.9)}.dark .panel-glow{box-shadow:0 0 0 1px hsl(var(--border)),0 4px 24px -4px #05080f99;border-color:hsl(var(--border))}@keyframes fadeIn{0%{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}@keyframes slideUp{0%{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}@keyframes shimmer{0%{background-position:-1000px 0}to{background-position:1000px 0}}.skeleton-shimmer{background:linear-gradient(90deg,hsl(var(--muted)),hsl(var(--accent)),hsl(var(--muted)));background-size:1000px 100%;animation:shimmer 1.6s linear infinite}.file\:border-0::file-selector-button{border-width:0px}.file\:bg-transparent::file-selector-button{background-color:transparent}.file\:text-sm::file-selector-button{font-size:.875rem;line-height:1.25rem}.file\:font-medium::file-selector-button{font-weight:500}.placeholder\:text-muted-foreground::-moz-placeholder{color:hsl(var(--muted-foreground))}.placeholder\:text-muted-foreground::placeholder{color:hsl(var(--muted-foreground))}.last\:border-0:last-child{border-width:0px}.hover\:border-foreground\/30:hover{border-color:hsl(var(--foreground) / .3)}.hover\:border-orange-200:hover{--tw-border-opacity: 1;border-color:rgb(254 215 170 / var(--tw-border-opacity, 1))}.hover\:border-primary\/40:hover{border-color:hsl(var(--primary) / .4)}.hover\:border-primary\/50:hover{border-color:hsl(var(--primary) / .5)}.hover\:bg-accent:hover{background-color:hsl(var(--accent))}.hover\:bg-blue-50:hover{--tw-bg-opacity: 1;background-color:rgb(239 246 255 / var(--tw-bg-opacity, 1))}.hover\:bg-destructive\/20:hover{background-color:hsl(var(--destructive) / .2)}.hover\:bg-destructive\/90:hover{background-color:hsl(var(--destructive) / .9)}.hover\:bg-gray-50:hover{--tw-bg-opacity: 1;background-color:rgb(249 250 251 / var(--tw-bg-opacity, 1))}.hover\:bg-muted:hover{background-color:hsl(var(--muted))}.hover\:bg-muted\/10:hover{background-color:hsl(var(--muted) / .1)}.hover\:bg-muted\/20:hover{background-color:hsl(var(--muted) / .2)}.hover\:bg-muted\/30:hover{background-color:hsl(var(--muted) / .3)}.hover\:bg-muted\/40:hover{background-color:hsl(var(--muted) / .4)}.hover\:bg-muted\/50:hover{background-color:hsl(var(--muted) / .5)}.hover\:bg-muted\/80:hover{background-color:hsl(var(--muted) / .8)}.hover\:bg-orange-50:hover{--tw-bg-opacity: 1;background-color:rgb(255 247 237 / var(--tw-bg-opacity, 1))}.hover\:bg-primary:hover{background-color:hsl(var(--primary))}.hover\:bg-primary\/10:hover{background-color:hsl(var(--primary) / .1)}.hover\:bg-primary\/30:hover{background-color:hsl(var(--primary) / .3)}.hover\:bg-primary\/90:hover{background-color:hsl(var(--primary) / .9)}.hover\:bg-red-50:hover{--tw-bg-opacity: 1;background-color:rgb(254 242 242 / var(--tw-bg-opacity, 1))}.hover\:bg-secondary\/80:hover{background-color:hsl(var(--secondary) / .8)}.hover\:bg-slate-50:hover{--tw-bg-opacity: 1;background-color:rgb(248 250 252 / var(--tw-bg-opacity, 1))}.hover\:text-accent-foreground:hover{color:hsl(var(--accent-foreground))}.hover\:text-blue-500:hover{--tw-text-opacity: 1;color:rgb(59 130 246 / var(--tw-text-opacity, 1))}.hover\:text-foreground:hover{color:hsl(var(--foreground))}.hover\:text-orange-500:hover{--tw-text-opacity: 1;color:rgb(249 115 22 / var(--tw-text-opacity, 1))}.hover\:text-primary:hover{color:hsl(var(--primary))}.hover\:text-primary\/60:hover{color:hsl(var(--primary) / .6)}.hover\:text-red-500:hover{--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}.hover\:text-slate-800:hover{--tw-text-opacity: 1;color:rgb(30 41 59 / var(--tw-text-opacity, 1))}.hover\:underline:hover{text-decoration-line:underline}.hover\:opacity-100:hover{opacity:1}.hover\:opacity-90:hover{opacity:.9}.hover\:shadow-md:hover{--tw-shadow: 0 4px 6px -1px rgb(0 0 0 / .1), 0 2px 4px -2px rgb(0 0 0 / .1);--tw-shadow-colored: 0 4px 6px -1px var(--tw-shadow-color), 0 2px 4px -2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.focus\:outline-none:focus{outline:2px solid transparent;outline-offset:2px}.focus\:ring-1:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\:ring-2:focus{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus\:ring-ring:focus{--tw-ring-color: hsl(var(--ring))}.focus\:ring-offset-2:focus{--tw-ring-offset-width: 2px}.focus-visible\:outline-none:focus-visible{outline:2px solid transparent;outline-offset:2px}.focus-visible\:ring-0:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(0px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\:ring-2:focus-visible{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.focus-visible\:ring-destructive:focus-visible{--tw-ring-color: hsl(var(--destructive))}.focus-visible\:ring-ring:focus-visible{--tw-ring-color: hsl(var(--ring))}.focus-visible\:ring-offset-2:focus-visible{--tw-ring-offset-width: 2px}.active\:cursor-grabbing:active{cursor:grabbing}.disabled\:pointer-events-none:disabled{pointer-events:none}.disabled\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\:opacity-50:disabled{opacity:.5}.group:hover .group-hover\:-translate-x-3{--tw-translate-x: -.75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:-translate-y-1{--tw-translate-y: -.25rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:-translate-y-3{--tw-translate-y: -.75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:translate-x-3{--tw-translate-x: .75rem;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group\/btn:hover .group-hover\/btn\:rotate-90{--tw-rotate: 90deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:-rotate-12{--tw-rotate: -12deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:rotate-12{--tw-rotate: 12deg;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.group:hover .group-hover\:border-primary{border-color:hsl(var(--primary))}.group:hover .group-hover\:text-primary{color:hsl(var(--primary))}.group:hover .group-hover\:text-slate-600{--tw-text-opacity: 1;color:rgb(71 85 105 / var(--tw-text-opacity, 1))}.group:hover .group-hover\:opacity-100{opacity:1}.group:hover .group-hover\:opacity-40{opacity:.4}.dark\:block:is(.dark *){display:block}.dark\:hidden:is(.dark *){display:none}.dark\:bg-white\/10:is(.dark *){background-color:#ffffff1a}.dark\:bg-white\/5:is(.dark *){background-color:#ffffff0d}.dark\:text-amber-300:is(.dark *){--tw-text-opacity: 1;color:rgb(252 211 77 / var(--tw-text-opacity, 1))}.dark\:text-emerald-300:is(.dark *){--tw-text-opacity: 1;color:rgb(110 231 183 / var(--tw-text-opacity, 1))}.dark\:text-emerald-400:is(.dark *){--tw-text-opacity: 1;color:rgb(52 211 153 / var(--tw-text-opacity, 1))}.dark\:text-rose-300:is(.dark *){--tw-text-opacity: 1;color:rgb(253 164 175 / var(--tw-text-opacity, 1))}.dark\:text-rose-400:is(.dark *){--tw-text-opacity: 1;color:rgb(251 113 133 / var(--tw-text-opacity, 1))}.dark\:hover\:bg-red-950\/30:hover:is(.dark *){background-color:#450a0a4d}@media (min-width: 640px){.sm\:block{display:block}.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}}@media (min-width: 768px){.md\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (min-width: 1024px){.lg\:relative{position:relative}.lg\:hidden{display:none}.lg\:translate-x-0{--tw-translate-x: 0px;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.lg\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr))}.lg\:grid-cols-3{grid-template-columns:repeat(3,minmax(0,1fr))}}@media (min-width: 1280px){.xl\:grid-cols-4{grid-template-columns:repeat(4,minmax(0,1fr))}.xl\:grid-cols-6{grid-template-columns:repeat(6,minmax(0,1fr))}} diff --git a/src/static/assets/plus-PpKYs9wJ.js b/src/static/assets/plus-CZK8TJCO.js similarity index 83% rename from src/static/assets/plus-PpKYs9wJ.js rename to src/static/assets/plus-CZK8TJCO.js index 53287a4..955d8b3 100644 --- a/src/static/assets/plus-PpKYs9wJ.js +++ b/src/static/assets/plus-CZK8TJCO.js @@ -1,4 +1,4 @@ -import{c as e}from"./createLucideIcon-D7qP-VdO.js";/** +import{c as e}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/assets/projects-BYok-JQo.js b/src/static/assets/projects-BYok-JQo.js new file mode 100644 index 0000000..b207536 --- /dev/null +++ b/src/static/assets/projects-BYok-JQo.js @@ -0,0 +1 @@ +import{c as i}from"./utils-7WVCegLb.js";import{d,o as r,c as n,n as c,h as u,D as m}from"./index-aIsLHJPY.js";const p=["id","value","placeholder","disabled","rows"],x=d({__name:"Textarea",props:{modelValue:{},placeholder:{},disabled:{type:Boolean},rows:{},class:{},id:{}},emits:["update:modelValue"],setup(e,{emit:l}){const s=e,a=l;return(f,o)=>(r(),n("textarea",{id:e.id,value:e.modelValue,placeholder:e.placeholder,disabled:e.disabled,rows:e.rows??3,class:c(u(i)("flex w-full rounded-md border border-input bg-background px-3 py-2 text-sm","ring-offset-background placeholder:text-muted-foreground","focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2","disabled:cursor-not-allowed disabled:opacity-50 resize-none",s.class)),onInput:o[0]||(o[0]=t=>a("update:modelValue",t.target.value))},null,42,p))}}),v={list:()=>m.get("/api/projects")};export{x as _,v as p}; diff --git a/src/static/assets/tasks-DwSuZPNM.js b/src/static/assets/tasks-caOFGu41.js similarity index 96% rename from src/static/assets/tasks-DwSuZPNM.js rename to src/static/assets/tasks-caOFGu41.js index a86680c..2be2fdc 100644 --- a/src/static/assets/tasks-DwSuZPNM.js +++ b/src/static/assets/tasks-caOFGu41.js @@ -1 +1 @@ -import{D as l,B as h,s as i}from"./index-BiYpJJoC.js";const o={list:a=>l.get("/api/tasks",{params:a}),get:a=>l.get(`/api/tasks/${a}`),create:a=>l.post("/api/tasks",a),update:(a,s)=>l.patch(`/api/tasks/${a}`,s),remove:a=>l.delete(`/api/tasks/${a}`),complete:a=>l.post(`/api/tasks/${a}/complete`),blocks:a=>l.get(`/api/tasks/${a}/blocks`),createBlock:(a,s)=>l.post(`/api/tasks/${a}/blocks`,s),updateBlock:(a,s)=>l.patch(`/api/tasks/blocks/${a}`,s),deleteBlock:a=>l.delete(`/api/tasks/blocks/${a}`)},b=Object.freeze(Object.defineProperty({__proto__:null,tasksApi:o},Symbol.toStringTag,{value:"Module"})),$=h("tasks",()=>{const a=i([]),s=i(!1),n=i(null);async function u(t){s.value=!0,n.value=null;try{const e=await o.list({date:t});a.value=e.data}catch(e){const c=e;n.value=c.message??"Failed to fetch tasks"}finally{s.value=!1}}async function d(t){s.value=!0,n.value=null;try{const e=await o.list(t?{project_id:t}:void 0);a.value=e.data}catch(e){const c=e;n.value=c.message??"Failed to fetch tasks"}finally{s.value=!1}}async function p(t){const e=await o.create(t);return a.value.push(e.data),e.data}async function k(t,e){const c=await o.update(t,e),r=a.value.findIndex(g=>g.id===t);return r!==-1&&(a.value[r]=c.data),c.data}async function f(t){await o.remove(t),a.value=a.value.filter(e=>e.id!==t)}async function v(t){const e=await o.complete(t),c=a.value.findIndex(r=>r.id===t);return c!==-1&&(a.value[c]=e.data),e.data}async function y(t,e){return(await o.createBlock(t,e)).data}async function m(t,e){return(await o.updateBlock(t,e)).data}async function B(t){await o.deleteBlock(t)}return{tasks:a,loading:s,error:n,fetchForDate:u,fetchAll:d,create:p,update:k,remove:f,complete:v,createBlock:y,updateBlock:m,deleteBlock:B}});export{b as t,$ as u}; +import{D as l,B as h,s as i}from"./index-aIsLHJPY.js";const o={list:a=>l.get("/api/tasks",{params:a}),get:a=>l.get(`/api/tasks/${a}`),create:a=>l.post("/api/tasks",a),update:(a,s)=>l.patch(`/api/tasks/${a}`,s),remove:a=>l.delete(`/api/tasks/${a}`),complete:a=>l.post(`/api/tasks/${a}/complete`),blocks:a=>l.get(`/api/tasks/${a}/blocks`),createBlock:(a,s)=>l.post(`/api/tasks/${a}/blocks`,s),updateBlock:(a,s)=>l.patch(`/api/tasks/blocks/${a}`,s),deleteBlock:a=>l.delete(`/api/tasks/blocks/${a}`)},b=Object.freeze(Object.defineProperty({__proto__:null,tasksApi:o},Symbol.toStringTag,{value:"Module"})),$=h("tasks",()=>{const a=i([]),s=i(!1),n=i(null);async function u(t){s.value=!0,n.value=null;try{const e=await o.list({date:t});a.value=e.data}catch(e){const c=e;n.value=c.message??"Failed to fetch tasks"}finally{s.value=!1}}async function d(t){s.value=!0,n.value=null;try{const e=await o.list(t?{project_id:t}:void 0);a.value=e.data}catch(e){const c=e;n.value=c.message??"Failed to fetch tasks"}finally{s.value=!1}}async function p(t){const e=await o.create(t);return a.value.push(e.data),e.data}async function k(t,e){const c=await o.update(t,e),r=a.value.findIndex(g=>g.id===t);return r!==-1&&(a.value[r]=c.data),c.data}async function f(t){await o.remove(t),a.value=a.value.filter(e=>e.id!==t)}async function v(t){const e=await o.complete(t),c=a.value.findIndex(r=>r.id===t);return c!==-1&&(a.value[c]=e.data),e.data}async function y(t,e){return(await o.createBlock(t,e)).data}async function m(t,e){return(await o.updateBlock(t,e)).data}async function B(t){await o.deleteBlock(t)}return{tasks:a,loading:s,error:n,fetchForDate:u,fetchAll:d,create:p,update:k,remove:f,complete:v,createBlock:y,updateBlock:m,deleteBlock:B}});export{b as t,$ as u}; diff --git a/src/static/assets/zap-CGuBGf0F.js b/src/static/assets/zap-BQ6FEFi3.js similarity index 87% rename from src/static/assets/zap-CGuBGf0F.js rename to src/static/assets/zap-BQ6FEFi3.js index a750dae..4002379 100644 --- a/src/static/assets/zap-CGuBGf0F.js +++ b/src/static/assets/zap-BQ6FEFi3.js @@ -1,4 +1,4 @@ -import{c as a}from"./createLucideIcon-D7qP-VdO.js";/** +import{c as a}from"./createLucideIcon-B5Z2hHtI.js";/** * @license lucide-vue-next v0.427.0 - ISC * * This source code is licensed under the ISC license. diff --git a/src/static/index.html b/src/static/index.html index f795da1..623ef90 100644 --- a/src/static/index.html +++ b/src/static/index.html @@ -14,8 +14,8 @@ else { document.documentElement.classList.remove('dark'); } })(); - - + +
diff --git a/web/src/views/OmgView.vue b/web/src/views/OmgView.vue index ed733ab..f3e5cc0 100644 --- a/web/src/views/OmgView.vue +++ b/web/src/views/OmgView.vue @@ -1,6 +1,8 @@