@mfs-atomic/ui 1.2.0 → 1.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/dist/mfs-theme.css +1 -1
- package/dist/mfs-theme.js +4 -4
- package/dist/mfs-theme.umd.cjs +2 -2
- package/package.json +7 -7
package/dist/mfs-theme.umd.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(L,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(L=typeof globalThis<"u"?globalThis:L||self,e(L.MfsTheme={},L.Vue))})(this,(function(L,e){"use strict";const Vn=["disabled","type"],xn={key:0,class:"btn__spinner"},Cn={key:1,class:"btn__icon btn__icon--prepend"},Nn={class:"btn__content"},Sn={key:2,class:"btn__icon btn__icon--append"},Mn=e.defineComponent({__name:"Button",props:{variant:{default:"primary"},size:{default:"md"},pill:{type:Boolean,default:!0},block:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},type:{default:"button"}},emits:["click"],setup(t,{emit:a}){const l=a,n=i=>{l("click",i)};return(i,r)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(["btn",`btn--${t.variant}`,`btn--${t.size}`,"mfs-shadow","mfs-focus-ring",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,{"mfs-pill":t.pill,"mfs-rounded":!t.pill,"btn--block":t.block,"btn--loading":t.loading,"btn--disabled mfs-disabled":t.disabled||t.loading}]),disabled:t.disabled||t.loading,type:t.type,onClick:n},[t.loading?(e.openBlock(),e.createElementBlock("span",xn)):e.createCommentVNode("",!0),i.$slots.prepend&&!t.loading?(e.openBlock(),e.createElementBlock("span",Cn,[e.renderSlot(i.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",Nn,[e.renderSlot(i.$slots,"default",{},void 0,!0)]),i.$slots.append&&!t.loading?(e.openBlock(),e.createElementBlock("span",Sn,[e.renderSlot(i.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],10,Vn))}}),F=(t,a)=>{const l=t.__vccOpts||t;for(const[n,i]of a)l[n]=i;return l},$e=F(Mn,[["__scopeId","data-v-6f98684f"]]),Dn={},Tn={class:"mfs-btn-group mfs-inline-flex mfs-items-center",role:"group"};function Ln(t,a){return e.openBlock(),e.createElementBlock("div",Tn,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const kt=F(Dn,[["render",Ln],["__scopeId","data-v-3e6bbebb"]]),zn={key:0,class:"card__header"},In={key:0,class:"card__title mfs-title"},Rn={key:1,class:"card__subtitle mfs-caption"},Pn={class:"card__body"},An={key:1,class:"card__footer"},ht=F(e.defineComponent({__name:"Card",props:{title:{},subtitle:{},hoverable:{type:Boolean,default:!1},bordered:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["card","mfs-card",{"card--hoverable":t.hoverable,"card--bordered":t.bordered}])},[a.$slots.header||t.title?(e.openBlock(),e.createElementBlock("div",zn,[e.renderSlot(a.$slots,"header",{},()=>[e.createElementVNode("div",null,[t.title?(e.openBlock(),e.createElementBlock("h3",In,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),t.subtitle?(e.openBlock(),e.createElementBlock("p",Rn,e.toDisplayString(t.subtitle),1)):e.createCommentVNode("",!0)])],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Pn,[e.renderSlot(a.$slots,"default",{},void 0,!0)]),a.$slots.footer?(e.openBlock(),e.createElementBlock("div",An,[e.renderSlot(a.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-9f7dd3af"]]),Fn={key:0,class:"input-label mfs-text"},jn={key:0,class:"input-required"},Kn={key:0,class:"input-affix mfs-text-muted input-affix--prepend"},On=["id","type","value","placeholder","disabled","readonly"],Hn={key:1,class:"input-affix mfs-text-muted input-affix--append"},Un={key:1,class:"input-msg input-msg--error mfs-text-danger"},Wn={key:2,class:"input-msg mfs-caption"},Te=F(e.defineComponent({__name:"Input",props:{modelValue:{default:""},id:{},type:{default:"text"},label:{},placeholder:{default:""},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},emits:["update:modelValue","focus","blur"],setup(t,{emit:a}){const l=a,n=i=>{const r=i.target;l("update:modelValue",r.value)};return(i,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["input-wrapper",{"input-wrapper--error":!!t.error,"input-wrapper--disabled is-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",Fn,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",jn,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["input-box mfs-surface mfs-rounded mfs-shadow-inset",{"mfs-disabled":t.disabled}])},[i.$slots.prepend?(e.openBlock(),e.createElementBlock("span",Kn,[e.renderSlot(i.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("input",{id:t.id,type:t.type,value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,class:"input-field mfs-text",onInput:n,onFocus:r[0]||(r[0]=s=>i.$emit("focus",s)),onBlur:r[1]||(r[1]=s=>i.$emit("blur",s))},null,40,On),i.$slots.append?(e.openBlock(),e.createElementBlock("span",Hn,[e.renderSlot(i.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],2),t.error?(e.openBlock(),e.createElementBlock("p",Un,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Wn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-ffe43dbd"]]),ve=F(e.defineComponent({__name:"Badge",props:{variant:{default:"primary"},size:{default:"md"}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["badge",`badge--${t.variant}`,`badge--${t.size}`,"mfs-pill",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`])},[e.renderSlot(a.$slots,"prepend",{},void 0,!0),e.renderSlot(a.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-649f6dac"]]),Gn=["checked","disabled"],qn={key:0,class:"switch__label"},ge=F(e.defineComponent({__name:"Switch",props:{modelValue:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=a,n=i=>{const r=i.target;l("update:modelValue",r.checked),l("change",r.checked)};return(i,r)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["switch mfs-text",{"switch--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{type:"checkbox",class:"switch__input",checked:t.modelValue,disabled:t.disabled,onChange:n},null,40,Gn),r[0]||(r[0]=e.createElementVNode("span",{class:"switch__track mfs-pill mfs-shadow-inset"},[e.createElementVNode("span",{class:"switch__thumb mfs-shadow"})],-1)),t.label||i.$slots.default?(e.openBlock(),e.createElementBlock("span",qn,[e.renderSlot(i.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-1fc9449a"]]),Yn={key:0,class:"modal-header mfs-flex mfs-items-center mfs-justify-between"},Xn={class:"modal-title mfs-title"},Zn={class:"modal-body"},Jn={key:1,class:"modal-footer mfs-flex mfs-items-center mfs-justify-end mfs-gap-3"},ye=F(e.defineComponent({__name:"Modal",props:{modelValue:{type:Boolean,default:!1},title:{},size:{default:"md"},closeOnBackdrop:{type:Boolean,default:!0}},emits:["update:modelValue","close"],setup(t,{emit:a}){const l=t,n=a,i=()=>{n("update:modelValue",!1),n("close")},r=()=>{l.closeOnBackdrop&&i()};let s="",d=!1;const c=o=>{if(!(typeof document>"u"))if(o){if(d)return;s=document.body.style.overflow,document.body.style.overflow="hidden",d=!0}else d&&(document.body.style.overflow=s,d=!1)};return e.onMounted(()=>{l.modelValue&&c(!0)}),e.watch(()=>l.modelValue,o=>c(o)),e.onBeforeUnmount(()=>{c(!1)}),(o,m)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"modal-fade"},{default:e.withCtx(()=>[t.modelValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:"modal-backdrop mfs-backdrop mfs-flex mfs-items-center mfs-justify-center mfs-p-4",onClick:r},[e.createElementVNode("div",{class:e.normalizeClass(["modal-dialog mfs-card mfs-overlay mfs-w-full mfs-flex mfs-flex-col mfs-overflow-hidden mfs-p-0",[`modal--${t.size}`]]),role:"dialog","aria-modal":"true",onClick:m[0]||(m[0]=e.withModifiers(()=>{},["stop"]))},[t.title||o.$slots.header?(e.openBlock(),e.createElementBlock("div",Yn,[e.renderSlot(o.$slots,"header",{},()=>[e.createElementVNode("h3",Xn,e.toDisplayString(t.title),1)],!0),e.createElementVNode("button",{class:"modal-close mfs-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text-muted mfs-focus-ring",onClick:i,"aria-label":"Close modal"}," ✕ ")])):e.createCommentVNode("",!0),e.createElementVNode("div",Zn,[e.renderSlot(o.$slots,"default",{},void 0,!0)]),o.$slots.footer?(e.openBlock(),e.createElementBlock("div",Jn,[e.renderSlot(o.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-0b390910"]]),Qn=["for"],vn={key:0,class:"mfs-text-danger"},eo=["id","value","placeholder","disabled","readonly","rows","maxlength","aria-invalid"],to={key:1,class:"textarea-footer mfs-flex mfs-items-center mfs-justify-between mfs-gap-2"},lo={key:0,class:"textarea-msg textarea-msg--error mfs-text-danger"},no={key:1,class:"textarea-msg mfs-caption"},oo={key:2,class:"textarea-spacer mfs-flex-1"},ao={key:3,class:"textarea-count mfs-caption"},gt=F(e.defineComponent({__name:"Textarea",props:{modelValue:{default:""},id:{},label:{},placeholder:{default:""},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},rows:{default:3},maxlength:{},showCount:{type:Boolean,default:!1},autoResize:{type:Boolean,default:!0}},emits:["update:modelValue","focus","blur"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.computed(()=>l.id||`mfs-textarea-${i}`),s=e.ref(null),d=e.computed(()=>(l.modelValue??"").length),c=()=>{const m=s.value;!m||!l.autoResize||(m.style.height="auto",m.style.height=`${m.scrollHeight}px`)},o=m=>{const f=m.target;n("update:modelValue",f.value),e.nextTick(c)};return e.watch(()=>l.modelValue,()=>e.nextTick(c)),e.onMounted(c),(m,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["textarea-wrapper mfs-flex mfs-flex-col mfs-w-full",{"textarea-wrapper--error":!!t.error,"textarea-wrapper--disabled is-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r.value,class:"textarea-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",vn,"*")):e.createCommentVNode("",!0)],8,Qn)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["textarea-box mfs-flex mfs-surface mfs-rounded mfs-shadow-inset",{"mfs-disabled":t.disabled}])},[e.createElementVNode("textarea",{ref_key:"textareaRef",ref:s,id:r.value,value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,rows:t.rows,maxlength:t.maxlength,"aria-invalid":!!t.error,class:"textarea-field mfs-flex-1 mfs-w-full mfs-border-none mfs-text",onInput:o,onFocus:f[0]||(f[0]=b=>m.$emit("focus",b)),onBlur:f[1]||(f[1]=b=>m.$emit("blur",b))},null,40,eo)],2),t.error||t.hint||t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("div",to,[t.error?(e.openBlock(),e.createElementBlock("p",lo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",no,e.toDisplayString(t.hint),1)):(e.openBlock(),e.createElementBlock("span",oo)),t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("span",ao,[e.createTextVNode(e.toDisplayString(d.value),1),t.maxlength!==void 0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(" / "+e.toDisplayString(t.maxlength),1)],64)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-d02aa1fe"]]),so=["for"],ro={key:0,class:"num-required mfs-text-danger"},io={class:"num-box mfs-surface mfs-rounded mfs-shadow-inset mfs-flex mfs-items-center mfs-gap-1-5"},co=["disabled"],mo={class:"num-input-area mfs-flex-1 mfs-flex mfs-items-center mfs-gap-1 mfs-min-w-0 mfs-px-1"},fo={key:0,class:"num-prefix mfs-text-muted mfs-font-semibold mfs-select-none"},uo=["id","value","placeholder","disabled","readonly","aria-invalid","aria-valuemin","aria-valuemax","aria-valuenow"],po=["disabled"],ko={key:1,class:"num-msg num-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},ho={key:2,class:"num-msg mfs-caption mfs-m-0"},yt=F(e.defineComponent({__name:"InputNumber",props:{modelValue:{default:null},id:{},label:{},placeholder:{default:"0"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},min:{},max:{},step:{default:1},decimals:{default:0},prefix:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.computed(()=>l.id||`mfs-num-${i}`),s=e.ref(!1),d=e.ref(""),c=k=>{let y=k;l.min!==void 0&&(y=Math.max(l.min,y)),l.max!==void 0&&(y=Math.min(l.max,y));const h=Math.pow(10,l.decimals);return Math.round(y*h)/h},o=e.computed(()=>l.min!==void 0&&l.modelValue!==null&&l.modelValue<=l.min),m=e.computed(()=>l.max!==void 0&&l.modelValue!==null&&l.modelValue>=l.max),f=e.computed(()=>s.value?d.value:l.modelValue===null||l.modelValue===void 0||Number.isNaN(l.modelValue)?"":l.decimals>0?l.modelValue.toFixed(l.decimals):String(l.modelValue)),b=()=>{s.value=!0,d.value=l.modelValue!==null&&l.modelValue!==void 0?String(l.modelValue):""},u=k=>{const y=k.target.value;if(d.value=y,y.trim()===""||y==="-"){y.trim()===""&&n("update:modelValue",null);return}const h=Number(y);Number.isNaN(h)||n("update:modelValue",h)},p=()=>{if(s.value=!1,d.value.trim()===""){n("update:modelValue",null),n("change",null);return}const k=Number(d.value);if(Number.isNaN(k)){n("update:modelValue",null),n("change",null);return}const y=c(k);n("update:modelValue",y),n("change",y)},g=k=>{if(l.disabled||l.readonly)return;const y=l.modelValue??(l.min!==void 0?l.min:0),h=c(y+k*l.step);n("update:modelValue",h),n("change",h)};return(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["num-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"num-wrapper--error":!!t.error,"num-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r.value,class:"num-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",ro,"*")):e.createCommentVNode("",!0)],8,so)):e.createCommentVNode("",!0),e.createElementVNode("div",io,[e.createElementVNode("button",{type:"button",class:"num-btn mfs-surface-subtle mfs-rounded-md mfs-shadow mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0 mfs-border-none mfs-text","aria-label":"Decrease value",disabled:t.disabled||t.readonly||o.value,onClick:y[0]||(y[0]=h=>g(-1))},[...y[4]||(y[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,co),e.createElementVNode("div",mo,[t.prefix?(e.openBlock(),e.createElementBlock("span",fo,e.toDisplayString(t.prefix),1)):e.createCommentVNode("",!0),e.createElementVNode("input",{id:r.value,type:"text",inputmode:"decimal",value:f.value,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,"aria-invalid":!!t.error,"aria-valuemin":t.min,"aria-valuemax":t.max,"aria-valuenow":t.modelValue??void 0,role:"spinbutton",class:"num-field mfs-font-mono mfs-w-full mfs-bg-transparent mfs-border-none mfs-outline-none mfs-text-center mfs-text mfs-py-2",onFocus:b,onBlur:p,onInput:u,onKeydown:[y[1]||(y[1]=e.withKeys(e.withModifiers(h=>g(1),["prevent"]),["up"])),y[2]||(y[2]=e.withKeys(e.withModifiers(h=>g(-1),["prevent"]),["down"]))]},null,40,uo)]),e.createElementVNode("button",{type:"button",class:"num-btn mfs-surface-subtle mfs-rounded-md mfs-shadow mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0 mfs-border-none mfs-text","aria-label":"Increase value",disabled:t.disabled||t.readonly||m.value,onClick:y[3]||(y[3]=h=>g(1))},[...y[5]||(y[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,po)]),t.error?(e.openBlock(),e.createElementBlock("p",ko,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",ho,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-9d3c9e18"]]),go=["for"],yo={key:0,class:"mfs-text-danger"},bo={class:"pwd-box mfs-flex mfs-items-center mfs-surface mfs-rounded mfs-shadow-inset"},Bo=["id","type","value","placeholder","disabled","readonly","aria-invalid"],wo=["aria-label","aria-pressed","disabled"],_o={key:0,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Eo={key:1,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},$o={key:1,class:"pwd-strength mfs-flex mfs-items-center mfs-gap-2","aria-live":"polite"},Vo={class:"pwd-bars mfs-flex-1"},xo={key:2,class:"pwd-msg pwd-msg--error mfs-text-danger"},Co={key:3,class:"pwd-msg mfs-caption"},bt=F(e.defineComponent({__name:"Password",props:{modelValue:{default:""},id:{},label:{},placeholder:{default:""},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},showStrength:{type:Boolean,default:!1}},emits:["update:modelValue","focus","blur"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.computed(()=>l.id||`mfs-pwd-${i}`),s=e.ref(!1),d=o=>{n("update:modelValue",o.target.value)},c=e.computed(()=>{const o=l.modelValue||"";let m=0;return o.length>=6&&m++,o.length>=10&&m++,/[a-z]/.test(o)&&/[A-Z]/.test(o)&&m++,/\d/.test(o)&&/[^A-Za-z0-9]/.test(o)&&m++,m=Math.max(1,Math.min(4,m)),{score:m,...{1:{label:"Weak",color:"var(--danger, #f43f5e)"},2:{label:"Fair",color:"var(--warning, #f59e0b)"},3:{label:"Good",color:"var(--primary)"},4:{label:"Strong",color:"var(--success, #10b981)"}}[m]}});return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["pwd-wrapper mfs-flex mfs-flex-col mfs-w-full",{"pwd-wrapper--error":!!t.error,"pwd-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r.value,class:"pwd-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",yo,"*")):e.createCommentVNode("",!0)],8,go)):e.createCommentVNode("",!0),e.createElementVNode("div",bo,[e.createElementVNode("input",{id:r.value,type:s.value?"text":"password",value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,"aria-invalid":!!t.error,class:"pwd-field mfs-flex-1 mfs-border-none mfs-text",onInput:d,onFocus:m[0]||(m[0]=f=>o.$emit("focus",f)),onBlur:m[1]||(m[1]=f=>o.$emit("blur",f))},null,40,Bo),e.createElementVNode("button",{type:"button",class:"pwd-toggle mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-rounded-sm mfs-text-muted","aria-label":s.value?"Hide password":"Show password","aria-pressed":s.value,disabled:t.disabled,onClick:m[2]||(m[2]=f=>s.value=!s.value)},[s.value?(e.openBlock(),e.createElementBlock("svg",_o,[...m[3]||(m[3]=[e.createElementVNode("path",{d:"M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94"},null,-1),e.createElementVNode("path",{d:"M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19"},null,-1),e.createElementVNode("line",{x1:"1",y1:"1",x2:"23",y2:"23"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Eo,[...m[4]||(m[4]=[e.createElementVNode("path",{d:"M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"},null,-1),e.createElementVNode("circle",{cx:"12",cy:"12",r:"3"},null,-1)])]))],8,wo)]),t.showStrength&&t.modelValue?(e.openBlock(),e.createElementBlock("div",$o,[e.createElementVNode("div",Vo,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(4,f=>e.createElementVNode("span",{key:f,class:e.normalizeClass(["pwd-bar mfs-pill",{"pwd-bar--active":f<=c.value.score}]),style:e.normalizeStyle({backgroundColor:f<=c.value.score?c.value.color:void 0})},null,6)),64))]),e.createElementVNode("span",{class:"pwd-strength-label mfs-text-xs mfs-font-semibold mfs-text-right",style:e.normalizeStyle({color:c.value.color})},e.toDisplayString(c.value.label),5)])):e.createCommentVNode("",!0),t.error?(e.openBlock(),e.createElementBlock("p",xo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Co,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-25a48744"]]),No=["id","checked","disabled","aria-label","tabindex"],So={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round",class:"checkbox__icon"},Mo={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round",class:"checkbox__icon"},Do={key:0,class:"checkbox__label"},fe=F(e.defineComponent({__name:"Checkbox",props:{modelValue:{type:[Boolean,Array],default:!1},value:{},indeterminate:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1},id:{},ariaLabel:{},tabindex:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue.includes(l.value):!!l.modelValue);e.watchEffect(()=>{i.value&&(i.value.indeterminate=l.indeterminate)}),e.onMounted(()=>{i.value&&(i.value.indeterminate=l.indeterminate)});const s=d=>{const c=d.target.checked;let o;Array.isArray(l.modelValue)?o=c?[...l.modelValue,l.value]:l.modelValue.filter(m=>m!==l.value):o=c,n("update:modelValue",o),n("change",o)};return(d,c)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["checkbox mfs-text",{"checkbox--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{ref_key:"inputRef",ref:i,id:t.id,type:"checkbox",class:"checkbox__input",checked:r.value,disabled:t.disabled,"aria-label":t.ariaLabel,tabindex:t.tabindex,onChange:s},null,40,No),e.createElementVNode("span",{class:e.normalizeClass(["checkbox__box mfs-surface mfs-shadow-inset",{"checkbox__box--checked":r.value||t.indeterminate}])},[t.indeterminate?(e.openBlock(),e.createElementBlock("svg",So,[...c[0]||(c[0]=[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"},null,-1)])])):r.value?(e.openBlock(),e.createElementBlock("svg",Mo,[...c[1]||(c[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),t.label||d.$slots.default?(e.openBlock(),e.createElementBlock("span",Do,[e.renderSlot(d.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-9b8c18e0"]]),To=["id","name","value","checked","disabled"],Lo={key:0,class:"radio__label"},et=F(e.defineComponent({__name:"RadioButton",props:{modelValue:{},value:{},name:{},label:{},disabled:{type:Boolean,default:!1},id:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.computed(()=>l.modelValue===l.value),r=()=>{l.disabled||(n("update:modelValue",l.value),n("change",l.value))};return(s,d)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["radio mfs-text",{"radio--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{id:t.id,type:"radio",class:"radio__input",name:t.name,value:t.value,checked:i.value,disabled:t.disabled,onChange:r},null,40,To),e.createElementVNode("span",{class:e.normalizeClass(["radio__circle mfs-surface mfs-shadow",{"radio__circle--checked":i.value}])},[...d[0]||(d[0]=[e.createElementVNode("span",{class:"radio__dot"},null,-1)])],2),t.label||s.$slots.default?(e.openBlock(),e.createElementBlock("span",Lo,[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-a1042f94"]]);function de(t,a,l,n){const i=(n==null?void 0:n.offset)??6,r=(n==null?void 0:n.matchWidth)??!1,s=(n==null?void 0:n.align)??"left",d=e.ref(0),c=e.ref(0),o=e.ref(void 0),m=()=>{var E;if(typeof window>"u"||!t.value)return;const p=t.value.getBoundingClientRect(),g=(E=a.value)==null?void 0:E.getBoundingClientRect(),k=Math.max((g==null?void 0:g.width)??0,r?p.width:0)||p.width,y=(g==null?void 0:g.height)??0;let h=p.left;s==="right"?h=p.right-k:s==="center"&&(h=p.left+(p.width-k)/2);const B=8,$=Math.max(B,window.innerWidth-k-B);h=Math.min(Math.max(B,h),$);const _=window.innerHeight-p.bottom,D=p.top;let S=p.bottom+i;y>0&&p.bottom+i+y>window.innerHeight-B&&D>_&&(S=Math.max(B,p.top-y-i)),d.value=S,c.value=h,o.value=r?p.width:void 0},f=e.computed(()=>{const p={position:"fixed",top:`${d.value}px`,left:`${c.value}px`,zIndex:10100};return r&&o.value!==void 0&&(p.minWidth=`${o.value}px`),p}),b=p=>{var g,k;return p instanceof Node?!!((g=t.value)!=null&&g.contains(p)||(k=a.value)!=null&&k.contains(p)):!1},u=()=>{l.value&&m()};return e.watch(l,p=>{p&&(m(),e.nextTick(m))}),e.watch(a,p=>{p&&l.value&&m()}),e.onMounted(()=>{typeof window>"u"||(window.addEventListener("scroll",u,!0),window.addEventListener("resize",u),l.value&&m())}),e.onBeforeUnmount(()=>{typeof window>"u"||(window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u))}),{overlayStyle:f,updatePosition:m,containsTarget:b}}const zo={key:0,class:"mfs-text-danger"},Io=["aria-expanded","aria-invalid","disabled"],Ro={class:"select-actions mfs-inline-flex mfs-items-center mfs-text-muted"},Po={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Ao={key:0,class:"select-search-box"},Fo={class:"select-options mfs-flex mfs-flex-col"},jo=["aria-selected","disabled","onClick","onMouseenter"],Ko={key:0,viewBox:"0 0 24 24",width:"15",height:"15",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round"},Oo={key:0,class:"select-empty mfs-empty-state"},Ho={key:1,class:"select-empty mfs-empty-state"},Uo={key:1,class:"select-msg select-msg--error mfs-text-danger"},Wo={key:2,class:"select-msg mfs-caption"},Le=F(e.defineComponent({__name:"Select",props:{modelValue:{},options:{default:()=>[]},label:{},placeholder:{default:"Select an option"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},remote:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","filter"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=`mfs-select-${i}`,s=`mfs-select-list-${i}`,d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref(null),f=e.ref(!1),b=e.ref(""),u=e.ref(-1),{overlayStyle:p,containsTarget:g}=de(c,o,f,{matchWidth:!0}),k=e.computed(()=>l.options.map(V=>typeof V=="string"?{label:V,value:V}:V)),y=e.computed(()=>{if(l.remote)return k.value;const V=b.value.trim().toLowerCase();return V?k.value.filter(C=>C.label.toLowerCase().includes(V)):k.value}),h=V=>{n("filter",{value:V.target.value})},B=e.computed(()=>k.value.find(V=>V.value===l.modelValue)),$=()=>{l.disabled||(f.value=!0,u.value=y.value.findIndex(V=>V.value===l.modelValue),l.searchable&&e.nextTick(()=>{var V;return(V=m.value)==null?void 0:V.focus()}))},_=()=>{f.value=!1,b.value=""},D=()=>{f.value?_():$()},S=V=>{V.disabled||(n("update:modelValue",V.value),n("change",V.value),_())},E=()=>{n("update:modelValue",null),n("change",null)},w=V=>{if(!f.value){(V.key==="ArrowDown"||V.key==="ArrowUp"||V.key==="Enter"||V.key===" ")&&(V.preventDefault(),$());return}const C=y.value;if(V.key==="Escape")V.preventDefault(),_();else if(V.key==="ArrowDown"){if(V.preventDefault(),!C.length)return;u.value=(u.value+1)%C.length}else if(V.key==="ArrowUp"){if(V.preventDefault(),!C.length)return;u.value=(u.value-1+C.length)%C.length}else if(V.key==="Enter"){V.preventDefault();const P=C[u.value];P&&!P.disabled&&S(P)}},N=V=>{g(V.target)||_()};return e.onMounted(()=>document.addEventListener("mousedown",N)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",N)),(V,C)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:d,class:e.normalizeClass(["select-wrapper mfs-flex mfs-flex-col mfs-w-full",{"select-wrapper--error":!!t.error,"select-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r,class:"select-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",zo,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:c,class:"select-container"},[e.createElementVNode("button",{id:r,type:"button",class:"select-trigger mfs-w-full mfs-flex mfs-items-center mfs-justify-between mfs-gap-2 mfs-surface mfs-rounded mfs-shadow-inset",role:"combobox","aria-expanded":f.value,"aria-controls":s,"aria-invalid":!!t.error,disabled:t.disabled,onClick:D,onKeydown:w},[e.createElementVNode("span",{class:e.normalizeClass(["select-value mfs-flex-1 mfs-truncate",{"select-value--placeholder":!B.value}])},e.toDisplayString(B.value?B.value.label:t.placeholder),3),e.createElementVNode("span",Ro,[t.loading?(e.openBlock(),e.createElementBlock("span",Po)):e.createCommentVNode("",!0),t.clearable&&B.value&&!t.disabled?(e.openBlock(),e.createElementBlock("span",{key:1,role:"button",tabindex:"-1","aria-label":"Clear selection",class:"select-clear mfs-inline-flex",onClick:e.withModifiers(E,["stop"])},[...C[1]||(C[1]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"})],-1)])])):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["select-chevron",{"select-chevron--open":f.value}])},[...C[2]||(C[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))])],40,Io),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"select-pop"},{default:e.withCtx(()=>[f.value?(e.openBlock(),e.createElementBlock("div",{key:0,id:s,ref_key:"overlayRef",ref:o,role:"listbox",style:e.normalizeStyle(e.unref(p)),class:"select-dropdown mfs-flex mfs-flex-col mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.searchable?(e.openBlock(),e.createElementBlock("div",Ao,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:m,"onUpdate:modelValue":C[0]||(C[0]=P=>b.value=P),type:"text",class:"select-search mfs-w-full mfs-text-sm mfs-inset",placeholder:"Search...",onInput:h,onKeydown:w},null,544),[[e.vModelText,b.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",Fo,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(P,T)=>(e.openBlock(),e.createElementBlock("button",{key:String(P.value)+T,type:"button",role:"option","aria-selected":P.value===t.modelValue,disabled:P.disabled,class:e.normalizeClass(["select-option mfs-w-full mfs-flex mfs-items-center mfs-justify-between mfs-gap-2 mfs-border-none mfs-text",{"select-option--selected":P.value===t.modelValue,"select-option--active":T===u.value}]),onClick:I=>S(P),onMouseenter:I=>u.value=T},[e.renderSlot(V.$slots,"option",{option:P,selected:P.value===t.modelValue},()=>[e.createElementVNode("span",null,e.toDisplayString(P.label),1),P.value===t.modelValue?(e.openBlock(),e.createElementBlock("svg",Ko,[...C[3]||(C[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],!0)],42,jo))),128)),t.loading&&y.value.length===0?(e.openBlock(),e.createElementBlock("div",Oo,[...C[4]||(C[4]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):y.value.length===0?(e.openBlock(),e.createElementBlock("div",Ho,[e.renderSlot(V.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0)])],4)):e.createCommentVNode("",!0)]),_:3})]))],512),t.error?(e.openBlock(),e.createElementBlock("p",Uo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Wo,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-2857ccce"]]),Go={key:0,class:"ms-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},qo={key:0,class:"mfs-text-danger"},Yo=["aria-expanded","aria-invalid","onKeydown"],Xo={class:"ms-chips mfs-flex-1 mfs-flex mfs-flex-wrap mfs-items-center mfs-gap-1-5"},Zo={class:"ms-chip-text"},Jo=["aria-label","onClick"],Qo={key:0,class:"ms-placeholder mfs-text-muted"},vo={key:0,class:"mfs-spinner mfs-spinner--sm mfs-shrink-0","aria-hidden":"true"},ea={key:0,class:"ms-search-box"},ta={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},la={class:"ms-options mfs-flex mfs-flex-col mfs-overflow-y-auto"},na=["aria-selected","disabled","onClick"],oa={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},aa={key:0,class:"ms-empty mfs-empty-state"},sa={key:1,class:"ms-empty mfs-empty-state"},ra={key:1,class:"ms-msg ms-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},ia={key:2,class:"ms-msg mfs-caption mfs-m-0"},Bt=F(e.defineComponent({__name:"MultiSelect",props:{modelValue:{default:()=>[]},options:{default:()=>[]},label:{},placeholder:{default:"Select items"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},selectAll:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},remote:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","filter"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(!1),o=e.ref(""),{overlayStyle:m,containsTarget:f}=de(r,s,c,{matchWidth:!0}),b=e.computed(()=>l.options.map(w=>typeof w=="string"?{label:w,value:w}:w)),u=e.computed(()=>{if(l.remote)return b.value;const w=o.value.trim().toLowerCase();return w?b.value.filter(N=>N.label.toLowerCase().includes(w)):b.value}),p=w=>{n("filter",{value:w.target.value})},g=e.computed(()=>b.value.filter(w=>!w.disabled)),k=e.computed(()=>b.value.filter(w=>l.modelValue.includes(w.value))),y=e.computed(()=>g.value.length>0&&g.value.every(w=>l.modelValue.includes(w.value))),h=w=>l.modelValue.includes(w),B=()=>{l.disabled||(c.value=!c.value,c.value&&l.searchable&&e.nextTick(()=>{var w;return(w=d.value)==null?void 0:w.focus()}))},$=()=>{c.value=!1,o.value=""},_=w=>{if(w.disabled)return;const N=h(w.value)?l.modelValue.filter(V=>V!==w.value):[...l.modelValue,w.value];n("update:modelValue",N),n("change",N)},D=w=>{const N=l.modelValue.filter(V=>V!==w);n("update:modelValue",N),n("change",N)},S=()=>{const w=y.value?[]:g.value.map(N=>N.value);n("update:modelValue",w),n("change",w)},E=w=>{f(w.target)||$()};return e.onMounted(()=>document.addEventListener("mousedown",E)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",E)),(w,N)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:i,class:e.normalizeClass(["ms-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"ms-wrapper--error":!!t.error,"ms-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",Go,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",qo,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:r,class:"ms-container mfs-relative"},[e.createElementVNode("div",{tabindex:"0",role:"combobox","aria-expanded":c.value,"aria-invalid":!!t.error,class:"ms-trigger mfs-flex mfs-items-center mfs-justify-between mfs-gap-2 mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring mfs-cursor-pointer",onClick:B,onKeydown:[e.withKeys($,["escape"]),e.withKeys(e.withModifiers(B,["prevent"]),["enter"])]},[e.createElementVNode("div",Xo,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,V=>(e.openBlock(),e.createElementBlock("span",{key:String(V.value),class:"ms-chip mfs-inline-flex mfs-items-center mfs-gap-1 mfs-bg-primary mfs-font-semibold mfs-pill"},[e.createElementVNode("span",Zo,e.toDisplayString(V.label),1),t.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"ms-chip-remove mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-p-0 mfs-rounded-full mfs-cursor-pointer","aria-label":`Remove ${V.label}`,onClick:e.withModifiers(C=>D(V.value),["stop"])},[...N[1]||(N[1]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"})],-1)])],8,Jo))]))),128)),k.value.length===0?(e.openBlock(),e.createElementBlock("span",Qo,e.toDisplayString(t.placeholder),1)):e.createCommentVNode("",!0)]),t.loading?(e.openBlock(),e.createElementBlock("span",vo)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["ms-chevron mfs-text-muted mfs-shrink-0",{"ms-chevron--open":c.value}])},[...N[2]||(N[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],40,Yo),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ms-pop"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:s,role:"listbox","aria-multiselectable":"true",style:e.normalizeStyle(e.unref(m)),class:"ms-dropdown mfs-flex mfs-flex-col mfs-gap-1 mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.searchable?(e.openBlock(),e.createElementBlock("div",ea,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:d,"onUpdate:modelValue":N[0]||(N[0]=V=>o.value=V),type:"text",class:"ms-search mfs-w-full mfs-text-sm mfs-inset mfs-rounded-sm mfs-outline-none",placeholder:"Search...",onInput:p,onKeydown:e.withKeys($,["escape"])},null,544),[[e.vModelText,o.value]])])):e.createCommentVNode("",!0),t.selectAll&&g.value.length>0?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"ms-option ms-option--all mfs-w-full mfs-flex mfs-items-center mfs-border-none mfs-font-semibold mfs-text mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer mfs-text-left",onClick:S},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":y.value}])},[y.value?(e.openBlock(),e.createElementBlock("svg",ta,[...N[3]||(N[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),N[4]||(N[4]=e.createElementVNode("span",null,"Select All",-1))])):e.createCommentVNode("",!0),e.createElementVNode("div",la,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(V,C)=>(e.openBlock(),e.createElementBlock("button",{key:String(V.value)+C,type:"button",role:"option","aria-selected":h(V.value),disabled:V.disabled,class:e.normalizeClass(["ms-option mfs-w-full mfs-flex mfs-items-center mfs-border-none mfs-text mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer mfs-text-left",{"ms-option--selected":h(V.value)}]),onClick:P=>_(V)},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":h(V.value)}])},[h(V.value)?(e.openBlock(),e.createElementBlock("svg",oa,[...N[5]||(N[5]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),e.createElementVNode("span",null,e.toDisplayString(V.label),1)],10,na))),128)),t.loading&&u.value.length===0?(e.openBlock(),e.createElementBlock("div",aa,[...N[6]||(N[6]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):u.value.length===0?(e.openBlock(),e.createElementBlock("div",sa,[e.renderSlot(w.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0)])],4)):e.createCommentVNode("",!0)]),_:3})]))],512),t.error?(e.openBlock(),e.createElementBlock("p",ra,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",ia,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-f75e22d9"]]),da={key:0,class:"mfs-flex mfs-justify-between mfs-items-center mfs-text-sm"},ca={class:"mfs-font-semibold mfs-text"},ma={class:"slider-readout mfs-text-primary mfs-font-semibold"},fa=["aria-valuemin","aria-valuemax","aria-valuenow"],ua={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},pa=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],ka={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},wt=F(e.defineComponent({__name:"Slider",props:{modelValue:{default:0},range:{type:Boolean,default:!1},min:{default:0},max:{default:100},step:{default:1},disabled:{type:Boolean,default:!1},label:{},showTooltip:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.computed(()=>typeof l.modelValue=="number"?l.modelValue:l.min),d=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[0]:l.min),c=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[1]:l.max),o=B=>{const $=l.max-l.min;return $<=0?0:Math.max(0,Math.min(100,(B-l.min)/$*100))},m=e.computed(()=>{if(l.range){const B=o(d.value),$=o(c.value);return{left:`${B}%`,width:`${Math.max(0,$-B)}%`}}return{left:"0%",width:`${o(s.value)}%`}}),f=B=>{const $=Math.max(l.min,Math.min(l.max,B)),_=Math.round(($-l.min)/l.step)*l.step+l.min;return Math.max(l.min,Math.min(l.max,Number(_.toFixed(6))))},b=B=>{var D;const $=(D=i.value)==null?void 0:D.getBoundingClientRect();if(!$||$.width===0)return l.min;const _=Math.max(0,Math.min(1,(B-$.left)/$.width));return f(l.min+_*(l.max-l.min))},u=(B,$)=>{if(l.range){const _=[d.value,c.value];B===0?_[0]=Math.min($,_[1]):_[1]=Math.max($,_[0]),n("update:modelValue",_)}else n("update:modelValue",$)},p=B=>{r.value!==null&&u(r.value,b(B.clientX))},g=()=>{r.value!==null&&(r.value=null,n("change",l.modelValue)),window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",g)},k=(B,$)=>{l.disabled||($.preventDefault(),r.value=B,window.addEventListener("pointermove",p),window.addEventListener("pointerup",g))},y=B=>{if(l.disabled)return;const $=b(B.clientX);let _=0;l.range&&(_=Math.abs($-d.value)<=Math.abs($-c.value)?0:1),u(_,$),k(_,B)},h=(B,$)=>{if(l.disabled)return;const _=$.key==="ArrowRight"||$.key==="ArrowUp"?l.step:$.key==="ArrowLeft"||$.key==="ArrowDown"?-l.step:0;if(!_)return;$.preventDefault();const D=l.range?B===0?d.value:c.value:s.value;u(B,f(D+_)),n("change",l.modelValue)};return e.onBeforeUnmount(g),(B,$)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["slider-wrapper mfs-flex mfs-flex-col mfs-w-full",{"mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("div",da,[e.createElementVNode("span",ca,e.toDisplayString(t.label),1),e.createElementVNode("span",ma,e.toDisplayString(t.range&&Array.isArray(t.modelValue)?`${t.modelValue[0]} – ${t.modelValue[1]}`:s.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"trackRef",ref:i,class:"slider-track mfs-relative mfs-surface mfs-pill mfs-shadow-inset mfs-cursor-pointer",onPointerdown:y},[e.createElementVNode("div",{class:"slider-fill mfs-absolute mfs-pill mfs-bg-primary",style:e.normalizeStyle(m.value)},null,4),t.range?(e.openBlock(),e.createElementBlock("div",{key:0,role:"slider",tabindex:"0",class:e.normalizeClass(["slider-thumb mfs-absolute mfs-rounded-full mfs-shadow mfs-focus-ring",{"slider-thumb--active":r.value===0}]),style:e.normalizeStyle({left:`${o(d.value)}%`}),"aria-valuemin":t.min,"aria-valuemax":c.value,"aria-valuenow":d.value,"aria-label":"Minimum value",onPointerdown:$[0]||($[0]=e.withModifiers(_=>k(0,_),["stop"])),onKeydown:$[1]||($[1]=_=>h(0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",ua,e.toDisplayString(d.value),1)):e.createCommentVNode("",!0)],46,fa)):e.createCommentVNode("",!0),e.createElementVNode("div",{role:"slider",tabindex:"0",class:e.normalizeClass(["slider-thumb mfs-absolute mfs-rounded-full mfs-shadow mfs-focus-ring",{"slider-thumb--active":r.value===(t.range?1:0)}]),style:e.normalizeStyle({left:`${o(t.range?c.value:s.value)}%`}),"aria-valuemin":t.range?d.value:t.min,"aria-valuemax":t.max,"aria-valuenow":t.range?c.value:s.value,"aria-label":t.range?"Maximum value":t.label||"Slider",onPointerdown:$[2]||($[2]=e.withModifiers(_=>k(t.range?1:0,_),["stop"])),onKeydown:$[3]||($[3]=_=>h(t.range?1:0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",ka,e.toDisplayString(t.range?c.value:s.value),1)):e.createCommentVNode("",!0)],46,pa)],544)],2))}}),[["__scopeId","data-v-5650bab9"]]),ha={key:0,class:"rating-label mfs-text"},ga=["aria-label","aria-valuemax","aria-valuenow"],ya=["disabled","aria-label","onMousemove","onClick"],ba={viewBox:"0 0 24 24",width:"24",height:"24",class:"rating-svg"},Ba=["id"],wa=["fill","stroke"],_t=F(e.defineComponent({__name:"Rating",props:{modelValue:{default:0},stars:{default:5},allowHalf:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},label:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-star-${e.useId()}`,r=e.ref(null),s=e.computed(()=>r.value!==null?r.value:l.modelValue),d=(u,p)=>{if(!l.allowHalf)return u;const g=p.currentTarget.getBoundingClientRect();return p.clientX-g.left<g.width/2?u-.5:u},c=(u,p)=>{l.disabled||l.readonly||(r.value=d(u,p))},o=(u,p)=>{if(l.disabled||l.readonly)return;const g=d(u,p);n("update:modelValue",g),n("change",g)},m=u=>{if(l.disabled||l.readonly)return;const p=l.allowHalf?.5:1;if(u.key==="ArrowRight"||u.key==="ArrowUp"){u.preventDefault();const g=Math.min(l.stars,l.modelValue+p);n("update:modelValue",g),n("change",g)}else if(u.key==="ArrowLeft"||u.key==="ArrowDown"){u.preventDefault();const g=Math.max(0,l.modelValue-p);n("update:modelValue",g),n("change",g)}},f=u=>{const p=s.value;return p>=u?"var(--warning, #f59e0b)":l.allowHalf&&p>=u-.5?`url(#${i}-${u})`:"transparent"},b=u=>s.value>=u-.5?"var(--warning, #f59e0b)":"var(--text-muted, #94a3b8)";return(u,p)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["rating-wrapper",{"rating-wrapper--disabled mfs-disabled":t.disabled,"rating-wrapper--readonly":t.readonly}])},[t.label?(e.openBlock(),e.createElementBlock("span",ha,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"rating-stars mfs-surface mfs-pill mfs-shadow mfs-focus-ring",role:"slider",tabindex:"0","aria-label":t.label||"Rating","aria-valuemin":0,"aria-valuemax":t.stars,"aria-valuenow":t.modelValue,onMouseleave:p[0]||(p[0]=g=>r.value=null),onKeydown:m},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.stars,g=>(e.openBlock(),e.createElementBlock("button",{key:g,type:"button",class:"rating-star",disabled:t.disabled,"aria-label":`Rate ${g} of ${t.stars}`,onMousemove:k=>c(g,k),onClick:k=>o(g,k)},[(e.openBlock(),e.createElementBlock("svg",ba,[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`${i}-${g}`,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[...p[1]||(p[1]=[e.createElementVNode("stop",{offset:"50%","stop-color":"var(--warning, #f59e0b)"},null,-1),e.createElementVNode("stop",{offset:"50%","stop-color":"transparent"},null,-1)])],8,Ba)]),e.createElementVNode("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2",fill:f(g),stroke:b(g),"stroke-width":"1.8","stroke-linejoin":"round"},null,8,wa)]))],40,ya))),128))],40,ga)],2))}}),[["__scopeId","data-v-3dbef716"]]),_a={key:0,class:"cp-label mfs-text mfs-text-sm mfs-font-semibold"},Ea={class:"cp-container mfs-relative"},$a=["disabled","aria-expanded"],Va={class:"cp-hex mfs-font-mono"},xa={class:"cp-native-row mfs-flex mfs-items-center mfs-gap-2"},Ca=["value"],Na=["value"],Sa={class:"cp-rgb mfs-grid mfs-grid-cols-3 mfs-gap-1-5"},Ma={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},Da=["value"],Ta={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},La=["value"],za={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},Ia=["value"],Ra={key:0,class:"cp-presets mfs-grid mfs-grid-cols-4 mfs-gap-2"},Pa=["aria-label","onClick"],Et=F(e.defineComponent({__name:"ColorPicker",props:{modelValue:{default:"#2563eb"},presets:{default:()=>["#2563eb","#38bdf8","#10b981","#f59e0b","#f43f5e","#14b8a6","#64748b","#0f172a"]},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:8}),o=e.computed(()=>/^#[0-9a-fA-F]{6}$/.test(l.modelValue)?l.modelValue:"#2563eb"),m=e.computed(()=>{const y=o.value.slice(1);return{r:parseInt(y.slice(0,2),16),g:parseInt(y.slice(2,4),16),b:parseInt(y.slice(4,6),16)}}),f=y=>{n("update:modelValue",y),n("change",y)},b=y=>{const h=y.startsWith("#")?y:`#${y}`;/^#[0-9a-fA-F]{6}$/.test(h)&&f(h.toLowerCase())},u=y=>Math.max(0,Math.min(255,y)).toString(16).padStart(2,"0"),p=(y,h)=>{const B=Number(h.target.value);if(Number.isNaN(B))return;const $={...m.value,[y]:B};f(`#${u($.r)}${u($.g)}${u($.b)}`)},g=y=>{s.value&&!c(y.target)&&(s.value=!1)},k=y=>{y.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",g),document.addEventListener("keydown",k)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",g),document.removeEventListener("keydown",k)}),(y,h)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cp-wrapper mfs-inline-flex mfs-flex-col mfs-gap-1-5",{"cp-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",_a,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Ea,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"cp-trigger mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-inline-flex mfs-items-center mfs-gap-2-5 mfs-font-semibold",disabled:t.disabled,"aria-expanded":s.value,"aria-label":"Pick a color",onClick:h[0]||(h[0]=B=>s.value=!s.value)},[e.createElementVNode("span",{class:"cp-swatch mfs-rounded-full",style:e.normalizeStyle({backgroundColor:t.modelValue})},null,4),e.createElementVNode("span",Va,e.toDisplayString(t.modelValue.toUpperCase()),1)],8,$a),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cp-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"cp-popover mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow mfs-p-3 mfs-flex mfs-flex-col mfs-gap-2-5",role:"dialog","aria-label":"Color picker"},[e.createElementVNode("div",xa,[e.createElementVNode("input",{type:"color",class:"cp-native mfs-p-0 mfs-border-none mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer",value:o.value,"aria-label":"Color palette",onInput:h[1]||(h[1]=B=>b(B.target.value))},null,40,Ca),e.createElementVNode("input",{type:"text",class:"cp-input mfs-inset mfs-font-mono mfs-flex-1 mfs-min-w-0 mfs-rounded-sm mfs-text-sm",value:t.modelValue,maxlength:"7","aria-label":"Hex color",onChange:h[2]||(h[2]=B=>b(B.target.value))},null,40,Na)]),e.createElementVNode("div",Sa,[e.createElementVNode("label",Ma,[h[6]||(h[6]=e.createElementVNode("span",null,"R",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:m.value.r,onInput:h[3]||(h[3]=B=>p("r",B))},null,40,Da)]),e.createElementVNode("label",Ta,[h[7]||(h[7]=e.createElementVNode("span",null,"G",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:m.value.g,onInput:h[4]||(h[4]=B=>p("g",B))},null,40,La)]),e.createElementVNode("label",za,[h[8]||(h[8]=e.createElementVNode("span",null,"B",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:m.value.b,onInput:h[5]||(h[5]=B=>p("b",B))},null,40,Ia)])]),t.presets.length?(e.openBlock(),e.createElementBlock("div",Ra,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.presets,B=>(e.openBlock(),e.createElementBlock("button",{key:B,type:"button",class:e.normalizeClass(["cp-preset mfs-rounded-sm mfs-cursor-pointer",{"cp-preset--active":B.toLowerCase()===o.value.toLowerCase()}]),style:e.normalizeStyle({backgroundColor:B}),"aria-label":`Select color ${B}`,onClick:$=>f(B)},null,14,Pa))),128))])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:1})]))])],2))}}),[["__scopeId","data-v-cb27bbc8"]]),Aa={key:0,class:"dp-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},Fa={key:0,class:"dp-required mfs-text-danger"},ja={class:"dp-container mfs-relative"},Ka=["disabled","aria-expanded","aria-invalid"],Oa={class:"dp-header mfs-flex mfs-items-center mfs-justify-between"},Ha={class:"dp-month-year mfs-font-bold mfs-text"},Ua={class:"dp-weekdays"},Wa=["disabled","onClick"],Ga={key:1,class:"dp-msg dp-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},qa={key:2,class:"dp-msg mfs-caption mfs-m-0"},ze=F(e.defineComponent({__name:"DatePicker",props:{modelValue:{default:null},range:{type:Boolean,default:!1},min:{},max:{},label:{},placeholder:{default:"Select date"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:8}),o=new Date,m=A=>{if(!A)return null;const K=A instanceof Date?new Date(A.getTime()):new Date(A);return Number.isNaN(K.getTime())?null:new Date(K.getFullYear(),K.getMonth(),K.getDate())},f=e.computed(()=>Array.isArray(l.modelValue)?m(l.modelValue[0])||o:m(l.modelValue)||o),b=e.ref(f.value.getFullYear()),u=e.ref(f.value.getMonth()),p=e.ref(null),g=["Su","Mo","Tu","We","Th","Fr","Sa"],k=["January","February","March","April","May","June","July","August","September","October","November","December"],y=e.computed(()=>k[u.value]),h=A=>{const K=new Date(b.value,u.value+A,1);b.value=K.getFullYear(),u.value=K.getMonth()},B=e.computed(()=>{const K=new Date(b.value,u.value,1).getDay(),W=[];for(let v=0;v<42;v++){const te=new Date(b.value,u.value,1-K+v);W.push({key:`${te.getFullYear()}-${te.getMonth()}-${te.getDate()}`,date:te,inMonth:te.getMonth()===u.value})}return W}),$=(A,K)=>!!(A&&K&&A.getFullYear()===K.getFullYear()&&A.getMonth()===K.getMonth()&&A.getDate()===K.getDate()),_=e.computed(()=>m(l.min)),D=e.computed(()=>m(l.max)),S=A=>!!(_.value&&A<_.value||D.value&&A>D.value),E=e.computed(()=>!l.range&&!Array.isArray(l.modelValue)?m(l.modelValue):null),w=e.computed(()=>l.range?p.value?[p.value,null]:Array.isArray(l.modelValue)?[m(l.modelValue[0]),m(l.modelValue[1])]:[null,null]:[null,null]),N=A=>{if(!l.range)return $(A,E.value);const[K,W]=w.value;return $(A,K)||$(A,W)},V=A=>{if(!l.range)return!1;const[K,W]=w.value;return!!(K&&W&&A>K&&A<W)},C=A=>A?`${A.getFullYear()}-${String(A.getMonth()+1).padStart(2,"0")}-${String(A.getDate()).padStart(2,"0")}`:"",P=e.computed(()=>{if(!l.range)return C(E.value);if(Array.isArray(l.modelValue)){const A=C(m(l.modelValue[0])),K=C(m(l.modelValue[1]));return A&&K?`${A} – ${K}`:A}return""}),T=A=>{if(!S(A)){if(!l.range){n("update:modelValue",A),n("change",A),s.value=!1;return}if(!p.value)p.value=A;else{const K=A<p.value?[A,p.value]:[p.value,A];p.value=null,n("update:modelValue",K),n("change",K),s.value=!1}}},I=A=>{c(A.target)||(s.value=!1)},j=A=>{A.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",I),document.addEventListener("keydown",j)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",I),document.removeEventListener("keydown",j)}),(A,K)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["dp-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"dp-wrapper--error":!!t.error,"dp-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",Aa,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",Fa,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",ja,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"dp-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-w-full mfs-flex mfs-items-center mfs-gap-2-5 mfs-text-left mfs-cursor-pointer",disabled:t.disabled,"aria-expanded":s.value,"aria-invalid":!!t.error,onClick:K[0]||(K[0]=W=>s.value=!s.value)},[K[3]||(K[3]=e.createStaticVNode('<svg viewBox="0 0 24 24" width="17" height="17" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="dp-icon mfs-text-muted mfs-shrink-0" data-v-1cc3183e><rect x="3" y="4" width="18" height="18" rx="2" ry="2" data-v-1cc3183e></rect><line x1="16" y1="2" x2="16" y2="6" data-v-1cc3183e></line><line x1="8" y1="2" x2="8" y2="6" data-v-1cc3183e></line><line x1="3" y1="10" x2="21" y2="10" data-v-1cc3183e></line></svg>',1)),e.createElementVNode("span",{class:e.normalizeClass(["dp-value",{"dp-value--placeholder mfs-text-muted":!P.value}])},e.toDisplayString(P.value||t.placeholder),3)],8,Ka),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"dp-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"dp-popover mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow mfs-p-3 mfs-flex mfs-flex-col mfs-gap-2",role:"dialog","aria-label":"Calendar"},[e.createElementVNode("div",Oa,[e.createElementVNode("button",{type:"button",class:"dp-nav mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text","aria-label":"Previous month",onClick:K[1]||(K[1]=W=>h(-1))},[...K[4]||(K[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("polyline",{points:"15 18 9 12 15 6"})],-1)])]),e.createElementVNode("span",Ha,e.toDisplayString(y.value)+" "+e.toDisplayString(b.value),1),e.createElementVNode("button",{type:"button",class:"dp-nav mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text","aria-label":"Next month",onClick:K[2]||(K[2]=W=>h(1))},[...K[5]||(K[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"})],-1)])])]),e.createElementVNode("div",Ua,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(g,W=>e.createElementVNode("span",{key:W,class:"dp-weekday mfs-text-center mfs-text-xs mfs-font-semibold mfs-text-muted mfs-py-1"},e.toDisplayString(W),1)),64))]),e.createVNode(e.Transition,{name:"dp-fade",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("div",{key:`${b.value}-${u.value}`,class:"dp-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,W=>(e.openBlock(),e.createElementBlock("button",{key:W.key,type:"button",class:e.normalizeClass(["dp-day mfs-border-none mfs-bg-transparent mfs-text mfs-font-medium mfs-cursor-pointer",{"dp-day--muted":!W.inMonth,"dp-day--selected":N(W.date),"dp-day--in-range":V(W.date),"dp-day--today":$(W.date,e.unref(o))}]),disabled:S(W.date),onClick:v=>T(W.date)},e.toDisplayString(W.date.getDate()),11,Wa))),128))]))]),_:1})],4)):e.createCommentVNode("",!0)]),_:1})]))]),t.error?(e.openBlock(),e.createElementBlock("p",Ga,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",qa,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-1cc3183e"]]),Ya=["role","aria-label"],Xa=["src","alt"],Za={key:1,class:"avatar__fallback"},Ja=["aria-label"],Ie=F(e.defineComponent({__name:"Avatar",props:{src:{},alt:{},label:{},size:{default:"md"},shape:{default:"circle"},status:{}},setup(t){const a=t,l=e.ref(!1);e.watch(()=>a.src,()=>{l.value=!1});const n=e.computed(()=>a.src&&!l.value?a.src:""),i=()=>{l.value=!0},r=e.computed(()=>{const s=(a.label||a.alt||"").trim();if(!s)return"?";const d=s.split(/\s+/).filter(Boolean);return d.length===1?d[0].slice(0,2).toUpperCase():(d[0][0]+d[d.length-1][0]).toUpperCase()});return(s,d)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["avatar","mfs-surface-subtle","mfs-shadow",t.shape==="circle"?"mfs-pill":"mfs-rounded",`avatar--${t.size}`,`avatar--${t.shape}`]),role:n.value?void 0:"img","aria-label":t.alt||t.label||"Avatar"},[n.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.value,alt:t.alt||t.label||"Avatar",class:"avatar__img",onError:i},null,40,Xa)):(e.openBlock(),e.createElementBlock("span",Za,[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(r.value),1)],!0)])),t.status?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(["avatar__status",t.status==="online"?"mfs-bg-success":t.status==="busy"?"mfs-bg-danger":t.status==="away"?"mfs-bg-warning":"",`avatar__status--${t.status}`]),"aria-label":`Status: ${t.status}`},null,10,Ja)):e.createCommentVNode("",!0)],10,Ya))}}),[["__scopeId","data-v-05a4906f"]]),Qa=["role","tabindex","aria-pressed","onKeydown"],va={key:0,class:"chip__prepend"},es={class:"chip__label"},Ve=F(e.defineComponent({__name:"Chip",props:{label:{},removable:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},active:{type:Boolean,default:!1},variant:{default:"surface"}},emits:["click","remove"],setup(t,{emit:a}){const l=t,n=a,i=r=>{l.clickable&&n("click",r)};return(r,s)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["chip","mfs-pill",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,`chip--${t.variant}`,{"chip--clickable mfs-interactive mfs-focus-ring":t.clickable,"chip--active":t.active}]),role:t.clickable?"button":void 0,tabindex:t.clickable?0:void 0,"aria-pressed":t.clickable?t.active:void 0,onClick:i,onKeydown:[e.withKeys(i,["enter"]),e.withKeys(e.withModifiers(i,["prevent"]),["space"])]},[r.$slots.prepend?(e.openBlock(),e.createElementBlock("span",va,[e.renderSlot(r.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",es,[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)]),t.removable?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"chip__remove","aria-label":"Remove",onClick:s[0]||(s[0]=e.withModifiers(d=>n("remove"),["stop"]))},[...s[1]||(s[1]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",width:"12",height:"12",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 4l8 8M12 4l-8 8",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"})],-1)])])):e.createCommentVNode("",!0)],42,Qa))}}),[["__scopeId","data-v-0a260f42"]]),ts=["aria-orientation"],ls={key:0,class:"divider__label mfs-caption"},$t=F(e.defineComponent({__name:"Divider",props:{orientation:{default:"horizontal"},align:{default:"center"},dashed:{type:Boolean,default:!1}},setup(t){const a=e.useSlots(),l=e.computed(()=>!!a.default);return(n,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["divider","mfs-text-muted",`divider--${t.orientation}`,`divider--align-${t.align}`,{"divider--dashed":t.dashed,"divider--with-text":l.value}]),role:"separator","aria-orientation":t.orientation},[l.value&&t.orientation==="horizontal"?(e.openBlock(),e.createElementBlock("span",ls,[e.renderSlot(n.$slots,"default",{},void 0,!0)])):e.createCommentVNode("",!0)],10,ts))}}),[["__scopeId","data-v-2cc4685f"]]),ns={class:"accordion mfs-flex mfs-flex-col mfs-gap-3 mfs-w-full"},os=["aria-expanded","aria-controls","disabled","onClick"],as={class:"accordion__title mfs-title"},ss=["id"],rs={class:"accordion__body mfs-overflow-hidden"},is={key:0,class:"accordion__text mfs-text-muted"},Vt=F(e.defineComponent({__name:"Accordion",props:{items:{default:()=>[]},multiple:{type:Boolean,default:!1},modelValue:{default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=o=>o==null?[]:Array.isArray(o)?o:[o],r=e.ref(i(l.modelValue));e.watch(()=>l.modelValue,o=>{o!==void 0&&(r.value=i(o))});const s=e.computed(()=>l.modelValue!==void 0?i(l.modelValue):r.value),d=o=>s.value.includes(o),c=o=>{const m=d(o);let f;l.multiple?f=m?s.value.filter(u=>u!==o):[...s.value,o]:f=m?[]:[o],r.value=f;const b=l.multiple?f:f[0]??null;n("update:modelValue",b),n("change",b)};return(o,m)=>(e.openBlock(),e.createElementBlock("div",ns,[t.items.length?e.createCommentVNode("",!0):e.renderSlot(o.$slots,"default",{},void 0,!0,0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,f=>(e.openBlock(),e.createElementBlock("div",{key:f.key,class:e.normalizeClass(["accordion__item","mfs-surface","mfs-rounded","mfs-shadow","mfs-overflow-hidden",{"is-open":d(f.key),"is-disabled mfs-disabled":f.disabled}])},[e.createElementVNode("button",{type:"button",class:"accordion__trigger mfs-w-full mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-none mfs-font-semibold mfs-focus-ring","aria-expanded":d(f.key),"aria-controls":`acc-panel-${f.key}`,disabled:f.disabled,onClick:b=>c(f.key)},[e.createElementVNode("span",as,e.toDisplayString(f.title),1),m[0]||(m[0]=e.createElementVNode("svg",{class:"accordion__chevron mfs-text-muted",viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1))],8,os),e.createElementVNode("div",{id:`acc-panel-${f.key}`,class:"accordion__panel",role:"region"},[e.createElementVNode("div",rs,[e.renderSlot(o.$slots,"item",{item:f,open:d(f.key)},()=>[f.content?(e.openBlock(),e.createElementBlock("p",is,e.toDisplayString(f.content),1)):e.createCommentVNode("",!0)],!0)])],8,ss)],2))),128))]))}}),[["__scopeId","data-v-ea3d94ac"]]),ds=["aria-busy"],cs={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ms={key:1,class:"mfs-empty-state"},fs={class:"timeline__rail mfs-flex mfs-flex-col mfs-items-center mfs-shrink-0","aria-hidden":"true"},us={key:0,class:"timeline__icon-text"},ps={key:0,class:"timeline__line mfs-flex-1 mfs-my-1"},ks={class:"timeline__content mfs-surface mfs-rounded mfs-shadow-card mfs-flex-1 mfs-mb-4"},hs={class:"timeline__header mfs-flex mfs-justify-between mfs-gap-2-5 mfs-flex-wrap"},gs={class:"timeline__title mfs-title mfs-m-0 mfs-font-bold"},ys={key:0,class:"timeline__time mfs-caption"},bs={key:0,class:"timeline__desc mfs-text-muted mfs-m-0"},xt=F(e.defineComponent({__name:"Timeline",props:{items:{default:()=>[]},layout:{default:"vertical"},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["timeline-container mfs-relative",{"timeline-container--loading-empty":t.loading&&t.items.length===0}]),"aria-busy":t.loading||void 0},[t.loading?(e.openBlock(),e.createElementBlock("div",cs,[e.renderSlot(a.$slots,"loading",{},()=>[l[0]||(l[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.items.length===0?(e.openBlock(),e.createElementBlock("div",ms,[e.renderSlot(a.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):t.items.length>0?(e.openBlock(),e.createElementBlock("ol",{key:2,class:e.normalizeClass(["timeline mfs-m-0 mfs-p-0 mfs-flex mfs-flex-col",`timeline--${t.layout}`])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,i)=>(e.openBlock(),e.createElementBlock("li",{key:i,class:"timeline__item mfs-flex mfs-gap-4"},[e.createElementVNode("div",fs,[e.createElementVNode("span",{class:e.normalizeClass(["timeline__dot","mfs-shadow","mfs-rounded-full","mfs-flex","mfs-items-center","mfs-justify-center",n.status==="surface"?"mfs-surface-subtle":`mfs-bg-${n.status||"primary"}`,`timeline__dot--${n.status||"primary"}`])},[e.renderSlot(a.$slots,"icon",{item:n,index:i},()=>[n.icon?(e.openBlock(),e.createElementBlock("span",us,e.toDisplayString(n.icon),1)):e.createCommentVNode("",!0)],!0)],2),i<t.items.length-1?(e.openBlock(),e.createElementBlock("span",ps)):e.createCommentVNode("",!0)]),e.createElementVNode("div",ks,[e.renderSlot(a.$slots,"item",{item:n,index:i},()=>[e.createElementVNode("div",hs,[e.createElementVNode("h4",gs,e.toDisplayString(n.title),1),n.timestamp?(e.openBlock(),e.createElementBlock("time",ys,e.toDisplayString(n.timestamp),1)):e.createCommentVNode("",!0)]),n.description?(e.openBlock(),e.createElementBlock("p",bs,e.toDisplayString(n.description),1)):e.createCommentVNode("",!0)],!0)])]))),128))],2)):e.createCommentVNode("",!0)],10,ds))}}),[["__scopeId","data-v-e4d2eafc"]]),Bs=["aria-busy"],ws={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},_s={key:1,class:"mfs-empty-state"},Es={key:2,class:"carousel__stage"},$s=["aria-hidden"],Vs={class:"carousel__fallback mfs-text"},xs=["disabled"],Cs=["disabled"],Ns={key:3,class:"carousel__indicators mfs-flex mfs-justify-center mfs-py-3"},Ss={class:"carousel__dots mfs-surface-subtle mfs-pill mfs-blur",role:"tablist","aria-label":"Slide indicators"},Ms=["aria-selected","aria-label","onClick"],Ct=F(e.defineComponent({__name:"Carousel",props:{items:{default:()=>[]},modelValue:{default:0},autoplay:{type:Boolean,default:!1},interval:{default:4e3},loop:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.modelValue),r=e.ref(!1);let s=null,d=null;e.watch(()=>l.modelValue,k=>{k>=0&&k<l.items.length&&(i.value=k)});const c=k=>{const y=l.items.length;if(!y)return;let h=k;l.loop?h=(k+y)%y:h=Math.max(0,Math.min(y-1,k)),i.value=h,n("update:modelValue",h),n("change",h)},o=()=>c(i.value+1),m=()=>c(i.value-1),f=k=>{s=k.clientX},b=k=>{if(s===null)return;const y=k.clientX-s;s=null,Math.abs(y)>40&&(y<0?o():m())},u=()=>{s=null},p=()=>{d&&(clearInterval(d),d=null)},g=()=>{p(),l.autoplay&&l.items.length>1&&(d=setInterval(()=>{r.value||o()},l.interval))};return e.watch(()=>[l.autoplay,l.interval,l.items.length],g),e.onMounted(g),e.onBeforeUnmount(p),(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["carousel mfs-surface mfs-rounded mfs-shadow-card",{"carousel--loading-empty":t.loading&&t.items.length===0}]),role:"region","aria-roledescription":"carousel","aria-busy":t.loading||void 0,onMouseenter:y[0]||(y[0]=h=>r.value=!0),onMouseleave:y[1]||(y[1]=h=>r.value=!1),onFocusin:y[2]||(y[2]=h=>r.value=!0),onFocusout:y[3]||(y[3]=h=>r.value=!1)},[t.loading?(e.openBlock(),e.createElementBlock("div",ws,[e.renderSlot(k.$slots,"loading",{},()=>[y[4]||(y[4]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.items.length===0?(e.openBlock(),e.createElementBlock("div",_s,[e.renderSlot(k.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",Es,[e.createElementVNode("div",{class:"carousel__viewport",onPointerdown:f,onPointerup:b,onPointercancel:u},[e.createElementVNode("div",{class:"carousel__track",style:e.normalizeStyle({transform:`translateX(-${i.value*100}%)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"carousel__slide","aria-hidden":B!==i.value},[e.renderSlot(k.$slots,"default",{item:h,index:B},()=>[e.createElementVNode("div",Vs,e.toDisplayString(h),1)],!0)],8,$s))),128))],4)],32),t.items.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("button",{type:"button",class:"carousel__btn carousel__btn--prev mfs-surface mfs-shadow mfs-pill mfs-focus-ring","aria-label":"Previous slide",disabled:!t.loop&&i.value===0,onClick:m},[...y[5]||(y[5]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M12.5 5L7.5 10L12.5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,xs),e.createElementVNode("button",{type:"button",class:"carousel__btn carousel__btn--next mfs-surface mfs-shadow mfs-pill mfs-focus-ring","aria-label":"Next slide",disabled:!t.loop&&i.value===t.items.length-1,onClick:o},[...y[6]||(y[6]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M7.5 5L12.5 10L7.5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Cs)],64)):e.createCommentVNode("",!0)])),t.items.length>1?(e.openBlock(),e.createElementBlock("div",Ns,[e.createElementVNode("div",Ss,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>(e.openBlock(),e.createElementBlock("button",{key:B,type:"button",role:"tab","aria-selected":B===i.value,"aria-label":`Go to slide ${B+1}`,class:e.normalizeClass(["carousel__dot","mfs-focus-ring",{"is-active":B===i.value}]),onClick:$=>c(B)},null,10,Ms))),128))])])):e.createCommentVNode("",!0)],42,Bs))}}),[["__scopeId","data-v-11e6f9bd"]]),Ds={key:0,class:"mfs-image__placeholder","aria-hidden":"true"},Ts=["aria-label"],Ls=["src","alt"],zs=["aria-label"],Is=["src","alt"],Nt=F(e.defineComponent({__name:"Image",props:{src:{},alt:{default:""},width:{},height:{},preview:{type:Boolean,default:!1},fit:{default:"cover"}},setup(t){const a=t,l=e.ref(!1),n=e.ref(!1),i=e.ref(!1),r=b=>b===void 0?void 0:typeof b=="number"?`${b}px`:b,s=e.computed(()=>({width:r(a.width),height:r(a.height)}));e.watch(()=>a.src,()=>{l.value=!1,n.value=!1});const d=()=>{l.value=!0,n.value=!1},c=()=>{l.value=!1,n.value=!0},o=b=>{b.key==="Escape"&&f()},m=()=>{a.preview&&l.value&&!n.value&&(i.value=!0,window.addEventListener("keydown",o))},f=()=>{i.value=!1,window.removeEventListener("keydown",o)};return e.onBeforeUnmount(()=>{window.removeEventListener("keydown",o)}),(b,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-image","mfs-surface-subtle","mfs-rounded","mfs-shadow-card",{"mfs-image--preview":t.preview&&l.value&&!n.value}]),style:e.normalizeStyle(s.value),onClick:m},[!l.value&&!n.value?(e.openBlock(),e.createElementBlock("div",Ds)):e.createCommentVNode("",!0),n.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"mfs-image__error mfs-text-muted",role:"img","aria-label":t.alt||"Image failed to load"},[...u[1]||(u[1]=[e.createStaticVNode('<svg viewBox="0 0 24 24" width="28" height="28" fill="none" aria-hidden="true" data-v-66fca7b1><rect x="3" y="4" width="18" height="16" rx="3" stroke="currentColor" stroke-width="1.8" data-v-66fca7b1></rect><path d="M4 16l4.5-4.5a1.5 1.5 0 012.1 0L15 16m-2-2l1.8-1.8a1.5 1.5 0 012.1 0L20 15" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" data-v-66fca7b1></path><circle cx="9" cy="9" r="1.3" fill="currentColor" data-v-66fca7b1></circle></svg><span class="mfs-image__error-text" data-v-66fca7b1>Failed to load</span>',2)])],8,Ts)):e.createCommentVNode("",!0),e.withDirectives(e.createElementVNode("img",{src:t.src,alt:t.alt,style:e.normalizeStyle({objectFit:t.fit}),class:e.normalizeClass(["mfs-image__img",{"is-loaded":l.value}]),onLoad:d,onError:c},null,46,Ls),[[e.vShow,!n.value]]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"img-fade"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-image__modal mfs-blur",role:"dialog","aria-modal":"true","aria-label":t.alt||"Image preview",onClick:f},[e.createElementVNode("button",{type:"button",class:"mfs-image__close","aria-label":"Close preview",onClick:e.withModifiers(f,["stop"])},[...u[2]||(u[2]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"20",height:"20",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 5l10 10M15 5L5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"})],-1)])]),e.createElementVNode("img",{src:t.src,alt:t.alt,class:"mfs-image__modal-img",onClick:u[0]||(u[0]=e.withModifiers(()=>{},["stop"]))},null,8,Is)],8,zs)):e.createCommentVNode("",!0)]),_:1})]))],6))}}),[["__scopeId","data-v-66fca7b1"]]),ue=e.ref([]),pe=new Map;let Rs=0;function tt(t){const a=pe.get(t);a!=null&&a.timerId&&(clearTimeout(a.timerId),a.timerId=null)}function Ps(t,a){if(a<=0)return;tt(t);const l=setTimeout(()=>{lt(t)},a);pe.set(t,{timerId:l,remaining:a,startedAt:Date.now()})}function lt(t){tt(t),pe.delete(t),ue.value=ue.value.filter(a=>a.id!==t)}function As(t){const a=pe.get(t);!a||!a.timerId||(clearTimeout(a.timerId),a.timerId=null,a.remaining=Math.max(0,a.remaining-(Date.now()-a.startedAt)))}function Fs(t){const a=pe.get(t);!a||a.timerId||a.remaining<=0||(a.startedAt=Date.now(),a.timerId=setTimeout(()=>{lt(t)},a.remaining))}function St(t){const a=t.id??`mfs-toast-${++Rs}`,l=t.duration??4e3,n={id:a,title:t.title,message:t.message,severity:t.severity??"info",duration:l,closable:t.closable??!0},i=ue.value.findIndex(r=>r.id===a);return i!==-1?ue.value.splice(i,1,n):ue.value.push(n),l>0&&Ps(a,l),a}function js(){for(const t of pe.keys())tt(t);pe.clear(),ue.value=[]}function Mt(){return{toasts:e.readonly(ue),add:St,show:St,remove:lt,clear:js,pause:As,resume:Fs}}const Ks=["role","onMouseenter","onMouseleave","onFocusin","onFocusout"],Os={class:"mfs-toast__icon mfs-shrink-0","aria-hidden":"true"},Hs={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Us={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ws={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Gs={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},qs={class:"mfs-toast__body mfs-flex-1 mfs-min-w-0"},Ys={key:0,class:"mfs-toast__title mfs-title mfs-font-bold"},Xs={class:"mfs-toast__message mfs-text-muted mfs-text-sm"},Zs=["onClick"],Dt=F(e.defineComponent({__name:"Toast",props:{position:{default:"top-right"},max:{}},setup(t){const a=t,{toasts:l,remove:n,pause:i,resume:r}=Mt(),s=e.computed(()=>a.max&&a.max>0?l.value.slice(-a.max):l.value);return(d,c)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createElementVNode("div",{class:e.normalizeClass(["mfs-toast-container mfs-fixed mfs-p-4",[`mfs-toast-container--${t.position}`]]),role:"region","aria-label":"Notifications"},[e.createVNode(e.TransitionGroup,{name:"mfs-toast",tag:"div",class:"mfs-toast-list mfs-flex mfs-flex-col mfs-gap-3"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,o=>(e.openBlock(),e.createElementBlock("div",{key:o.id,class:e.normalizeClass(["mfs-toast mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur mfs-flex mfs-items-start mfs-gap-3 mfs-relative",[`mfs-toast--${o.severity}`]]),role:o.severity==="danger"||o.severity==="warning"?"alert":"status","aria-live":"polite",onMouseenter:m=>e.unref(i)(o.id),onMouseleave:m=>e.unref(r)(o.id),onFocusin:m=>e.unref(i)(o.id),onFocusout:m=>e.unref(r)(o.id)},[e.createElementVNode("span",Os,[o.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Hs,[...c[0]||(c[0]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):o.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",Us,[...c[1]||(c[1]=[e.createElementVNode("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"},null,-1),e.createElementVNode("path",{d:"M12 9v4"},null,-1),e.createElementVNode("path",{d:"M12 17h.01"},null,-1)])])):o.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",Ws,[...c[2]||(c[2]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m15 9-6 6"},null,-1),e.createElementVNode("path",{d:"m9 9 6 6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Gs,[...c[3]||(c[3]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"M12 16v-4"},null,-1),e.createElementVNode("path",{d:"M12 8h.01"},null,-1)])]))]),e.createElementVNode("div",qs,[o.title?(e.openBlock(),e.createElementBlock("div",Ys,e.toDisplayString(o.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Xs,e.toDisplayString(o.message),1)]),o.closable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"mfs-toast__close mfs-surface-subtle mfs-pill mfs-focus-ring mfs-shrink-0 mfs-border-none mfs-text-muted mfs-inline-flex mfs-items-center mfs-justify-center mfs-cursor-pointer","aria-label":"Close notification",onClick:m=>e.unref(n)(o.id)},[...c[4]||(c[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])],8,Zs)):e.createCommentVNode("",!0)],42,Ks))),128))]),_:1})],2)]))}}),[["__scopeId","data-v-1a3d8498"]]),Js={class:"mfs-alert__icon","aria-hidden":"true"},Qs={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},vs={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},er={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},tr={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},lr={class:"mfs-alert__content"},nr={key:0,class:"mfs-alert__title mfs-title"},or={class:"mfs-alert__body mfs-text-muted"},Re=F(e.defineComponent({__name:"Alert",props:{severity:{default:"info"},title:{},closable:{type:Boolean,default:!1}},emits:["close"],setup(t,{emit:a}){const l=a;return(n,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-alert mfs-surface mfs-rounded mfs-shadow mfs-blur",[`mfs-alert--${t.severity}`]]),role:"alert"},[e.createElementVNode("span",Js,[e.renderSlot(n.$slots,"icon",{},()=>[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Qs,[...i[1]||(i[1]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):t.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",vs,[...i[2]||(i[2]=[e.createElementVNode("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"},null,-1),e.createElementVNode("path",{d:"M12 9v4"},null,-1),e.createElementVNode("path",{d:"M12 17h.01"},null,-1)])])):t.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",er,[...i[3]||(i[3]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m15 9-6 6"},null,-1),e.createElementVNode("path",{d:"m9 9 6 6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",tr,[...i[4]||(i[4]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"M12 16v-4"},null,-1),e.createElementVNode("path",{d:"M12 8h.01"},null,-1)])]))],!0)]),e.createElementVNode("div",lr,[t.title?(e.openBlock(),e.createElementBlock("div",nr,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",or,[e.renderSlot(n.$slots,"default",{},void 0,!0)])]),t.closable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"mfs-alert__close mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":"Close alert",onClick:i[0]||(i[0]=r=>l("close"))},[...i[5]||(i[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-d22695b6"]]),ar=["aria-describedby"],sr=["id"],Tt=F(e.defineComponent({__name:"Tooltip",props:{content:{default:""},placement:{default:"top"},disabled:{type:Boolean,default:!1}},setup(t){const a=t,l=e.ref(!1),n=e.useId(),i=()=>{!a.disabled&&a.content&&(l.value=!0)},r=()=>{l.value=!1};return(s,d)=>(e.openBlock(),e.createElementBlock("span",{class:"mfs-relative mfs-inline-flex mfs-items-center",onMouseenter:i,onMouseleave:r,onFocusin:i,onFocusout:r,onKeydown:e.withKeys(r,["escape"])},[e.createElementVNode("span",{class:"mfs-inline-flex mfs-items-center","aria-describedby":l.value&&t.content?e.unref(n):void 0},[e.renderSlot(s.$slots,"default",{},void 0,!0)],8,ar),e.createVNode(e.Transition,{name:"mfs-tooltip"},{default:e.withCtx(()=>[l.value&&!t.disabled&&t.content?(e.openBlock(),e.createElementBlock("span",{key:0,id:e.unref(n),role:"tooltip",class:e.normalizeClass(["mfs-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-blur mfs-whitespace-nowrap mfs-font-semibold",[`mfs-tooltip--${t.placement}`]])},[e.createTextVNode(e.toDisplayString(t.content)+" ",1),d[0]||(d[0]=e.createElementVNode("span",{class:"mfs-tooltip__arrow mfs-absolute","aria-hidden":"true"},null,-1))],10,sr)):e.createCommentVNode("",!0)]),_:1})],32))}}),[["__scopeId","data-v-41e6fd61"]]),rr=["aria-label"],ir={key:0,class:"mfs-drawer__header mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},dr={class:"mfs-drawer__title mfs-title mfs-m-0 mfs-font-bold"},cr={class:"mfs-drawer__body mfs-flex-1 mfs-p-5 mfs-overflow-y-auto"},mr={key:1,class:"mfs-drawer__footer mfs-border-t mfs-flex mfs-justify-end mfs-gap-2-5"},Pe=F(e.defineComponent({__name:"Drawer",props:{modelValue:{type:Boolean,default:!1},position:{default:"right"},size:{default:"360px"},title:{},closeOnBackdrop:{type:Boolean,default:!0}},emits:["update:modelValue","close"],setup(t,{emit:a}){const l=t,n=a,i=e.computed(()=>l.position==="left"||l.position==="right"),r=e.computed(()=>i.value?{width:l.size,maxWidth:"100vw",height:"100%"}:{height:l.size,maxHeight:"100vh",width:"100%"}),s=()=>{n("update:modelValue",!1),n("close")},d=()=>{l.closeOnBackdrop&&s()},c=b=>{b.key==="Escape"&&l.modelValue&&s()};let o="",m=!1;const f=b=>{if(!(typeof document>"u"))if(b){if(m)return;o=document.body.style.overflow,document.body.style.overflow="hidden",document.addEventListener("keydown",c),m=!0}else m&&(document.body.style.overflow=o,document.removeEventListener("keydown",c),m=!1)};return e.onMounted(()=>{l.modelValue&&f(!0)}),e.watch(()=>l.modelValue,b=>f(b)),e.onBeforeUnmount(()=>{f(!1)}),(b,u)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-drawer-fade"},{default:e.withCtx(()=>[t.modelValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-drawer-backdrop mfs-backdrop mfs-fixed mfs-inset-0 mfs-flex",onClick:d},[e.createElementVNode("aside",{class:e.normalizeClass(["mfs-drawer mfs-surface mfs-overlay mfs-shadow-card mfs-blur mfs-fixed mfs-flex mfs-flex-col mfs-overflow-hidden",[`mfs-drawer--${t.position}`]]),style:e.normalizeStyle(r.value),role:"dialog","aria-modal":"true","aria-label":t.title||"Drawer",onClick:u[0]||(u[0]=e.withModifiers(()=>{},["stop"]))},[t.title||b.$slots.header?(e.openBlock(),e.createElementBlock("div",ir,[e.renderSlot(b.$slots,"header",{},()=>[e.createElementVNode("h3",dr,e.toDisplayString(t.title),1)],!0),e.createElementVNode("button",{type:"button",class:"mfs-drawer__close mfs-surface-subtle mfs-pill mfs-focus-ring mfs-shrink-0 mfs-border-none mfs-text-muted mfs-inline-flex mfs-items-center mfs-justify-center mfs-cursor-pointer","aria-label":"Close drawer",onClick:s},[...u[1]||(u[1]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",cr,[e.renderSlot(b.$slots,"default",{},void 0,!0)]),b.$slots.footer?(e.openBlock(),e.createElementBlock("div",mr,[e.renderSlot(b.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],14,rr)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-cf8492dc"]]),fr={class:"mfs-popover-wrapper"},ur=["aria-expanded"],Ae=F(e.defineComponent({__name:"Popover",props:{modelValue:{type:Boolean,default:void 0},placement:{default:"bottom"}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),d=e.computed(()=>l.modelValue!==void 0),c=e.computed(()=>d.value?!!l.modelValue:s.value),{overlayStyle:o,containsTarget:m}=de(i,r,c,{offset:10,align:"center"}),f=y=>{d.value||(s.value=y),n("update:modelValue",y)},b=()=>f(!c.value),u=()=>f(!1),p=y=>{m(y.target)||u()},g=y=>{y.key==="Escape"&&u()},k=y=>{typeof document>"u"||(y?(document.addEventListener("pointerdown",p),document.addEventListener("keydown",g)):(document.removeEventListener("pointerdown",p),document.removeEventListener("keydown",g)))};return e.watch(c,y=>k(y),{immediate:!0}),e.onBeforeUnmount(()=>{k(!1)}),(y,h)=>(e.openBlock(),e.createElementBlock("div",fr,[e.createElementVNode("div",{ref_key:"triggerRef",ref:i,class:"mfs-popover__trigger","aria-expanded":c.value,"aria-haspopup":"dialog",onClick:b},[e.renderSlot(y.$slots,"trigger",{open:c.value,toggle:b},void 0,!0)],8,ur),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-popover"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(o)),class:e.normalizeClass(["mfs-popover mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur",[`mfs-popover--${t.placement}`]]),role:"dialog"},[e.renderSlot(y.$slots,"default",{close:u},void 0,!0)],6)):e.createCommentVNode("",!0)]),_:3})]))]))}}),[["__scopeId","data-v-00dfd9fd"]]),Lt=F(e.defineComponent({__name:"Skeleton",props:{variant:{default:"text"},width:{},height:{},lines:{default:1},animated:{type:Boolean,default:!0}},setup(t){const a=t,l=e.computed(()=>a.variant!=="text"?1:Math.max(1,Math.floor(a.lines))),n=i=>{const r=a.variant==="text"&&l.value>1&&i===l.value,s=a.variant==="circle"?"48px":r?"72%":"100%",d=a.variant==="circle"?a.width??"48px":a.variant==="text"?"14px":"80px";return{width:r&&!a.width?"72%":a.width??s,height:a.height??d}};return(i,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-skeleton-group",{"mfs-skeleton-group--lines":t.variant==="text"&&l.value>1}]),"aria-hidden":"true"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,s=>(e.openBlock(),e.createElementBlock("div",{key:s,class:e.normalizeClass(["mfs-skeleton",[`mfs-skeleton--${t.variant}`,t.variant==="text"?"mfs-rounded-sm":t.variant==="circle"?"mfs-pill":"mfs-rounded",{"mfs-skeleton--animated":t.animated}]]),style:e.normalizeStyle(n(s))},null,6))),128))],2))}}),[["__scopeId","data-v-7d535714"]]),pr={class:"mfs-progress"},kr=["aria-valuenow"],hr={key:0,class:"mfs-progress__label mfs-caption"},zt=F(e.defineComponent({__name:"ProgressBar",props:{value:{default:0},indeterminate:{type:Boolean,default:!1},showValue:{type:Boolean,default:!1},variant:{default:"primary"},height:{default:"10px"}},setup(t){const a=t,l=e.computed(()=>Math.min(100,Math.max(0,a.value)));return(n,i)=>(e.openBlock(),e.createElementBlock("div",pr,[e.createElementVNode("div",{class:"mfs-progress__track mfs-surface-subtle mfs-pill mfs-shadow-inset",role:"progressbar","aria-valuenow":t.indeterminate?void 0:l.value,"aria-valuemin":"0","aria-valuemax":"100",style:e.normalizeStyle({height:t.height})},[e.createElementVNode("div",{class:e.normalizeClass(["mfs-progress__bar mfs-pill",[`mfs-progress__bar--${t.variant}`,{"mfs-progress__bar--indeterminate":t.indeterminate}]]),style:e.normalizeStyle(t.indeterminate?void 0:{width:`${l.value}%`})},null,6)],12,kr),t.showValue&&!t.indeterminate?(e.openBlock(),e.createElementBlock("span",hr,e.toDisplayString(Math.round(l.value))+"% ",1)):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-9a84cdec"]]),gr={class:"mfs-spinner__svg",viewBox:"0 0 50 50"},yr=["stroke-width"],br=["stroke-width"],It=F(e.defineComponent({__name:"ProgressSpinner",props:{size:{default:"md"},strokeWidth:{default:4},variant:{default:"primary"}},setup(t){const a=t,l={sm:"22px",md:"36px",lg:"52px"},n=e.computed(()=>typeof a.size=="number"?`${a.size}px`:l[a.size]);return(i,r)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["mfs-spinner mfs-text",[`mfs-spinner--${t.variant}`]]),style:e.normalizeStyle({width:n.value,height:n.value}),role:"status","aria-label":"Loading"},[(e.openBlock(),e.createElementBlock("svg",gr,[e.createElementVNode("circle",{class:"mfs-spinner__track",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth},null,8,yr),e.createElementVNode("circle",{class:"mfs-spinner__ring",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,br)]))],6))}}),[["__scopeId","data-v-fcb783c0"]]),Fe=e.ref({isOpen:!1,options:null});let be=null;function Rt(t){var n,i;const a=Fe.value.options,l=be;be=null,Fe.value={isOpen:!1,options:null},t?(n=a==null?void 0:a.onAccept)==null||n.call(a):(i=a==null?void 0:a.onReject)==null||i.call(a),l==null||l(t)}function Br(t){return be&&(be(!1),be=null),Fe.value={isOpen:!0,options:{confirmLabel:"Confirm",cancelLabel:"Cancel",variant:"primary",...t}},new Promise(a=>{be=a})}function Pt(){return{state:e.readonly(Fe),confirm:Br,accept:()=>Rt(!0),reject:()=>Rt(!1)}}const wr=["aria-labelledby","aria-describedby"],_r={class:"mfs-confirm__header"},Er=["id"],$r=["id"],Vr={class:"mfs-flex mfs-justify-end mfs-gap-2-5 mfs-flex-wrap"},At=F(e.defineComponent({__name:"ConfirmDialog",setup(t){const{state:a,accept:l,reject:n}=Pt(),i=e.useId(),r=e.useId(),s=d=>{d.key==="Escape"&&a.value.isOpen&&n()};return e.watch(()=>a.value.isOpen,d=>{typeof document>"u"||(d?document.addEventListener("keydown",s):document.removeEventListener("keydown",s))},{immediate:!0}),e.onBeforeUnmount(()=>{typeof document<"u"&&document.removeEventListener("keydown",s)}),(d,c)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-fade"},{default:e.withCtx(()=>[e.unref(a).isOpen&&e.unref(a).options?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-confirm-backdrop mfs-backdrop mfs-fixed mfs-inset-0 mfs-flex mfs-items-center mfs-justify-center mfs-p-4",onClick:c[3]||(c[3]=(...o)=>e.unref(n)&&e.unref(n)(...o))},[e.createElementVNode("div",{class:"mfs-confirm mfs-overlay mfs-surface mfs-rounded mfs-shadow-card mfs-blur mfs-w-full",role:"alertdialog","aria-modal":"true","aria-labelledby":e.unref(i),"aria-describedby":e.unref(r),onClick:c[2]||(c[2]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",_r,[e.createElementVNode("h3",{id:e.unref(i),class:"mfs-confirm__title mfs-title mfs-m-0"},e.toDisplayString(e.unref(a).options.title),9,Er)]),e.createElementVNode("p",{id:e.unref(r),class:"mfs-confirm__message mfs-text-muted"},e.toDisplayString(e.unref(a).options.message),9,$r),e.createElementVNode("div",Vr,[e.createElementVNode("button",{type:"button",class:"mfs-confirm__btn mfs-surface-subtle mfs-pill mfs-shadow mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",onClick:c[0]||(c[0]=(...o)=>e.unref(n)&&e.unref(n)(...o))},e.toDisplayString(e.unref(a).options.cancelLabel??"Cancel"),1),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-confirm__btn mfs-pill mfs-shadow mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",[`mfs-bg-${e.unref(a).options.variant??"primary"}`]]),onClick:c[1]||(c[1]=(...o)=>e.unref(l)&&e.unref(l)(...o))},e.toDisplayString(e.unref(a).options.confirmLabel??"Confirm"),3)])],8,wr)])):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-cd6aa53d"]]),xr=new Set(["p","br","b","strong","i","em","u","s","del","ul","ol","li","span","div","blockquote","code","pre","h1","h2","h3","h4","a"]),Cr=new Set(["script","style","iframe","object","embed","svg","math","noscript","template"]);function se(t){if(!t||typeof t!="string")return;const a=t.replace(/[\u0000-\u001f\u007f]/g,"").trim();if(!a)return;const l=a.replace(/[\u0000-\u0020\u007f]+/g,"").toLowerCase();if(l&&!(l.startsWith("//")||l.startsWith("/\\"))&&(l.startsWith("/")||l.startsWith("#")||l.startsWith("./")||l.startsWith("../")||/^(https?:|mailto:|tel:)/.test(l)))return a}function Ft(t,a){if(t.nodeType===Node.TEXT_NODE)return[a.createTextNode(t.textContent??"")];if(t.nodeType!==Node.ELEMENT_NODE)return[];const l=t,n=l.tagName.toLowerCase();if(Cr.has(n))return[];const i=[];for(const s of Array.from(l.childNodes))i.push(...Ft(s,a));if(!xr.has(n))return i;const r=a.createElement(n);if(n==="a"){const s=se(l.getAttribute("href")??void 0);s&&(r.setAttribute("href",s),r.setAttribute("rel","noopener noreferrer"))}for(const s of i)r.appendChild(s);return[r]}function jt(t){if(typeof DOMParser>"u")return[];const a=new DOMParser().parseFromString(t||"","text/html"),l=[];for(const n of Array.from(a.body.childNodes))l.push(...Ft(n,a));return l}function nt(t){if(typeof document>"u"||typeof DOMParser>"u")return"";const a=document.createElement("div");return a.append(...jt(t)),a.innerHTML}const Nr={class:"navbar__inner mfs-flex mfs-items-center mfs-justify-between mfs-gap-4"},Sr={class:"navbar__brand mfs-flex mfs-items-center mfs-font-bold"},Mr={class:"navbar__nav","aria-label":"Main navigation"},Dr={class:"navbar__list mfs-flex mfs-items-center"},Tr=["aria-current","onClick"],Lr={class:"navbar__actions mfs-flex mfs-items-center"},zr=["aria-expanded"],Ir={key:0,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Rr={key:1,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Pr={key:0,id:"navbar-mobile-drawer",class:"navbar__drawer",role:"region","aria-label":"Mobile navigation"},Ar={class:"navbar__mobile-list mfs-flex mfs-flex-col"},Fr=["aria-current","onClick"],je=F(e.defineComponent({__name:"Navbar",props:{items:{default:()=>[]},sticky:{type:Boolean,default:!0},bordered:{type:Boolean,default:!0}},emits:["navigate"],setup(t,{emit:a}){const l=a,n=e.ref(!1),i=(d,c)=>{l("navigate",d,c)},r=(d,c)=>{n.value=!1,l("navigate",d,c)},s=d=>{d.key==="Escape"&&n.value&&(n.value=!1)};return e.onMounted(()=>{window.addEventListener("keydown",s)}),e.onUnmounted(()=>{window.removeEventListener("keydown",s)}),(d,c)=>(e.openBlock(),e.createElementBlock("header",{class:e.normalizeClass(["navbar mfs-w-full mfs-surface mfs-shadow mfs-rounded",{"navbar--sticky":t.sticky,"mfs-border-none":!t.bordered}])},[e.createElementVNode("div",Nr,[e.createElementVNode("div",Sr,[e.renderSlot(d.$slots,"brand",{},void 0,!0)]),e.createElementVNode("nav",Mr,[e.renderSlot(d.$slots,"links",{items:t.items,navigate:i},()=>[e.createElementVNode("ul",Dr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(o,m)=>(e.openBlock(),e.createElementBlock("li",{key:m,class:"navbar__item"},[!o.to&&!o.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["navbar__link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-pill",{"navbar__link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>i(o,f)},e.toDisplayString(o.label),11,Tr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.to?"router-link":"a"),{key:1,to:o.to,href:e.unref(se)(o.href),class:e.normalizeClass(["navbar__link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-pill",{"navbar__link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>i(o,f)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)]),e.createElementVNode("div",Lr,[e.renderSlot(d.$slots,"actions",{},void 0,!0),e.createElementVNode("button",{type:"button",class:"navbar__toggle mfs-inline-flex mfs-items-center mfs-justify-center mfs-surface-subtle mfs-shadow mfs-rounded-md mfs-interactive","aria-expanded":n.value,"aria-controls":"navbar-mobile-drawer","aria-label":"Toggle navigation menu",onClick:c[0]||(c[0]=o=>n.value=!n.value)},[n.value?(e.openBlock(),e.createElementBlock("svg",Rr,[...c[2]||(c[2]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Ir,[...c[1]||(c[1]=[e.createElementVNode("line",{x1:"3",y1:"6",x2:"21",y2:"6"},null,-1),e.createElementVNode("line",{x1:"3",y1:"12",x2:"21",y2:"12"},null,-1),e.createElementVNode("line",{x1:"3",y1:"18",x2:"21",y2:"18"},null,-1)])]))],8,zr)])]),e.createVNode(e.Transition,{name:"navbar-drawer"},{default:e.withCtx(()=>[n.value?(e.openBlock(),e.createElementBlock("div",Pr,[e.renderSlot(d.$slots,"links",{items:t.items,navigate:r},()=>[e.createElementVNode("ul",Ar,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(o,m)=>(e.openBlock(),e.createElementBlock("li",{key:m},[!o.to&&!o.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["navbar__mobile-link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-w-full mfs-rounded-md",{"navbar__mobile-link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>r(o,f)},e.toDisplayString(o.label),11,Fr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.to?"router-link":"a"),{key:1,to:o.to,href:e.unref(se)(o.href),class:e.normalizeClass(["navbar__mobile-link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-w-full mfs-rounded-md",{"navbar__mobile-link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>r(o,f)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)])):e.createCommentVNode("",!0)]),_:3})],2))}}),[["__scopeId","data-v-725e9bf5"]]),jr={class:"tabs"},Kr=["aria-selected","aria-disabled","disabled","tabindex","onClick"],Or={key:0,class:"tabs__panel",role:"tabpanel"},Ke=F(e.defineComponent({__name:"Tabs",props:{items:{},modelValue:{},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=new Map,s=e.ref({left:0,width:0,ready:!1}),d=e.computed(()=>{var k;if(l.modelValue!==void 0)return l.modelValue;const g=l.items.find(y=>!y.disabled);return(g==null?void 0:g.key)??((k=l.items[0])==null?void 0:k.key)??""}),c=e.computed(()=>({transform:`translateX(${s.value.left}px)`,width:`${s.value.width}px`,opacity:s.value.ready&&s.value.width>0?1:0})),o=(g,k)=>{k?r.set(g,k):r.delete(g)},m=async(g=!1)=>{await e.nextTick();const k=r.get(d.value);if(!k){s.value={left:0,width:0,ready:!1};return}s.value={left:k.offsetLeft,width:k.offsetWidth,ready:!0},g&&l.scrollable&&k.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},f=(g,k)=>{g.disabled||g.key===d.value||(n("update:modelValue",g.key),n("change",g.key))},b=g=>{var B;const k=l.items.filter($=>!$.disabled);if(!k.length)return;const y=k.findIndex($=>$.key===d.value);let h=-1;if(g.key==="ArrowRight"?h=(y+1)%k.length:g.key==="ArrowLeft"?h=(y-1+k.length)%k.length:g.key==="Home"?h=0:g.key==="End"&&(h=k.length-1),h>=0){g.preventDefault();const $=k[h];f($),(B=r.get($.key))==null||B.focus()}};let u=null;e.watch(()=>[d.value,l.items],()=>m(!0),{deep:!0});const p=()=>m(!1);return e.onMounted(()=>{m(!1),typeof ResizeObserver<"u"&&i.value&&(u=new ResizeObserver(p),u.observe(i.value)),window.addEventListener("resize",p)}),e.onUnmounted(()=>{u==null||u.disconnect(),window.removeEventListener("resize",p)}),(g,k)=>(e.openBlock(),e.createElementBlock("div",jr,[e.createElementVNode("div",{ref_key:"listRef",ref:i,class:e.normalizeClass(["tabs__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tabs__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:b},[e.createElementVNode("span",{class:"tabs__indicator mfs-pill",style:e.normalizeStyle(c.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(y,h)=>(e.openBlock(),e.createElementBlock("button",{key:y.key,ref_for:!0,ref:B=>o(y.key,B),type:"button",role:"tab",class:e.normalizeClass(["tabs__tab mfs-pill mfs-bg-transparent",{"tabs__tab--active":y.key===d.value,"tabs__tab--disabled mfs-disabled":y.disabled}]),"aria-selected":y.key===d.value,"aria-disabled":y.disabled||void 0,disabled:y.disabled,tabindex:y.key===d.value?0:-1,onClick:B=>f(y)},[e.renderSlot(g.$slots,"tab",{item:y,active:y.key===d.value},()=>[e.createTextVNode(e.toDisplayString(y.label),1)],!0)],10,Kr))),128))],34),g.$slots.default?(e.openBlock(),e.createElementBlock("div",Or,[e.renderSlot(g.$slots,"default",{activeKey:d.value},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7c67efbf"]]),Hr={class:"breadcrumb mfs-surface mfs-pill mfs-inline-flex mfs-items-center","aria-label":"Breadcrumb"},Ur={class:"breadcrumb__list mfs-flex mfs-flex-wrap mfs-items-center"},Wr={key:0,class:"breadcrumb__separator mfs-inline-flex mfs-items-center mfs-text-muted","aria-hidden":"true"},Gr={key:0},qr={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Yr=["aria-current"],Xr=["onClick"],Kt=F(e.defineComponent({__name:"Breadcrumb",props:{items:{},separator:{default:"chevron"}},emits:["navigate"],setup(t,{emit:a}){const l=a;return(n,i)=>(e.openBlock(),e.createElementBlock("nav",Hr,[e.createElementVNode("ol",Ur,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(r,s)=>(e.openBlock(),e.createElementBlock("li",{key:s,class:"breadcrumb__item mfs-inline-flex mfs-items-center"},[s>0?(e.openBlock(),e.createElementBlock("span",Wr,[e.renderSlot(n.$slots,"separator",{},()=>[t.separator==="slash"?(e.openBlock(),e.createElementBlock("span",Gr,"/")):(e.openBlock(),e.createElementBlock("svg",qr,[...i[0]||(i[0]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])]))],!0)])):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"item",{item:r,isLast:s===t.items.length-1},()=>[s===t.items.length-1||r.disabled?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["breadcrumb__leaf mfs-text mfs-font-semibold",{"breadcrumb__leaf--disabled mfs-disabled":r.disabled}]),"aria-current":s===t.items.length-1?"page":void 0},e.toDisplayString(r.label),11,Yr)):!r.to&&!r.href?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"breadcrumb__link mfs-inline-flex mfs-items-center mfs-rounded-sm mfs-border-none mfs-font-medium mfs-text",onClick:d=>l("navigate",r,d)},e.toDisplayString(r.label),9,Xr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.to?"router-link":"a"),{key:2,to:r.to,href:e.unref(se)(r.href),class:"breadcrumb__link mfs-inline-flex mfs-items-center mfs-rounded-sm mfs-border-none mfs-font-medium mfs-text",onClick:d=>l("navigate",r,d)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.label),1)]),_:2},1032,["to","href","onClick"]))],!0)]))),128))])]))}}),[["__scopeId","data-v-569a080d"]]),Zr=["aria-busy"],Jr={class:"pagination__controls"},Qr=["disabled"],vr=["disabled"],ei={key:0,class:"pagination__ellipsis mfs-text-muted","aria-hidden":"true"},ti=["disabled","aria-label","aria-current","onClick"],li=["disabled"],ni=["disabled"],oi={key:0,class:"pagination__extras"},ai={key:0,class:"pagination__per-page"},si=["value","disabled"],ri=["value"],ii={class:"pagination__label mfs-text-muted"},di=["max","disabled"],xe=F(e.defineComponent({__name:"Pagination",props:{modelValue:{},total:{},perPage:{default:10},perPageOptions:{default:()=>[10,20,50,100]},showJumpTo:{type:Boolean,default:!1},siblingCount:{default:1},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","update:perPage","change"],setup(t,{emit:a}){const l=t,n=e.computed(()=>l.disabled||l.loading),i=a,r=e.ref(""),s=e.computed(()=>Math.max(1,Math.ceil(l.total/Math.max(1,l.perPage)))),d=e.computed(()=>Math.min(Math.max(1,l.modelValue),s.value)),c=e.computed(()=>{const b=s.value,u=d.value,p=l.siblingCount,g=p*2+5;if(b<=g)return Array.from({length:b},(_,D)=>D+1);const k=Math.max(u-p,1),y=Math.min(u+p,b),h=k>2,B=y<b-1,$=[1];if(h)$.push("ellipsis");else for(let _=2;_<k;_++)$.push(_);for(let _=Math.max(2,k);_<=Math.min(b-1,y);_++)$.push(_);if(B)$.push("ellipsis");else for(let _=y+1;_<b;_++)$.push(_);return b>1&&$.push(b),$}),o=b=>{if(n.value)return;const u=Math.min(Math.max(1,b),s.value);u!==d.value&&(i("update:modelValue",u),i("change",{page:u,perPage:l.perPage}))},m=b=>{if(n.value)return;const u=Number(b.target.value),p=Math.max(1,Math.ceil(l.total/Math.max(1,u))),g=Math.min(d.value,p);i("update:perPage",u),g!==d.value&&i("update:modelValue",g),i("change",{page:g,perPage:u})},f=()=>{if(n.value)return;const b=Number.parseInt(r.value,10);Number.isNaN(b)||o(b),r.value=""};return(b,u)=>(e.openBlock(),e.createElementBlock("nav",{class:"pagination mfs-row mfs-text","aria-label":"Pagination","aria-busy":t.loading||void 0},[e.createElementVNode("div",Jr,[e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value<=1,"aria-label":"First page",onClick:u[0]||(u[0]=p=>o(1))},[...u[5]||(u[5]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"11 17 6 12 11 7"}),e.createElementVNode("polyline",{points:"18 17 13 12 18 7"})],-1)])],8,Qr),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value<=1,"aria-label":"Previous page",onClick:u[1]||(u[1]=p=>o(d.value-1))},[...u[6]||(u[6]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"15 18 9 12 15 6"})],-1)])],8,vr),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(p,g)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:g},[p==="ellipsis"?(e.openBlock(),e.createElementBlock("span",ei," … ")):(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:e.normalizeClass(["pagination__btn pagination__btn--page mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",{"pagination__btn--active":p===d.value}]),disabled:n.value,"aria-label":`Page ${p}`,"aria-current":p===d.value?"page":void 0,onClick:k=>o(p)},e.toDisplayString(p),11,ti))],64))),128)),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value>=s.value,"aria-label":"Next page",onClick:u[2]||(u[2]=p=>o(d.value+1))},[...u[7]||(u[7]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"})],-1)])],8,li),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value>=s.value,"aria-label":"Last page",onClick:u[3]||(u[3]=p=>o(s.value))},[...u[8]||(u[8]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"13 17 18 12 13 7"}),e.createElementVNode("polyline",{points:"6 17 11 12 6 7"})],-1)])],8,ni)]),t.perPageOptions.length||t.showJumpTo?(e.openBlock(),e.createElementBlock("div",oi,[t.perPageOptions.length?(e.openBlock(),e.createElementBlock("label",ai,[u[9]||(u[9]=e.createElementVNode("span",{class:"pagination__label mfs-text-muted"},"Rows",-1)),e.createElementVNode("select",{class:"pagination__select mfs-surface mfs-rounded-md mfs-shadow-inset",value:t.perPage,disabled:n.value,"aria-label":"Items per page",onChange:m},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.perPageOptions,p=>(e.openBlock(),e.createElementBlock("option",{key:p,value:p},e.toDisplayString(p),9,ri))),128))],40,si)])):e.createCommentVNode("",!0),t.showJumpTo?(e.openBlock(),e.createElementBlock("form",{key:1,class:"pagination__jump",onSubmit:e.withModifiers(f,["prevent"])},[e.createElementVNode("label",ii,[u[10]||(u[10]=e.createTextVNode(" Go ",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":u[4]||(u[4]=p=>r.value=p),type:"number",min:"1",max:s.value,disabled:n.value,class:"pagination__input mfs-surface mfs-rounded-md mfs-shadow-inset","aria-label":"Jump to page"},null,8,di),[[e.vModelText,r.value]])])],32)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],8,Zr))}}),[["__scopeId","data-v-4b04f139"]]),ci=["aria-current"],mi=["onClick"],fi={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},ui={key:0,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},pi={key:1,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},ki={key:2},hi={class:"steps__content mfs-flex mfs-flex-col"},gi={class:"steps__label mfs-font-semibold"},yi={key:0,class:"steps__desc mfs-text-muted"},bi={key:1,class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md"},Bi={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},wi={key:0,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},_i={key:1,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Ei={key:2},$i={class:"steps__content mfs-flex mfs-flex-col"},Vi={class:"steps__label mfs-font-semibold"},xi={key:0,class:"steps__desc mfs-text-muted"},Oe=F(e.defineComponent({__name:"Steps",props:{items:{},modelValue:{default:0},clickable:{type:Boolean,default:!1},direction:{default:"responsive"}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=(s,d)=>s.status?s.status:d<l.modelValue?"completed":d===l.modelValue?"active":"upcoming",r=s=>{!l.clickable||s===l.modelValue||(n("update:modelValue",s),n("change",s))};return(s,d)=>(e.openBlock(),e.createElementBlock("ol",{class:e.normalizeClass(["steps mfs-flex mfs-w-full mfs-gap-2",[`steps--${t.direction}`]]),"aria-label":"Progress steps"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(c,o)=>(e.openBlock(),e.createElementBlock("li",{key:o,class:e.normalizeClass(["steps__item mfs-flex mfs-items-center mfs-gap-2",[`steps__item--${i(c,o)}`,{"steps__item--clickable":t.clickable}]]),"aria-current":i(c,o)==="active"?"step":void 0},[t.clickable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md",onClick:m=>r(o)},[e.createElementVNode("span",fi,[i(c,o)==="completed"?(e.openBlock(),e.createElementBlock("svg",ui,[...d[0]||(d[0]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):i(c,o)==="error"?(e.openBlock(),e.createElementBlock("svg",pi,[...d[1]||(d[1]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("span",ki,e.toDisplayString(o+1),1))]),e.createElementVNode("span",hi,[e.createElementVNode("span",gi,e.toDisplayString(c.label),1),c.description?(e.openBlock(),e.createElementBlock("span",yi,e.toDisplayString(c.description),1)):e.createCommentVNode("",!0)])],8,mi)):(e.openBlock(),e.createElementBlock("div",bi,[e.createElementVNode("span",Bi,[i(c,o)==="completed"?(e.openBlock(),e.createElementBlock("svg",wi,[...d[2]||(d[2]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):i(c,o)==="error"?(e.openBlock(),e.createElementBlock("svg",_i,[...d[3]||(d[3]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("span",Ei,e.toDisplayString(o+1),1))]),e.createElementVNode("span",$i,[e.createElementVNode("span",Vi,e.toDisplayString(c.label),1),c.description?(e.openBlock(),e.createElementBlock("span",xi,e.toDisplayString(c.description),1)):e.createCommentVNode("",!0)])])),o<t.items.length-1?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(["steps__connector mfs-surface-subtle mfs-shadow-inset mfs-pill",{"steps__connector--completed":i(c,o)==="completed"}]),"aria-hidden":"true"},null,2)):e.createCommentVNode("",!0)],10,ci))),128))],2))}}),[["__scopeId","data-v-aef341ac"]]),Ci={key:0,class:"ctx-menu__divider mfs-divider",role:"separator"},Ni={key:1,role:"none"},Si=["disabled","onClick"],Mi={key:0,class:"ctx-menu__icon","aria-hidden":"true"},Di={class:"ctx-menu__label"},Ot=F(e.defineComponent({__name:"ContextMenu",props:{items:{}},emits:["select","open","close"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(!1),s=e.ref(null),d=e.ref({x:0,y:0}),c=new Map,o=(h,B)=>{B?c.set(h,B):c.delete(h)},m=()=>{r.value&&(r.value=!1,y(),i("close"))},f=async h=>{var $;r.value=!0,d.value={x:h.clientX,y:h.clientY},i("open"),await e.nextTick();const B=s.value;if(B){const _=B.getBoundingClientRect(),D=8,S=window.innerWidth-_.width-D,E=window.innerHeight-_.height-D;d.value={x:Math.max(D,Math.min(h.clientX,S)),y:Math.max(D,Math.min(h.clientY,E))};const w=n.items.findIndex(N=>!N.divider&&!N.disabled);w>=0&&(($=c.get(w))==null||$.focus())}k()},b=h=>{var B;h.disabled||((B=h.action)==null||B.call(h),i("select",h),m())},u=h=>{var D,S;const B=n.items.map((E,w)=>!E.divider&&!E.disabled?w:-1).filter(E=>E>=0);if(!B.length)return;const $=document.activeElement,_=B.findIndex(E=>c.get(E)===$);if(h.key==="ArrowDown"){h.preventDefault();const E=B[(_+1)%B.length];(D=c.get(E))==null||D.focus()}else if(h.key==="ArrowUp"){h.preventDefault();const E=B[(_-1+B.length)%B.length];(S=c.get(E))==null||S.focus()}else h.key==="Escape"&&(h.preventDefault(),m())},p=h=>{s.value&&!s.value.contains(h.target)&&m()},g=h=>{h.key==="Escape"&&m()},k=()=>{window.addEventListener("pointerdown",p),window.addEventListener("keydown",g),window.addEventListener("resize",m)},y=()=>{window.removeEventListener("pointerdown",p),window.removeEventListener("keydown",g),window.removeEventListener("resize",m)};return e.onUnmounted(()=>{y()}),a({open:f,close:m}),(h,B)=>(e.openBlock(),e.createElementBlock("div",{class:"ctx-wrapper",onContextmenu:e.withModifiers(f,["prevent"])},[e.renderSlot(h.$slots,"default",{},void 0,!0),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ctx-pop"},{default:e.withCtx(()=>[r.value?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"menuRef",ref:s,class:"ctx-menu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${d.value.x}px`,top:`${d.value.y}px`}),onKeydown:u},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,($,_)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:_},[$.divider?(e.openBlock(),e.createElementBlock("li",Ci)):(e.openBlock(),e.createElementBlock("li",Ni,[e.createElementVNode("button",{ref_for:!0,ref:D=>o(_,D),type:"button",role:"menuitem",class:e.normalizeClass(["ctx-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"ctx-menu__item--disabled mfs-disabled":$.disabled,"ctx-menu__item--danger":$.danger}]),disabled:$.disabled,onClick:D=>b($)},[e.renderSlot(h.$slots,"item",{item:$},()=>[$.icon?(e.openBlock(),e.createElementBlock("span",Mi,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Di,e.toDisplayString($.label),1)],!0)],10,Si)]))],64))),128))],36)):e.createCommentVNode("",!0)]),_:3})]))],32))}}),[["__scopeId","data-v-ebbadeb3"]]),Ht=F(e.defineComponent({__name:"ScrollTop",props:{threshold:{default:200},behavior:{default:"smooth"},target:{default:null}},emits:["click"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);let r=null;const s=()=>typeof l.target=="string"?document.querySelector(l.target)??window:l.target instanceof HTMLElement?l.target:window,d=()=>{if(!r)return;const o=r===window?window.scrollY:r.scrollTop;i.value=o>=l.threshold},c=o=>{s().scrollTo({top:0,behavior:l.behavior}),n("click",o)};return e.onMounted(()=>{r=s(),r.addEventListener("scroll",d,{passive:!0}),d()}),e.onUnmounted(()=>{r==null||r.removeEventListener("scroll",d)}),(o,m)=>(e.openBlock(),e.createBlock(e.Transition,{name:"scroll-top-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"scroll-top mfs-shadow mfs-interactive","aria-label":"Scroll to top",onClick:c},[e.renderSlot(o.$slots,"default",{},()=>[m[0]||(m[0]=e.createElementVNode("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"18 15 12 9 6 15"})],-1))],!0)])):e.createCommentVNode("",!0)]),_:3}))}}),[["__scopeId","data-v-a8dbdc07"]]),Ti={key:0,class:"data-table__toolbar mfs-flex mfs-flex-wrap mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},Li={key:0,class:"data-table__toolbar-actions"},zi={key:0,class:"data-table__search mfs-relative mfs-flex mfs-items-center"},Ii=["value"],Ri=["aria-expanded"],Pi={class:"data-table__wrap mfs-w-full mfs-overflow-x-auto"},Ai={class:"data-table__table mfs-w-full mfs-text-left"},Fi={class:"data-table__head"},ji={key:0,class:"data-table__th data-table__th--expand mfs-text-muted","aria-label":"Expand row"},Ki={key:1,class:"data-table__th data-table__th--select mfs-text-muted mfs-whitespace-nowrap"},Oi=["aria-sort"],Hi=["onClick"],Ui={class:"data-table__sort-icon mfs-shrink-0",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},Wi=["fill"],Gi=["fill"],qi={key:0,class:"data-table__sort-badge"},Yi={key:1},Xi={class:"data-table__body"},Zi={key:0,class:"data-table__empty-row"},Ji=["colspan"],Qi={class:"data-table__empty-content mfs-inline-flex mfs-flex-col mfs-items-center mfs-gap-2"},vi=["aria-selected","onClick"],ed=["aria-expanded","aria-label","onClick"],td=["checked","aria-label","onChange"],ld=["data-label"],nd={class:"data-table__cell-value"},od={key:0,class:"data-table__expansion-row"},ad=["colspan"],sd={key:1,class:"data-table__paginator mfs-flex mfs-items-center mfs-justify-between mfs-flex-wrap mfs-gap-3 mfs-pt-3 mfs-border-t"},rd={key:0,class:"data-table__per-page mfs-inline-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-text-muted"},id=["value","disabled"],dd=["value"],cd={key:2,class:"mfs-loading-overlay","aria-busy":"true"},Ut=F(e.defineComponent({__name:"DataTable",props:{columns:{},rows:{},value:{},rowKey:{default:"id"},searchable:{type:Boolean,default:!1},searchQuery:{default:""},selectable:{type:[Boolean,String],default:!1},selection:{default:null},responsiveMode:{default:"card"},emptyText:{default:"No data available"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},paginator:{type:Boolean,default:!1},totalRecords:{},rowsPerPage:{},rowsPerPageOptions:{default:()=>[5,10,20,50]},page:{},first:{default:0},sortMode:{default:"single"},multiSortMeta:{},expandable:{type:Boolean,default:!1},expandedRows:{},columnToggle:{type:Boolean,default:!1},visibleColumns:{}},emits:["update:selection","update:searchQuery","update:page","update:rows","update:rowsPerPage","update:first","update:multiSortMeta","update:expandedRows","update:visibleColumns","page","sort","filter","row-click","row-expand","row-collapse"],setup(t,{emit:a}){const l=t,n=a,i=`dt-radio-${e.useId()}`,r=e.ref(l.searchQuery),s=e.ref(null),d=e.ref(null),c=e.ref(l.multiSortMeta?l.multiSortMeta.map(M=>({...M})):[]);e.watch(()=>l.multiSortMeta,M=>{c.value=M?M.map(x=>({...x})):[]},{deep:!0});const o=e.computed(()=>l.multiSortMeta??c.value),m=e.computed(()=>l.value??(Array.isArray(l.rows)?l.rows:[])),f=e.ref(typeof l.rows=="number"?l.rows:l.rowsPerPage??10);e.watch(()=>l.rows,M=>{typeof M=="number"&&(f.value=M)}),e.watch(()=>l.rowsPerPage,M=>{M!==void 0&&(f.value=M)});const b=e.computed(()=>Math.max(1,typeof l.rows=="number"?l.rows:l.rowsPerPage??f.value)),u=e.ref(l.page!==void 0?Math.max(1,l.page):l.first>0?Math.floor(l.first/b.value)+1:1);e.watch(()=>l.page,M=>{M!==void 0&&(u.value=Math.max(1,M))}),e.watch(()=>l.first,M=>{M!==void 0&&l.page===void 0&&(u.value=Math.floor(Math.max(0,M)/b.value)+1)}),e.watch(()=>l.searchQuery,M=>{r.value=M});const p=e.computed(()=>l.searchQuery!==""?l.searchQuery:r.value);e.watch(p,()=>{!l.lazy&&l.paginator&&N.value!==1&&(u.value=1,n("update:page",1),n("update:first",0))});const g=e.computed(()=>l.selectable===!0||l.selectable==="multiple"?"multiple":l.selectable==="single"?"single":null);function k(M,x){const R=M==null?void 0:M[l.rowKey];return typeof R=="string"||typeof R=="number"?R:x}function y(M){const x=M.target.value;r.value=x,n("update:searchQuery",x),n("filter",x)}function h(M){if(l.sortMode==="multiple"){const x=o.value.find(R=>R.key===M);return x?x.order:null}return s.value===M?d.value:null}function B(M){if(l.sortMode!=="multiple"||o.value.length===0)return null;const x=o.value.findIndex(R=>R.key===M);return x>=0?x+1:null}function $(M){if(l.sortMode==="multiple"){const x=o.value.map(X=>({...X})),R=x.findIndex(X=>X.key===M);let H="asc";R===-1?(x.push({key:M,order:"asc"}),H="asc"):x[R].order==="asc"?(x[R].order="desc",H="desc"):(x.splice(R,1),H=null),c.value=x,n("update:multiSortMeta",x),n("sort",{key:M,order:H,multiSortMeta:x});return}s.value!==M?(s.value=M,d.value="asc"):d.value==="asc"?d.value="desc":(s.value=null,d.value=null),n("sort",{key:M,order:d.value})}function _(M){if(!M.sortable)return;const x=h(M.key);return x?x==="asc"?"ascending":"descending":"none"}function D(M,x,R){return M==null&&x==null?0:M==null?-1*R:x==null?1*R:typeof M=="number"&&typeof x=="number"?(M-x)*R:String(M).localeCompare(String(x))*R}const S=e.computed(()=>{if(l.lazy)return m.value;const M=p.value.trim().toLowerCase();let x=m.value;if(M){const R=l.columns.map(H=>H.key);x=x.filter(H=>R.some(X=>String(H[X]??"").toLowerCase().includes(M)))}if(l.sortMode==="multiple"){if(o.value.length>0){const R=o.value;x=[...x].sort((H,X)=>{for(const le of R){const ce=le.order==="asc"?1:-1,De=D(H[le.key],X[le.key],ce);if(De!==0)return De}return 0})}}else if(s.value&&d.value){const R=s.value,H=d.value==="asc"?1:-1;x=[...x].sort((X,le)=>D(X[R],le[R],H))}return x}),E=e.computed(()=>l.lazy?l.totalRecords??m.value.length:l.totalRecords??S.value.length),w=e.computed(()=>Math.max(1,Math.ceil(E.value/b.value))),N=e.computed(()=>{const M=l.page!==void 0?l.page:u.value;return Math.min(Math.max(1,M),w.value)}),V=e.computed(()=>{if(l.lazy||!l.paginator)return S.value;const M=(N.value-1)*b.value;return S.value.slice(M,M+b.value)});function C(M){const x=b.value,R=w.value,H=Math.min(Math.max(1,M),R),X=(H-1)*x;u.value=H,n("update:page",H),n("update:first",X),n("page",{page:H,first:X,rows:x,pageCount:R,rowsPerPage:x})}function P(M){if(l.loading)return;const x=Number(M.target.value);if(!Number.isFinite(x)||x<=0)return;f.value=x;const R=Math.max(1,Math.ceil(E.value/x)),H=Math.min(N.value,R),X=(H-1)*x;u.value=H,n("update:rows",x),n("update:rowsPerPage",x),n("update:page",H),n("update:first",X),n("page",{page:H,first:X,rows:x,pageCount:R,rowsPerPage:x})}function T(M,x){if(!g.value||!l.selection)return!1;const R=k(M,x);return g.value==="single"?Array.isArray(l.selection)?!1:k(l.selection,-1)===R:Array.isArray(l.selection)&&l.selection.some((H,X)=>k(H,X)===R)}const I=e.computed(()=>g.value!=="multiple"||V.value.length===0?!1:V.value.every((M,x)=>T(M,x))),j=e.computed(()=>{if(g.value!=="multiple"||V.value.length===0)return!1;const M=V.value.filter((x,R)=>T(x,R)).length;return M>0&&M<V.value.length});function A(M,x){if(!g.value)return;if(g.value==="single"){n("update:selection",M);return}const R=k(M,x),H=Array.isArray(l.selection)?[...l.selection]:[],X=H.findIndex((le,ce)=>k(le,ce)===R);X>=0?H.splice(X,1):H.push(M),n("update:selection",H)}function K(){g.value==="multiple"&&(I.value?n("update:selection",[]):n("update:selection",[...V.value]))}function W(M,x){n("row-click",M),g.value&&A(M,x)}const v=e.ref(l.expandedRows?[...l.expandedRows]:[]);e.watch(()=>l.expandedRows,M=>{v.value=M?[...M]:[]},{deep:!0});const te=e.computed(()=>l.expandedRows??v.value);function oe(M,x){if(!l.expandable)return!1;const R=k(M,x);return te.value.some((H,X)=>k(H,X)===R)}function z(M,x){if(!l.expandable)return;const R=k(M,x),H=[...te.value],X=H.findIndex((le,ce)=>k(le,ce)===R);X>=0?(H.splice(X,1),v.value=H,n("update:expandedRows",H),n("row-collapse",M)):(H.push(M),v.value=H,n("update:expandedRows",H),n("row-expand",M))}const O=e.ref(l.visibleColumns?[...l.visibleColumns]:l.columns.map(M=>M.key));e.watch(()=>l.visibleColumns,M=>{M!==void 0&&(O.value=[...M])},{deep:!0}),e.watch(()=>l.columns,M=>{l.visibleColumns===void 0&&(O.value=M.map(x=>x.key))});const Z=e.computed(()=>l.visibleColumns??O.value),Y=e.computed(()=>{if(!l.columnToggle)return l.columns;const M=new Set(Z.value);return l.columns.filter(x=>M.has(x.key))}),Q=e.computed(()=>Y.value.length+(g.value?1:0)+(l.expandable?1:0));function q(M){return Z.value.includes(M)}function U(M){const x=[...Z.value],R=x.indexOf(M);if(R>=0){if(x.length<=1)return;x.splice(R,1)}else{const H=l.columns.map(X=>X.key);x.push(M),x.sort((X,le)=>H.indexOf(X)-H.indexOf(le))}O.value=x,n("update:visibleColumns",x)}const J=e.ref(!1),ne=e.ref(null),G=e.ref(null),ee=e.ref({top:0,left:0}),re=e.computed(()=>({position:"fixed",top:`${ee.value.top}px`,left:`${ee.value.left}px`,zIndex:9999}));function ae(){var le;const M=ne.value;if(!M)return;const x=M.getBoundingClientRect(),R=((le=G.value)==null?void 0:le.offsetWidth)||190,H=Math.max(8,Math.min(x.right-R,window.innerWidth-R-8)),X=x.bottom+6;ee.value={top:X,left:H}}function Me(M){var R,H;const x=M.target;x&&((R=ne.value)!=null&&R.contains(x)||(H=G.value)!=null&&H.contains(x)||he())}function me(M){M.key==="Escape"&&he()}function Je(){J.value=!0,e.nextTick(()=>{ae(),document.addEventListener("mousedown",Me),document.addEventListener("keydown",me),window.addEventListener("resize",ae),window.addEventListener("scroll",ae,!0)})}function he(){J.value=!1,document.removeEventListener("mousedown",Me),document.removeEventListener("keydown",me),window.removeEventListener("resize",ae),window.removeEventListener("scroll",ae,!0)}function Qe(){J.value?he():Je()}return e.onBeforeUnmount(()=>{he()}),(M,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["data-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card mfs-overflow-hidden",`data-table--${t.responsiveMode}`])},[t.searchable||t.columnToggle||M.$slots.header?(e.openBlock(),e.createElementBlock("div",Ti,[e.renderSlot(M.$slots,"header",{},void 0,!0),t.searchable||t.columnToggle?(e.openBlock(),e.createElementBlock("div",Li,[t.searchable?(e.openBlock(),e.createElementBlock("div",zi,[x[4]||(x[4]=e.createElementVNode("svg",{class:"data-table__search-icon mfs-absolute mfs-text-muted",viewBox:"0 0 20 20",fill:"none","aria-hidden":"true"},[e.createElementVNode("circle",{cx:"9",cy:"9",r:"6",stroke:"currentColor","stroke-width":"1.8"}),e.createElementVNode("path",{d:"M13.5 13.5L17 17",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round"})],-1)),e.createElementVNode("input",{type:"search",class:"data-table__search-input mfs-inset mfs-rounded-sm mfs-w-full mfs-text-sm mfs-outline-none",value:p.value,placeholder:"Search...","aria-label":"Search table",onInput:y},null,40,Ii)])):e.createCommentVNode("",!0),t.columnToggle?(e.openBlock(),e.createElementBlock("button",{key:1,ref_key:"columnToggleBtnRef",ref:ne,type:"button",class:"data-table__col-btn mfs-focus-ring mfs-surface-subtle mfs-rounded-sm mfs-shadow-inset mfs-text-sm mfs-font-semibold mfs-cursor-pointer mfs-inline-flex mfs-items-center mfs-gap-2","aria-expanded":J.value,"aria-haspopup":"true",onClick:Qe},[...x[5]||(x[5]=[e.createElementVNode("svg",{class:"data-table__col-icon",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true"},[e.createElementVNode("rect",{x:"2.5",y:"3.5",width:"3.5",height:"11",rx:"1",stroke:"currentColor","stroke-width":"1.5"}),e.createElementVNode("rect",{x:"7.25",y:"3.5",width:"3.5",height:"11",rx:"1",stroke:"currentColor","stroke-width":"1.5"}),e.createElementVNode("rect",{x:"12",y:"3.5",width:"3.5",height:"11",rx:"1",stroke:"currentColor","stroke-width":"1.5"})],-1),e.createElementVNode("span",null,"Columns",-1)])],8,Ri)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[t.columnToggle&&J.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"columnMenuRef",ref:G,class:"data-table__col-menu mfs-surface mfs-rounded-md mfs-shadow-card",style:e.normalizeStyle(re.value),role:"menu","aria-label":"Toggle columns"},[x[6]||(x[6]=e.createElementVNode("div",{class:"data-table__col-menu-title mfs-text-xs mfs-font-bold mfs-text-muted"}," Visible Columns ",-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,R=>(e.openBlock(),e.createElementBlock("label",{key:R.key,class:e.normalizeClass(["data-table__col-item mfs-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-cursor-pointer",{"data-table__col-item--disabled":q(R.key)&&Z.value.length<=1}])},[e.createVNode(fe,{"model-value":q(R.key),disabled:q(R.key)&&Z.value.length<=1,"onUpdate:modelValue":H=>U(R.key)},null,8,["model-value","disabled","onUpdate:modelValue"]),e.createElementVNode("span",null,e.toDisplayString(R.label),1)],2))),128))],4)):e.createCommentVNode("",!0)])),e.createElementVNode("div",Pi,[e.createElementVNode("table",Ai,[e.createElementVNode("thead",Fi,[e.createElementVNode("tr",null,[t.expandable?(e.openBlock(),e.createElementBlock("th",ji)):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("th",Ki,[g.value==="multiple"?(e.openBlock(),e.createBlock(fe,{key:0,class:"data-table__checkbox","model-value":I.value,indeterminate:j.value,"aria-label":"Select all rows",onClick:x[0]||(x[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":K},null,8,["model-value","indeterminate"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Y.value,R=>(e.openBlock(),e.createElementBlock("th",{key:R.key,class:e.normalizeClass(["data-table__th mfs-text-muted mfs-whitespace-nowrap",[R.align?`data-table__cell--${R.align}`:"",{"data-table__th--sortable":R.sortable}]]),style:e.normalizeStyle(R.width?{width:R.width}:void 0),"aria-sort":_(R)},[R.sortable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["data-table__sort-btn mfs-focus-ring mfs-inline-flex mfs-items-center mfs-bg-transparent mfs-border-none mfs-cursor-pointer mfs-p-0",{"data-table__sort-btn--active":h(R.key)!==null}]),onClick:H=>$(R.key)},[e.createElementVNode("span",null,e.toDisplayString(R.label),1),(e.openBlock(),e.createElementBlock("svg",Ui,[e.createElementVNode("path",{d:"M8 3L11 6.5H5L8 3Z",fill:h(R.key)==="asc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Wi),e.createElementVNode("path",{d:"M8 13L5 9.5H11L8 13Z",fill:h(R.key)==="desc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Gi)])),t.sortMode==="multiple"&&B(R.key)!==null?(e.openBlock(),e.createElementBlock("span",qi,e.toDisplayString(B(R.key)),1)):e.createCommentVNode("",!0)],10,Hi)):(e.openBlock(),e.createElementBlock("span",Yi,e.toDisplayString(R.label),1))],14,Oi))),128))])]),e.createElementVNode("tbody",Xi,[V.value.length===0?(e.openBlock(),e.createElementBlock("tr",Zi,[e.createElementVNode("td",{colspan:Q.value,class:"data-table__empty mfs-text-muted mfs-text-center"},[e.renderSlot(M.$slots,"empty",{},()=>[e.createElementVNode("div",Qi,[x[7]||(x[7]=e.createElementVNode("svg",{class:"data-table__empty-icon",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true"},[e.createElementVNode("rect",{x:"3",y:"5",width:"18",height:"14",rx:"3",stroke:"currentColor","stroke-width":"1.6"}),e.createElementVNode("path",{d:"M3 10H21",stroke:"currentColor","stroke-width":"1.6"})],-1)),e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])],!0)],8,Ji)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(V.value,(R,H)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:k(R,H)},[e.createElementVNode("tr",{class:e.normalizeClass(["data-table__row",{"data-table__row--selected":T(R,H),"data-table__row--expanded":t.expandable&&oe(R,H)}]),"aria-selected":g.value?T(R,H):void 0,onClick:X=>W(R,H)},[t.expandable?(e.openBlock(),e.createElementBlock("td",{key:0,class:"data-table__td data-table__td--expand","data-label":"Details",onClick:x[1]||(x[1]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("button",{type:"button",class:"data-table__expand-btn mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center mfs-bg-transparent mfs-border-none mfs-cursor-pointer","aria-expanded":oe(R,H),"aria-label":oe(R,H)?`Collapse row ${H+1}`:`Expand row ${H+1}`,onClick:X=>z(R,H)},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["data-table__expand-icon",{"data-table__expand-icon--open":oe(R,H)}]),viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[...x[8]||(x[8]=[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2))],8,ed)])):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("td",{key:1,class:"data-table__td data-table__td--select","data-label":"Select",onClick:x[3]||(x[3]=e.withModifiers(()=>{},["stop"]))},[g.value==="single"?(e.openBlock(),e.createElementBlock("input",{key:0,type:"radio",class:"data-table__checkbox mfs-cursor-pointer",name:i,checked:T(R,H),"aria-label":`Select row ${H+1}`,onChange:X=>A(R,H)},null,40,td)):(e.openBlock(),e.createBlock(fe,{key:1,class:"data-table__checkbox","model-value":T(R,H),"aria-label":`Select row ${H+1}`,onClick:x[2]||(x[2]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":X=>A(R,H)},null,8,["model-value","aria-label","onUpdate:modelValue"]))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Y.value,X=>(e.openBlock(),e.createElementBlock("td",{key:X.key,class:e.normalizeClass(["data-table__td",X.align?`data-table__cell--${X.align}`:""]),"data-label":X.label},[e.renderSlot(M.$slots,`cell-${X.key}`,{row:R,value:R[X.key],column:X,index:H},()=>[e.createElementVNode("span",nd,e.toDisplayString(R[X.key]??""),1)],!0)],10,ld))),128))],10,vi),t.expandable&&oe(R,H)?(e.openBlock(),e.createElementBlock("tr",od,[e.createElementVNode("td",{colspan:Q.value,class:"data-table__expansion-cell"},[e.renderSlot(M.$slots,"expansion",{row:R,index:H},void 0,!0)],8,ad)])):e.createCommentVNode("",!0)],64))),128))])])]),t.paginator?(e.openBlock(),e.createElementBlock("div",sd,[t.rowsPerPageOptions.length?(e.openBlock(),e.createElementBlock("label",rd,[x[9]||(x[9]=e.createElementVNode("span",null,"Show",-1)),e.createElementVNode("select",{class:"data-table__per-page-select mfs-surface mfs-rounded-md mfs-shadow-inset mfs-text",value:b.value,disabled:t.loading,"aria-label":"Rows per page",onChange:P},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.rowsPerPageOptions,R=>(e.openBlock(),e.createElementBlock("option",{key:R,value:R},e.toDisplayString(R),9,dd))),128))],40,id),x[10]||(x[10]=e.createElementVNode("span",null,"per page",-1))])):e.createCommentVNode("",!0),e.createVNode(xe,{"model-value":N.value,total:E.value,"per-page":b.value,"per-page-options":[],loading:t.loading,"onUpdate:modelValue":C},null,8,["model-value","total","per-page","loading"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",cd,[e.renderSlot(M.$slots,"loading",{},()=>[x[11]||(x[11]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-b4a35d96"]]),Wt=e.defineComponent({__name:"Column",props:{field:{},header:{},sortable:{type:Boolean},sortField:{},filterField:{},headerStyle:{},bodyStyle:{},headerClass:{},bodyClass:{},style:{},frozen:{type:Boolean},alignFrozen:{},selectionMode:{},expander:{type:Boolean},hidden:{type:Boolean}},setup(t){return(a,l)=>null}});function Be(t,a,l="id"){if(t&&typeof t=="object"&&l in t){const n=t[l];if(typeof n=="string"||typeof n=="number")return n}return a}const md={class:"data-view mfs-relative"},fd={class:"data-view__header"},ud={class:"data-view__header-left"},pd={class:"data-view__toggle mfs-inset mfs-rounded-md",role:"group","aria-label":"View layout"},kd=["aria-pressed"],hd=["aria-pressed"],gd={key:0,class:"data-view__empty mfs-card mfs-text-muted"},yd={class:"data-view__empty-content"},bd={class:"data-view__fallback-card mfs-card"},Bd={key:2,class:"mfs-loading-overlay","aria-busy":"true"},Gt=F(e.defineComponent({__name:"DataView",props:{items:{},layout:{default:"grid"},itemKey:{default:"id"},columns:{},emptyText:{default:"No items found"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},totalRecords:{}},emits:["update:layout","page","sort","filter"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.layout);e.watch(()=>l.layout,c=>{i.value=c});const r=e.computed(()=>i.value),s=e.computed(()=>{if(!(r.value!=="grid"||!l.columns))return{gridTemplateColumns:`repeat(${l.columns}, minmax(0, 1fr))`}});function d(c){i.value!==c&&(i.value=c,n("update:layout",c))}return(c,o)=>(e.openBlock(),e.createElementBlock("div",md,[e.createElementVNode("div",fd,[e.createElementVNode("div",ud,[e.renderSlot(c.$slots,"header",{},void 0,!0)]),e.createElementVNode("div",pd,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["data-view__toggle-btn mfs-rounded-sm",{"data-view__toggle-btn--active mfs-shadow":r.value==="grid"}]),"aria-pressed":r.value==="grid","aria-label":"Grid layout",onClick:o[0]||(o[0]=m=>d("grid"))},[...o[2]||(o[2]=[e.createStaticVNode('<svg viewBox="0 0 18 18" fill="none" aria-hidden="true" data-v-23afce0e><rect x="2" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect><rect x="10" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect><rect x="2" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect><rect x="10" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect></svg>',1)])],10,kd),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["data-view__toggle-btn mfs-rounded-sm",{"data-view__toggle-btn--active mfs-shadow":r.value==="list"}]),"aria-pressed":r.value==="list","aria-label":"List layout",onClick:o[1]||(o[1]=m=>d("list"))},[...o[3]||(o[3]=[e.createElementVNode("svg",{viewBox:"0 0 18 18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M3 4.5H15M3 9H15M3 13.5H15",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round"})],-1)])],10,hd)])]),t.items.length===0?(e.openBlock(),e.createElementBlock("div",gd,[e.renderSlot(c.$slots,"empty",{},()=>[e.createElementVNode("div",yd,[o[4]||(o[4]=e.createElementVNode("svg",{class:"data-view__empty-icon",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true"},[e.createElementVNode("rect",{x:"3",y:"4",width:"18",height:"16",rx:"3",stroke:"currentColor","stroke-width":"1.6"}),e.createElementVNode("path",{d:"M8 10H16M8 14H13",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round"})],-1)),e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])],!0)])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["data-view__body",`data-view__body--${r.value}`]),style:e.normalizeStyle(s.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(m,f)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(Be)(m,f,t.itemKey),class:"data-view__item"},[r.value==="grid"&&c.$slots.grid?e.renderSlot(c.$slots,"grid",{item:m,index:f},void 0,!0,0):r.value==="list"&&c.$slots.list?e.renderSlot(c.$slots,"list",{item:m,index:f},void 0,!0,1):e.renderSlot(c.$slots,"default",{item:m,index:f,layout:r.value},()=>[e.createElementVNode("div",bd,e.toDisplayString(m),1)],!0,2)]))),128))],6)),t.loading?(e.openBlock(),e.createElementBlock("div",Bd,[e.renderSlot(c.$slots,"loading",{},()=>[o[5]||(o[5]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-23afce0e"]]),wd=["role"],_d={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ed={key:1,class:"mfs-empty-state"},$d=["aria-expanded","aria-selected","aria-disabled"],Vd=["onClick","onKeydown"],xd=["aria-label","onClick"],Cd={key:1,class:"tree__spacer","aria-hidden":"true"},Nd={key:3,class:"tree__icon","aria-hidden":"true"},Sd={class:"tree__content"},Md={class:"tree__label"},qt=F(e.defineComponent({name:"Tree",__name:"Tree",props:{nodes:{},expandedKeys:{default:()=>[]},selectionMode:{default:"none"},selectedKeys:{default:()=>[]},level:{default:0},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No items found"}},emits:["update:expandedKeys","update:selectedKeys","node-click","node-toggle","lazy-load"],setup(t,{emit:a}){const l=t,n=a;function i(u){return Array.isArray(u.children)&&u.children.length>0}function r(u){return i(u)||l.lazy&&!u.leaf}function s(u){return l.expandedKeys.includes(u)}function d(u){return l.selectedKeys.includes(u)}function c(u){var k;if(!r(u))return;const p=new Set(l.expandedKeys),g=!p.has(u.key);g?(p.add(u.key),l.lazy&&!((k=u.children)!=null&&k.length)&&n("lazy-load",u)):p.delete(u.key),n("update:expandedKeys",Array.from(p)),n("node-toggle",u,g)}function o(u){r(u)&&!s(u.key)&&c(u)}function m(u){r(u)&&s(u.key)&&c(u)}function f(u){if(u.disabled||l.selectionMode==="none")return;if(l.selectionMode==="single"){n("update:selectedKeys",d(u.key)?[]:[u.key]);return}const p=new Set(l.selectedKeys);p.has(u.key)?p.delete(u.key):p.add(u.key),n("update:selectedKeys",Array.from(p))}function b(u){u.disabled||(n("node-click",u),l.selectionMode!=="none"?f(u):r(u)&&c(u))}return(u,p)=>{const g=e.resolveComponent("Tree",!0);return e.openBlock(),e.createElementBlock("ul",{class:e.normalizeClass(["tree",{"tree--root mfs-surface mfs-rounded mfs-shadow-card":t.level===0}]),role:t.level===0?"tree":"group"},[t.level===0&&t.loading?(e.openBlock(),e.createElementBlock("li",_d,[e.renderSlot(u.$slots,"loading",{},()=>[p[6]||(p[6]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.level===0&&!t.loading&&t.nodes.length===0?(e.openBlock(),e.createElementBlock("li",Ed,[e.renderSlot(u.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.nodes,k=>(e.openBlock(),e.createElementBlock("li",{key:k.key,class:"tree__item",role:"treeitem","aria-expanded":r(k)?s(k.key):void 0,"aria-selected":t.selectionMode!=="none"?d(k.key):void 0,"aria-disabled":k.disabled||void 0},[e.createElementVNode("div",{class:e.normalizeClass(["tree__row mfs-rounded-sm mfs-focus-ring",{"tree__row--selected":d(k.key),"tree__row--disabled mfs-disabled":k.disabled}]),style:e.normalizeStyle({paddingLeft:`${t.level*20+8}px`}),tabindex:"0",onClick:y=>b(k),onKeydown:[e.withKeys(e.withModifiers(y=>b(k),["prevent"]),["enter"]),e.withKeys(e.withModifiers(y=>b(k),["prevent"]),["space"]),e.withKeys(e.withModifiers(y=>o(k),["prevent"]),["right"]),e.withKeys(e.withModifiers(y=>m(k),["prevent"]),["left"])]},[r(k)?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree__toggle mfs-text-muted",{"tree__toggle--expanded":s(k.key)}]),"aria-label":s(k.key)?`Collapse ${k.label}`:`Expand ${k.label}`,tabindex:"-1",onClick:e.withModifiers(y=>c(k),["stop"])},[...p[7]||(p[7]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,xd)):(e.openBlock(),e.createElementBlock("span",Cd)),t.selectionMode==="checkbox"?(e.openBlock(),e.createBlock(fe,{key:2,class:"tree__checkbox","model-value":d(k.key),disabled:k.disabled,"aria-label":`Select ${k.label}`,tabindex:-1,onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":y=>f(k)},null,8,["model-value","disabled","aria-label","onUpdate:modelValue"])):e.createCommentVNode("",!0),k.icon?(e.openBlock(),e.createElementBlock("span",Nd,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Sd,[e.renderSlot(u.$slots,"node",{node:k,expanded:s(k.key),selected:d(k.key),level:t.level},()=>[e.createElementVNode("span",Md,e.toDisplayString(k.label),1)],!0)])],46,Vd),i(k)&&s(k.key)?(e.openBlock(),e.createBlock(g,{key:0,nodes:k.children,"expanded-keys":t.expandedKeys,"selection-mode":t.selectionMode,"selected-keys":t.selectedKeys,lazy:t.lazy,level:t.level+1,"onUpdate:expandedKeys":p[1]||(p[1]=y=>u.$emit("update:expandedKeys",y)),"onUpdate:selectedKeys":p[2]||(p[2]=y=>u.$emit("update:selectedKeys",y)),onNodeClick:p[3]||(p[3]=y=>u.$emit("node-click",y)),onNodeToggle:p[4]||(p[4]=(y,h)=>u.$emit("node-toggle",y,h)),onLazyLoad:p[5]||(p[5]=y=>u.$emit("lazy-load",y))},e.createSlots({_:2},[u.$slots.node?{name:"node",fn:e.withCtx(y=>[e.renderSlot(u.$slots,"node",e.mergeProps({ref_for:!0},y),void 0,!0)]),key:"0"}:void 0]),1032,["nodes","expanded-keys","selection-mode","selected-keys","lazy","level"])):e.createCommentVNode("",!0)],8,$d))),128))],10,wd)}}}),[["__scopeId","data-v-0e17bf40"]]),Dd={class:"ac-box mfs-surface mfs-rounded mfs-shadow-inset"},Td=["aria-expanded","value","placeholder","disabled"],Ld={key:0,class:"ac-spinner","aria-hidden":"true"},zd=["aria-selected","onMousedown","onMouseenter"],Id={key:0,class:"mfs-empty-state",role:"status"},Yt=F(e.defineComponent({__name:"AutoComplete",props:{modelValue:{default:""},suggestions:{default:()=>[]},label:{},placeholder:{default:"Type to search..."},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},minLength:{default:1},remote:{type:Boolean,default:!1},emptyText:{default:"No results found"}},emits:["update:modelValue","complete","select"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-ac-${e.useId()}`,r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(!1),o=e.ref(-1),{overlayStyle:m,containsTarget:f}=de(s,d,c,{matchWidth:!0}),b=e.computed(()=>{const B=l.suggestions.map(_=>typeof _=="string"?{label:_,value:_}:_);if(l.remote)return B;const $=(l.modelValue||"").toLowerCase();return B.filter(_=>!$||_.label.toLowerCase().includes($))}),u=e.computed(()=>(l.modelValue||"").length>=l.minLength&&!l.loading&&b.value.length===0),p=B=>{const $=B.target.value;n("update:modelValue",$),$.length>=l.minLength?(n("complete",{query:$}),c.value=!0,o.value=-1):c.value=!1},g=()=>{(l.modelValue||"").length>=l.minLength&&(b.value.length||!l.loading)&&(c.value=!0)},k=B=>{n("update:modelValue",B.label),n("select",B),c.value=!1},y=B=>{if(c.value){if(B.key==="Escape")c.value=!1;else if(B.key==="ArrowDown")B.preventDefault(),b.value.length&&(o.value=(o.value+1)%b.value.length);else if(B.key==="ArrowUp")B.preventDefault(),b.value.length&&(o.value=(o.value-1+b.value.length)%b.value.length);else if(B.key==="Enter"&&o.value>=0){B.preventDefault();const $=b.value[o.value];$&&k($)}}},h=B=>{f(B.target)||(c.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",h)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",h)),(B,$)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:r,class:e.normalizeClass(["ac-wrapper",{"ac-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:i,class:"ac-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:s,class:"ac-container"},[e.createElementVNode("div",Dd,[e.createElementVNode("input",{id:i,type:"text",role:"combobox","aria-expanded":c.value,"aria-autocomplete":"list",value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,class:"ac-input mfs-text",onInput:p,onFocus:g,onKeydown:y},null,40,Td),t.loading?(e.openBlock(),e.createElementBlock("span",Ld)):e.createCommentVNode("",!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ac-pop"},{default:e.withCtx(()=>[c.value&&(b.value.length||u.value)?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:d,role:"listbox",style:e.normalizeStyle(e.unref(m)),class:"ac-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(_,D)=>(e.openBlock(),e.createElementBlock("li",{key:_.label+D,role:"option","aria-selected":D===o.value,class:e.normalizeClass(["ac-option mfs-text",{"ac-option--active":D===o.value}]),onMousedown:e.withModifiers(S=>k(_),["prevent"]),onMouseenter:S=>o.value=D},e.toDisplayString(_.label),43,zd))),128)),u.value?(e.openBlock(),e.createElementBlock("li",Id,[e.renderSlot(B.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:3})]))],512)],2))}}),[["__scopeId","data-v-e5421cb2"]]),Rd={key:0,class:"cas-label mfs-text"},Pd={class:"cas-container"},Ad=["disabled","aria-expanded"],Fd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},jd={key:0,class:"cas-col"},Kd={key:1,class:"cas-col"},Od={class:"mfs-empty-state"},Hd=["disabled","onClick"],Ud={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Wd={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Gd={key:0,class:"cas-col"},He=F(e.defineComponent({__name:"Cascader",props:{modelValue:{default:()=>[]},options:{default:()=>[]},label:{},placeholder:{default:"Select..."},separator:{default:" / "},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:6}),o=e.ref([...l.modelValue]);e.watch(()=>l.modelValue,g=>{o.value=[...g||[]]});const m=e.computed(()=>{const g=[];let k=l.options,y=0;for(;k&&k.length;){g.push(k);const h=o.value[y],B=k.find($=>$.value===h);k=B==null?void 0:B.children,y++}return g}),f=e.computed(()=>{const g=[];let k=l.options;for(const y of l.modelValue||[]){const h=k==null?void 0:k.find(B=>B.value===y);if(!h)break;g.push(h.label),k=h.children}return g.join(l.separator)}),b=(g,k)=>{var h,B;if(k.disabled)return;const y=[...o.value.slice(0,g),k.value];if(o.value=y,l.lazy&&!k.isLeaf&&!((h=k.children)!=null&&h.length)){n("lazy-load",k);return}(B=k.children)!=null&&B.length||(n("update:modelValue",y),n("change",y),s.value=!1)},u=g=>{c(g.target)||(s.value=!1)},p=g=>{g.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",u),document.addEventListener("keydown",p)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",u),document.removeEventListener("keydown",p)}),(g,k)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cas-wrapper",{"cas-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",Rd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Pd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"cas-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":s.value,onClick:k[0]||(k[0]=y=>s.value=!s.value)},[e.createElementVNode("span",{class:e.normalizeClass(["cas-value",{"mfs-text-muted":!f.value}])},e.toDisplayString(f.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",Fd)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["cas-chevron",{"cas-chevron--open":s.value}])},[...k[1]||(k[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,Ad),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cas-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"cas-panel mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading&&m.value.length===0?(e.openBlock(),e.createElementBlock("div",jd,[e.renderSlot(g.$slots,"loading",{},()=>[k[2]||(k[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):m.value.length===0?(e.openBlock(),e.createElementBlock("div",Kd,[e.createElementVNode("div",Od,[e.renderSlot(g.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(y,h)=>(e.openBlock(),e.createElementBlock("div",{key:h,class:"cas-col"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y,B=>{var $;return e.openBlock(),e.createElementBlock("button",{key:String(B.value),type:"button",class:e.normalizeClass(["cas-item mfs-text",{"cas-item--active":o.value[h]===B.value}]),disabled:B.disabled,onClick:_=>b(h,B)},[e.createElementVNode("span",null,e.toDisplayString(B.label),1),B.loading?(e.openBlock(),e.createElementBlock("span",Ud)):($=B.children)!=null&&$.length||t.lazy&&!B.isLeaf?(e.openBlock(),e.createElementBlock("svg",Wd,[...k[3]||(k[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Hd)}),128))]))),128)),t.loading?(e.openBlock(),e.createElementBlock("div",Gd,[e.renderSlot(g.$slots,"loading",{},()=>[k[4]||(k[4]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-63dca0d2"]]),qd={key:0,class:"ts-label mfs-text"},Yd={class:"ts-container"},Xd=["disabled","aria-expanded"],Zd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Jd={key:1,class:"mfs-empty-state"},Qd=["aria-selected"],vd=["aria-label","onClick"],ec={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},tc={key:1,class:"ts-expand-spacer"},lc=["disabled","onClick"],nc={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round"},Xt=F(e.defineComponent({__name:"TreeSelect",props:{modelValue:{default:null},options:{default:()=>[]},multiple:{type:Boolean,default:!1},label:{},placeholder:{default:"Select node..."},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:6,matchWidth:!0}),o=e.reactive(new Set),m=h=>{var B;o.has(h.value)?o.delete(h.value):(o.add(h.value),l.lazy&&!h.isLeaf&&!((B=h.children)!=null&&B.length)&&n("lazy-load",h))},f=e.computed(()=>{const h=[],B=($,_)=>{var D;for(const S of $)h.push({node:S,depth:_}),(D=S.children)!=null&&D.length&&o.has(S.value)&&B(S.children,_+1)};return B(l.options,0),h}),b=e.computed(()=>{const h=new Map,B=$=>{var _;for(const D of $)h.set(D.value,D.label),(_=D.children)!=null&&_.length&&B(D.children)};return B(l.options),h}),u=e.computed(()=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.map(h=>b.value.get(h)??String(h)).join(", "):l.modelValue===null||l.modelValue===void 0?"":b.value.get(l.modelValue)??String(l.modelValue)),p=h=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(h):l.modelValue===h,g=h=>{if(!h.disabled)if(l.multiple){const B=Array.isArray(l.modelValue)?l.modelValue:[],$=B.includes(h.value)?B.filter(_=>_!==h.value):[...B,h.value];n("update:modelValue",$),n("change",$)}else n("update:modelValue",h.value),n("change",h.value),s.value=!1},k=h=>{c(h.target)||(s.value=!1)},y=h=>{h.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",k),document.addEventListener("keydown",y)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",k),document.removeEventListener("keydown",y)}),(h,B)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["ts-wrapper",{"ts-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",qd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Yd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"ts-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":s.value,onClick:B[0]||(B[0]=$=>s.value=!s.value)},[e.createElementVNode("span",{class:e.normalizeClass(["ts-value",{"mfs-text-muted":!u.value}])},e.toDisplayString(u.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",Zd)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["ts-chevron",{"ts-chevron--open":s.value}])},[...B[1]||(B[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,Xd),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ts-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"ts-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow",role:"tree"},[t.loading&&f.value.length===0?e.renderSlot(h.$slots,"loading",{},()=>[B[2]||(B[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0,0):f.value.length===0?(e.openBlock(),e.createElementBlock("div",Jd,[e.renderSlot(h.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,$=>{var _;return e.openBlock(),e.createElementBlock("div",{key:String($.node.value),role:"treeitem","aria-selected":p($.node.value),class:"ts-row",style:e.normalizeStyle({paddingLeft:`${8+$.depth*18}px`})},[(_=$.node.children)!=null&&_.length||t.lazy&&!$.node.isLeaf?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"ts-expand mfs-text-muted","aria-label":o.has($.node.value)?"Collapse":"Expand",onClick:e.withModifiers(D=>m($.node),["stop"])},[$.node.loading?(e.openBlock(),e.createElementBlock("span",ec)):(e.openBlock(),e.createElementBlock("svg",{key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round",style:e.normalizeStyle({transform:o.has($.node.value)?"rotate(90deg)":""})},[...B[3]||(B[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])],4))],8,vd)):(e.openBlock(),e.createElementBlock("span",tc)),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["ts-node mfs-text",{"ts-node--selected":p($.node.value)}]),disabled:$.node.disabled,onClick:D=>g($.node)},[e.createElementVNode("span",null,e.toDisplayString($.node.label),1),p($.node.value)?(e.openBlock(),e.createElementBlock("svg",nc,[...B[4]||(B[4]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],10,lc)],12,Qd)}),128)),t.loading?e.renderSlot(h.$slots,"loading",{},void 0,!0,0):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-2741eadc"]]),oc=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],ac=["viewBox","width","height"],sc=["d","stroke-width"],rc=["d","stroke-width"],ic={class:"knob-value mfs-text mfs-font-mono"},dc={key:0,class:"knob-label mfs-caption"},Zt=F(e.defineComponent({__name:"Knob",props:{modelValue:{default:0},min:{default:0},max:{default:100},step:{default:1},size:{default:112},strokeWidth:{default:10},valueTemplate:{default:"{value}"},label:{},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(!1),s=e.computed(()=>l.size/2),d=e.computed(()=>l.size/2-l.strokeWidth-4),c=B=>{const $=(B-90)*Math.PI/180;return{x:s.value+d.value*Math.cos($),y:s.value+d.value*Math.sin($)}},o=(B,$)=>{const _=c($),D=c(B),S=$-B<=180?"0":"1";return`M ${_.x} ${_.y} A ${d.value} ${d.value} 0 ${S} 0 ${D.x} ${D.y}`},m=e.computed(()=>{const B=l.max-l.min;return B<=0?0:Math.max(0,Math.min(1,(l.modelValue-l.min)/B))}),f=e.computed(()=>o(225,495)),b=e.computed(()=>{const B=225+m.value*270;return B<=225.1?"":o(225,B)}),u=e.computed(()=>l.valueTemplate.replace("{value}",String(l.modelValue))),p=(B,$)=>{var P;const _=(P=i.value)==null?void 0:P.getBoundingClientRect();if(!_)return;const D=_.left+_.width/2,S=_.top+_.height/2;let E=Math.atan2($-S,B-D)*180/Math.PI+90;E<0&&(E+=360);let w=E>=225?E-225:E<=135?E+135:E<180?270:0;w=Math.max(0,Math.min(270,w));const N=l.min+w/270*(l.max-l.min),V=Math.round((N-l.min)/l.step)*l.step+l.min,C=Math.max(l.min,Math.min(l.max,Number(V.toFixed(6))));n("update:modelValue",C)},g=B=>{r.value&&p(B.clientX,B.clientY)},k=()=>{r.value&&(r.value=!1,n("change",l.modelValue)),window.removeEventListener("pointermove",g),window.removeEventListener("pointerup",k)},y=B=>{l.disabled||l.readonly||(B.preventDefault(),r.value=!0,p(B.clientX,B.clientY),window.addEventListener("pointermove",g),window.addEventListener("pointerup",k))},h=B=>{if(l.disabled||l.readonly)return;const $=B.key==="ArrowRight"||B.key==="ArrowUp"?l.step:B.key==="ArrowLeft"||B.key==="ArrowDown"?-l.step:0;if(!$)return;B.preventDefault();const _=Math.max(l.min,Math.min(l.max,l.modelValue+$));n("update:modelValue",_),n("change",_)};return e.onBeforeUnmount(k),(B,$)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["knob-wrapper",{"knob-wrapper--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("div",{ref_key:"svgBoxRef",ref:i,role:"slider",tabindex:"0",class:"knob-control mfs-surface mfs-shadow mfs-focus-ring",style:e.normalizeStyle({width:`${t.size}px`,height:`${t.size}px`}),"aria-valuemin":t.min,"aria-valuemax":t.max,"aria-valuenow":t.modelValue,"aria-label":t.label||"Knob",onPointerdown:y,onKeydown:h},[(e.openBlock(),e.createElementBlock("svg",{viewBox:`0 0 ${t.size} ${t.size}`,width:t.size,height:t.size},[e.createElementVNode("path",{d:f.value,fill:"none",stroke:"var(--surface-subtle, rgba(148,163,184,0.28))","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,sc),e.createElementVNode("path",{d:b.value,fill:"none",stroke:"var(--primary)","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,rc)],8,ac)),e.createElementVNode("span",ic,e.toDisplayString(u.value),1)],44,oc),t.label?(e.openBlock(),e.createElementBlock("span",dc,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4399dd45"]]),cc=["disabled","aria-pressed","onClick"],Jt=F(e.defineComponent({__name:"SelectButton",props:{modelValue:{},options:{default:()=>[]},multiple:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.computed(()=>l.options.map(d=>typeof d=="string"?{label:d,value:d}:d)),r=d=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(d):l.modelValue===d,s=d=>{if(!(l.disabled||d.disabled))if(l.multiple){const c=Array.isArray(l.modelValue)?l.modelValue:[],o=c.includes(d.value)?c.filter(m=>m!==d.value):[...c,d.value];n("update:modelValue",o),n("change",o)}else n("update:modelValue",d.value),n("change",d.value)};return(d,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["sb-group mfs-surface mfs-rounded mfs-shadow-inset",{"sb-group--disabled mfs-disabled":t.disabled}]),role:"group"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(o,m)=>(e.openBlock(),e.createElementBlock("button",{key:String(o.value)+m,type:"button",class:e.normalizeClass(["sb-btn mfs-text mfs-focus-ring",{"sb-btn--active mfs-shadow":r(o.value)}]),disabled:t.disabled||o.disabled,"aria-pressed":r(o.value),onClick:f=>s(o)},e.toDisplayString(o.label),11,cc))),128))],2))}}),[["__scopeId","data-v-04586dfe"]]),mc=["aria-pressed","disabled"],Qt=F(e.defineComponent({__name:"ToggleButton",props:{modelValue:{type:Boolean,default:!1},onLabel:{default:"On"},offLabel:{default:"Off"},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=()=>{if(l.disabled)return;const r=!l.modelValue;n("update:modelValue",r),n("change",r)};return(r,s)=>(e.openBlock(),e.createElementBlock("button",{type:"button",class:e.normalizeClass(["tb-btn mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-text mfs-focus-ring",{"tb-btn--active mfs-border-primary":t.modelValue}]),"aria-pressed":t.modelValue,disabled:t.disabled,onClick:i},[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.modelValue?t.onLabel:t.offLabel),1)],!0)],10,mc))}}),[["__scopeId","data-v-701ced8e"]]),fc=["type","inputmode","value","disabled","aria-label","onInput","onKeydown","onPaste"],vt=F(e.defineComponent({__name:"InputOtp",props:{modelValue:{default:""},length:{default:4},mask:{type:Boolean,default:!1},integerOnly:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","complete"],setup(t,{emit:a}){const l=t,n=a,i=e.ref([]),r=(f,b)=>{i.value[b]=f},s=e.computed(()=>Array.from({length:l.length},(f,b)=>l.modelValue[b]??"")),d=f=>{const b=f.join("").slice(0,l.length);n("update:modelValue",b),b.length===l.length&&!f.includes("")&&n("complete",b)},c=(f,b)=>{var k;const p=b.target.value.slice(-1);if(l.integerOnly&&p&&!/^\d$/.test(p)){b.target.value=s.value[f];return}const g=[...s.value];g[f]=p,d(g),p&&f<l.length-1&&((k=i.value[f+1])==null||k.focus())},o=(f,b)=>{var u,p,g;b.key==="Backspace"&&!s.value[f]&&f>0?(u=i.value[f-1])==null||u.focus():b.key==="ArrowLeft"&&f>0?(b.preventDefault(),(p=i.value[f-1])==null||p.focus()):b.key==="ArrowRight"&&f<l.length-1&&(b.preventDefault(),(g=i.value[f+1])==null||g.focus())},m=(f,b)=>{var y,h;b.preventDefault();const u=((y=b.clipboardData)==null?void 0:y.getData("text"))??"",p=l.integerOnly?u.replace(/\D/g,""):u;if(!p)return;const g=[...s.value];for(let B=0;B<p.length&&f+B<l.length;B++)g[f+B]=p[B];d(g);const k=Math.min(l.length-1,f+p.length);(h=i.value[k])==null||h.focus()};return(f,b)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["otp-wrapper",{"otp-wrapper--disabled mfs-disabled":t.disabled}]),role:"group","aria-label":"One-time password"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.length,u=>(e.openBlock(),e.createElementBlock("input",{key:u,ref_for:!0,ref:p=>r(p,u-1),type:t.mask?"password":"text",inputmode:t.integerOnly?"numeric":"text",maxlength:"1",value:s.value[u-1],disabled:t.disabled,"aria-label":`Digit ${u} of ${t.length}`,class:"otp-cell mfs-surface mfs-rounded mfs-shadow-inset mfs-text mfs-font-mono",onInput:p=>c(u-1,p),onKeydown:p=>o(u-1,p),onPaste:p=>m(u-1,p)},null,40,fc))),128))],2))}}),[["__scopeId","data-v-8fabd2c1"]]),uc={class:"mask-box mfs-surface mfs-rounded mfs-shadow-inset"},pc=["value","placeholder","disabled"],el=F(e.defineComponent({__name:"InputMask",props:{modelValue:{default:""},mask:{},label:{},placeholder:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-mask-${e.useId()}`,r=(c,o)=>c==="9"?/^\d$/.test(o):c==="a"?/^[a-zA-Z]$/.test(o):c==="*"?/^[a-zA-Z0-9]$/.test(o):!1,s=c=>{const o=c.split("");let m="",f=0;for(let b=0;b<l.mask.length&&f<o.length;b++){const u=l.mask[b];if(u==="9"||u==="a"||u==="*"){for(;f<o.length&&!r(u,o[f]);)f++;f<o.length&&(m+=o[f],f++)}else m+=u,o[f]===u&&f++}return m},d=c=>{const o=c.target,m=s(o.value);o.value=m,n("update:modelValue",m)};return(c,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mask-wrapper",{"mask-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:i,class:"mask-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",uc,[e.createElementVNode("input",{id:i,type:"text",value:t.modelValue,placeholder:t.placeholder||t.mask,disabled:t.disabled,class:"mask-input mfs-text mfs-font-mono",onInput:d},null,40,pc)])],2))}}),[["__scopeId","data-v-1b5c5774"]]),kc={},hc={class:"ig-wrapper mfs-surface mfs-rounded mfs-shadow-inset"};function gc(t,a){return e.openBlock(),e.createElementBlock("div",hc,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const tl=F(kc,[["render",gc],["__scopeId","data-v-3f9e9407"]]),yc={},bc={class:"ig-addon mfs-inline-flex mfs-items-center mfs-justify-center mfs-whitespace-nowrap mfs-text-muted mfs-text-sm mfs-font-semibold"};function Bc(t,a){return e.openBlock(),e.createElementBlock("span",bc,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const ll=F(yc,[["render",Bc],["__scopeId","data-v-06440459"]]),wc={key:0,class:"icon-field__icon mfs-text-muted","aria-hidden":"true"},nl=F(e.defineComponent({__name:"IconField",props:{iconPosition:{default:"left"},fluid:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["icon-field",[`icon-field--${t.iconPosition}`,{"icon-field--fluid":t.fluid}]])},[a.$slots.icon?(e.openBlock(),e.createElementBlock("span",wc,[e.renderSlot(a.$slots,"icon",{},void 0,!0)])):e.createCommentVNode("",!0),e.renderSlot(a.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-aafeb221"]]),_c={},Ec={class:"input-icon mfs-inline-flex mfs-items-center mfs-justify-center mfs-text-muted","aria-hidden":"true"};function $c(t,a){return e.openBlock(),e.createElementBlock("span",Ec,[e.renderSlot(t.$slots,"default")])}const ol=F(_c,[["render",$c]]),Vc={key:0,class:"lb-filter-box"},xc=["disabled"],Cc=["aria-multiselectable"],Nc=["aria-selected","onClick","onKeydown"],Sc={key:0,viewBox:"0 0 24 24",width:"15",height:"15",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round"},Mc={key:0,class:"lb-empty mfs-text-muted"},al=F(e.defineComponent({__name:"Listbox",props:{modelValue:{},options:{default:()=>[]},multiple:{type:Boolean,default:!1},filter:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(""),r=e.computed(()=>l.options.map(o=>typeof o=="string"?{label:o,value:o}:o)),s=e.computed(()=>{const o=i.value.trim().toLowerCase();return o?r.value.filter(m=>m.label.toLowerCase().includes(o)):r.value}),d=o=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(o):l.modelValue===o,c=o=>{if(!(l.disabled||o.disabled))if(l.multiple){const m=Array.isArray(l.modelValue)?l.modelValue:[],f=m.includes(o.value)?m.filter(b=>b!==o.value):[...m,o.value];n("update:modelValue",f),n("change",f)}else n("update:modelValue",o.value),n("change",o.value)};return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["lb-wrapper mfs-surface mfs-rounded mfs-shadow",{"lb-wrapper--disabled mfs-disabled":t.disabled}])},[t.filter?(e.openBlock(),e.createElementBlock("div",Vc,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":m[0]||(m[0]=f=>i.value=f),type:"text",class:"lb-filter mfs-inset mfs-text",placeholder:"Filter...",disabled:t.disabled},null,8,xc),[[e.vModelText,i.value]])])):e.createCommentVNode("",!0),e.createElementVNode("ul",{role:"listbox","aria-multiselectable":t.multiple,class:"lb-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(f,b)=>(e.openBlock(),e.createElementBlock("li",{key:String(f.value)+b,role:"option","aria-selected":d(f.value),class:e.normalizeClass(["lb-item mfs-text mfs-focus-ring",{"lb-item--selected":d(f.value),"lb-item--disabled":f.disabled}]),tabindex:"0",onClick:u=>c(f),onKeydown:[e.withKeys(e.withModifiers(u=>c(f),["prevent"]),["enter"]),e.withKeys(e.withModifiers(u=>c(f),["prevent"]),["space"])]},[e.createElementVNode("span",null,e.toDisplayString(f.label),1),d(f.value)?(e.openBlock(),e.createElementBlock("svg",Sc,[...m[1]||(m[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],42,Nc))),128)),s.value.length===0?(e.openBlock(),e.createElementBlock("li",Mc,"No options")):e.createCommentVNode("",!0)],8,Cc)],2))}}),[["__scopeId","data-v-57e05a19"]]),Dc=["for"],sl=F(e.defineComponent({__name:"FloatLabel",props:{label:{},forId:{},active:{type:Boolean}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["fl-wrapper",{"fl-wrapper--active":t.active}])},[e.renderSlot(a.$slots,"default",{},void 0,!0),t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"fl-label mfs-text-muted"},e.toDisplayString(t.label),9,Dc)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-62e5b422"]]),Tc={class:"ifta-wrapper mfs-surface mfs-rounded mfs-shadow-inset"},Lc=["for"],zc={class:"ifta-control"},rl=F(e.defineComponent({__name:"IftaLabel",props:{label:{},forId:{}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",Tc,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"ifta-label mfs-text-muted"},e.toDisplayString(t.label),9,Lc)):e.createCommentVNode("",!0),e.createElementVNode("div",zc,[e.renderSlot(a.$slots,"default",{},void 0,!0)])]))}}),[["__scopeId","data-v-795e4d1e"]]),Ic={key:0,class:"ed-toolbar mfs-surface-subtle",role:"toolbar","aria-label":"Formatting"},Rc=["contenteditable","data-placeholder"],il=F(e.defineComponent({__name:"Editor",props:{modelValue:{default:""},placeholder:{default:"Write something..."},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},minHeight:{default:"140px"}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=o=>{const m=nt(o);!i.value||i.value.innerHTML===m||i.value.replaceChildren(...jt(m))};e.onMounted(()=>r(l.modelValue)),e.watch(()=>l.modelValue,o=>r(o));const s=()=>{i.value&&n("update:modelValue",nt(i.value.innerHTML))},d=o=>{var f,b;if(l.disabled||l.readonly)return;o.preventDefault();const m=(f=o.clipboardData)==null?void 0:f.getData("text/html");if(m)document.execCommand("insertHTML",!1,nt(m));else{const u=((b=o.clipboardData)==null?void 0:b.getData("text/plain"))??"";document.execCommand("insertText",!1,u)}s()},c=o=>{var m;l.disabled||l.readonly||((m=i.value)==null||m.focus(),document.execCommand(o,!1),s())};return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["ed-wrapper mfs-surface mfs-rounded mfs-shadow-inset",{"ed-wrapper--disabled mfs-disabled":t.disabled}])},[t.readonly?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Ic,[e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bold","aria-label":"Bold",onMousedown:m[0]||(m[0]=e.withModifiers(f=>c("bold"),["prevent"]))},[...m[7]||(m[7]=[e.createElementVNode("strong",null,"B",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Italic","aria-label":"Italic",onMousedown:m[1]||(m[1]=e.withModifiers(f=>c("italic"),["prevent"]))},[...m[8]||(m[8]=[e.createElementVNode("em",null,"I",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Underline","aria-label":"Underline",onMousedown:m[2]||(m[2]=e.withModifiers(f=>c("underline"),["prevent"]))},[...m[9]||(m[9]=[e.createElementVNode("u",null,"U",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Strikethrough","aria-label":"Strikethrough",onMousedown:m[3]||(m[3]=e.withModifiers(f=>c("strikeThrough"),["prevent"]))},[...m[10]||(m[10]=[e.createElementVNode("s",null,"S",-1)])],32),m[11]||(m[11]=e.createElementVNode("span",{class:"ed-sep"},null,-1)),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bullet List","aria-label":"Bullet List",onMousedown:m[4]||(m[4]=e.withModifiers(f=>c("insertUnorderedList"),["prevent"]))}," • List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Numbered List","aria-label":"Numbered List",onMousedown:m[5]||(m[5]=e.withModifiers(f=>c("insertOrderedList"),["prevent"]))}," 1. List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text-muted",title:"Clear Formatting","aria-label":"Clear Formatting",onMousedown:m[6]||(m[6]=e.withModifiers(f=>c("removeFormat"),["prevent"]))}," Clear ",32)])),e.createElementVNode("div",{ref_key:"editorRef",ref:i,class:"ed-content mfs-text",contenteditable:!t.disabled&&!t.readonly,"data-placeholder":t.placeholder,style:e.normalizeStyle({minHeight:t.minHeight}),role:"textbox","aria-multiline":"true",onInput:s,onPaste:d},null,44,Rc)],2))}}),[["__scopeId","data-v-b6f2ee62"]]);/**
|
|
1
|
+
(function(L,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(L=typeof globalThis<"u"?globalThis:L||self,e(L.MfsTheme={},L.Vue))})(this,(function(L,e){"use strict";const Vn=["disabled","type"],xn={key:0,class:"btn__spinner"},Cn={key:1,class:"btn__icon btn__icon--prepend"},Nn={class:"btn__content"},Sn={key:2,class:"btn__icon btn__icon--append"},Mn=e.defineComponent({__name:"Button",props:{variant:{default:"primary"},size:{default:"md"},pill:{type:Boolean,default:!0},block:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},type:{default:"button"}},emits:["click"],setup(t,{emit:a}){const l=a,n=i=>{l("click",i)};return(i,r)=>(e.openBlock(),e.createElementBlock("button",{class:e.normalizeClass(["btn",`btn--${t.variant}`,`btn--${t.size}`,"mfs-shadow","mfs-focus-ring",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,{"mfs-pill":t.pill,"mfs-rounded":!t.pill,"btn--block":t.block,"btn--loading":t.loading,"btn--disabled mfs-disabled":t.disabled||t.loading}]),disabled:t.disabled||t.loading,type:t.type,onClick:n},[t.loading?(e.openBlock(),e.createElementBlock("span",xn)):e.createCommentVNode("",!0),i.$slots.prepend&&!t.loading?(e.openBlock(),e.createElementBlock("span",Cn,[e.renderSlot(i.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",Nn,[e.renderSlot(i.$slots,"default",{},void 0,!0)]),i.$slots.append&&!t.loading?(e.openBlock(),e.createElementBlock("span",Sn,[e.renderSlot(i.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],10,Vn))}}),F=(t,a)=>{const l=t.__vccOpts||t;for(const[n,i]of a)l[n]=i;return l},$e=F(Mn,[["__scopeId","data-v-f24a6d58"]]),Dn={},Tn={class:"mfs-btn-group mfs-inline-flex mfs-items-center",role:"group"};function Ln(t,a){return e.openBlock(),e.createElementBlock("div",Tn,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const kt=F(Dn,[["render",Ln],["__scopeId","data-v-3e6bbebb"]]),zn={key:0,class:"card__header"},In={key:0,class:"card__title mfs-title"},Rn={key:1,class:"card__subtitle mfs-caption"},Pn={class:"card__body"},An={key:1,class:"card__footer"},ht=F(e.defineComponent({__name:"Card",props:{title:{},subtitle:{},hoverable:{type:Boolean,default:!1},bordered:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["card","mfs-card",{"card--hoverable":t.hoverable,"card--bordered":t.bordered}])},[a.$slots.header||t.title?(e.openBlock(),e.createElementBlock("div",zn,[e.renderSlot(a.$slots,"header",{},()=>[e.createElementVNode("div",null,[t.title?(e.openBlock(),e.createElementBlock("h3",In,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),t.subtitle?(e.openBlock(),e.createElementBlock("p",Rn,e.toDisplayString(t.subtitle),1)):e.createCommentVNode("",!0)])],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Pn,[e.renderSlot(a.$slots,"default",{},void 0,!0)]),a.$slots.footer?(e.openBlock(),e.createElementBlock("div",An,[e.renderSlot(a.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-5c08bebb"]]),Fn={key:0,class:"input-label mfs-text"},jn={key:0,class:"input-required"},Kn={key:0,class:"input-affix mfs-text-muted input-affix--prepend"},On=["id","type","value","placeholder","disabled","readonly"],Hn={key:1,class:"input-affix mfs-text-muted input-affix--append"},Un={key:1,class:"input-msg input-msg--error mfs-text-danger"},Wn={key:2,class:"input-msg mfs-caption"},Te=F(e.defineComponent({__name:"Input",props:{modelValue:{default:""},id:{},type:{default:"text"},label:{},placeholder:{default:""},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},emits:["update:modelValue","focus","blur"],setup(t,{emit:a}){const l=a,n=i=>{const r=i.target;l("update:modelValue",r.value)};return(i,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["input-wrapper",{"input-wrapper--error":!!t.error,"input-wrapper--disabled is-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",Fn,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",jn,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["input-box mfs-surface mfs-rounded mfs-shadow-inset",{"mfs-disabled":t.disabled}])},[i.$slots.prepend?(e.openBlock(),e.createElementBlock("span",Kn,[e.renderSlot(i.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("input",{id:t.id,type:t.type,value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,class:"input-field mfs-text",onInput:n,onFocus:r[0]||(r[0]=s=>i.$emit("focus",s)),onBlur:r[1]||(r[1]=s=>i.$emit("blur",s))},null,40,On),i.$slots.append?(e.openBlock(),e.createElementBlock("span",Hn,[e.renderSlot(i.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],2),t.error?(e.openBlock(),e.createElementBlock("p",Un,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Wn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-ffe43dbd"]]),ve=F(e.defineComponent({__name:"Badge",props:{variant:{default:"primary"},size:{default:"md"}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["badge",`badge--${t.variant}`,`badge--${t.size}`,"mfs-pill",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`])},[e.renderSlot(a.$slots,"prepend",{},void 0,!0),e.renderSlot(a.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-649f6dac"]]),Gn=["checked","disabled"],qn={key:0,class:"switch__label"},ge=F(e.defineComponent({__name:"Switch",props:{modelValue:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=a,n=i=>{const r=i.target;l("update:modelValue",r.checked),l("change",r.checked)};return(i,r)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["switch mfs-text",{"switch--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{type:"checkbox",class:"switch__input",checked:t.modelValue,disabled:t.disabled,onChange:n},null,40,Gn),r[0]||(r[0]=e.createElementVNode("span",{class:"switch__track mfs-pill mfs-shadow-inset"},[e.createElementVNode("span",{class:"switch__thumb mfs-shadow"})],-1)),t.label||i.$slots.default?(e.openBlock(),e.createElementBlock("span",qn,[e.renderSlot(i.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-1fc9449a"]]),Yn={key:0,class:"modal-header mfs-flex mfs-items-center mfs-justify-between"},Xn={class:"modal-title mfs-title"},Zn={class:"modal-body"},Jn={key:1,class:"modal-footer mfs-flex mfs-items-center mfs-justify-end mfs-gap-3"},ye=F(e.defineComponent({__name:"Modal",props:{modelValue:{type:Boolean,default:!1},title:{},size:{default:"md"},closeOnBackdrop:{type:Boolean,default:!0}},emits:["update:modelValue","close"],setup(t,{emit:a}){const l=t,n=a,i=()=>{n("update:modelValue",!1),n("close")},r=()=>{l.closeOnBackdrop&&i()};let s="",d=!1;const c=o=>{if(!(typeof document>"u"))if(o){if(d)return;s=document.body.style.overflow,document.body.style.overflow="hidden",d=!0}else d&&(document.body.style.overflow=s,d=!1)};return e.onMounted(()=>{l.modelValue&&c(!0)}),e.watch(()=>l.modelValue,o=>c(o)),e.onBeforeUnmount(()=>{c(!1)}),(o,m)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"modal-fade"},{default:e.withCtx(()=>[t.modelValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:"modal-backdrop mfs-backdrop mfs-flex mfs-items-center mfs-justify-center mfs-p-4",onClick:r},[e.createElementVNode("div",{class:e.normalizeClass(["modal-dialog mfs-card mfs-overlay mfs-w-full mfs-flex mfs-flex-col mfs-overflow-hidden mfs-p-0",[`modal--${t.size}`]]),role:"dialog","aria-modal":"true",onClick:m[0]||(m[0]=e.withModifiers(()=>{},["stop"]))},[t.title||o.$slots.header?(e.openBlock(),e.createElementBlock("div",Yn,[e.renderSlot(o.$slots,"header",{},()=>[e.createElementVNode("h3",Xn,e.toDisplayString(t.title),1)],!0),e.createElementVNode("button",{class:"modal-close mfs-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text-muted mfs-focus-ring",onClick:i,"aria-label":"Close modal"}," ✕ ")])):e.createCommentVNode("",!0),e.createElementVNode("div",Zn,[e.renderSlot(o.$slots,"default",{},void 0,!0)]),o.$slots.footer?(e.openBlock(),e.createElementBlock("div",Jn,[e.renderSlot(o.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-0b390910"]]),Qn=["for"],vn={key:0,class:"mfs-text-danger"},eo=["id","value","placeholder","disabled","readonly","rows","maxlength","aria-invalid"],to={key:1,class:"textarea-footer mfs-flex mfs-items-center mfs-justify-between mfs-gap-2"},lo={key:0,class:"textarea-msg textarea-msg--error mfs-text-danger"},no={key:1,class:"textarea-msg mfs-caption"},oo={key:2,class:"textarea-spacer mfs-flex-1"},ao={key:3,class:"textarea-count mfs-caption"},gt=F(e.defineComponent({__name:"Textarea",props:{modelValue:{default:""},id:{},label:{},placeholder:{default:""},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},rows:{default:3},maxlength:{},showCount:{type:Boolean,default:!1},autoResize:{type:Boolean,default:!0}},emits:["update:modelValue","focus","blur"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.computed(()=>l.id||`mfs-textarea-${i}`),s=e.ref(null),d=e.computed(()=>(l.modelValue??"").length),c=()=>{const m=s.value;!m||!l.autoResize||(m.style.height="auto",m.style.height=`${m.scrollHeight}px`)},o=m=>{const f=m.target;n("update:modelValue",f.value),e.nextTick(c)};return e.watch(()=>l.modelValue,()=>e.nextTick(c)),e.onMounted(c),(m,f)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["textarea-wrapper mfs-flex mfs-flex-col mfs-w-full",{"textarea-wrapper--error":!!t.error,"textarea-wrapper--disabled is-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r.value,class:"textarea-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",vn,"*")):e.createCommentVNode("",!0)],8,Qn)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["textarea-box mfs-flex mfs-surface mfs-rounded mfs-shadow-inset",{"mfs-disabled":t.disabled}])},[e.createElementVNode("textarea",{ref_key:"textareaRef",ref:s,id:r.value,value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,rows:t.rows,maxlength:t.maxlength,"aria-invalid":!!t.error,class:"textarea-field mfs-flex-1 mfs-w-full mfs-border-none mfs-text",onInput:o,onFocus:f[0]||(f[0]=b=>m.$emit("focus",b)),onBlur:f[1]||(f[1]=b=>m.$emit("blur",b))},null,40,eo)],2),t.error||t.hint||t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("div",to,[t.error?(e.openBlock(),e.createElementBlock("p",lo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",no,e.toDisplayString(t.hint),1)):(e.openBlock(),e.createElementBlock("span",oo)),t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("span",ao,[e.createTextVNode(e.toDisplayString(d.value),1),t.maxlength!==void 0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(" / "+e.toDisplayString(t.maxlength),1)],64)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-d02aa1fe"]]),so=["for"],ro={key:0,class:"num-required mfs-text-danger"},io={class:"num-box mfs-surface mfs-rounded mfs-shadow-inset mfs-flex mfs-items-center mfs-gap-1-5"},co=["disabled"],mo={class:"num-input-area mfs-flex-1 mfs-flex mfs-items-center mfs-gap-1 mfs-min-w-0 mfs-px-1"},fo={key:0,class:"num-prefix mfs-text-muted mfs-font-semibold mfs-select-none"},uo=["id","value","placeholder","disabled","readonly","aria-invalid","aria-valuemin","aria-valuemax","aria-valuenow"],po=["disabled"],ko={key:1,class:"num-msg num-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},ho={key:2,class:"num-msg mfs-caption mfs-m-0"},yt=F(e.defineComponent({__name:"InputNumber",props:{modelValue:{default:null},id:{},label:{},placeholder:{default:"0"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},min:{},max:{},step:{default:1},decimals:{default:0},prefix:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.computed(()=>l.id||`mfs-num-${i}`),s=e.ref(!1),d=e.ref(""),c=k=>{let y=k;l.min!==void 0&&(y=Math.max(l.min,y)),l.max!==void 0&&(y=Math.min(l.max,y));const h=Math.pow(10,l.decimals);return Math.round(y*h)/h},o=e.computed(()=>l.min!==void 0&&l.modelValue!==null&&l.modelValue<=l.min),m=e.computed(()=>l.max!==void 0&&l.modelValue!==null&&l.modelValue>=l.max),f=e.computed(()=>s.value?d.value:l.modelValue===null||l.modelValue===void 0||Number.isNaN(l.modelValue)?"":l.decimals>0?l.modelValue.toFixed(l.decimals):String(l.modelValue)),b=()=>{s.value=!0,d.value=l.modelValue!==null&&l.modelValue!==void 0?String(l.modelValue):""},u=k=>{const y=k.target.value;if(d.value=y,y.trim()===""||y==="-"){y.trim()===""&&n("update:modelValue",null);return}const h=Number(y);Number.isNaN(h)||n("update:modelValue",h)},p=()=>{if(s.value=!1,d.value.trim()===""){n("update:modelValue",null),n("change",null);return}const k=Number(d.value);if(Number.isNaN(k)){n("update:modelValue",null),n("change",null);return}const y=c(k);n("update:modelValue",y),n("change",y)},g=k=>{if(l.disabled||l.readonly)return;const y=l.modelValue??(l.min!==void 0?l.min:0),h=c(y+k*l.step);n("update:modelValue",h),n("change",h)};return(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["num-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"num-wrapper--error":!!t.error,"num-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r.value,class:"num-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",ro,"*")):e.createCommentVNode("",!0)],8,so)):e.createCommentVNode("",!0),e.createElementVNode("div",io,[e.createElementVNode("button",{type:"button",class:"num-btn mfs-surface-subtle mfs-rounded-md mfs-shadow mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0 mfs-border-none mfs-text","aria-label":"Decrease value",disabled:t.disabled||t.readonly||o.value,onClick:y[0]||(y[0]=h=>g(-1))},[...y[4]||(y[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,co),e.createElementVNode("div",mo,[t.prefix?(e.openBlock(),e.createElementBlock("span",fo,e.toDisplayString(t.prefix),1)):e.createCommentVNode("",!0),e.createElementVNode("input",{id:r.value,type:"text",inputmode:"decimal",value:f.value,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,"aria-invalid":!!t.error,"aria-valuemin":t.min,"aria-valuemax":t.max,"aria-valuenow":t.modelValue??void 0,role:"spinbutton",class:"num-field mfs-font-mono mfs-w-full mfs-bg-transparent mfs-border-none mfs-outline-none mfs-text-center mfs-text mfs-py-2",onFocus:b,onBlur:p,onInput:u,onKeydown:[y[1]||(y[1]=e.withKeys(e.withModifiers(h=>g(1),["prevent"]),["up"])),y[2]||(y[2]=e.withKeys(e.withModifiers(h=>g(-1),["prevent"]),["down"]))]},null,40,uo)]),e.createElementVNode("button",{type:"button",class:"num-btn mfs-surface-subtle mfs-rounded-md mfs-shadow mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0 mfs-border-none mfs-text","aria-label":"Increase value",disabled:t.disabled||t.readonly||m.value,onClick:y[3]||(y[3]=h=>g(1))},[...y[5]||(y[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,po)]),t.error?(e.openBlock(),e.createElementBlock("p",ko,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",ho,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-9d3c9e18"]]),go=["for"],yo={key:0,class:"mfs-text-danger"},bo={class:"pwd-box mfs-flex mfs-items-center mfs-surface mfs-rounded mfs-shadow-inset"},Bo=["id","type","value","placeholder","disabled","readonly","aria-invalid"],wo=["aria-label","aria-pressed","disabled"],_o={key:0,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Eo={key:1,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},$o={key:1,class:"pwd-strength mfs-flex mfs-items-center mfs-gap-2","aria-live":"polite"},Vo={class:"pwd-bars mfs-flex-1"},xo={key:2,class:"pwd-msg pwd-msg--error mfs-text-danger"},Co={key:3,class:"pwd-msg mfs-caption"},bt=F(e.defineComponent({__name:"Password",props:{modelValue:{default:""},id:{},label:{},placeholder:{default:""},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},showStrength:{type:Boolean,default:!1}},emits:["update:modelValue","focus","blur"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.computed(()=>l.id||`mfs-pwd-${i}`),s=e.ref(!1),d=o=>{n("update:modelValue",o.target.value)},c=e.computed(()=>{const o=l.modelValue||"";let m=0;return o.length>=6&&m++,o.length>=10&&m++,/[a-z]/.test(o)&&/[A-Z]/.test(o)&&m++,/\d/.test(o)&&/[^A-Za-z0-9]/.test(o)&&m++,m=Math.max(1,Math.min(4,m)),{score:m,...{1:{label:"Weak",color:"var(--danger, #f43f5e)"},2:{label:"Fair",color:"var(--warning, #f59e0b)"},3:{label:"Good",color:"var(--primary)"},4:{label:"Strong",color:"var(--success, #10b981)"}}[m]}});return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["pwd-wrapper mfs-flex mfs-flex-col mfs-w-full",{"pwd-wrapper--error":!!t.error,"pwd-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r.value,class:"pwd-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",yo,"*")):e.createCommentVNode("",!0)],8,go)):e.createCommentVNode("",!0),e.createElementVNode("div",bo,[e.createElementVNode("input",{id:r.value,type:s.value?"text":"password",value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,readonly:t.readonly,"aria-invalid":!!t.error,class:"pwd-field mfs-flex-1 mfs-border-none mfs-text",onInput:d,onFocus:m[0]||(m[0]=f=>o.$emit("focus",f)),onBlur:m[1]||(m[1]=f=>o.$emit("blur",f))},null,40,Bo),e.createElementVNode("button",{type:"button",class:"pwd-toggle mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-rounded-sm mfs-text-muted","aria-label":s.value?"Hide password":"Show password","aria-pressed":s.value,disabled:t.disabled,onClick:m[2]||(m[2]=f=>s.value=!s.value)},[s.value?(e.openBlock(),e.createElementBlock("svg",_o,[...m[3]||(m[3]=[e.createElementVNode("path",{d:"M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94"},null,-1),e.createElementVNode("path",{d:"M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19"},null,-1),e.createElementVNode("line",{x1:"1",y1:"1",x2:"23",y2:"23"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Eo,[...m[4]||(m[4]=[e.createElementVNode("path",{d:"M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"},null,-1),e.createElementVNode("circle",{cx:"12",cy:"12",r:"3"},null,-1)])]))],8,wo)]),t.showStrength&&t.modelValue?(e.openBlock(),e.createElementBlock("div",$o,[e.createElementVNode("div",Vo,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(4,f=>e.createElementVNode("span",{key:f,class:e.normalizeClass(["pwd-bar mfs-pill",{"pwd-bar--active":f<=c.value.score}]),style:e.normalizeStyle({backgroundColor:f<=c.value.score?c.value.color:void 0})},null,6)),64))]),e.createElementVNode("span",{class:"pwd-strength-label mfs-text-xs mfs-font-semibold mfs-text-right",style:e.normalizeStyle({color:c.value.color})},e.toDisplayString(c.value.label),5)])):e.createCommentVNode("",!0),t.error?(e.openBlock(),e.createElementBlock("p",xo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Co,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-25a48744"]]),No=["id","checked","disabled","aria-label","tabindex"],So={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round",class:"checkbox__icon"},Mo={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round",class:"checkbox__icon"},Do={key:0,class:"checkbox__label"},fe=F(e.defineComponent({__name:"Checkbox",props:{modelValue:{type:[Boolean,Array],default:!1},value:{},indeterminate:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1},id:{},ariaLabel:{},tabindex:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue.includes(l.value):!!l.modelValue);e.watchEffect(()=>{i.value&&(i.value.indeterminate=l.indeterminate)}),e.onMounted(()=>{i.value&&(i.value.indeterminate=l.indeterminate)});const s=d=>{const c=d.target.checked;let o;Array.isArray(l.modelValue)?o=c?[...l.modelValue,l.value]:l.modelValue.filter(m=>m!==l.value):o=c,n("update:modelValue",o),n("change",o)};return(d,c)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["checkbox mfs-text",{"checkbox--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{ref_key:"inputRef",ref:i,id:t.id,type:"checkbox",class:"checkbox__input",checked:r.value,disabled:t.disabled,"aria-label":t.ariaLabel,tabindex:t.tabindex,onChange:s},null,40,No),e.createElementVNode("span",{class:e.normalizeClass(["checkbox__box mfs-surface mfs-shadow-inset",{"checkbox__box--checked":r.value||t.indeterminate}])},[t.indeterminate?(e.openBlock(),e.createElementBlock("svg",So,[...c[0]||(c[0]=[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"},null,-1)])])):r.value?(e.openBlock(),e.createElementBlock("svg",Mo,[...c[1]||(c[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),t.label||d.$slots.default?(e.openBlock(),e.createElementBlock("span",Do,[e.renderSlot(d.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-9b8c18e0"]]),To=["id","name","value","checked","disabled"],Lo={key:0,class:"radio__label"},et=F(e.defineComponent({__name:"RadioButton",props:{modelValue:{},value:{},name:{},label:{},disabled:{type:Boolean,default:!1},id:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.computed(()=>l.modelValue===l.value),r=()=>{l.disabled||(n("update:modelValue",l.value),n("change",l.value))};return(s,d)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["radio mfs-text",{"radio--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{id:t.id,type:"radio",class:"radio__input",name:t.name,value:t.value,checked:i.value,disabled:t.disabled,onChange:r},null,40,To),e.createElementVNode("span",{class:e.normalizeClass(["radio__circle mfs-surface mfs-shadow",{"radio__circle--checked":i.value}])},[...d[0]||(d[0]=[e.createElementVNode("span",{class:"radio__dot"},null,-1)])],2),t.label||s.$slots.default?(e.openBlock(),e.createElementBlock("span",Lo,[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-a1042f94"]]);function de(t,a,l,n){const i=(n==null?void 0:n.offset)??6,r=(n==null?void 0:n.matchWidth)??!1,s=(n==null?void 0:n.align)??"left",d=e.ref(0),c=e.ref(0),o=e.ref(void 0),m=()=>{var E;if(typeof window>"u"||!t.value)return;const p=t.value.getBoundingClientRect(),g=(E=a.value)==null?void 0:E.getBoundingClientRect(),k=Math.max((g==null?void 0:g.width)??0,r?p.width:0)||p.width,y=(g==null?void 0:g.height)??0;let h=p.left;s==="right"?h=p.right-k:s==="center"&&(h=p.left+(p.width-k)/2);const B=8,$=Math.max(B,window.innerWidth-k-B);h=Math.min(Math.max(B,h),$);const _=window.innerHeight-p.bottom,D=p.top;let S=p.bottom+i;y>0&&p.bottom+i+y>window.innerHeight-B&&D>_&&(S=Math.max(B,p.top-y-i)),d.value=S,c.value=h,o.value=r?p.width:void 0},f=e.computed(()=>{const p={position:"fixed",top:`${d.value}px`,left:`${c.value}px`,zIndex:10100};return r&&o.value!==void 0&&(p.minWidth=`${o.value}px`),p}),b=p=>{var g,k;return p instanceof Node?!!((g=t.value)!=null&&g.contains(p)||(k=a.value)!=null&&k.contains(p)):!1},u=()=>{l.value&&m()};return e.watch(l,p=>{p&&(m(),e.nextTick(m))}),e.watch(a,p=>{p&&l.value&&m()}),e.onMounted(()=>{typeof window>"u"||(window.addEventListener("scroll",u,!0),window.addEventListener("resize",u),l.value&&m())}),e.onBeforeUnmount(()=>{typeof window>"u"||(window.removeEventListener("scroll",u,!0),window.removeEventListener("resize",u))}),{overlayStyle:f,updatePosition:m,containsTarget:b}}const zo={key:0,class:"mfs-text-danger"},Io=["aria-expanded","aria-invalid","disabled"],Ro={class:"select-actions mfs-inline-flex mfs-items-center mfs-text-muted"},Po={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Ao={key:0,class:"select-search-box"},Fo={class:"select-options mfs-flex mfs-flex-col"},jo=["aria-selected","disabled","onClick","onMouseenter"],Ko={key:0,viewBox:"0 0 24 24",width:"15",height:"15",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round"},Oo={key:0,class:"select-empty mfs-empty-state"},Ho={key:1,class:"select-empty mfs-empty-state"},Uo={key:1,class:"select-msg select-msg--error mfs-text-danger"},Wo={key:2,class:"select-msg mfs-caption"},Le=F(e.defineComponent({__name:"Select",props:{modelValue:{},options:{default:()=>[]},label:{},placeholder:{default:"Select an option"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},clearable:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},remote:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","filter"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=`mfs-select-${i}`,s=`mfs-select-list-${i}`,d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref(null),f=e.ref(!1),b=e.ref(""),u=e.ref(-1),{overlayStyle:p,containsTarget:g}=de(c,o,f,{matchWidth:!0}),k=e.computed(()=>l.options.map(V=>typeof V=="string"?{label:V,value:V}:V)),y=e.computed(()=>{if(l.remote)return k.value;const V=b.value.trim().toLowerCase();return V?k.value.filter(C=>C.label.toLowerCase().includes(V)):k.value}),h=V=>{n("filter",{value:V.target.value})},B=e.computed(()=>k.value.find(V=>V.value===l.modelValue)),$=()=>{l.disabled||(f.value=!0,u.value=y.value.findIndex(V=>V.value===l.modelValue),l.searchable&&e.nextTick(()=>{var V;return(V=m.value)==null?void 0:V.focus()}))},_=()=>{f.value=!1,b.value=""},D=()=>{f.value?_():$()},S=V=>{V.disabled||(n("update:modelValue",V.value),n("change",V.value),_())},E=()=>{n("update:modelValue",null),n("change",null)},w=V=>{if(!f.value){(V.key==="ArrowDown"||V.key==="ArrowUp"||V.key==="Enter"||V.key===" ")&&(V.preventDefault(),$());return}const C=y.value;if(V.key==="Escape")V.preventDefault(),_();else if(V.key==="ArrowDown"){if(V.preventDefault(),!C.length)return;u.value=(u.value+1)%C.length}else if(V.key==="ArrowUp"){if(V.preventDefault(),!C.length)return;u.value=(u.value-1+C.length)%C.length}else if(V.key==="Enter"){V.preventDefault();const P=C[u.value];P&&!P.disabled&&S(P)}},N=V=>{g(V.target)||_()};return e.onMounted(()=>document.addEventListener("mousedown",N)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",N)),(V,C)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:d,class:e.normalizeClass(["select-wrapper mfs-flex mfs-flex-col mfs-w-full",{"select-wrapper--error":!!t.error,"select-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:r,class:"select-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",zo,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:c,class:"select-container"},[e.createElementVNode("button",{id:r,type:"button",class:"select-trigger mfs-w-full mfs-flex mfs-items-center mfs-justify-between mfs-gap-2 mfs-surface mfs-rounded mfs-shadow-inset",role:"combobox","aria-expanded":f.value,"aria-controls":s,"aria-invalid":!!t.error,disabled:t.disabled,onClick:D,onKeydown:w},[e.createElementVNode("span",{class:e.normalizeClass(["select-value mfs-flex-1 mfs-truncate",{"select-value--placeholder":!B.value}])},e.toDisplayString(B.value?B.value.label:t.placeholder),3),e.createElementVNode("span",Ro,[t.loading?(e.openBlock(),e.createElementBlock("span",Po)):e.createCommentVNode("",!0),t.clearable&&B.value&&!t.disabled?(e.openBlock(),e.createElementBlock("span",{key:1,role:"button",tabindex:"-1","aria-label":"Clear selection",class:"select-clear mfs-inline-flex",onClick:e.withModifiers(E,["stop"])},[...C[1]||(C[1]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"})],-1)])])):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["select-chevron",{"select-chevron--open":f.value}])},[...C[2]||(C[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))])],40,Io),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"select-pop"},{default:e.withCtx(()=>[f.value?(e.openBlock(),e.createElementBlock("div",{key:0,id:s,ref_key:"overlayRef",ref:o,role:"listbox",style:e.normalizeStyle(e.unref(p)),class:"select-dropdown mfs-flex mfs-flex-col mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.searchable?(e.openBlock(),e.createElementBlock("div",Ao,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:m,"onUpdate:modelValue":C[0]||(C[0]=P=>b.value=P),type:"text",class:"select-search mfs-w-full mfs-text-sm mfs-inset",placeholder:"Search...",onInput:h,onKeydown:w},null,544),[[e.vModelText,b.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",Fo,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(P,T)=>(e.openBlock(),e.createElementBlock("button",{key:String(P.value)+T,type:"button",role:"option","aria-selected":P.value===t.modelValue,disabled:P.disabled,class:e.normalizeClass(["select-option mfs-w-full mfs-flex mfs-items-center mfs-justify-between mfs-gap-2 mfs-border-none mfs-text",{"select-option--selected":P.value===t.modelValue,"select-option--active":T===u.value}]),onClick:I=>S(P),onMouseenter:I=>u.value=T},[e.renderSlot(V.$slots,"option",{option:P,selected:P.value===t.modelValue},()=>[e.createElementVNode("span",null,e.toDisplayString(P.label),1),P.value===t.modelValue?(e.openBlock(),e.createElementBlock("svg",Ko,[...C[3]||(C[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],!0)],42,jo))),128)),t.loading&&y.value.length===0?(e.openBlock(),e.createElementBlock("div",Oo,[...C[4]||(C[4]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):y.value.length===0?(e.openBlock(),e.createElementBlock("div",Ho,[e.renderSlot(V.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0)])],4)):e.createCommentVNode("",!0)]),_:3})]))],512),t.error?(e.openBlock(),e.createElementBlock("p",Uo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Wo,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-2857ccce"]]),Go={key:0,class:"ms-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},qo={key:0,class:"mfs-text-danger"},Yo=["aria-expanded","aria-invalid","onKeydown"],Xo={class:"ms-chips mfs-flex-1 mfs-flex mfs-flex-wrap mfs-items-center mfs-gap-1-5"},Zo={class:"ms-chip-text"},Jo=["aria-label","onClick"],Qo={key:0,class:"ms-placeholder mfs-text-muted"},vo={key:0,class:"mfs-spinner mfs-spinner--sm mfs-shrink-0","aria-hidden":"true"},ea={key:0,class:"ms-search-box"},ta={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},la={class:"ms-options mfs-flex mfs-flex-col mfs-overflow-y-auto"},na=["aria-selected","disabled","onClick"],oa={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},aa={key:0,class:"ms-empty mfs-empty-state"},sa={key:1,class:"ms-empty mfs-empty-state"},ra={key:1,class:"ms-msg ms-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},ia={key:2,class:"ms-msg mfs-caption mfs-m-0"},Bt=F(e.defineComponent({__name:"MultiSelect",props:{modelValue:{default:()=>[]},options:{default:()=>[]},label:{},placeholder:{default:"Select items"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},searchable:{type:Boolean,default:!1},selectAll:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},remote:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","filter"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(!1),o=e.ref(""),{overlayStyle:m,containsTarget:f}=de(r,s,c,{matchWidth:!0}),b=e.computed(()=>l.options.map(w=>typeof w=="string"?{label:w,value:w}:w)),u=e.computed(()=>{if(l.remote)return b.value;const w=o.value.trim().toLowerCase();return w?b.value.filter(N=>N.label.toLowerCase().includes(w)):b.value}),p=w=>{n("filter",{value:w.target.value})},g=e.computed(()=>b.value.filter(w=>!w.disabled)),k=e.computed(()=>b.value.filter(w=>l.modelValue.includes(w.value))),y=e.computed(()=>g.value.length>0&&g.value.every(w=>l.modelValue.includes(w.value))),h=w=>l.modelValue.includes(w),B=()=>{l.disabled||(c.value=!c.value,c.value&&l.searchable&&e.nextTick(()=>{var w;return(w=d.value)==null?void 0:w.focus()}))},$=()=>{c.value=!1,o.value=""},_=w=>{if(w.disabled)return;const N=h(w.value)?l.modelValue.filter(V=>V!==w.value):[...l.modelValue,w.value];n("update:modelValue",N),n("change",N)},D=w=>{const N=l.modelValue.filter(V=>V!==w);n("update:modelValue",N),n("change",N)},S=()=>{const w=y.value?[]:g.value.map(N=>N.value);n("update:modelValue",w),n("change",w)},E=w=>{f(w.target)||$()};return e.onMounted(()=>document.addEventListener("mousedown",E)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",E)),(w,N)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:i,class:e.normalizeClass(["ms-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"ms-wrapper--error":!!t.error,"ms-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",Go,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",qo,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:r,class:"ms-container mfs-relative"},[e.createElementVNode("div",{tabindex:"0",role:"combobox","aria-expanded":c.value,"aria-invalid":!!t.error,class:"ms-trigger mfs-flex mfs-items-center mfs-justify-between mfs-gap-2 mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring mfs-cursor-pointer",onClick:B,onKeydown:[e.withKeys($,["escape"]),e.withKeys(e.withModifiers(B,["prevent"]),["enter"])]},[e.createElementVNode("div",Xo,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.value,V=>(e.openBlock(),e.createElementBlock("span",{key:String(V.value),class:"ms-chip mfs-inline-flex mfs-items-center mfs-gap-1 mfs-bg-primary mfs-font-semibold mfs-pill"},[e.createElementVNode("span",Zo,e.toDisplayString(V.label),1),t.disabled?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"ms-chip-remove mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-p-0 mfs-rounded-full mfs-cursor-pointer","aria-label":`Remove ${V.label}`,onClick:e.withModifiers(C=>D(V.value),["stop"])},[...N[1]||(N[1]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"})],-1)])],8,Jo))]))),128)),k.value.length===0?(e.openBlock(),e.createElementBlock("span",Qo,e.toDisplayString(t.placeholder),1)):e.createCommentVNode("",!0)]),t.loading?(e.openBlock(),e.createElementBlock("span",vo)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["ms-chevron mfs-text-muted mfs-shrink-0",{"ms-chevron--open":c.value}])},[...N[2]||(N[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],40,Yo),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ms-pop"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:s,role:"listbox","aria-multiselectable":"true",style:e.normalizeStyle(e.unref(m)),class:"ms-dropdown mfs-flex mfs-flex-col mfs-gap-1 mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.searchable?(e.openBlock(),e.createElementBlock("div",ea,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:d,"onUpdate:modelValue":N[0]||(N[0]=V=>o.value=V),type:"text",class:"ms-search mfs-w-full mfs-text-sm mfs-inset mfs-rounded-sm mfs-outline-none",placeholder:"Search...",onInput:p,onKeydown:e.withKeys($,["escape"])},null,544),[[e.vModelText,o.value]])])):e.createCommentVNode("",!0),t.selectAll&&g.value.length>0?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"ms-option ms-option--all mfs-w-full mfs-flex mfs-items-center mfs-border-none mfs-font-semibold mfs-text mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer mfs-text-left",onClick:S},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":y.value}])},[y.value?(e.openBlock(),e.createElementBlock("svg",ta,[...N[3]||(N[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),N[4]||(N[4]=e.createElementVNode("span",null,"Select All",-1))])):e.createCommentVNode("",!0),e.createElementVNode("div",la,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(V,C)=>(e.openBlock(),e.createElementBlock("button",{key:String(V.value)+C,type:"button",role:"option","aria-selected":h(V.value),disabled:V.disabled,class:e.normalizeClass(["ms-option mfs-w-full mfs-flex mfs-items-center mfs-border-none mfs-text mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer mfs-text-left",{"ms-option--selected":h(V.value)}]),onClick:P=>_(V)},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":h(V.value)}])},[h(V.value)?(e.openBlock(),e.createElementBlock("svg",oa,[...N[5]||(N[5]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),e.createElementVNode("span",null,e.toDisplayString(V.label),1)],10,na))),128)),t.loading&&u.value.length===0?(e.openBlock(),e.createElementBlock("div",aa,[...N[6]||(N[6]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):u.value.length===0?(e.openBlock(),e.createElementBlock("div",sa,[e.renderSlot(w.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0)])],4)):e.createCommentVNode("",!0)]),_:3})]))],512),t.error?(e.openBlock(),e.createElementBlock("p",ra,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",ia,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-f75e22d9"]]),da={key:0,class:"mfs-flex mfs-justify-between mfs-items-center mfs-text-sm"},ca={class:"mfs-font-semibold mfs-text"},ma={class:"slider-readout mfs-text-primary mfs-font-semibold"},fa=["aria-valuemin","aria-valuemax","aria-valuenow"],ua={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},pa=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],ka={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},wt=F(e.defineComponent({__name:"Slider",props:{modelValue:{default:0},range:{type:Boolean,default:!1},min:{default:0},max:{default:100},step:{default:1},disabled:{type:Boolean,default:!1},label:{},showTooltip:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.computed(()=>typeof l.modelValue=="number"?l.modelValue:l.min),d=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[0]:l.min),c=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[1]:l.max),o=B=>{const $=l.max-l.min;return $<=0?0:Math.max(0,Math.min(100,(B-l.min)/$*100))},m=e.computed(()=>{if(l.range){const B=o(d.value),$=o(c.value);return{left:`${B}%`,width:`${Math.max(0,$-B)}%`}}return{left:"0%",width:`${o(s.value)}%`}}),f=B=>{const $=Math.max(l.min,Math.min(l.max,B)),_=Math.round(($-l.min)/l.step)*l.step+l.min;return Math.max(l.min,Math.min(l.max,Number(_.toFixed(6))))},b=B=>{var D;const $=(D=i.value)==null?void 0:D.getBoundingClientRect();if(!$||$.width===0)return l.min;const _=Math.max(0,Math.min(1,(B-$.left)/$.width));return f(l.min+_*(l.max-l.min))},u=(B,$)=>{if(l.range){const _=[d.value,c.value];B===0?_[0]=Math.min($,_[1]):_[1]=Math.max($,_[0]),n("update:modelValue",_)}else n("update:modelValue",$)},p=B=>{r.value!==null&&u(r.value,b(B.clientX))},g=()=>{r.value!==null&&(r.value=null,n("change",l.modelValue)),window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",g)},k=(B,$)=>{l.disabled||($.preventDefault(),r.value=B,window.addEventListener("pointermove",p),window.addEventListener("pointerup",g))},y=B=>{if(l.disabled)return;const $=b(B.clientX);let _=0;l.range&&(_=Math.abs($-d.value)<=Math.abs($-c.value)?0:1),u(_,$),k(_,B)},h=(B,$)=>{if(l.disabled)return;const _=$.key==="ArrowRight"||$.key==="ArrowUp"?l.step:$.key==="ArrowLeft"||$.key==="ArrowDown"?-l.step:0;if(!_)return;$.preventDefault();const D=l.range?B===0?d.value:c.value:s.value;u(B,f(D+_)),n("change",l.modelValue)};return e.onBeforeUnmount(g),(B,$)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["slider-wrapper mfs-flex mfs-flex-col mfs-w-full",{"mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("div",da,[e.createElementVNode("span",ca,e.toDisplayString(t.label),1),e.createElementVNode("span",ma,e.toDisplayString(t.range&&Array.isArray(t.modelValue)?`${t.modelValue[0]} – ${t.modelValue[1]}`:s.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"trackRef",ref:i,class:"slider-track mfs-relative mfs-surface mfs-pill mfs-shadow-inset mfs-cursor-pointer",onPointerdown:y},[e.createElementVNode("div",{class:"slider-fill mfs-absolute mfs-pill mfs-bg-primary",style:e.normalizeStyle(m.value)},null,4),t.range?(e.openBlock(),e.createElementBlock("div",{key:0,role:"slider",tabindex:"0",class:e.normalizeClass(["slider-thumb mfs-absolute mfs-rounded-full mfs-shadow mfs-focus-ring",{"slider-thumb--active":r.value===0}]),style:e.normalizeStyle({left:`${o(d.value)}%`}),"aria-valuemin":t.min,"aria-valuemax":c.value,"aria-valuenow":d.value,"aria-label":"Minimum value",onPointerdown:$[0]||($[0]=e.withModifiers(_=>k(0,_),["stop"])),onKeydown:$[1]||($[1]=_=>h(0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",ua,e.toDisplayString(d.value),1)):e.createCommentVNode("",!0)],46,fa)):e.createCommentVNode("",!0),e.createElementVNode("div",{role:"slider",tabindex:"0",class:e.normalizeClass(["slider-thumb mfs-absolute mfs-rounded-full mfs-shadow mfs-focus-ring",{"slider-thumb--active":r.value===(t.range?1:0)}]),style:e.normalizeStyle({left:`${o(t.range?c.value:s.value)}%`}),"aria-valuemin":t.range?d.value:t.min,"aria-valuemax":t.max,"aria-valuenow":t.range?c.value:s.value,"aria-label":t.range?"Maximum value":t.label||"Slider",onPointerdown:$[2]||($[2]=e.withModifiers(_=>k(t.range?1:0,_),["stop"])),onKeydown:$[3]||($[3]=_=>h(t.range?1:0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",ka,e.toDisplayString(t.range?c.value:s.value),1)):e.createCommentVNode("",!0)],46,pa)],544)],2))}}),[["__scopeId","data-v-5650bab9"]]),ha={key:0,class:"rating-label mfs-text"},ga=["aria-label","aria-valuemax","aria-valuenow"],ya=["disabled","aria-label","onMousemove","onClick"],ba={viewBox:"0 0 24 24",width:"24",height:"24",class:"rating-svg"},Ba=["id"],wa=["fill","stroke"],_t=F(e.defineComponent({__name:"Rating",props:{modelValue:{default:0},stars:{default:5},allowHalf:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},label:{}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-star-${e.useId()}`,r=e.ref(null),s=e.computed(()=>r.value!==null?r.value:l.modelValue),d=(u,p)=>{if(!l.allowHalf)return u;const g=p.currentTarget.getBoundingClientRect();return p.clientX-g.left<g.width/2?u-.5:u},c=(u,p)=>{l.disabled||l.readonly||(r.value=d(u,p))},o=(u,p)=>{if(l.disabled||l.readonly)return;const g=d(u,p);n("update:modelValue",g),n("change",g)},m=u=>{if(l.disabled||l.readonly)return;const p=l.allowHalf?.5:1;if(u.key==="ArrowRight"||u.key==="ArrowUp"){u.preventDefault();const g=Math.min(l.stars,l.modelValue+p);n("update:modelValue",g),n("change",g)}else if(u.key==="ArrowLeft"||u.key==="ArrowDown"){u.preventDefault();const g=Math.max(0,l.modelValue-p);n("update:modelValue",g),n("change",g)}},f=u=>{const p=s.value;return p>=u?"var(--warning, #f59e0b)":l.allowHalf&&p>=u-.5?`url(#${i}-${u})`:"transparent"},b=u=>s.value>=u-.5?"var(--warning, #f59e0b)":"var(--text-muted, #94a3b8)";return(u,p)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["rating-wrapper",{"rating-wrapper--disabled mfs-disabled":t.disabled,"rating-wrapper--readonly":t.readonly}])},[t.label?(e.openBlock(),e.createElementBlock("span",ha,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:"rating-stars mfs-surface mfs-pill mfs-shadow mfs-focus-ring",role:"slider",tabindex:"0","aria-label":t.label||"Rating","aria-valuemin":0,"aria-valuemax":t.stars,"aria-valuenow":t.modelValue,onMouseleave:p[0]||(p[0]=g=>r.value=null),onKeydown:m},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.stars,g=>(e.openBlock(),e.createElementBlock("button",{key:g,type:"button",class:"rating-star",disabled:t.disabled,"aria-label":`Rate ${g} of ${t.stars}`,onMousemove:k=>c(g,k),onClick:k=>o(g,k)},[(e.openBlock(),e.createElementBlock("svg",ba,[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`${i}-${g}`,x1:"0%",y1:"0%",x2:"100%",y2:"0%"},[...p[1]||(p[1]=[e.createElementVNode("stop",{offset:"50%","stop-color":"var(--warning, #f59e0b)"},null,-1),e.createElementVNode("stop",{offset:"50%","stop-color":"transparent"},null,-1)])],8,Ba)]),e.createElementVNode("polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2",fill:f(g),stroke:b(g),"stroke-width":"1.8","stroke-linejoin":"round"},null,8,wa)]))],40,ya))),128))],40,ga)],2))}}),[["__scopeId","data-v-3dbef716"]]),_a={key:0,class:"cp-label mfs-text mfs-text-sm mfs-font-semibold"},Ea={class:"cp-container mfs-relative"},$a=["disabled","aria-expanded"],Va={class:"cp-hex mfs-font-mono"},xa={class:"cp-native-row mfs-flex mfs-items-center mfs-gap-2"},Ca=["value"],Na=["value"],Sa={class:"cp-rgb mfs-grid mfs-grid-cols-3 mfs-gap-1-5"},Ma={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},Da=["value"],Ta={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},La=["value"],za={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},Ia=["value"],Ra={key:0,class:"cp-presets mfs-grid mfs-grid-cols-4 mfs-gap-2"},Pa=["aria-label","onClick"],Et=F(e.defineComponent({__name:"ColorPicker",props:{modelValue:{default:"#2563eb"},presets:{default:()=>["#2563eb","#38bdf8","#10b981","#f59e0b","#f43f5e","#14b8a6","#64748b","#0f172a"]},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:8}),o=e.computed(()=>/^#[0-9a-fA-F]{6}$/.test(l.modelValue)?l.modelValue:"#2563eb"),m=e.computed(()=>{const y=o.value.slice(1);return{r:parseInt(y.slice(0,2),16),g:parseInt(y.slice(2,4),16),b:parseInt(y.slice(4,6),16)}}),f=y=>{n("update:modelValue",y),n("change",y)},b=y=>{const h=y.startsWith("#")?y:`#${y}`;/^#[0-9a-fA-F]{6}$/.test(h)&&f(h.toLowerCase())},u=y=>Math.max(0,Math.min(255,y)).toString(16).padStart(2,"0"),p=(y,h)=>{const B=Number(h.target.value);if(Number.isNaN(B))return;const $={...m.value,[y]:B};f(`#${u($.r)}${u($.g)}${u($.b)}`)},g=y=>{s.value&&!c(y.target)&&(s.value=!1)},k=y=>{y.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",g),document.addEventListener("keydown",k)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",g),document.removeEventListener("keydown",k)}),(y,h)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cp-wrapper mfs-inline-flex mfs-flex-col mfs-gap-1-5",{"cp-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",_a,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Ea,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"cp-trigger mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-inline-flex mfs-items-center mfs-gap-2-5 mfs-font-semibold",disabled:t.disabled,"aria-expanded":s.value,"aria-label":"Pick a color",onClick:h[0]||(h[0]=B=>s.value=!s.value)},[e.createElementVNode("span",{class:"cp-swatch mfs-rounded-full",style:e.normalizeStyle({backgroundColor:t.modelValue})},null,4),e.createElementVNode("span",Va,e.toDisplayString(t.modelValue.toUpperCase()),1)],8,$a),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cp-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"cp-popover mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow mfs-p-3 mfs-flex mfs-flex-col mfs-gap-2-5",role:"dialog","aria-label":"Color picker"},[e.createElementVNode("div",xa,[e.createElementVNode("input",{type:"color",class:"cp-native mfs-p-0 mfs-border-none mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer",value:o.value,"aria-label":"Color palette",onInput:h[1]||(h[1]=B=>b(B.target.value))},null,40,Ca),e.createElementVNode("input",{type:"text",class:"cp-input mfs-inset mfs-font-mono mfs-flex-1 mfs-min-w-0 mfs-rounded-sm mfs-text-sm",value:t.modelValue,maxlength:"7","aria-label":"Hex color",onChange:h[2]||(h[2]=B=>b(B.target.value))},null,40,Na)]),e.createElementVNode("div",Sa,[e.createElementVNode("label",Ma,[h[6]||(h[6]=e.createElementVNode("span",null,"R",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:m.value.r,onInput:h[3]||(h[3]=B=>p("r",B))},null,40,Da)]),e.createElementVNode("label",Ta,[h[7]||(h[7]=e.createElementVNode("span",null,"G",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:m.value.g,onInput:h[4]||(h[4]=B=>p("g",B))},null,40,La)]),e.createElementVNode("label",za,[h[8]||(h[8]=e.createElementVNode("span",null,"B",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:m.value.b,onInput:h[5]||(h[5]=B=>p("b",B))},null,40,Ia)])]),t.presets.length?(e.openBlock(),e.createElementBlock("div",Ra,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.presets,B=>(e.openBlock(),e.createElementBlock("button",{key:B,type:"button",class:e.normalizeClass(["cp-preset mfs-rounded-sm mfs-cursor-pointer",{"cp-preset--active":B.toLowerCase()===o.value.toLowerCase()}]),style:e.normalizeStyle({backgroundColor:B}),"aria-label":`Select color ${B}`,onClick:$=>f(B)},null,14,Pa))),128))])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:1})]))])],2))}}),[["__scopeId","data-v-cb27bbc8"]]),Aa={key:0,class:"dp-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},Fa={key:0,class:"dp-required mfs-text-danger"},ja={class:"dp-container mfs-relative"},Ka=["disabled","aria-expanded","aria-invalid"],Oa={class:"dp-header mfs-flex mfs-items-center mfs-justify-between"},Ha={class:"dp-month-year mfs-font-bold mfs-text"},Ua={class:"dp-weekdays"},Wa=["disabled","onClick"],Ga={key:1,class:"dp-msg dp-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},qa={key:2,class:"dp-msg mfs-caption mfs-m-0"},ze=F(e.defineComponent({__name:"DatePicker",props:{modelValue:{default:null},range:{type:Boolean,default:!1},min:{},max:{},label:{},placeholder:{default:"Select date"},hint:{},error:{},required:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:8}),o=new Date,m=A=>{if(!A)return null;const K=A instanceof Date?new Date(A.getTime()):new Date(A);return Number.isNaN(K.getTime())?null:new Date(K.getFullYear(),K.getMonth(),K.getDate())},f=e.computed(()=>Array.isArray(l.modelValue)?m(l.modelValue[0])||o:m(l.modelValue)||o),b=e.ref(f.value.getFullYear()),u=e.ref(f.value.getMonth()),p=e.ref(null),g=["Su","Mo","Tu","We","Th","Fr","Sa"],k=["January","February","March","April","May","June","July","August","September","October","November","December"],y=e.computed(()=>k[u.value]),h=A=>{const K=new Date(b.value,u.value+A,1);b.value=K.getFullYear(),u.value=K.getMonth()},B=e.computed(()=>{const K=new Date(b.value,u.value,1).getDay(),W=[];for(let v=0;v<42;v++){const te=new Date(b.value,u.value,1-K+v);W.push({key:`${te.getFullYear()}-${te.getMonth()}-${te.getDate()}`,date:te,inMonth:te.getMonth()===u.value})}return W}),$=(A,K)=>!!(A&&K&&A.getFullYear()===K.getFullYear()&&A.getMonth()===K.getMonth()&&A.getDate()===K.getDate()),_=e.computed(()=>m(l.min)),D=e.computed(()=>m(l.max)),S=A=>!!(_.value&&A<_.value||D.value&&A>D.value),E=e.computed(()=>!l.range&&!Array.isArray(l.modelValue)?m(l.modelValue):null),w=e.computed(()=>l.range?p.value?[p.value,null]:Array.isArray(l.modelValue)?[m(l.modelValue[0]),m(l.modelValue[1])]:[null,null]:[null,null]),N=A=>{if(!l.range)return $(A,E.value);const[K,W]=w.value;return $(A,K)||$(A,W)},V=A=>{if(!l.range)return!1;const[K,W]=w.value;return!!(K&&W&&A>K&&A<W)},C=A=>A?`${A.getFullYear()}-${String(A.getMonth()+1).padStart(2,"0")}-${String(A.getDate()).padStart(2,"0")}`:"",P=e.computed(()=>{if(!l.range)return C(E.value);if(Array.isArray(l.modelValue)){const A=C(m(l.modelValue[0])),K=C(m(l.modelValue[1]));return A&&K?`${A} – ${K}`:A}return""}),T=A=>{if(!S(A)){if(!l.range){n("update:modelValue",A),n("change",A),s.value=!1;return}if(!p.value)p.value=A;else{const K=A<p.value?[A,p.value]:[p.value,A];p.value=null,n("update:modelValue",K),n("change",K),s.value=!1}}},I=A=>{c(A.target)||(s.value=!1)},j=A=>{A.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",I),document.addEventListener("keydown",j)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",I),document.removeEventListener("keydown",j)}),(A,K)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["dp-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"dp-wrapper--error":!!t.error,"dp-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",Aa,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",Fa,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",ja,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"dp-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-w-full mfs-flex mfs-items-center mfs-gap-2-5 mfs-text-left mfs-cursor-pointer",disabled:t.disabled,"aria-expanded":s.value,"aria-invalid":!!t.error,onClick:K[0]||(K[0]=W=>s.value=!s.value)},[K[3]||(K[3]=e.createStaticVNode('<svg viewBox="0 0 24 24" width="17" height="17" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="dp-icon mfs-text-muted mfs-shrink-0" data-v-1cc3183e><rect x="3" y="4" width="18" height="18" rx="2" ry="2" data-v-1cc3183e></rect><line x1="16" y1="2" x2="16" y2="6" data-v-1cc3183e></line><line x1="8" y1="2" x2="8" y2="6" data-v-1cc3183e></line><line x1="3" y1="10" x2="21" y2="10" data-v-1cc3183e></line></svg>',1)),e.createElementVNode("span",{class:e.normalizeClass(["dp-value",{"dp-value--placeholder mfs-text-muted":!P.value}])},e.toDisplayString(P.value||t.placeholder),3)],8,Ka),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"dp-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"dp-popover mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow mfs-p-3 mfs-flex mfs-flex-col mfs-gap-2",role:"dialog","aria-label":"Calendar"},[e.createElementVNode("div",Oa,[e.createElementVNode("button",{type:"button",class:"dp-nav mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text","aria-label":"Previous month",onClick:K[1]||(K[1]=W=>h(-1))},[...K[4]||(K[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("polyline",{points:"15 18 9 12 15 6"})],-1)])]),e.createElementVNode("span",Ha,e.toDisplayString(y.value)+" "+e.toDisplayString(b.value),1),e.createElementVNode("button",{type:"button",class:"dp-nav mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text","aria-label":"Next month",onClick:K[2]||(K[2]=W=>h(1))},[...K[5]||(K[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"})],-1)])])]),e.createElementVNode("div",Ua,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(g,W=>e.createElementVNode("span",{key:W,class:"dp-weekday mfs-text-center mfs-text-xs mfs-font-semibold mfs-text-muted mfs-py-1"},e.toDisplayString(W),1)),64))]),e.createVNode(e.Transition,{name:"dp-fade",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("div",{key:`${b.value}-${u.value}`,class:"dp-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,W=>(e.openBlock(),e.createElementBlock("button",{key:W.key,type:"button",class:e.normalizeClass(["dp-day mfs-border-none mfs-bg-transparent mfs-text mfs-font-medium mfs-cursor-pointer",{"dp-day--muted":!W.inMonth,"dp-day--selected":N(W.date),"dp-day--in-range":V(W.date),"dp-day--today":$(W.date,e.unref(o))}]),disabled:S(W.date),onClick:v=>T(W.date)},e.toDisplayString(W.date.getDate()),11,Wa))),128))]))]),_:1})],4)):e.createCommentVNode("",!0)]),_:1})]))]),t.error?(e.openBlock(),e.createElementBlock("p",Ga,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",qa,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-1cc3183e"]]),Ya=["role","aria-label"],Xa=["src","alt"],Za={key:1,class:"avatar__fallback"},Ja=["aria-label"],Ie=F(e.defineComponent({__name:"Avatar",props:{src:{},alt:{},label:{},size:{default:"md"},shape:{default:"circle"},status:{}},setup(t){const a=t,l=e.ref(!1);e.watch(()=>a.src,()=>{l.value=!1});const n=e.computed(()=>a.src&&!l.value?a.src:""),i=()=>{l.value=!0},r=e.computed(()=>{const s=(a.label||a.alt||"").trim();if(!s)return"?";const d=s.split(/\s+/).filter(Boolean);return d.length===1?d[0].slice(0,2).toUpperCase():(d[0][0]+d[d.length-1][0]).toUpperCase()});return(s,d)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["avatar","mfs-surface-subtle","mfs-shadow",t.shape==="circle"?"mfs-pill":"mfs-rounded",`avatar--${t.size}`,`avatar--${t.shape}`]),role:n.value?void 0:"img","aria-label":t.alt||t.label||"Avatar"},[n.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:n.value,alt:t.alt||t.label||"Avatar",class:"avatar__img",onError:i},null,40,Xa)):(e.openBlock(),e.createElementBlock("span",Za,[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(r.value),1)],!0)])),t.status?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(["avatar__status",t.status==="online"?"mfs-bg-success":t.status==="busy"?"mfs-bg-danger":t.status==="away"?"mfs-bg-warning":"",`avatar__status--${t.status}`]),"aria-label":`Status: ${t.status}`},null,10,Ja)):e.createCommentVNode("",!0)],10,Ya))}}),[["__scopeId","data-v-05a4906f"]]),Qa=["role","tabindex","aria-pressed","onKeydown"],va={key:0,class:"chip__prepend"},es={class:"chip__label"},Ve=F(e.defineComponent({__name:"Chip",props:{label:{},removable:{type:Boolean,default:!1},clickable:{type:Boolean,default:!1},active:{type:Boolean,default:!1},variant:{default:"surface"}},emits:["click","remove"],setup(t,{emit:a}){const l=t,n=a,i=r=>{l.clickable&&n("click",r)};return(r,s)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["chip","mfs-pill",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,`chip--${t.variant}`,{"chip--clickable mfs-interactive mfs-focus-ring":t.clickable,"chip--active":t.active}]),role:t.clickable?"button":void 0,tabindex:t.clickable?0:void 0,"aria-pressed":t.clickable?t.active:void 0,onClick:i,onKeydown:[e.withKeys(i,["enter"]),e.withKeys(e.withModifiers(i,["prevent"]),["space"])]},[r.$slots.prepend?(e.openBlock(),e.createElementBlock("span",va,[e.renderSlot(r.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",es,[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)]),t.removable?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"chip__remove","aria-label":"Remove",onClick:s[0]||(s[0]=e.withModifiers(d=>n("remove"),["stop"]))},[...s[1]||(s[1]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",width:"12",height:"12",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 4l8 8M12 4l-8 8",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"})],-1)])])):e.createCommentVNode("",!0)],42,Qa))}}),[["__scopeId","data-v-0a260f42"]]),ts=["aria-orientation"],ls={key:0,class:"divider__label mfs-caption"},$t=F(e.defineComponent({__name:"Divider",props:{orientation:{default:"horizontal"},align:{default:"center"},dashed:{type:Boolean,default:!1}},setup(t){const a=e.useSlots(),l=e.computed(()=>!!a.default);return(n,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["divider","mfs-text-muted",`divider--${t.orientation}`,`divider--align-${t.align}`,{"divider--dashed":t.dashed,"divider--with-text":l.value}]),role:"separator","aria-orientation":t.orientation},[l.value&&t.orientation==="horizontal"?(e.openBlock(),e.createElementBlock("span",ls,[e.renderSlot(n.$slots,"default",{},void 0,!0)])):e.createCommentVNode("",!0)],10,ts))}}),[["__scopeId","data-v-2cc4685f"]]),ns={class:"accordion mfs-flex mfs-flex-col mfs-gap-3 mfs-w-full"},os=["aria-expanded","aria-controls","disabled","onClick"],as={class:"accordion__title mfs-title"},ss=["id"],rs={class:"accordion__body mfs-overflow-hidden"},is={key:0,class:"accordion__text mfs-text-muted"},Vt=F(e.defineComponent({__name:"Accordion",props:{items:{default:()=>[]},multiple:{type:Boolean,default:!1},modelValue:{default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=o=>o==null?[]:Array.isArray(o)?o:[o],r=e.ref(i(l.modelValue));e.watch(()=>l.modelValue,o=>{o!==void 0&&(r.value=i(o))});const s=e.computed(()=>l.modelValue!==void 0?i(l.modelValue):r.value),d=o=>s.value.includes(o),c=o=>{const m=d(o);let f;l.multiple?f=m?s.value.filter(u=>u!==o):[...s.value,o]:f=m?[]:[o],r.value=f;const b=l.multiple?f:f[0]??null;n("update:modelValue",b),n("change",b)};return(o,m)=>(e.openBlock(),e.createElementBlock("div",ns,[t.items.length?e.createCommentVNode("",!0):e.renderSlot(o.$slots,"default",{},void 0,!0,0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,f=>(e.openBlock(),e.createElementBlock("div",{key:f.key,class:e.normalizeClass(["accordion__item","mfs-surface","mfs-rounded","mfs-shadow","mfs-overflow-hidden",{"is-open":d(f.key),"is-disabled mfs-disabled":f.disabled}])},[e.createElementVNode("button",{type:"button",class:"accordion__trigger mfs-w-full mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-none mfs-font-semibold mfs-focus-ring","aria-expanded":d(f.key),"aria-controls":`acc-panel-${f.key}`,disabled:f.disabled,onClick:b=>c(f.key)},[e.createElementVNode("span",as,e.toDisplayString(f.title),1),m[0]||(m[0]=e.createElementVNode("svg",{class:"accordion__chevron mfs-text-muted",viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1))],8,os),e.createElementVNode("div",{id:`acc-panel-${f.key}`,class:"accordion__panel",role:"region"},[e.createElementVNode("div",rs,[e.renderSlot(o.$slots,"item",{item:f,open:d(f.key)},()=>[f.content?(e.openBlock(),e.createElementBlock("p",is,e.toDisplayString(f.content),1)):e.createCommentVNode("",!0)],!0)])],8,ss)],2))),128))]))}}),[["__scopeId","data-v-ea3d94ac"]]),ds=["aria-busy"],cs={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ms={key:1,class:"mfs-empty-state"},fs={class:"timeline__rail mfs-flex mfs-flex-col mfs-items-center mfs-shrink-0","aria-hidden":"true"},us={key:0,class:"timeline__icon-text"},ps={key:0,class:"timeline__line mfs-flex-1 mfs-my-1"},ks={class:"timeline__content mfs-surface mfs-rounded mfs-shadow-card mfs-flex-1 mfs-mb-4"},hs={class:"timeline__header mfs-flex mfs-justify-between mfs-gap-2-5 mfs-flex-wrap"},gs={class:"timeline__title mfs-title mfs-m-0 mfs-font-bold"},ys={key:0,class:"timeline__time mfs-caption"},bs={key:0,class:"timeline__desc mfs-text-muted mfs-m-0"},xt=F(e.defineComponent({__name:"Timeline",props:{items:{default:()=>[]},layout:{default:"vertical"},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["timeline-container mfs-relative",{"timeline-container--loading-empty":t.loading&&t.items.length===0}]),"aria-busy":t.loading||void 0},[t.loading?(e.openBlock(),e.createElementBlock("div",cs,[e.renderSlot(a.$slots,"loading",{},()=>[l[0]||(l[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.items.length===0?(e.openBlock(),e.createElementBlock("div",ms,[e.renderSlot(a.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):t.items.length>0?(e.openBlock(),e.createElementBlock("ol",{key:2,class:e.normalizeClass(["timeline mfs-m-0 mfs-p-0 mfs-flex mfs-flex-col",`timeline--${t.layout}`])},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,i)=>(e.openBlock(),e.createElementBlock("li",{key:i,class:"timeline__item mfs-flex mfs-gap-4"},[e.createElementVNode("div",fs,[e.createElementVNode("span",{class:e.normalizeClass(["timeline__dot","mfs-shadow","mfs-rounded-full","mfs-flex","mfs-items-center","mfs-justify-center",n.status==="surface"?"mfs-surface-subtle":`mfs-bg-${n.status||"primary"}`,`timeline__dot--${n.status||"primary"}`])},[e.renderSlot(a.$slots,"icon",{item:n,index:i},()=>[n.icon?(e.openBlock(),e.createElementBlock("span",us,e.toDisplayString(n.icon),1)):e.createCommentVNode("",!0)],!0)],2),i<t.items.length-1?(e.openBlock(),e.createElementBlock("span",ps)):e.createCommentVNode("",!0)]),e.createElementVNode("div",ks,[e.renderSlot(a.$slots,"item",{item:n,index:i},()=>[e.createElementVNode("div",hs,[e.createElementVNode("h4",gs,e.toDisplayString(n.title),1),n.timestamp?(e.openBlock(),e.createElementBlock("time",ys,e.toDisplayString(n.timestamp),1)):e.createCommentVNode("",!0)]),n.description?(e.openBlock(),e.createElementBlock("p",bs,e.toDisplayString(n.description),1)):e.createCommentVNode("",!0)],!0)])]))),128))],2)):e.createCommentVNode("",!0)],10,ds))}}),[["__scopeId","data-v-e4d2eafc"]]),Bs=["aria-busy"],ws={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},_s={key:1,class:"mfs-empty-state"},Es={key:2,class:"carousel__stage"},$s=["aria-hidden"],Vs={class:"carousel__fallback mfs-text"},xs=["disabled"],Cs=["disabled"],Ns={key:3,class:"carousel__indicators mfs-flex mfs-justify-center mfs-py-3"},Ss={class:"carousel__dots mfs-surface-subtle mfs-pill mfs-blur",role:"tablist","aria-label":"Slide indicators"},Ms=["aria-selected","aria-label","onClick"],Ct=F(e.defineComponent({__name:"Carousel",props:{items:{default:()=>[]},modelValue:{default:0},autoplay:{type:Boolean,default:!1},interval:{default:4e3},loop:{type:Boolean,default:!0},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.modelValue),r=e.ref(!1);let s=null,d=null;e.watch(()=>l.modelValue,k=>{k>=0&&k<l.items.length&&(i.value=k)});const c=k=>{const y=l.items.length;if(!y)return;let h=k;l.loop?h=(k+y)%y:h=Math.max(0,Math.min(y-1,k)),i.value=h,n("update:modelValue",h),n("change",h)},o=()=>c(i.value+1),m=()=>c(i.value-1),f=k=>{s=k.clientX},b=k=>{if(s===null)return;const y=k.clientX-s;s=null,Math.abs(y)>40&&(y<0?o():m())},u=()=>{s=null},p=()=>{d&&(clearInterval(d),d=null)},g=()=>{p(),l.autoplay&&l.items.length>1&&(d=setInterval(()=>{r.value||o()},l.interval))};return e.watch(()=>[l.autoplay,l.interval,l.items.length],g),e.onMounted(g),e.onBeforeUnmount(p),(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["carousel mfs-surface mfs-rounded mfs-shadow-card",{"carousel--loading-empty":t.loading&&t.items.length===0}]),role:"region","aria-roledescription":"carousel","aria-busy":t.loading||void 0,onMouseenter:y[0]||(y[0]=h=>r.value=!0),onMouseleave:y[1]||(y[1]=h=>r.value=!1),onFocusin:y[2]||(y[2]=h=>r.value=!0),onFocusout:y[3]||(y[3]=h=>r.value=!1)},[t.loading?(e.openBlock(),e.createElementBlock("div",ws,[e.renderSlot(k.$slots,"loading",{},()=>[y[4]||(y[4]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.items.length===0?(e.openBlock(),e.createElementBlock("div",_s,[e.renderSlot(k.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",Es,[e.createElementVNode("div",{class:"carousel__viewport",onPointerdown:f,onPointerup:b,onPointercancel:u},[e.createElementVNode("div",{class:"carousel__track",style:e.normalizeStyle({transform:`translateX(-${i.value*100}%)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"carousel__slide","aria-hidden":B!==i.value},[e.renderSlot(k.$slots,"default",{item:h,index:B},()=>[e.createElementVNode("div",Vs,e.toDisplayString(h),1)],!0)],8,$s))),128))],4)],32),t.items.length>1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("button",{type:"button",class:"carousel__btn carousel__btn--prev mfs-surface mfs-shadow mfs-pill mfs-focus-ring","aria-label":"Previous slide",disabled:!t.loop&&i.value===0,onClick:m},[...y[5]||(y[5]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M12.5 5L7.5 10L12.5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,xs),e.createElementVNode("button",{type:"button",class:"carousel__btn carousel__btn--next mfs-surface mfs-shadow mfs-pill mfs-focus-ring","aria-label":"Next slide",disabled:!t.loop&&i.value===t.items.length-1,onClick:o},[...y[6]||(y[6]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M7.5 5L12.5 10L7.5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Cs)],64)):e.createCommentVNode("",!0)])),t.items.length>1?(e.openBlock(),e.createElementBlock("div",Ns,[e.createElementVNode("div",Ss,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>(e.openBlock(),e.createElementBlock("button",{key:B,type:"button",role:"tab","aria-selected":B===i.value,"aria-label":`Go to slide ${B+1}`,class:e.normalizeClass(["carousel__dot","mfs-focus-ring",{"is-active":B===i.value}]),onClick:$=>c(B)},null,10,Ms))),128))])])):e.createCommentVNode("",!0)],42,Bs))}}),[["__scopeId","data-v-11e6f9bd"]]),Ds={key:0,class:"mfs-image__placeholder","aria-hidden":"true"},Ts=["aria-label"],Ls=["src","alt"],zs=["aria-label"],Is=["src","alt"],Nt=F(e.defineComponent({__name:"Image",props:{src:{},alt:{default:""},width:{},height:{},preview:{type:Boolean,default:!1},fit:{default:"cover"}},setup(t){const a=t,l=e.ref(!1),n=e.ref(!1),i=e.ref(!1),r=b=>b===void 0?void 0:typeof b=="number"?`${b}px`:b,s=e.computed(()=>({width:r(a.width),height:r(a.height)}));e.watch(()=>a.src,()=>{l.value=!1,n.value=!1});const d=()=>{l.value=!0,n.value=!1},c=()=>{l.value=!1,n.value=!0},o=b=>{b.key==="Escape"&&f()},m=()=>{a.preview&&l.value&&!n.value&&(i.value=!0,window.addEventListener("keydown",o))},f=()=>{i.value=!1,window.removeEventListener("keydown",o)};return e.onBeforeUnmount(()=>{window.removeEventListener("keydown",o)}),(b,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-image","mfs-surface-subtle","mfs-rounded","mfs-shadow-card",{"mfs-image--preview":t.preview&&l.value&&!n.value}]),style:e.normalizeStyle(s.value),onClick:m},[!l.value&&!n.value?(e.openBlock(),e.createElementBlock("div",Ds)):e.createCommentVNode("",!0),n.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"mfs-image__error mfs-text-muted",role:"img","aria-label":t.alt||"Image failed to load"},[...u[1]||(u[1]=[e.createStaticVNode('<svg viewBox="0 0 24 24" width="28" height="28" fill="none" aria-hidden="true" data-v-66fca7b1><rect x="3" y="4" width="18" height="16" rx="3" stroke="currentColor" stroke-width="1.8" data-v-66fca7b1></rect><path d="M4 16l4.5-4.5a1.5 1.5 0 012.1 0L15 16m-2-2l1.8-1.8a1.5 1.5 0 012.1 0L20 15" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" data-v-66fca7b1></path><circle cx="9" cy="9" r="1.3" fill="currentColor" data-v-66fca7b1></circle></svg><span class="mfs-image__error-text" data-v-66fca7b1>Failed to load</span>',2)])],8,Ts)):e.createCommentVNode("",!0),e.withDirectives(e.createElementVNode("img",{src:t.src,alt:t.alt,style:e.normalizeStyle({objectFit:t.fit}),class:e.normalizeClass(["mfs-image__img",{"is-loaded":l.value}]),onLoad:d,onError:c},null,46,Ls),[[e.vShow,!n.value]]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"img-fade"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-image__modal mfs-blur",role:"dialog","aria-modal":"true","aria-label":t.alt||"Image preview",onClick:f},[e.createElementVNode("button",{type:"button",class:"mfs-image__close","aria-label":"Close preview",onClick:e.withModifiers(f,["stop"])},[...u[2]||(u[2]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"20",height:"20",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 5l10 10M15 5L5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"})],-1)])]),e.createElementVNode("img",{src:t.src,alt:t.alt,class:"mfs-image__modal-img",onClick:u[0]||(u[0]=e.withModifiers(()=>{},["stop"]))},null,8,Is)],8,zs)):e.createCommentVNode("",!0)]),_:1})]))],6))}}),[["__scopeId","data-v-66fca7b1"]]),ue=e.ref([]),pe=new Map;let Rs=0;function tt(t){const a=pe.get(t);a!=null&&a.timerId&&(clearTimeout(a.timerId),a.timerId=null)}function Ps(t,a){if(a<=0)return;tt(t);const l=setTimeout(()=>{lt(t)},a);pe.set(t,{timerId:l,remaining:a,startedAt:Date.now()})}function lt(t){tt(t),pe.delete(t),ue.value=ue.value.filter(a=>a.id!==t)}function As(t){const a=pe.get(t);!a||!a.timerId||(clearTimeout(a.timerId),a.timerId=null,a.remaining=Math.max(0,a.remaining-(Date.now()-a.startedAt)))}function Fs(t){const a=pe.get(t);!a||a.timerId||a.remaining<=0||(a.startedAt=Date.now(),a.timerId=setTimeout(()=>{lt(t)},a.remaining))}function St(t){const a=t.id??`mfs-toast-${++Rs}`,l=t.duration??4e3,n={id:a,title:t.title,message:t.message,severity:t.severity??"info",duration:l,closable:t.closable??!0},i=ue.value.findIndex(r=>r.id===a);return i!==-1?ue.value.splice(i,1,n):ue.value.push(n),l>0&&Ps(a,l),a}function js(){for(const t of pe.keys())tt(t);pe.clear(),ue.value=[]}function Mt(){return{toasts:e.readonly(ue),add:St,show:St,remove:lt,clear:js,pause:As,resume:Fs}}const Ks=["role","onMouseenter","onMouseleave","onFocusin","onFocusout"],Os={class:"mfs-toast__icon mfs-shrink-0","aria-hidden":"true"},Hs={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Us={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ws={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Gs={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},qs={class:"mfs-toast__body mfs-flex-1 mfs-min-w-0"},Ys={key:0,class:"mfs-toast__title mfs-title mfs-font-bold"},Xs={class:"mfs-toast__message mfs-text-muted mfs-text-sm"},Zs=["onClick"],Dt=F(e.defineComponent({__name:"Toast",props:{position:{default:"top-right"},max:{}},setup(t){const a=t,{toasts:l,remove:n,pause:i,resume:r}=Mt(),s=e.computed(()=>a.max&&a.max>0?l.value.slice(-a.max):l.value);return(d,c)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createElementVNode("div",{class:e.normalizeClass(["mfs-toast-container mfs-fixed mfs-p-4",[`mfs-toast-container--${t.position}`]]),role:"region","aria-label":"Notifications"},[e.createVNode(e.TransitionGroup,{name:"mfs-toast",tag:"div",class:"mfs-toast-list mfs-flex mfs-flex-col mfs-gap-3"},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,o=>(e.openBlock(),e.createElementBlock("div",{key:o.id,class:e.normalizeClass(["mfs-toast mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur mfs-flex mfs-items-start mfs-gap-3 mfs-relative",[`mfs-toast--${o.severity}`]]),role:o.severity==="danger"||o.severity==="warning"?"alert":"status","aria-live":"polite",onMouseenter:m=>e.unref(i)(o.id),onMouseleave:m=>e.unref(r)(o.id),onFocusin:m=>e.unref(i)(o.id),onFocusout:m=>e.unref(r)(o.id)},[e.createElementVNode("span",Os,[o.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Hs,[...c[0]||(c[0]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):o.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",Us,[...c[1]||(c[1]=[e.createElementVNode("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"},null,-1),e.createElementVNode("path",{d:"M12 9v4"},null,-1),e.createElementVNode("path",{d:"M12 17h.01"},null,-1)])])):o.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",Ws,[...c[2]||(c[2]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m15 9-6 6"},null,-1),e.createElementVNode("path",{d:"m9 9 6 6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Gs,[...c[3]||(c[3]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"M12 16v-4"},null,-1),e.createElementVNode("path",{d:"M12 8h.01"},null,-1)])]))]),e.createElementVNode("div",qs,[o.title?(e.openBlock(),e.createElementBlock("div",Ys,e.toDisplayString(o.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Xs,e.toDisplayString(o.message),1)]),o.closable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"mfs-toast__close mfs-surface-subtle mfs-pill mfs-focus-ring mfs-shrink-0 mfs-border-none mfs-text-muted mfs-inline-flex mfs-items-center mfs-justify-center mfs-cursor-pointer","aria-label":"Close notification",onClick:m=>e.unref(n)(o.id)},[...c[4]||(c[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])],8,Zs)):e.createCommentVNode("",!0)],42,Ks))),128))]),_:1})],2)]))}}),[["__scopeId","data-v-1a3d8498"]]),Js={class:"mfs-alert__icon","aria-hidden":"true"},Qs={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},vs={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},er={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},tr={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},lr={class:"mfs-alert__content"},nr={key:0,class:"mfs-alert__title mfs-title"},or={class:"mfs-alert__body mfs-text-muted"},Re=F(e.defineComponent({__name:"Alert",props:{severity:{default:"info"},title:{},closable:{type:Boolean,default:!1}},emits:["close"],setup(t,{emit:a}){const l=a;return(n,i)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-alert mfs-surface mfs-rounded mfs-shadow mfs-blur",[`mfs-alert--${t.severity}`]]),role:"alert"},[e.createElementVNode("span",Js,[e.renderSlot(n.$slots,"icon",{},()=>[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Qs,[...i[1]||(i[1]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):t.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",vs,[...i[2]||(i[2]=[e.createElementVNode("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"},null,-1),e.createElementVNode("path",{d:"M12 9v4"},null,-1),e.createElementVNode("path",{d:"M12 17h.01"},null,-1)])])):t.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",er,[...i[3]||(i[3]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m15 9-6 6"},null,-1),e.createElementVNode("path",{d:"m9 9 6 6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",tr,[...i[4]||(i[4]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"M12 16v-4"},null,-1),e.createElementVNode("path",{d:"M12 8h.01"},null,-1)])]))],!0)]),e.createElementVNode("div",lr,[t.title?(e.openBlock(),e.createElementBlock("div",nr,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",or,[e.renderSlot(n.$slots,"default",{},void 0,!0)])]),t.closable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"mfs-alert__close mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":"Close alert",onClick:i[0]||(i[0]=r=>l("close"))},[...i[5]||(i[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-d22695b6"]]),ar=["aria-describedby"],sr=["id"],Tt=F(e.defineComponent({__name:"Tooltip",props:{content:{default:""},placement:{default:"top"},disabled:{type:Boolean,default:!1}},setup(t){const a=t,l=e.ref(!1),n=e.useId(),i=()=>{!a.disabled&&a.content&&(l.value=!0)},r=()=>{l.value=!1};return(s,d)=>(e.openBlock(),e.createElementBlock("span",{class:"mfs-relative mfs-inline-flex mfs-items-center",onMouseenter:i,onMouseleave:r,onFocusin:i,onFocusout:r,onKeydown:e.withKeys(r,["escape"])},[e.createElementVNode("span",{class:"mfs-inline-flex mfs-items-center","aria-describedby":l.value&&t.content?e.unref(n):void 0},[e.renderSlot(s.$slots,"default",{},void 0,!0)],8,ar),e.createVNode(e.Transition,{name:"mfs-tooltip"},{default:e.withCtx(()=>[l.value&&!t.disabled&&t.content?(e.openBlock(),e.createElementBlock("span",{key:0,id:e.unref(n),role:"tooltip",class:e.normalizeClass(["mfs-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-blur mfs-whitespace-nowrap mfs-font-semibold",[`mfs-tooltip--${t.placement}`]])},[e.createTextVNode(e.toDisplayString(t.content)+" ",1),d[0]||(d[0]=e.createElementVNode("span",{class:"mfs-tooltip__arrow mfs-absolute","aria-hidden":"true"},null,-1))],10,sr)):e.createCommentVNode("",!0)]),_:1})],32))}}),[["__scopeId","data-v-41e6fd61"]]),rr=["aria-label"],ir={key:0,class:"mfs-drawer__header mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},dr={class:"mfs-drawer__title mfs-title mfs-m-0 mfs-font-bold"},cr={class:"mfs-drawer__body mfs-flex-1 mfs-p-5 mfs-overflow-y-auto"},mr={key:1,class:"mfs-drawer__footer mfs-border-t mfs-flex mfs-justify-end mfs-gap-2-5"},Pe=F(e.defineComponent({__name:"Drawer",props:{modelValue:{type:Boolean,default:!1},position:{default:"right"},size:{default:"360px"},title:{},closeOnBackdrop:{type:Boolean,default:!0}},emits:["update:modelValue","close"],setup(t,{emit:a}){const l=t,n=a,i=e.computed(()=>l.position==="left"||l.position==="right"),r=e.computed(()=>i.value?{width:l.size,maxWidth:"100vw",height:"100%"}:{height:l.size,maxHeight:"100vh",width:"100%"}),s=()=>{n("update:modelValue",!1),n("close")},d=()=>{l.closeOnBackdrop&&s()},c=b=>{b.key==="Escape"&&l.modelValue&&s()};let o="",m=!1;const f=b=>{if(!(typeof document>"u"))if(b){if(m)return;o=document.body.style.overflow,document.body.style.overflow="hidden",document.addEventListener("keydown",c),m=!0}else m&&(document.body.style.overflow=o,document.removeEventListener("keydown",c),m=!1)};return e.onMounted(()=>{l.modelValue&&f(!0)}),e.watch(()=>l.modelValue,b=>f(b)),e.onBeforeUnmount(()=>{f(!1)}),(b,u)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-drawer-fade"},{default:e.withCtx(()=>[t.modelValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-drawer-backdrop mfs-backdrop mfs-fixed mfs-inset-0 mfs-flex",onClick:d},[e.createElementVNode("aside",{class:e.normalizeClass(["mfs-drawer mfs-surface mfs-overlay mfs-shadow-card mfs-blur mfs-fixed mfs-flex mfs-flex-col mfs-overflow-hidden",[`mfs-drawer--${t.position}`]]),style:e.normalizeStyle(r.value),role:"dialog","aria-modal":"true","aria-label":t.title||"Drawer",onClick:u[0]||(u[0]=e.withModifiers(()=>{},["stop"]))},[t.title||b.$slots.header?(e.openBlock(),e.createElementBlock("div",ir,[e.renderSlot(b.$slots,"header",{},()=>[e.createElementVNode("h3",dr,e.toDisplayString(t.title),1)],!0),e.createElementVNode("button",{type:"button",class:"mfs-drawer__close mfs-surface-subtle mfs-pill mfs-focus-ring mfs-shrink-0 mfs-border-none mfs-text-muted mfs-inline-flex mfs-items-center mfs-justify-center mfs-cursor-pointer","aria-label":"Close drawer",onClick:s},[...u[1]||(u[1]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",cr,[e.renderSlot(b.$slots,"default",{},void 0,!0)]),b.$slots.footer?(e.openBlock(),e.createElementBlock("div",mr,[e.renderSlot(b.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],14,rr)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-cf8492dc"]]),fr={class:"mfs-popover-wrapper"},ur=["aria-expanded"],Ae=F(e.defineComponent({__name:"Popover",props:{modelValue:{type:Boolean,default:void 0},placement:{default:"bottom"}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),d=e.computed(()=>l.modelValue!==void 0),c=e.computed(()=>d.value?!!l.modelValue:s.value),{overlayStyle:o,containsTarget:m}=de(i,r,c,{offset:10,align:"center"}),f=y=>{d.value||(s.value=y),n("update:modelValue",y)},b=()=>f(!c.value),u=()=>f(!1),p=y=>{m(y.target)||u()},g=y=>{y.key==="Escape"&&u()},k=y=>{typeof document>"u"||(y?(document.addEventListener("pointerdown",p),document.addEventListener("keydown",g)):(document.removeEventListener("pointerdown",p),document.removeEventListener("keydown",g)))};return e.watch(c,y=>k(y),{immediate:!0}),e.onBeforeUnmount(()=>{k(!1)}),(y,h)=>(e.openBlock(),e.createElementBlock("div",fr,[e.createElementVNode("div",{ref_key:"triggerRef",ref:i,class:"mfs-popover__trigger","aria-expanded":c.value,"aria-haspopup":"dialog",onClick:b},[e.renderSlot(y.$slots,"trigger",{open:c.value,toggle:b},void 0,!0)],8,ur),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-popover"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(o)),class:e.normalizeClass(["mfs-popover mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur",[`mfs-popover--${t.placement}`]]),role:"dialog"},[e.renderSlot(y.$slots,"default",{close:u},void 0,!0)],6)):e.createCommentVNode("",!0)]),_:3})]))]))}}),[["__scopeId","data-v-00dfd9fd"]]),Lt=F(e.defineComponent({__name:"Skeleton",props:{variant:{default:"text"},width:{},height:{},lines:{default:1},animated:{type:Boolean,default:!0}},setup(t){const a=t,l=e.computed(()=>a.variant!=="text"?1:Math.max(1,Math.floor(a.lines))),n=i=>{const r=a.variant==="text"&&l.value>1&&i===l.value,s=a.variant==="circle"?"48px":r?"72%":"100%",d=a.variant==="circle"?a.width??"48px":a.variant==="text"?"14px":"80px";return{width:r&&!a.width?"72%":a.width??s,height:a.height??d}};return(i,r)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-skeleton-group",{"mfs-skeleton-group--lines":t.variant==="text"&&l.value>1}]),"aria-hidden":"true"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,s=>(e.openBlock(),e.createElementBlock("div",{key:s,class:e.normalizeClass(["mfs-skeleton",[`mfs-skeleton--${t.variant}`,t.variant==="text"?"mfs-rounded-sm":t.variant==="circle"?"mfs-pill":"mfs-rounded",{"mfs-skeleton--animated":t.animated}]]),style:e.normalizeStyle(n(s))},null,6))),128))],2))}}),[["__scopeId","data-v-7d535714"]]),pr={class:"mfs-progress"},kr=["aria-valuenow"],hr={key:0,class:"mfs-progress__label mfs-caption"},zt=F(e.defineComponent({__name:"ProgressBar",props:{value:{default:0},indeterminate:{type:Boolean,default:!1},showValue:{type:Boolean,default:!1},variant:{default:"primary"},height:{default:"10px"}},setup(t){const a=t,l=e.computed(()=>Math.min(100,Math.max(0,a.value)));return(n,i)=>(e.openBlock(),e.createElementBlock("div",pr,[e.createElementVNode("div",{class:"mfs-progress__track mfs-surface-subtle mfs-pill mfs-shadow-inset",role:"progressbar","aria-valuenow":t.indeterminate?void 0:l.value,"aria-valuemin":"0","aria-valuemax":"100",style:e.normalizeStyle({height:t.height})},[e.createElementVNode("div",{class:e.normalizeClass(["mfs-progress__bar mfs-pill",[`mfs-progress__bar--${t.variant}`,{"mfs-progress__bar--indeterminate":t.indeterminate}]]),style:e.normalizeStyle(t.indeterminate?void 0:{width:`${l.value}%`})},null,6)],12,kr),t.showValue&&!t.indeterminate?(e.openBlock(),e.createElementBlock("span",hr,e.toDisplayString(Math.round(l.value))+"% ",1)):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-9a84cdec"]]),gr={class:"mfs-spinner__svg",viewBox:"0 0 50 50"},yr=["stroke-width"],br=["stroke-width"],It=F(e.defineComponent({__name:"ProgressSpinner",props:{size:{default:"md"},strokeWidth:{default:4},variant:{default:"primary"}},setup(t){const a=t,l={sm:"22px",md:"36px",lg:"52px"},n=e.computed(()=>typeof a.size=="number"?`${a.size}px`:l[a.size]);return(i,r)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["mfs-spinner mfs-text",[`mfs-spinner--${t.variant}`]]),style:e.normalizeStyle({width:n.value,height:n.value}),role:"status","aria-label":"Loading"},[(e.openBlock(),e.createElementBlock("svg",gr,[e.createElementVNode("circle",{class:"mfs-spinner__track",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth},null,8,yr),e.createElementVNode("circle",{class:"mfs-spinner__ring",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,br)]))],6))}}),[["__scopeId","data-v-fcb783c0"]]),Fe=e.ref({isOpen:!1,options:null});let be=null;function Rt(t){var n,i;const a=Fe.value.options,l=be;be=null,Fe.value={isOpen:!1,options:null},t?(n=a==null?void 0:a.onAccept)==null||n.call(a):(i=a==null?void 0:a.onReject)==null||i.call(a),l==null||l(t)}function Br(t){return be&&(be(!1),be=null),Fe.value={isOpen:!0,options:{confirmLabel:"Confirm",cancelLabel:"Cancel",variant:"primary",...t}},new Promise(a=>{be=a})}function Pt(){return{state:e.readonly(Fe),confirm:Br,accept:()=>Rt(!0),reject:()=>Rt(!1)}}const wr=["aria-labelledby","aria-describedby"],_r={class:"mfs-confirm__header"},Er=["id"],$r=["id"],Vr={class:"mfs-flex mfs-justify-end mfs-gap-2-5 mfs-flex-wrap"},At=F(e.defineComponent({__name:"ConfirmDialog",setup(t){const{state:a,accept:l,reject:n}=Pt(),i=e.useId(),r=e.useId(),s=d=>{d.key==="Escape"&&a.value.isOpen&&n()};return e.watch(()=>a.value.isOpen,d=>{typeof document>"u"||(d?document.addEventListener("keydown",s):document.removeEventListener("keydown",s))},{immediate:!0}),e.onBeforeUnmount(()=>{typeof document<"u"&&document.removeEventListener("keydown",s)}),(d,c)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-fade"},{default:e.withCtx(()=>[e.unref(a).isOpen&&e.unref(a).options?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-confirm-backdrop mfs-backdrop mfs-fixed mfs-inset-0 mfs-flex mfs-items-center mfs-justify-center mfs-p-4",onClick:c[3]||(c[3]=(...o)=>e.unref(n)&&e.unref(n)(...o))},[e.createElementVNode("div",{class:"mfs-confirm mfs-overlay mfs-surface mfs-rounded mfs-shadow-card mfs-blur mfs-w-full",role:"alertdialog","aria-modal":"true","aria-labelledby":e.unref(i),"aria-describedby":e.unref(r),onClick:c[2]||(c[2]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",_r,[e.createElementVNode("h3",{id:e.unref(i),class:"mfs-confirm__title mfs-title mfs-m-0"},e.toDisplayString(e.unref(a).options.title),9,Er)]),e.createElementVNode("p",{id:e.unref(r),class:"mfs-confirm__message mfs-text-muted"},e.toDisplayString(e.unref(a).options.message),9,$r),e.createElementVNode("div",Vr,[e.createElementVNode("button",{type:"button",class:"mfs-confirm__btn mfs-surface-subtle mfs-pill mfs-shadow mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",onClick:c[0]||(c[0]=(...o)=>e.unref(n)&&e.unref(n)(...o))},e.toDisplayString(e.unref(a).options.cancelLabel??"Cancel"),1),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-confirm__btn mfs-pill mfs-shadow mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",[`mfs-bg-${e.unref(a).options.variant??"primary"}`]]),onClick:c[1]||(c[1]=(...o)=>e.unref(l)&&e.unref(l)(...o))},e.toDisplayString(e.unref(a).options.confirmLabel??"Confirm"),3)])],8,wr)])):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-cd6aa53d"]]),xr=new Set(["p","br","b","strong","i","em","u","s","del","ul","ol","li","span","div","blockquote","code","pre","h1","h2","h3","h4","a"]),Cr=new Set(["script","style","iframe","object","embed","svg","math","noscript","template"]);function se(t){if(!t||typeof t!="string")return;const a=t.replace(/[\u0000-\u001f\u007f]/g,"").trim();if(!a)return;const l=a.replace(/[\u0000-\u0020\u007f]+/g,"").toLowerCase();if(l&&!(l.startsWith("//")||l.startsWith("/\\"))&&(l.startsWith("/")||l.startsWith("#")||l.startsWith("./")||l.startsWith("../")||/^(https?:|mailto:|tel:)/.test(l)))return a}function Ft(t,a){if(t.nodeType===Node.TEXT_NODE)return[a.createTextNode(t.textContent??"")];if(t.nodeType!==Node.ELEMENT_NODE)return[];const l=t,n=l.tagName.toLowerCase();if(Cr.has(n))return[];const i=[];for(const s of Array.from(l.childNodes))i.push(...Ft(s,a));if(!xr.has(n))return i;const r=a.createElement(n);if(n==="a"){const s=se(l.getAttribute("href")??void 0);s&&(r.setAttribute("href",s),r.setAttribute("rel","noopener noreferrer"))}for(const s of i)r.appendChild(s);return[r]}function jt(t){if(typeof DOMParser>"u")return[];const a=new DOMParser().parseFromString(t||"","text/html"),l=[];for(const n of Array.from(a.body.childNodes))l.push(...Ft(n,a));return l}function nt(t){if(typeof document>"u"||typeof DOMParser>"u")return"";const a=document.createElement("div");return a.append(...jt(t)),a.innerHTML}const Nr={class:"navbar__inner mfs-flex mfs-items-center mfs-justify-between mfs-gap-4"},Sr={class:"navbar__brand mfs-flex mfs-items-center mfs-font-bold"},Mr={class:"navbar__nav","aria-label":"Main navigation"},Dr={class:"navbar__list mfs-flex mfs-items-center"},Tr=["aria-current","onClick"],Lr={class:"navbar__actions mfs-flex mfs-items-center"},zr=["aria-expanded"],Ir={key:0,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Rr={key:1,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Pr={key:0,id:"navbar-mobile-drawer",class:"navbar__drawer",role:"region","aria-label":"Mobile navigation"},Ar={class:"navbar__mobile-list mfs-flex mfs-flex-col"},Fr=["aria-current","onClick"],je=F(e.defineComponent({__name:"Navbar",props:{items:{default:()=>[]},sticky:{type:Boolean,default:!0},bordered:{type:Boolean,default:!0}},emits:["navigate"],setup(t,{emit:a}){const l=a,n=e.ref(!1),i=(d,c)=>{l("navigate",d,c)},r=(d,c)=>{n.value=!1,l("navigate",d,c)},s=d=>{d.key==="Escape"&&n.value&&(n.value=!1)};return e.onMounted(()=>{window.addEventListener("keydown",s)}),e.onUnmounted(()=>{window.removeEventListener("keydown",s)}),(d,c)=>(e.openBlock(),e.createElementBlock("header",{class:e.normalizeClass(["navbar mfs-w-full mfs-surface mfs-shadow mfs-rounded",{"navbar--sticky":t.sticky,"mfs-border-none":!t.bordered}])},[e.createElementVNode("div",Nr,[e.createElementVNode("div",Sr,[e.renderSlot(d.$slots,"brand",{},void 0,!0)]),e.createElementVNode("nav",Mr,[e.renderSlot(d.$slots,"links",{items:t.items,navigate:i},()=>[e.createElementVNode("ul",Dr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(o,m)=>(e.openBlock(),e.createElementBlock("li",{key:m,class:"navbar__item"},[!o.to&&!o.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["navbar__link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-pill",{"navbar__link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>i(o,f)},e.toDisplayString(o.label),11,Tr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.to?"router-link":"a"),{key:1,to:o.to,href:e.unref(se)(o.href),class:e.normalizeClass(["navbar__link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-pill",{"navbar__link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>i(o,f)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)]),e.createElementVNode("div",Lr,[e.renderSlot(d.$slots,"actions",{},void 0,!0),e.createElementVNode("button",{type:"button",class:"navbar__toggle mfs-inline-flex mfs-items-center mfs-justify-center mfs-surface-subtle mfs-shadow mfs-rounded-md mfs-interactive","aria-expanded":n.value,"aria-controls":"navbar-mobile-drawer","aria-label":"Toggle navigation menu",onClick:c[0]||(c[0]=o=>n.value=!n.value)},[n.value?(e.openBlock(),e.createElementBlock("svg",Rr,[...c[2]||(c[2]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Ir,[...c[1]||(c[1]=[e.createElementVNode("line",{x1:"3",y1:"6",x2:"21",y2:"6"},null,-1),e.createElementVNode("line",{x1:"3",y1:"12",x2:"21",y2:"12"},null,-1),e.createElementVNode("line",{x1:"3",y1:"18",x2:"21",y2:"18"},null,-1)])]))],8,zr)])]),e.createVNode(e.Transition,{name:"navbar-drawer"},{default:e.withCtx(()=>[n.value?(e.openBlock(),e.createElementBlock("div",Pr,[e.renderSlot(d.$slots,"links",{items:t.items,navigate:r},()=>[e.createElementVNode("ul",Ar,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(o,m)=>(e.openBlock(),e.createElementBlock("li",{key:m},[!o.to&&!o.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["navbar__mobile-link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-w-full mfs-rounded-md",{"navbar__mobile-link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>r(o,f)},e.toDisplayString(o.label),11,Fr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.to?"router-link":"a"),{key:1,to:o.to,href:e.unref(se)(o.href),class:e.normalizeClass(["navbar__mobile-link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-w-full mfs-rounded-md",{"navbar__mobile-link--active":o.active}]),"aria-current":o.active?"page":void 0,onClick:f=>r(o,f)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(o.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)])):e.createCommentVNode("",!0)]),_:3})],2))}}),[["__scopeId","data-v-725e9bf5"]]),jr={class:"tabs"},Kr=["aria-selected","aria-disabled","disabled","tabindex","onClick"],Or={key:0,class:"tabs__panel",role:"tabpanel"},Ke=F(e.defineComponent({__name:"Tabs",props:{items:{},modelValue:{},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=new Map,s=e.ref({left:0,width:0,ready:!1}),d=e.computed(()=>{var k;if(l.modelValue!==void 0)return l.modelValue;const g=l.items.find(y=>!y.disabled);return(g==null?void 0:g.key)??((k=l.items[0])==null?void 0:k.key)??""}),c=e.computed(()=>({transform:`translateX(${s.value.left}px)`,width:`${s.value.width}px`,opacity:s.value.ready&&s.value.width>0?1:0})),o=(g,k)=>{k?r.set(g,k):r.delete(g)},m=async(g=!1)=>{await e.nextTick();const k=r.get(d.value);if(!k){s.value={left:0,width:0,ready:!1};return}s.value={left:k.offsetLeft,width:k.offsetWidth,ready:!0},g&&l.scrollable&&k.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},f=(g,k)=>{g.disabled||g.key===d.value||(n("update:modelValue",g.key),n("change",g.key))},b=g=>{var B;const k=l.items.filter($=>!$.disabled);if(!k.length)return;const y=k.findIndex($=>$.key===d.value);let h=-1;if(g.key==="ArrowRight"?h=(y+1)%k.length:g.key==="ArrowLeft"?h=(y-1+k.length)%k.length:g.key==="Home"?h=0:g.key==="End"&&(h=k.length-1),h>=0){g.preventDefault();const $=k[h];f($),(B=r.get($.key))==null||B.focus()}};let u=null;e.watch(()=>[d.value,l.items],()=>m(!0),{deep:!0});const p=()=>m(!1);return e.onMounted(()=>{m(!1),typeof ResizeObserver<"u"&&i.value&&(u=new ResizeObserver(p),u.observe(i.value)),window.addEventListener("resize",p)}),e.onUnmounted(()=>{u==null||u.disconnect(),window.removeEventListener("resize",p)}),(g,k)=>(e.openBlock(),e.createElementBlock("div",jr,[e.createElementVNode("div",{ref_key:"listRef",ref:i,class:e.normalizeClass(["tabs__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tabs__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:b},[e.createElementVNode("span",{class:"tabs__indicator mfs-pill",style:e.normalizeStyle(c.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(y,h)=>(e.openBlock(),e.createElementBlock("button",{key:y.key,ref_for:!0,ref:B=>o(y.key,B),type:"button",role:"tab",class:e.normalizeClass(["tabs__tab mfs-pill mfs-bg-transparent",{"tabs__tab--active":y.key===d.value,"tabs__tab--disabled mfs-disabled":y.disabled}]),"aria-selected":y.key===d.value,"aria-disabled":y.disabled||void 0,disabled:y.disabled,tabindex:y.key===d.value?0:-1,onClick:B=>f(y)},[e.renderSlot(g.$slots,"tab",{item:y,active:y.key===d.value},()=>[e.createTextVNode(e.toDisplayString(y.label),1)],!0)],10,Kr))),128))],34),g.$slots.default?(e.openBlock(),e.createElementBlock("div",Or,[e.renderSlot(g.$slots,"default",{activeKey:d.value},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7c67efbf"]]),Hr={class:"breadcrumb mfs-surface mfs-pill mfs-inline-flex mfs-items-center","aria-label":"Breadcrumb"},Ur={class:"breadcrumb__list mfs-flex mfs-flex-wrap mfs-items-center"},Wr={key:0,class:"breadcrumb__separator mfs-inline-flex mfs-items-center mfs-text-muted","aria-hidden":"true"},Gr={key:0},qr={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Yr=["aria-current"],Xr=["onClick"],Kt=F(e.defineComponent({__name:"Breadcrumb",props:{items:{},separator:{default:"chevron"}},emits:["navigate"],setup(t,{emit:a}){const l=a;return(n,i)=>(e.openBlock(),e.createElementBlock("nav",Hr,[e.createElementVNode("ol",Ur,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(r,s)=>(e.openBlock(),e.createElementBlock("li",{key:s,class:"breadcrumb__item mfs-inline-flex mfs-items-center"},[s>0?(e.openBlock(),e.createElementBlock("span",Wr,[e.renderSlot(n.$slots,"separator",{},()=>[t.separator==="slash"?(e.openBlock(),e.createElementBlock("span",Gr,"/")):(e.openBlock(),e.createElementBlock("svg",qr,[...i[0]||(i[0]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])]))],!0)])):e.createCommentVNode("",!0),e.renderSlot(n.$slots,"item",{item:r,isLast:s===t.items.length-1},()=>[s===t.items.length-1||r.disabled?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["breadcrumb__leaf mfs-text mfs-font-semibold",{"breadcrumb__leaf--disabled mfs-disabled":r.disabled}]),"aria-current":s===t.items.length-1?"page":void 0},e.toDisplayString(r.label),11,Yr)):!r.to&&!r.href?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"breadcrumb__link mfs-inline-flex mfs-items-center mfs-rounded-sm mfs-border-none mfs-font-medium mfs-text",onClick:d=>l("navigate",r,d)},e.toDisplayString(r.label),9,Xr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.to?"router-link":"a"),{key:2,to:r.to,href:e.unref(se)(r.href),class:"breadcrumb__link mfs-inline-flex mfs-items-center mfs-rounded-sm mfs-border-none mfs-font-medium mfs-text",onClick:d=>l("navigate",r,d)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.label),1)]),_:2},1032,["to","href","onClick"]))],!0)]))),128))])]))}}),[["__scopeId","data-v-569a080d"]]),Zr=["aria-busy"],Jr={class:"pagination__controls"},Qr=["disabled"],vr=["disabled"],ei={key:0,class:"pagination__ellipsis mfs-text-muted","aria-hidden":"true"},ti=["disabled","aria-label","aria-current","onClick"],li=["disabled"],ni=["disabled"],oi={key:0,class:"pagination__extras"},ai={key:0,class:"pagination__per-page"},si=["value","disabled"],ri=["value"],ii={class:"pagination__label mfs-text-muted"},di=["max","disabled"],xe=F(e.defineComponent({__name:"Pagination",props:{modelValue:{},total:{},perPage:{default:10},perPageOptions:{default:()=>[10,20,50,100]},showJumpTo:{type:Boolean,default:!1},siblingCount:{default:1},loading:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","update:perPage","change"],setup(t,{emit:a}){const l=t,n=e.computed(()=>l.disabled||l.loading),i=a,r=e.ref(""),s=e.computed(()=>Math.max(1,Math.ceil(l.total/Math.max(1,l.perPage)))),d=e.computed(()=>Math.min(Math.max(1,l.modelValue),s.value)),c=e.computed(()=>{const b=s.value,u=d.value,p=l.siblingCount,g=p*2+5;if(b<=g)return Array.from({length:b},(_,D)=>D+1);const k=Math.max(u-p,1),y=Math.min(u+p,b),h=k>2,B=y<b-1,$=[1];if(h)$.push("ellipsis");else for(let _=2;_<k;_++)$.push(_);for(let _=Math.max(2,k);_<=Math.min(b-1,y);_++)$.push(_);if(B)$.push("ellipsis");else for(let _=y+1;_<b;_++)$.push(_);return b>1&&$.push(b),$}),o=b=>{if(n.value)return;const u=Math.min(Math.max(1,b),s.value);u!==d.value&&(i("update:modelValue",u),i("change",{page:u,perPage:l.perPage}))},m=b=>{if(n.value)return;const u=Number(b.target.value),p=Math.max(1,Math.ceil(l.total/Math.max(1,u))),g=Math.min(d.value,p);i("update:perPage",u),g!==d.value&&i("update:modelValue",g),i("change",{page:g,perPage:u})},f=()=>{if(n.value)return;const b=Number.parseInt(r.value,10);Number.isNaN(b)||o(b),r.value=""};return(b,u)=>(e.openBlock(),e.createElementBlock("nav",{class:"pagination mfs-row mfs-text","aria-label":"Pagination","aria-busy":t.loading||void 0},[e.createElementVNode("div",Jr,[e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value<=1,"aria-label":"First page",onClick:u[0]||(u[0]=p=>o(1))},[...u[5]||(u[5]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"11 17 6 12 11 7"}),e.createElementVNode("polyline",{points:"18 17 13 12 18 7"})],-1)])],8,Qr),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value<=1,"aria-label":"Previous page",onClick:u[1]||(u[1]=p=>o(d.value-1))},[...u[6]||(u[6]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"15 18 9 12 15 6"})],-1)])],8,vr),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(p,g)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:g},[p==="ellipsis"?(e.openBlock(),e.createElementBlock("span",ei," … ")):(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:e.normalizeClass(["pagination__btn pagination__btn--page mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",{"pagination__btn--active":p===d.value}]),disabled:n.value,"aria-label":`Page ${p}`,"aria-current":p===d.value?"page":void 0,onClick:k=>o(p)},e.toDisplayString(p),11,ti))],64))),128)),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value>=s.value,"aria-label":"Next page",onClick:u[2]||(u[2]=p=>o(d.value+1))},[...u[7]||(u[7]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"})],-1)])],8,li),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:n.value||d.value>=s.value,"aria-label":"Last page",onClick:u[3]||(u[3]=p=>o(s.value))},[...u[8]||(u[8]=[e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"13 17 18 12 13 7"}),e.createElementVNode("polyline",{points:"6 17 11 12 6 7"})],-1)])],8,ni)]),t.perPageOptions.length||t.showJumpTo?(e.openBlock(),e.createElementBlock("div",oi,[t.perPageOptions.length?(e.openBlock(),e.createElementBlock("label",ai,[u[9]||(u[9]=e.createElementVNode("span",{class:"pagination__label mfs-text-muted"},"Rows",-1)),e.createElementVNode("select",{class:"pagination__select mfs-surface mfs-rounded-md mfs-shadow-inset",value:t.perPage,disabled:n.value,"aria-label":"Items per page",onChange:m},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.perPageOptions,p=>(e.openBlock(),e.createElementBlock("option",{key:p,value:p},e.toDisplayString(p),9,ri))),128))],40,si)])):e.createCommentVNode("",!0),t.showJumpTo?(e.openBlock(),e.createElementBlock("form",{key:1,class:"pagination__jump",onSubmit:e.withModifiers(f,["prevent"])},[e.createElementVNode("label",ii,[u[10]||(u[10]=e.createTextVNode(" Go ",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":u[4]||(u[4]=p=>r.value=p),type:"number",min:"1",max:s.value,disabled:n.value,class:"pagination__input mfs-surface mfs-rounded-md mfs-shadow-inset","aria-label":"Jump to page"},null,8,di),[[e.vModelText,r.value]])])],32)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],8,Zr))}}),[["__scopeId","data-v-4b04f139"]]),ci=["aria-current"],mi=["onClick"],fi={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},ui={key:0,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},pi={key:1,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},ki={key:2},hi={class:"steps__content mfs-flex mfs-flex-col"},gi={class:"steps__label mfs-font-semibold"},yi={key:0,class:"steps__desc mfs-text-muted"},bi={key:1,class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md"},Bi={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},wi={key:0,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},_i={key:1,width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Ei={key:2},$i={class:"steps__content mfs-flex mfs-flex-col"},Vi={class:"steps__label mfs-font-semibold"},xi={key:0,class:"steps__desc mfs-text-muted"},Oe=F(e.defineComponent({__name:"Steps",props:{items:{},modelValue:{default:0},clickable:{type:Boolean,default:!1},direction:{default:"responsive"}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=(s,d)=>s.status?s.status:d<l.modelValue?"completed":d===l.modelValue?"active":"upcoming",r=s=>{!l.clickable||s===l.modelValue||(n("update:modelValue",s),n("change",s))};return(s,d)=>(e.openBlock(),e.createElementBlock("ol",{class:e.normalizeClass(["steps mfs-flex mfs-w-full mfs-gap-2",[`steps--${t.direction}`]]),"aria-label":"Progress steps"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(c,o)=>(e.openBlock(),e.createElementBlock("li",{key:o,class:e.normalizeClass(["steps__item mfs-flex mfs-items-center mfs-gap-2",[`steps__item--${i(c,o)}`,{"steps__item--clickable":t.clickable}]]),"aria-current":i(c,o)==="active"?"step":void 0},[t.clickable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md",onClick:m=>r(o)},[e.createElementVNode("span",fi,[i(c,o)==="completed"?(e.openBlock(),e.createElementBlock("svg",ui,[...d[0]||(d[0]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):i(c,o)==="error"?(e.openBlock(),e.createElementBlock("svg",pi,[...d[1]||(d[1]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("span",ki,e.toDisplayString(o+1),1))]),e.createElementVNode("span",hi,[e.createElementVNode("span",gi,e.toDisplayString(c.label),1),c.description?(e.openBlock(),e.createElementBlock("span",yi,e.toDisplayString(c.description),1)):e.createCommentVNode("",!0)])],8,mi)):(e.openBlock(),e.createElementBlock("div",bi,[e.createElementVNode("span",Bi,[i(c,o)==="completed"?(e.openBlock(),e.createElementBlock("svg",wi,[...d[2]||(d[2]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):i(c,o)==="error"?(e.openBlock(),e.createElementBlock("svg",_i,[...d[3]||(d[3]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("span",Ei,e.toDisplayString(o+1),1))]),e.createElementVNode("span",$i,[e.createElementVNode("span",Vi,e.toDisplayString(c.label),1),c.description?(e.openBlock(),e.createElementBlock("span",xi,e.toDisplayString(c.description),1)):e.createCommentVNode("",!0)])])),o<t.items.length-1?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(["steps__connector mfs-surface-subtle mfs-shadow-inset mfs-pill",{"steps__connector--completed":i(c,o)==="completed"}]),"aria-hidden":"true"},null,2)):e.createCommentVNode("",!0)],10,ci))),128))],2))}}),[["__scopeId","data-v-aef341ac"]]),Ci={key:0,class:"ctx-menu__divider mfs-divider",role:"separator"},Ni={key:1,role:"none"},Si=["disabled","onClick"],Mi={key:0,class:"ctx-menu__icon","aria-hidden":"true"},Di={class:"ctx-menu__label"},Ot=F(e.defineComponent({__name:"ContextMenu",props:{items:{}},emits:["select","open","close"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(!1),s=e.ref(null),d=e.ref({x:0,y:0}),c=new Map,o=(h,B)=>{B?c.set(h,B):c.delete(h)},m=()=>{r.value&&(r.value=!1,y(),i("close"))},f=async h=>{var $;r.value=!0,d.value={x:h.clientX,y:h.clientY},i("open"),await e.nextTick();const B=s.value;if(B){const _=B.getBoundingClientRect(),D=8,S=window.innerWidth-_.width-D,E=window.innerHeight-_.height-D;d.value={x:Math.max(D,Math.min(h.clientX,S)),y:Math.max(D,Math.min(h.clientY,E))};const w=n.items.findIndex(N=>!N.divider&&!N.disabled);w>=0&&(($=c.get(w))==null||$.focus())}k()},b=h=>{var B;h.disabled||((B=h.action)==null||B.call(h),i("select",h),m())},u=h=>{var D,S;const B=n.items.map((E,w)=>!E.divider&&!E.disabled?w:-1).filter(E=>E>=0);if(!B.length)return;const $=document.activeElement,_=B.findIndex(E=>c.get(E)===$);if(h.key==="ArrowDown"){h.preventDefault();const E=B[(_+1)%B.length];(D=c.get(E))==null||D.focus()}else if(h.key==="ArrowUp"){h.preventDefault();const E=B[(_-1+B.length)%B.length];(S=c.get(E))==null||S.focus()}else h.key==="Escape"&&(h.preventDefault(),m())},p=h=>{s.value&&!s.value.contains(h.target)&&m()},g=h=>{h.key==="Escape"&&m()},k=()=>{window.addEventListener("pointerdown",p),window.addEventListener("keydown",g),window.addEventListener("resize",m)},y=()=>{window.removeEventListener("pointerdown",p),window.removeEventListener("keydown",g),window.removeEventListener("resize",m)};return e.onUnmounted(()=>{y()}),a({open:f,close:m}),(h,B)=>(e.openBlock(),e.createElementBlock("div",{class:"ctx-wrapper",onContextmenu:e.withModifiers(f,["prevent"])},[e.renderSlot(h.$slots,"default",{},void 0,!0),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ctx-pop"},{default:e.withCtx(()=>[r.value?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"menuRef",ref:s,class:"ctx-menu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${d.value.x}px`,top:`${d.value.y}px`}),onKeydown:u},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,($,_)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:_},[$.divider?(e.openBlock(),e.createElementBlock("li",Ci)):(e.openBlock(),e.createElementBlock("li",Ni,[e.createElementVNode("button",{ref_for:!0,ref:D=>o(_,D),type:"button",role:"menuitem",class:e.normalizeClass(["ctx-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"ctx-menu__item--disabled mfs-disabled":$.disabled,"ctx-menu__item--danger":$.danger}]),disabled:$.disabled,onClick:D=>b($)},[e.renderSlot(h.$slots,"item",{item:$},()=>[$.icon?(e.openBlock(),e.createElementBlock("span",Mi,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Di,e.toDisplayString($.label),1)],!0)],10,Si)]))],64))),128))],36)):e.createCommentVNode("",!0)]),_:3})]))],32))}}),[["__scopeId","data-v-ebbadeb3"]]),Ht=F(e.defineComponent({__name:"ScrollTop",props:{threshold:{default:200},behavior:{default:"smooth"},target:{default:null}},emits:["click"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);let r=null;const s=()=>typeof l.target=="string"?document.querySelector(l.target)??window:l.target instanceof HTMLElement?l.target:window,d=()=>{if(!r)return;const o=r===window?window.scrollY:r.scrollTop;i.value=o>=l.threshold},c=o=>{s().scrollTo({top:0,behavior:l.behavior}),n("click",o)};return e.onMounted(()=>{r=s(),r.addEventListener("scroll",d,{passive:!0}),d()}),e.onUnmounted(()=>{r==null||r.removeEventListener("scroll",d)}),(o,m)=>(e.openBlock(),e.createBlock(e.Transition,{name:"scroll-top-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"scroll-top mfs-shadow mfs-interactive","aria-label":"Scroll to top",onClick:c},[e.renderSlot(o.$slots,"default",{},()=>[m[0]||(m[0]=e.createElementVNode("svg",{width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"18 15 12 9 6 15"})],-1))],!0)])):e.createCommentVNode("",!0)]),_:3}))}}),[["__scopeId","data-v-a8dbdc07"]]),Ti={key:0,class:"data-table__toolbar mfs-flex mfs-flex-wrap mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},Li={key:0,class:"data-table__toolbar-actions"},zi={key:0,class:"data-table__search mfs-relative mfs-flex mfs-items-center"},Ii=["value"],Ri=["aria-expanded"],Pi={class:"data-table__wrap mfs-w-full mfs-overflow-x-auto"},Ai={class:"data-table__table mfs-w-full mfs-text-left"},Fi={class:"data-table__head"},ji={key:0,class:"data-table__th data-table__th--expand mfs-text-muted","aria-label":"Expand row"},Ki={key:1,class:"data-table__th data-table__th--select mfs-text-muted mfs-whitespace-nowrap"},Oi=["aria-sort"],Hi=["onClick"],Ui={class:"data-table__sort-icon mfs-shrink-0",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},Wi=["fill"],Gi=["fill"],qi={key:0,class:"data-table__sort-badge"},Yi={key:1},Xi={class:"data-table__body"},Zi={key:0,class:"data-table__empty-row"},Ji=["colspan"],Qi={class:"data-table__empty-content mfs-inline-flex mfs-flex-col mfs-items-center mfs-gap-2"},vi=["aria-selected","onClick"],ed=["aria-expanded","aria-label","onClick"],td=["checked","aria-label","onChange"],ld=["data-label"],nd={class:"data-table__cell-value"},od={key:0,class:"data-table__expansion-row"},ad=["colspan"],sd={key:1,class:"data-table__paginator mfs-flex mfs-items-center mfs-justify-between mfs-flex-wrap mfs-gap-3 mfs-pt-3 mfs-border-t"},rd={key:0,class:"data-table__per-page mfs-inline-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-text-muted"},id=["value","disabled"],dd=["value"],cd={key:2,class:"mfs-loading-overlay","aria-busy":"true"},Ut=F(e.defineComponent({__name:"DataTable",props:{columns:{},rows:{},value:{},rowKey:{default:"id"},searchable:{type:Boolean,default:!1},searchQuery:{default:""},selectable:{type:[Boolean,String],default:!1},selection:{default:null},responsiveMode:{default:"card"},emptyText:{default:"No data available"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},paginator:{type:Boolean,default:!1},totalRecords:{},rowsPerPage:{},rowsPerPageOptions:{default:()=>[5,10,20,50]},page:{},first:{default:0},sortMode:{default:"single"},multiSortMeta:{},expandable:{type:Boolean,default:!1},expandedRows:{},columnToggle:{type:Boolean,default:!1},visibleColumns:{}},emits:["update:selection","update:searchQuery","update:page","update:rows","update:rowsPerPage","update:first","update:multiSortMeta","update:expandedRows","update:visibleColumns","page","sort","filter","row-click","row-expand","row-collapse"],setup(t,{emit:a}){const l=t,n=a,i=`dt-radio-${e.useId()}`,r=e.ref(l.searchQuery),s=e.ref(null),d=e.ref(null),c=e.ref(l.multiSortMeta?l.multiSortMeta.map(M=>({...M})):[]);e.watch(()=>l.multiSortMeta,M=>{c.value=M?M.map(x=>({...x})):[]},{deep:!0});const o=e.computed(()=>l.multiSortMeta??c.value),m=e.computed(()=>l.value??(Array.isArray(l.rows)?l.rows:[])),f=e.ref(typeof l.rows=="number"?l.rows:l.rowsPerPage??10);e.watch(()=>l.rows,M=>{typeof M=="number"&&(f.value=M)}),e.watch(()=>l.rowsPerPage,M=>{M!==void 0&&(f.value=M)});const b=e.computed(()=>Math.max(1,typeof l.rows=="number"?l.rows:l.rowsPerPage??f.value)),u=e.ref(l.page!==void 0?Math.max(1,l.page):l.first>0?Math.floor(l.first/b.value)+1:1);e.watch(()=>l.page,M=>{M!==void 0&&(u.value=Math.max(1,M))}),e.watch(()=>l.first,M=>{M!==void 0&&l.page===void 0&&(u.value=Math.floor(Math.max(0,M)/b.value)+1)}),e.watch(()=>l.searchQuery,M=>{r.value=M});const p=e.computed(()=>l.searchQuery!==""?l.searchQuery:r.value);e.watch(p,()=>{!l.lazy&&l.paginator&&N.value!==1&&(u.value=1,n("update:page",1),n("update:first",0))});const g=e.computed(()=>l.selectable===!0||l.selectable==="multiple"?"multiple":l.selectable==="single"?"single":null);function k(M,x){const R=M==null?void 0:M[l.rowKey];return typeof R=="string"||typeof R=="number"?R:x}function y(M){const x=M.target.value;r.value=x,n("update:searchQuery",x),n("filter",x)}function h(M){if(l.sortMode==="multiple"){const x=o.value.find(R=>R.key===M);return x?x.order:null}return s.value===M?d.value:null}function B(M){if(l.sortMode!=="multiple"||o.value.length===0)return null;const x=o.value.findIndex(R=>R.key===M);return x>=0?x+1:null}function $(M){if(l.sortMode==="multiple"){const x=o.value.map(X=>({...X})),R=x.findIndex(X=>X.key===M);let H="asc";R===-1?(x.push({key:M,order:"asc"}),H="asc"):x[R].order==="asc"?(x[R].order="desc",H="desc"):(x.splice(R,1),H=null),c.value=x,n("update:multiSortMeta",x),n("sort",{key:M,order:H,multiSortMeta:x});return}s.value!==M?(s.value=M,d.value="asc"):d.value==="asc"?d.value="desc":(s.value=null,d.value=null),n("sort",{key:M,order:d.value})}function _(M){if(!M.sortable)return;const x=h(M.key);return x?x==="asc"?"ascending":"descending":"none"}function D(M,x,R){return M==null&&x==null?0:M==null?-1*R:x==null?1*R:typeof M=="number"&&typeof x=="number"?(M-x)*R:String(M).localeCompare(String(x))*R}const S=e.computed(()=>{if(l.lazy)return m.value;const M=p.value.trim().toLowerCase();let x=m.value;if(M){const R=l.columns.map(H=>H.key);x=x.filter(H=>R.some(X=>String(H[X]??"").toLowerCase().includes(M)))}if(l.sortMode==="multiple"){if(o.value.length>0){const R=o.value;x=[...x].sort((H,X)=>{for(const le of R){const ce=le.order==="asc"?1:-1,De=D(H[le.key],X[le.key],ce);if(De!==0)return De}return 0})}}else if(s.value&&d.value){const R=s.value,H=d.value==="asc"?1:-1;x=[...x].sort((X,le)=>D(X[R],le[R],H))}return x}),E=e.computed(()=>l.lazy?l.totalRecords??m.value.length:l.totalRecords??S.value.length),w=e.computed(()=>Math.max(1,Math.ceil(E.value/b.value))),N=e.computed(()=>{const M=l.page!==void 0?l.page:u.value;return Math.min(Math.max(1,M),w.value)}),V=e.computed(()=>{if(l.lazy||!l.paginator)return S.value;const M=(N.value-1)*b.value;return S.value.slice(M,M+b.value)});function C(M){const x=b.value,R=w.value,H=Math.min(Math.max(1,M),R),X=(H-1)*x;u.value=H,n("update:page",H),n("update:first",X),n("page",{page:H,first:X,rows:x,pageCount:R,rowsPerPage:x})}function P(M){if(l.loading)return;const x=Number(M.target.value);if(!Number.isFinite(x)||x<=0)return;f.value=x;const R=Math.max(1,Math.ceil(E.value/x)),H=Math.min(N.value,R),X=(H-1)*x;u.value=H,n("update:rows",x),n("update:rowsPerPage",x),n("update:page",H),n("update:first",X),n("page",{page:H,first:X,rows:x,pageCount:R,rowsPerPage:x})}function T(M,x){if(!g.value||!l.selection)return!1;const R=k(M,x);return g.value==="single"?Array.isArray(l.selection)?!1:k(l.selection,-1)===R:Array.isArray(l.selection)&&l.selection.some((H,X)=>k(H,X)===R)}const I=e.computed(()=>g.value!=="multiple"||V.value.length===0?!1:V.value.every((M,x)=>T(M,x))),j=e.computed(()=>{if(g.value!=="multiple"||V.value.length===0)return!1;const M=V.value.filter((x,R)=>T(x,R)).length;return M>0&&M<V.value.length});function A(M,x){if(!g.value)return;if(g.value==="single"){n("update:selection",M);return}const R=k(M,x),H=Array.isArray(l.selection)?[...l.selection]:[],X=H.findIndex((le,ce)=>k(le,ce)===R);X>=0?H.splice(X,1):H.push(M),n("update:selection",H)}function K(){g.value==="multiple"&&(I.value?n("update:selection",[]):n("update:selection",[...V.value]))}function W(M,x){n("row-click",M),g.value&&A(M,x)}const v=e.ref(l.expandedRows?[...l.expandedRows]:[]);e.watch(()=>l.expandedRows,M=>{v.value=M?[...M]:[]},{deep:!0});const te=e.computed(()=>l.expandedRows??v.value);function oe(M,x){if(!l.expandable)return!1;const R=k(M,x);return te.value.some((H,X)=>k(H,X)===R)}function z(M,x){if(!l.expandable)return;const R=k(M,x),H=[...te.value],X=H.findIndex((le,ce)=>k(le,ce)===R);X>=0?(H.splice(X,1),v.value=H,n("update:expandedRows",H),n("row-collapse",M)):(H.push(M),v.value=H,n("update:expandedRows",H),n("row-expand",M))}const O=e.ref(l.visibleColumns?[...l.visibleColumns]:l.columns.map(M=>M.key));e.watch(()=>l.visibleColumns,M=>{M!==void 0&&(O.value=[...M])},{deep:!0}),e.watch(()=>l.columns,M=>{l.visibleColumns===void 0&&(O.value=M.map(x=>x.key))});const Z=e.computed(()=>l.visibleColumns??O.value),Y=e.computed(()=>{if(!l.columnToggle)return l.columns;const M=new Set(Z.value);return l.columns.filter(x=>M.has(x.key))}),Q=e.computed(()=>Y.value.length+(g.value?1:0)+(l.expandable?1:0));function q(M){return Z.value.includes(M)}function U(M){const x=[...Z.value],R=x.indexOf(M);if(R>=0){if(x.length<=1)return;x.splice(R,1)}else{const H=l.columns.map(X=>X.key);x.push(M),x.sort((X,le)=>H.indexOf(X)-H.indexOf(le))}O.value=x,n("update:visibleColumns",x)}const J=e.ref(!1),ne=e.ref(null),G=e.ref(null),ee=e.ref({top:0,left:0}),re=e.computed(()=>({position:"fixed",top:`${ee.value.top}px`,left:`${ee.value.left}px`,zIndex:9999}));function ae(){var le;const M=ne.value;if(!M)return;const x=M.getBoundingClientRect(),R=((le=G.value)==null?void 0:le.offsetWidth)||190,H=Math.max(8,Math.min(x.right-R,window.innerWidth-R-8)),X=x.bottom+6;ee.value={top:X,left:H}}function Me(M){var R,H;const x=M.target;x&&((R=ne.value)!=null&&R.contains(x)||(H=G.value)!=null&&H.contains(x)||he())}function me(M){M.key==="Escape"&&he()}function Je(){J.value=!0,e.nextTick(()=>{ae(),document.addEventListener("mousedown",Me),document.addEventListener("keydown",me),window.addEventListener("resize",ae),window.addEventListener("scroll",ae,!0)})}function he(){J.value=!1,document.removeEventListener("mousedown",Me),document.removeEventListener("keydown",me),window.removeEventListener("resize",ae),window.removeEventListener("scroll",ae,!0)}function Qe(){J.value?he():Je()}return e.onBeforeUnmount(()=>{he()}),(M,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["data-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card mfs-overflow-hidden",`data-table--${t.responsiveMode}`])},[t.searchable||t.columnToggle||M.$slots.header?(e.openBlock(),e.createElementBlock("div",Ti,[e.renderSlot(M.$slots,"header",{},void 0,!0),t.searchable||t.columnToggle?(e.openBlock(),e.createElementBlock("div",Li,[t.searchable?(e.openBlock(),e.createElementBlock("div",zi,[x[4]||(x[4]=e.createElementVNode("svg",{class:"data-table__search-icon mfs-absolute mfs-text-muted",viewBox:"0 0 20 20",fill:"none","aria-hidden":"true"},[e.createElementVNode("circle",{cx:"9",cy:"9",r:"6",stroke:"currentColor","stroke-width":"1.8"}),e.createElementVNode("path",{d:"M13.5 13.5L17 17",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round"})],-1)),e.createElementVNode("input",{type:"search",class:"data-table__search-input mfs-inset mfs-rounded-sm mfs-w-full mfs-text-sm mfs-outline-none",value:p.value,placeholder:"Search...","aria-label":"Search table",onInput:y},null,40,Ii)])):e.createCommentVNode("",!0),t.columnToggle?(e.openBlock(),e.createElementBlock("button",{key:1,ref_key:"columnToggleBtnRef",ref:ne,type:"button",class:"data-table__col-btn mfs-focus-ring mfs-surface-subtle mfs-rounded-sm mfs-shadow-inset mfs-text-sm mfs-font-semibold mfs-cursor-pointer mfs-inline-flex mfs-items-center mfs-gap-2","aria-expanded":J.value,"aria-haspopup":"true",onClick:Qe},[...x[5]||(x[5]=[e.createElementVNode("svg",{class:"data-table__col-icon",viewBox:"0 0 18 18",fill:"none","aria-hidden":"true"},[e.createElementVNode("rect",{x:"2.5",y:"3.5",width:"3.5",height:"11",rx:"1",stroke:"currentColor","stroke-width":"1.5"}),e.createElementVNode("rect",{x:"7.25",y:"3.5",width:"3.5",height:"11",rx:"1",stroke:"currentColor","stroke-width":"1.5"}),e.createElementVNode("rect",{x:"12",y:"3.5",width:"3.5",height:"11",rx:"1",stroke:"currentColor","stroke-width":"1.5"})],-1),e.createElementVNode("span",null,"Columns",-1)])],8,Ri)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[t.columnToggle&&J.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"columnMenuRef",ref:G,class:"data-table__col-menu mfs-surface mfs-rounded-md mfs-shadow-card",style:e.normalizeStyle(re.value),role:"menu","aria-label":"Toggle columns"},[x[6]||(x[6]=e.createElementVNode("div",{class:"data-table__col-menu-title mfs-text-xs mfs-font-bold mfs-text-muted"}," Visible Columns ",-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,R=>(e.openBlock(),e.createElementBlock("label",{key:R.key,class:e.normalizeClass(["data-table__col-item mfs-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-cursor-pointer",{"data-table__col-item--disabled":q(R.key)&&Z.value.length<=1}])},[e.createVNode(fe,{"model-value":q(R.key),disabled:q(R.key)&&Z.value.length<=1,"onUpdate:modelValue":H=>U(R.key)},null,8,["model-value","disabled","onUpdate:modelValue"]),e.createElementVNode("span",null,e.toDisplayString(R.label),1)],2))),128))],4)):e.createCommentVNode("",!0)])),e.createElementVNode("div",Pi,[e.createElementVNode("table",Ai,[e.createElementVNode("thead",Fi,[e.createElementVNode("tr",null,[t.expandable?(e.openBlock(),e.createElementBlock("th",ji)):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("th",Ki,[g.value==="multiple"?(e.openBlock(),e.createBlock(fe,{key:0,class:"data-table__checkbox","model-value":I.value,indeterminate:j.value,"aria-label":"Select all rows",onClick:x[0]||(x[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":K},null,8,["model-value","indeterminate"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Y.value,R=>(e.openBlock(),e.createElementBlock("th",{key:R.key,class:e.normalizeClass(["data-table__th mfs-text-muted mfs-whitespace-nowrap",[R.align?`data-table__cell--${R.align}`:"",{"data-table__th--sortable":R.sortable}]]),style:e.normalizeStyle(R.width?{width:R.width}:void 0),"aria-sort":_(R)},[R.sortable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["data-table__sort-btn mfs-focus-ring mfs-inline-flex mfs-items-center mfs-bg-transparent mfs-border-none mfs-cursor-pointer mfs-p-0",{"data-table__sort-btn--active":h(R.key)!==null}]),onClick:H=>$(R.key)},[e.createElementVNode("span",null,e.toDisplayString(R.label),1),(e.openBlock(),e.createElementBlock("svg",Ui,[e.createElementVNode("path",{d:"M8 3L11 6.5H5L8 3Z",fill:h(R.key)==="asc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Wi),e.createElementVNode("path",{d:"M8 13L5 9.5H11L8 13Z",fill:h(R.key)==="desc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Gi)])),t.sortMode==="multiple"&&B(R.key)!==null?(e.openBlock(),e.createElementBlock("span",qi,e.toDisplayString(B(R.key)),1)):e.createCommentVNode("",!0)],10,Hi)):(e.openBlock(),e.createElementBlock("span",Yi,e.toDisplayString(R.label),1))],14,Oi))),128))])]),e.createElementVNode("tbody",Xi,[V.value.length===0?(e.openBlock(),e.createElementBlock("tr",Zi,[e.createElementVNode("td",{colspan:Q.value,class:"data-table__empty mfs-text-muted mfs-text-center"},[e.renderSlot(M.$slots,"empty",{},()=>[e.createElementVNode("div",Qi,[x[7]||(x[7]=e.createElementVNode("svg",{class:"data-table__empty-icon",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true"},[e.createElementVNode("rect",{x:"3",y:"5",width:"18",height:"14",rx:"3",stroke:"currentColor","stroke-width":"1.6"}),e.createElementVNode("path",{d:"M3 10H21",stroke:"currentColor","stroke-width":"1.6"})],-1)),e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])],!0)],8,Ji)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(V.value,(R,H)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:k(R,H)},[e.createElementVNode("tr",{class:e.normalizeClass(["data-table__row",{"data-table__row--selected":T(R,H),"data-table__row--expanded":t.expandable&&oe(R,H)}]),"aria-selected":g.value?T(R,H):void 0,onClick:X=>W(R,H)},[t.expandable?(e.openBlock(),e.createElementBlock("td",{key:0,class:"data-table__td data-table__td--expand","data-label":"Details",onClick:x[1]||(x[1]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("button",{type:"button",class:"data-table__expand-btn mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center mfs-bg-transparent mfs-border-none mfs-cursor-pointer","aria-expanded":oe(R,H),"aria-label":oe(R,H)?`Collapse row ${H+1}`:`Expand row ${H+1}`,onClick:X=>z(R,H)},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["data-table__expand-icon",{"data-table__expand-icon--open":oe(R,H)}]),viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[...x[8]||(x[8]=[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2))],8,ed)])):e.createCommentVNode("",!0),g.value?(e.openBlock(),e.createElementBlock("td",{key:1,class:"data-table__td data-table__td--select","data-label":"Select",onClick:x[3]||(x[3]=e.withModifiers(()=>{},["stop"]))},[g.value==="single"?(e.openBlock(),e.createElementBlock("input",{key:0,type:"radio",class:"data-table__checkbox mfs-cursor-pointer",name:i,checked:T(R,H),"aria-label":`Select row ${H+1}`,onChange:X=>A(R,H)},null,40,td)):(e.openBlock(),e.createBlock(fe,{key:1,class:"data-table__checkbox","model-value":T(R,H),"aria-label":`Select row ${H+1}`,onClick:x[2]||(x[2]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":X=>A(R,H)},null,8,["model-value","aria-label","onUpdate:modelValue"]))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(Y.value,X=>(e.openBlock(),e.createElementBlock("td",{key:X.key,class:e.normalizeClass(["data-table__td",X.align?`data-table__cell--${X.align}`:""]),"data-label":X.label},[e.renderSlot(M.$slots,`cell-${X.key}`,{row:R,value:R[X.key],column:X,index:H},()=>[e.createElementVNode("span",nd,e.toDisplayString(R[X.key]??""),1)],!0)],10,ld))),128))],10,vi),t.expandable&&oe(R,H)?(e.openBlock(),e.createElementBlock("tr",od,[e.createElementVNode("td",{colspan:Q.value,class:"data-table__expansion-cell"},[e.renderSlot(M.$slots,"expansion",{row:R,index:H},void 0,!0)],8,ad)])):e.createCommentVNode("",!0)],64))),128))])])]),t.paginator?(e.openBlock(),e.createElementBlock("div",sd,[t.rowsPerPageOptions.length?(e.openBlock(),e.createElementBlock("label",rd,[x[9]||(x[9]=e.createElementVNode("span",null,"Show",-1)),e.createElementVNode("select",{class:"data-table__per-page-select mfs-surface mfs-rounded-md mfs-shadow-inset mfs-text",value:b.value,disabled:t.loading,"aria-label":"Rows per page",onChange:P},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.rowsPerPageOptions,R=>(e.openBlock(),e.createElementBlock("option",{key:R,value:R},e.toDisplayString(R),9,dd))),128))],40,id),x[10]||(x[10]=e.createElementVNode("span",null,"per page",-1))])):e.createCommentVNode("",!0),e.createVNode(xe,{"model-value":N.value,total:E.value,"per-page":b.value,"per-page-options":[],loading:t.loading,"onUpdate:modelValue":C},null,8,["model-value","total","per-page","loading"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",cd,[e.renderSlot(M.$slots,"loading",{},()=>[x[11]||(x[11]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-b4a35d96"]]),Wt=e.defineComponent({__name:"Column",props:{field:{},header:{},sortable:{type:Boolean},sortField:{},filterField:{},headerStyle:{},bodyStyle:{},headerClass:{},bodyClass:{},style:{},frozen:{type:Boolean},alignFrozen:{},selectionMode:{},expander:{type:Boolean},hidden:{type:Boolean}},setup(t){return(a,l)=>null}});function Be(t,a,l="id"){if(t&&typeof t=="object"&&l in t){const n=t[l];if(typeof n=="string"||typeof n=="number")return n}return a}const md={class:"data-view mfs-relative"},fd={class:"data-view__header"},ud={class:"data-view__header-left"},pd={class:"data-view__toggle mfs-inset mfs-rounded-md",role:"group","aria-label":"View layout"},kd=["aria-pressed"],hd=["aria-pressed"],gd={key:0,class:"data-view__empty mfs-card mfs-text-muted"},yd={class:"data-view__empty-content"},bd={class:"data-view__fallback-card mfs-card"},Bd={key:2,class:"mfs-loading-overlay","aria-busy":"true"},Gt=F(e.defineComponent({__name:"DataView",props:{items:{},layout:{default:"grid"},itemKey:{default:"id"},columns:{},emptyText:{default:"No items found"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},totalRecords:{}},emits:["update:layout","page","sort","filter"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.layout);e.watch(()=>l.layout,c=>{i.value=c});const r=e.computed(()=>i.value),s=e.computed(()=>{if(!(r.value!=="grid"||!l.columns))return{gridTemplateColumns:`repeat(${l.columns}, minmax(0, 1fr))`}});function d(c){i.value!==c&&(i.value=c,n("update:layout",c))}return(c,o)=>(e.openBlock(),e.createElementBlock("div",md,[e.createElementVNode("div",fd,[e.createElementVNode("div",ud,[e.renderSlot(c.$slots,"header",{},void 0,!0)]),e.createElementVNode("div",pd,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["data-view__toggle-btn mfs-rounded-sm",{"data-view__toggle-btn--active mfs-shadow":r.value==="grid"}]),"aria-pressed":r.value==="grid","aria-label":"Grid layout",onClick:o[0]||(o[0]=m=>d("grid"))},[...o[2]||(o[2]=[e.createStaticVNode('<svg viewBox="0 0 18 18" fill="none" aria-hidden="true" data-v-23afce0e><rect x="2" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect><rect x="10" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect><rect x="2" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect><rect x="10" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-23afce0e></rect></svg>',1)])],10,kd),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["data-view__toggle-btn mfs-rounded-sm",{"data-view__toggle-btn--active mfs-shadow":r.value==="list"}]),"aria-pressed":r.value==="list","aria-label":"List layout",onClick:o[1]||(o[1]=m=>d("list"))},[...o[3]||(o[3]=[e.createElementVNode("svg",{viewBox:"0 0 18 18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M3 4.5H15M3 9H15M3 13.5H15",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round"})],-1)])],10,hd)])]),t.items.length===0?(e.openBlock(),e.createElementBlock("div",gd,[e.renderSlot(c.$slots,"empty",{},()=>[e.createElementVNode("div",yd,[o[4]||(o[4]=e.createElementVNode("svg",{class:"data-view__empty-icon",viewBox:"0 0 24 24",fill:"none","aria-hidden":"true"},[e.createElementVNode("rect",{x:"3",y:"4",width:"18",height:"16",rx:"3",stroke:"currentColor","stroke-width":"1.6"}),e.createElementVNode("path",{d:"M8 10H16M8 14H13",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round"})],-1)),e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])],!0)])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["data-view__body",`data-view__body--${r.value}`]),style:e.normalizeStyle(s.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(m,f)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(Be)(m,f,t.itemKey),class:"data-view__item"},[r.value==="grid"&&c.$slots.grid?e.renderSlot(c.$slots,"grid",{item:m,index:f},void 0,!0,0):r.value==="list"&&c.$slots.list?e.renderSlot(c.$slots,"list",{item:m,index:f},void 0,!0,1):e.renderSlot(c.$slots,"default",{item:m,index:f,layout:r.value},()=>[e.createElementVNode("div",bd,e.toDisplayString(m),1)],!0,2)]))),128))],6)),t.loading?(e.openBlock(),e.createElementBlock("div",Bd,[e.renderSlot(c.$slots,"loading",{},()=>[o[5]||(o[5]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-23afce0e"]]),wd=["role"],_d={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ed={key:1,class:"mfs-empty-state"},$d=["aria-expanded","aria-selected","aria-disabled"],Vd=["onClick","onKeydown"],xd=["aria-label","onClick"],Cd={key:1,class:"tree__spacer","aria-hidden":"true"},Nd={key:3,class:"tree__icon","aria-hidden":"true"},Sd={class:"tree__content"},Md={class:"tree__label"},qt=F(e.defineComponent({name:"Tree",__name:"Tree",props:{nodes:{},expandedKeys:{default:()=>[]},selectionMode:{default:"none"},selectedKeys:{default:()=>[]},level:{default:0},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No items found"}},emits:["update:expandedKeys","update:selectedKeys","node-click","node-toggle","lazy-load"],setup(t,{emit:a}){const l=t,n=a;function i(u){return Array.isArray(u.children)&&u.children.length>0}function r(u){return i(u)||l.lazy&&!u.leaf}function s(u){return l.expandedKeys.includes(u)}function d(u){return l.selectedKeys.includes(u)}function c(u){var k;if(!r(u))return;const p=new Set(l.expandedKeys),g=!p.has(u.key);g?(p.add(u.key),l.lazy&&!((k=u.children)!=null&&k.length)&&n("lazy-load",u)):p.delete(u.key),n("update:expandedKeys",Array.from(p)),n("node-toggle",u,g)}function o(u){r(u)&&!s(u.key)&&c(u)}function m(u){r(u)&&s(u.key)&&c(u)}function f(u){if(u.disabled||l.selectionMode==="none")return;if(l.selectionMode==="single"){n("update:selectedKeys",d(u.key)?[]:[u.key]);return}const p=new Set(l.selectedKeys);p.has(u.key)?p.delete(u.key):p.add(u.key),n("update:selectedKeys",Array.from(p))}function b(u){u.disabled||(n("node-click",u),l.selectionMode!=="none"?f(u):r(u)&&c(u))}return(u,p)=>{const g=e.resolveComponent("Tree",!0);return e.openBlock(),e.createElementBlock("ul",{class:e.normalizeClass(["tree",{"tree--root mfs-surface mfs-rounded mfs-shadow-card":t.level===0}]),role:t.level===0?"tree":"group"},[t.level===0&&t.loading?(e.openBlock(),e.createElementBlock("li",_d,[e.renderSlot(u.$slots,"loading",{},()=>[p[6]||(p[6]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.level===0&&!t.loading&&t.nodes.length===0?(e.openBlock(),e.createElementBlock("li",Ed,[e.renderSlot(u.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.nodes,k=>(e.openBlock(),e.createElementBlock("li",{key:k.key,class:"tree__item",role:"treeitem","aria-expanded":r(k)?s(k.key):void 0,"aria-selected":t.selectionMode!=="none"?d(k.key):void 0,"aria-disabled":k.disabled||void 0},[e.createElementVNode("div",{class:e.normalizeClass(["tree__row mfs-rounded-sm mfs-focus-ring",{"tree__row--selected":d(k.key),"tree__row--disabled mfs-disabled":k.disabled}]),style:e.normalizeStyle({paddingLeft:`${t.level*20+8}px`}),tabindex:"0",onClick:y=>b(k),onKeydown:[e.withKeys(e.withModifiers(y=>b(k),["prevent"]),["enter"]),e.withKeys(e.withModifiers(y=>b(k),["prevent"]),["space"]),e.withKeys(e.withModifiers(y=>o(k),["prevent"]),["right"]),e.withKeys(e.withModifiers(y=>m(k),["prevent"]),["left"])]},[r(k)?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree__toggle mfs-text-muted",{"tree__toggle--expanded":s(k.key)}]),"aria-label":s(k.key)?`Collapse ${k.label}`:`Expand ${k.label}`,tabindex:"-1",onClick:e.withModifiers(y=>c(k),["stop"])},[...p[7]||(p[7]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,xd)):(e.openBlock(),e.createElementBlock("span",Cd)),t.selectionMode==="checkbox"?(e.openBlock(),e.createBlock(fe,{key:2,class:"tree__checkbox","model-value":d(k.key),disabled:k.disabled,"aria-label":`Select ${k.label}`,tabindex:-1,onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":y=>f(k)},null,8,["model-value","disabled","aria-label","onUpdate:modelValue"])):e.createCommentVNode("",!0),k.icon?(e.openBlock(),e.createElementBlock("span",Nd,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Sd,[e.renderSlot(u.$slots,"node",{node:k,expanded:s(k.key),selected:d(k.key),level:t.level},()=>[e.createElementVNode("span",Md,e.toDisplayString(k.label),1)],!0)])],46,Vd),i(k)&&s(k.key)?(e.openBlock(),e.createBlock(g,{key:0,nodes:k.children,"expanded-keys":t.expandedKeys,"selection-mode":t.selectionMode,"selected-keys":t.selectedKeys,lazy:t.lazy,level:t.level+1,"onUpdate:expandedKeys":p[1]||(p[1]=y=>u.$emit("update:expandedKeys",y)),"onUpdate:selectedKeys":p[2]||(p[2]=y=>u.$emit("update:selectedKeys",y)),onNodeClick:p[3]||(p[3]=y=>u.$emit("node-click",y)),onNodeToggle:p[4]||(p[4]=(y,h)=>u.$emit("node-toggle",y,h)),onLazyLoad:p[5]||(p[5]=y=>u.$emit("lazy-load",y))},e.createSlots({_:2},[u.$slots.node?{name:"node",fn:e.withCtx(y=>[e.renderSlot(u.$slots,"node",e.mergeProps({ref_for:!0},y),void 0,!0)]),key:"0"}:void 0]),1032,["nodes","expanded-keys","selection-mode","selected-keys","lazy","level"])):e.createCommentVNode("",!0)],8,$d))),128))],10,wd)}}}),[["__scopeId","data-v-0e17bf40"]]),Dd={class:"ac-box mfs-surface mfs-rounded mfs-shadow-inset"},Td=["aria-expanded","value","placeholder","disabled"],Ld={key:0,class:"ac-spinner","aria-hidden":"true"},zd=["aria-selected","onMousedown","onMouseenter"],Id={key:0,class:"mfs-empty-state",role:"status"},Yt=F(e.defineComponent({__name:"AutoComplete",props:{modelValue:{default:""},suggestions:{default:()=>[]},label:{},placeholder:{default:"Type to search..."},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},minLength:{default:1},remote:{type:Boolean,default:!1},emptyText:{default:"No results found"}},emits:["update:modelValue","complete","select"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-ac-${e.useId()}`,r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(!1),o=e.ref(-1),{overlayStyle:m,containsTarget:f}=de(s,d,c,{matchWidth:!0}),b=e.computed(()=>{const B=l.suggestions.map(_=>typeof _=="string"?{label:_,value:_}:_);if(l.remote)return B;const $=(l.modelValue||"").toLowerCase();return B.filter(_=>!$||_.label.toLowerCase().includes($))}),u=e.computed(()=>(l.modelValue||"").length>=l.minLength&&!l.loading&&b.value.length===0),p=B=>{const $=B.target.value;n("update:modelValue",$),$.length>=l.minLength?(n("complete",{query:$}),c.value=!0,o.value=-1):c.value=!1},g=()=>{(l.modelValue||"").length>=l.minLength&&(b.value.length||!l.loading)&&(c.value=!0)},k=B=>{n("update:modelValue",B.label),n("select",B),c.value=!1},y=B=>{if(c.value){if(B.key==="Escape")c.value=!1;else if(B.key==="ArrowDown")B.preventDefault(),b.value.length&&(o.value=(o.value+1)%b.value.length);else if(B.key==="ArrowUp")B.preventDefault(),b.value.length&&(o.value=(o.value-1+b.value.length)%b.value.length);else if(B.key==="Enter"&&o.value>=0){B.preventDefault();const $=b.value[o.value];$&&k($)}}},h=B=>{f(B.target)||(c.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",h)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",h)),(B,$)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:r,class:e.normalizeClass(["ac-wrapper",{"ac-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:i,class:"ac-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:s,class:"ac-container"},[e.createElementVNode("div",Dd,[e.createElementVNode("input",{id:i,type:"text",role:"combobox","aria-expanded":c.value,"aria-autocomplete":"list",value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,class:"ac-input mfs-text",onInput:p,onFocus:g,onKeydown:y},null,40,Td),t.loading?(e.openBlock(),e.createElementBlock("span",Ld)):e.createCommentVNode("",!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ac-pop"},{default:e.withCtx(()=>[c.value&&(b.value.length||u.value)?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:d,role:"listbox",style:e.normalizeStyle(e.unref(m)),class:"ac-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(_,D)=>(e.openBlock(),e.createElementBlock("li",{key:_.label+D,role:"option","aria-selected":D===o.value,class:e.normalizeClass(["ac-option mfs-text",{"ac-option--active":D===o.value}]),onMousedown:e.withModifiers(S=>k(_),["prevent"]),onMouseenter:S=>o.value=D},e.toDisplayString(_.label),43,zd))),128)),u.value?(e.openBlock(),e.createElementBlock("li",Id,[e.renderSlot(B.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:3})]))],512)],2))}}),[["__scopeId","data-v-e5421cb2"]]),Rd={key:0,class:"cas-label mfs-text"},Pd={class:"cas-container"},Ad=["disabled","aria-expanded"],Fd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},jd={key:0,class:"cas-col"},Kd={key:1,class:"cas-col"},Od={class:"mfs-empty-state"},Hd=["disabled","onClick"],Ud={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Wd={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Gd={key:0,class:"cas-col"},He=F(e.defineComponent({__name:"Cascader",props:{modelValue:{default:()=>[]},options:{default:()=>[]},label:{},placeholder:{default:"Select..."},separator:{default:" / "},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:6}),o=e.ref([...l.modelValue]);e.watch(()=>l.modelValue,g=>{o.value=[...g||[]]});const m=e.computed(()=>{const g=[];let k=l.options,y=0;for(;k&&k.length;){g.push(k);const h=o.value[y],B=k.find($=>$.value===h);k=B==null?void 0:B.children,y++}return g}),f=e.computed(()=>{const g=[];let k=l.options;for(const y of l.modelValue||[]){const h=k==null?void 0:k.find(B=>B.value===y);if(!h)break;g.push(h.label),k=h.children}return g.join(l.separator)}),b=(g,k)=>{var h,B;if(k.disabled)return;const y=[...o.value.slice(0,g),k.value];if(o.value=y,l.lazy&&!k.isLeaf&&!((h=k.children)!=null&&h.length)){n("lazy-load",k);return}(B=k.children)!=null&&B.length||(n("update:modelValue",y),n("change",y),s.value=!1)},u=g=>{c(g.target)||(s.value=!1)},p=g=>{g.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",u),document.addEventListener("keydown",p)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",u),document.removeEventListener("keydown",p)}),(g,k)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cas-wrapper",{"cas-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",Rd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Pd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"cas-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":s.value,onClick:k[0]||(k[0]=y=>s.value=!s.value)},[e.createElementVNode("span",{class:e.normalizeClass(["cas-value",{"mfs-text-muted":!f.value}])},e.toDisplayString(f.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",Fd)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["cas-chevron",{"cas-chevron--open":s.value}])},[...k[1]||(k[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,Ad),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cas-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"cas-panel mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading&&m.value.length===0?(e.openBlock(),e.createElementBlock("div",jd,[e.renderSlot(g.$slots,"loading",{},()=>[k[2]||(k[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):m.value.length===0?(e.openBlock(),e.createElementBlock("div",Kd,[e.createElementVNode("div",Od,[e.renderSlot(g.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(y,h)=>(e.openBlock(),e.createElementBlock("div",{key:h,class:"cas-col"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y,B=>{var $;return e.openBlock(),e.createElementBlock("button",{key:String(B.value),type:"button",class:e.normalizeClass(["cas-item mfs-text",{"cas-item--active":o.value[h]===B.value}]),disabled:B.disabled,onClick:_=>b(h,B)},[e.createElementVNode("span",null,e.toDisplayString(B.label),1),B.loading?(e.openBlock(),e.createElementBlock("span",Ud)):($=B.children)!=null&&$.length||t.lazy&&!B.isLeaf?(e.openBlock(),e.createElementBlock("svg",Wd,[...k[3]||(k[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Hd)}),128))]))),128)),t.loading?(e.openBlock(),e.createElementBlock("div",Gd,[e.renderSlot(g.$slots,"loading",{},()=>[k[4]||(k[4]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-63dca0d2"]]),qd={key:0,class:"ts-label mfs-text"},Yd={class:"ts-container"},Xd=["disabled","aria-expanded"],Zd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Jd={key:1,class:"mfs-empty-state"},Qd=["aria-selected"],vd=["aria-label","onClick"],ec={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},tc={key:1,class:"ts-expand-spacer"},lc=["disabled","onClick"],nc={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round"},Xt=F(e.defineComponent({__name:"TreeSelect",props:{modelValue:{default:null},options:{default:()=>[]},multiple:{type:Boolean,default:!1},label:{},placeholder:{default:"Select node..."},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No options found"}},emits:["update:modelValue","change","lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),{overlayStyle:d,containsTarget:c}=de(i,r,s,{offset:6,matchWidth:!0}),o=e.reactive(new Set),m=h=>{var B;o.has(h.value)?o.delete(h.value):(o.add(h.value),l.lazy&&!h.isLeaf&&!((B=h.children)!=null&&B.length)&&n("lazy-load",h))},f=e.computed(()=>{const h=[],B=($,_)=>{var D;for(const S of $)h.push({node:S,depth:_}),(D=S.children)!=null&&D.length&&o.has(S.value)&&B(S.children,_+1)};return B(l.options,0),h}),b=e.computed(()=>{const h=new Map,B=$=>{var _;for(const D of $)h.set(D.value,D.label),(_=D.children)!=null&&_.length&&B(D.children)};return B(l.options),h}),u=e.computed(()=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.map(h=>b.value.get(h)??String(h)).join(", "):l.modelValue===null||l.modelValue===void 0?"":b.value.get(l.modelValue)??String(l.modelValue)),p=h=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(h):l.modelValue===h,g=h=>{if(!h.disabled)if(l.multiple){const B=Array.isArray(l.modelValue)?l.modelValue:[],$=B.includes(h.value)?B.filter(_=>_!==h.value):[...B,h.value];n("update:modelValue",$),n("change",$)}else n("update:modelValue",h.value),n("change",h.value),s.value=!1},k=h=>{c(h.target)||(s.value=!1)},y=h=>{h.key==="Escape"&&(s.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",k),document.addEventListener("keydown",y)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",k),document.removeEventListener("keydown",y)}),(h,B)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["ts-wrapper",{"ts-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",qd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Yd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:i,type:"button",class:"ts-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":s.value,onClick:B[0]||(B[0]=$=>s.value=!s.value)},[e.createElementVNode("span",{class:e.normalizeClass(["ts-value",{"mfs-text-muted":!u.value}])},e.toDisplayString(u.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",Zd)):e.createCommentVNode("",!0),(e.openBlock(),e.createElementBlock("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round",class:e.normalizeClass(["ts-chevron",{"ts-chevron--open":s.value}])},[...B[1]||(B[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,Xd),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ts-pop"},{default:e.withCtx(()=>[s.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(d)),class:"ts-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow",role:"tree"},[t.loading&&f.value.length===0?e.renderSlot(h.$slots,"loading",{},()=>[B[2]||(B[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0,0):f.value.length===0?(e.openBlock(),e.createElementBlock("div",Jd,[e.renderSlot(h.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,$=>{var _;return e.openBlock(),e.createElementBlock("div",{key:String($.node.value),role:"treeitem","aria-selected":p($.node.value),class:"ts-row",style:e.normalizeStyle({paddingLeft:`${8+$.depth*18}px`})},[(_=$.node.children)!=null&&_.length||t.lazy&&!$.node.isLeaf?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"ts-expand mfs-text-muted","aria-label":o.has($.node.value)?"Collapse":"Expand",onClick:e.withModifiers(D=>m($.node),["stop"])},[$.node.loading?(e.openBlock(),e.createElementBlock("span",ec)):(e.openBlock(),e.createElementBlock("svg",{key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round",style:e.normalizeStyle({transform:o.has($.node.value)?"rotate(90deg)":""})},[...B[3]||(B[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])],4))],8,vd)):(e.openBlock(),e.createElementBlock("span",tc)),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["ts-node mfs-text",{"ts-node--selected":p($.node.value)}]),disabled:$.node.disabled,onClick:D=>g($.node)},[e.createElementVNode("span",null,e.toDisplayString($.node.label),1),p($.node.value)?(e.openBlock(),e.createElementBlock("svg",nc,[...B[4]||(B[4]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],10,lc)],12,Qd)}),128)),t.loading?e.renderSlot(h.$slots,"loading",{},void 0,!0,0):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-2741eadc"]]),oc=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],ac=["viewBox","width","height"],sc=["d","stroke-width"],rc=["d","stroke-width"],ic={class:"knob-value mfs-text mfs-font-mono"},dc={key:0,class:"knob-label mfs-caption"},Zt=F(e.defineComponent({__name:"Knob",props:{modelValue:{default:0},min:{default:0},max:{default:100},step:{default:1},size:{default:112},strokeWidth:{default:10},valueTemplate:{default:"{value}"},label:{},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(!1),s=e.computed(()=>l.size/2),d=e.computed(()=>l.size/2-l.strokeWidth-4),c=B=>{const $=(B-90)*Math.PI/180;return{x:s.value+d.value*Math.cos($),y:s.value+d.value*Math.sin($)}},o=(B,$)=>{const _=c($),D=c(B),S=$-B<=180?"0":"1";return`M ${_.x} ${_.y} A ${d.value} ${d.value} 0 ${S} 0 ${D.x} ${D.y}`},m=e.computed(()=>{const B=l.max-l.min;return B<=0?0:Math.max(0,Math.min(1,(l.modelValue-l.min)/B))}),f=e.computed(()=>o(225,495)),b=e.computed(()=>{const B=225+m.value*270;return B<=225.1?"":o(225,B)}),u=e.computed(()=>l.valueTemplate.replace("{value}",String(l.modelValue))),p=(B,$)=>{var P;const _=(P=i.value)==null?void 0:P.getBoundingClientRect();if(!_)return;const D=_.left+_.width/2,S=_.top+_.height/2;let E=Math.atan2($-S,B-D)*180/Math.PI+90;E<0&&(E+=360);let w=E>=225?E-225:E<=135?E+135:E<180?270:0;w=Math.max(0,Math.min(270,w));const N=l.min+w/270*(l.max-l.min),V=Math.round((N-l.min)/l.step)*l.step+l.min,C=Math.max(l.min,Math.min(l.max,Number(V.toFixed(6))));n("update:modelValue",C)},g=B=>{r.value&&p(B.clientX,B.clientY)},k=()=>{r.value&&(r.value=!1,n("change",l.modelValue)),window.removeEventListener("pointermove",g),window.removeEventListener("pointerup",k)},y=B=>{l.disabled||l.readonly||(B.preventDefault(),r.value=!0,p(B.clientX,B.clientY),window.addEventListener("pointermove",g),window.addEventListener("pointerup",k))},h=B=>{if(l.disabled||l.readonly)return;const $=B.key==="ArrowRight"||B.key==="ArrowUp"?l.step:B.key==="ArrowLeft"||B.key==="ArrowDown"?-l.step:0;if(!$)return;B.preventDefault();const _=Math.max(l.min,Math.min(l.max,l.modelValue+$));n("update:modelValue",_),n("change",_)};return e.onBeforeUnmount(k),(B,$)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["knob-wrapper",{"knob-wrapper--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("div",{ref_key:"svgBoxRef",ref:i,role:"slider",tabindex:"0",class:"knob-control mfs-surface mfs-shadow mfs-focus-ring",style:e.normalizeStyle({width:`${t.size}px`,height:`${t.size}px`}),"aria-valuemin":t.min,"aria-valuemax":t.max,"aria-valuenow":t.modelValue,"aria-label":t.label||"Knob",onPointerdown:y,onKeydown:h},[(e.openBlock(),e.createElementBlock("svg",{viewBox:`0 0 ${t.size} ${t.size}`,width:t.size,height:t.size},[e.createElementVNode("path",{d:f.value,fill:"none",stroke:"var(--surface-subtle, rgba(148,163,184,0.28))","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,sc),e.createElementVNode("path",{d:b.value,fill:"none",stroke:"var(--primary)","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,rc)],8,ac)),e.createElementVNode("span",ic,e.toDisplayString(u.value),1)],44,oc),t.label?(e.openBlock(),e.createElementBlock("span",dc,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4399dd45"]]),cc=["disabled","aria-pressed","onClick"],Jt=F(e.defineComponent({__name:"SelectButton",props:{modelValue:{},options:{default:()=>[]},multiple:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.computed(()=>l.options.map(d=>typeof d=="string"?{label:d,value:d}:d)),r=d=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(d):l.modelValue===d,s=d=>{if(!(l.disabled||d.disabled))if(l.multiple){const c=Array.isArray(l.modelValue)?l.modelValue:[],o=c.includes(d.value)?c.filter(m=>m!==d.value):[...c,d.value];n("update:modelValue",o),n("change",o)}else n("update:modelValue",d.value),n("change",d.value)};return(d,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["sb-group mfs-surface mfs-rounded mfs-shadow-inset",{"sb-group--disabled mfs-disabled":t.disabled}]),role:"group"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(o,m)=>(e.openBlock(),e.createElementBlock("button",{key:String(o.value)+m,type:"button",class:e.normalizeClass(["sb-btn mfs-text mfs-focus-ring",{"sb-btn--active mfs-shadow":r(o.value)}]),disabled:t.disabled||o.disabled,"aria-pressed":r(o.value),onClick:f=>s(o)},e.toDisplayString(o.label),11,cc))),128))],2))}}),[["__scopeId","data-v-04586dfe"]]),mc=["aria-pressed","disabled"],Qt=F(e.defineComponent({__name:"ToggleButton",props:{modelValue:{type:Boolean,default:!1},onLabel:{default:"On"},offLabel:{default:"Off"},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=()=>{if(l.disabled)return;const r=!l.modelValue;n("update:modelValue",r),n("change",r)};return(r,s)=>(e.openBlock(),e.createElementBlock("button",{type:"button",class:e.normalizeClass(["tb-btn mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-text mfs-focus-ring",{"tb-btn--active mfs-border-primary":t.modelValue}]),"aria-pressed":t.modelValue,disabled:t.disabled,onClick:i},[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.modelValue?t.onLabel:t.offLabel),1)],!0)],10,mc))}}),[["__scopeId","data-v-701ced8e"]]),fc=["type","inputmode","value","disabled","aria-label","onInput","onKeydown","onPaste"],vt=F(e.defineComponent({__name:"InputOtp",props:{modelValue:{default:""},length:{default:4},mask:{type:Boolean,default:!1},integerOnly:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","complete"],setup(t,{emit:a}){const l=t,n=a,i=e.ref([]),r=(f,b)=>{i.value[b]=f},s=e.computed(()=>Array.from({length:l.length},(f,b)=>l.modelValue[b]??"")),d=f=>{const b=f.join("").slice(0,l.length);n("update:modelValue",b),b.length===l.length&&!f.includes("")&&n("complete",b)},c=(f,b)=>{var k;const p=b.target.value.slice(-1);if(l.integerOnly&&p&&!/^\d$/.test(p)){b.target.value=s.value[f];return}const g=[...s.value];g[f]=p,d(g),p&&f<l.length-1&&((k=i.value[f+1])==null||k.focus())},o=(f,b)=>{var u,p,g;b.key==="Backspace"&&!s.value[f]&&f>0?(u=i.value[f-1])==null||u.focus():b.key==="ArrowLeft"&&f>0?(b.preventDefault(),(p=i.value[f-1])==null||p.focus()):b.key==="ArrowRight"&&f<l.length-1&&(b.preventDefault(),(g=i.value[f+1])==null||g.focus())},m=(f,b)=>{var y,h;b.preventDefault();const u=((y=b.clipboardData)==null?void 0:y.getData("text"))??"",p=l.integerOnly?u.replace(/\D/g,""):u;if(!p)return;const g=[...s.value];for(let B=0;B<p.length&&f+B<l.length;B++)g[f+B]=p[B];d(g);const k=Math.min(l.length-1,f+p.length);(h=i.value[k])==null||h.focus()};return(f,b)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["otp-wrapper",{"otp-wrapper--disabled mfs-disabled":t.disabled}]),role:"group","aria-label":"One-time password"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.length,u=>(e.openBlock(),e.createElementBlock("input",{key:u,ref_for:!0,ref:p=>r(p,u-1),type:t.mask?"password":"text",inputmode:t.integerOnly?"numeric":"text",maxlength:"1",value:s.value[u-1],disabled:t.disabled,"aria-label":`Digit ${u} of ${t.length}`,class:"otp-cell mfs-surface mfs-rounded mfs-shadow-inset mfs-text mfs-font-mono",onInput:p=>c(u-1,p),onKeydown:p=>o(u-1,p),onPaste:p=>m(u-1,p)},null,40,fc))),128))],2))}}),[["__scopeId","data-v-8fabd2c1"]]),uc={class:"mask-box mfs-surface mfs-rounded mfs-shadow-inset"},pc=["value","placeholder","disabled"],el=F(e.defineComponent({__name:"InputMask",props:{modelValue:{default:""},mask:{},label:{},placeholder:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-mask-${e.useId()}`,r=(c,o)=>c==="9"?/^\d$/.test(o):c==="a"?/^[a-zA-Z]$/.test(o):c==="*"?/^[a-zA-Z0-9]$/.test(o):!1,s=c=>{const o=c.split("");let m="",f=0;for(let b=0;b<l.mask.length&&f<o.length;b++){const u=l.mask[b];if(u==="9"||u==="a"||u==="*"){for(;f<o.length&&!r(u,o[f]);)f++;f<o.length&&(m+=o[f],f++)}else m+=u,o[f]===u&&f++}return m},d=c=>{const o=c.target,m=s(o.value);o.value=m,n("update:modelValue",m)};return(c,o)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mask-wrapper",{"mask-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:i,class:"mask-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",uc,[e.createElementVNode("input",{id:i,type:"text",value:t.modelValue,placeholder:t.placeholder||t.mask,disabled:t.disabled,class:"mask-input mfs-text mfs-font-mono",onInput:d},null,40,pc)])],2))}}),[["__scopeId","data-v-1b5c5774"]]),kc={},hc={class:"ig-wrapper mfs-surface mfs-rounded mfs-shadow-inset"};function gc(t,a){return e.openBlock(),e.createElementBlock("div",hc,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const tl=F(kc,[["render",gc],["__scopeId","data-v-3f9e9407"]]),yc={},bc={class:"ig-addon mfs-inline-flex mfs-items-center mfs-justify-center mfs-whitespace-nowrap mfs-text-muted mfs-text-sm mfs-font-semibold"};function Bc(t,a){return e.openBlock(),e.createElementBlock("span",bc,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const ll=F(yc,[["render",Bc],["__scopeId","data-v-06440459"]]),wc={key:0,class:"icon-field__icon mfs-text-muted","aria-hidden":"true"},nl=F(e.defineComponent({__name:"IconField",props:{iconPosition:{default:"left"},fluid:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["icon-field",[`icon-field--${t.iconPosition}`,{"icon-field--fluid":t.fluid}]])},[a.$slots.icon?(e.openBlock(),e.createElementBlock("span",wc,[e.renderSlot(a.$slots,"icon",{},void 0,!0)])):e.createCommentVNode("",!0),e.renderSlot(a.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-aafeb221"]]),_c={},Ec={class:"input-icon mfs-inline-flex mfs-items-center mfs-justify-center mfs-text-muted","aria-hidden":"true"};function $c(t,a){return e.openBlock(),e.createElementBlock("span",Ec,[e.renderSlot(t.$slots,"default")])}const ol=F(_c,[["render",$c]]),Vc={key:0,class:"lb-filter-box"},xc=["disabled"],Cc=["aria-multiselectable"],Nc=["aria-selected","onClick","onKeydown"],Sc={key:0,viewBox:"0 0 24 24",width:"15",height:"15",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round"},Mc={key:0,class:"lb-empty mfs-text-muted"},al=F(e.defineComponent({__name:"Listbox",props:{modelValue:{},options:{default:()=>[]},multiple:{type:Boolean,default:!1},filter:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(""),r=e.computed(()=>l.options.map(o=>typeof o=="string"?{label:o,value:o}:o)),s=e.computed(()=>{const o=i.value.trim().toLowerCase();return o?r.value.filter(m=>m.label.toLowerCase().includes(o)):r.value}),d=o=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(o):l.modelValue===o,c=o=>{if(!(l.disabled||o.disabled))if(l.multiple){const m=Array.isArray(l.modelValue)?l.modelValue:[],f=m.includes(o.value)?m.filter(b=>b!==o.value):[...m,o.value];n("update:modelValue",f),n("change",f)}else n("update:modelValue",o.value),n("change",o.value)};return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["lb-wrapper mfs-surface mfs-rounded mfs-shadow",{"lb-wrapper--disabled mfs-disabled":t.disabled}])},[t.filter?(e.openBlock(),e.createElementBlock("div",Vc,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":m[0]||(m[0]=f=>i.value=f),type:"text",class:"lb-filter mfs-inset mfs-text",placeholder:"Filter...",disabled:t.disabled},null,8,xc),[[e.vModelText,i.value]])])):e.createCommentVNode("",!0),e.createElementVNode("ul",{role:"listbox","aria-multiselectable":t.multiple,class:"lb-list"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(f,b)=>(e.openBlock(),e.createElementBlock("li",{key:String(f.value)+b,role:"option","aria-selected":d(f.value),class:e.normalizeClass(["lb-item mfs-text mfs-focus-ring",{"lb-item--selected":d(f.value),"lb-item--disabled":f.disabled}]),tabindex:"0",onClick:u=>c(f),onKeydown:[e.withKeys(e.withModifiers(u=>c(f),["prevent"]),["enter"]),e.withKeys(e.withModifiers(u=>c(f),["prevent"]),["space"])]},[e.createElementVNode("span",null,e.toDisplayString(f.label),1),d(f.value)?(e.openBlock(),e.createElementBlock("svg",Sc,[...m[1]||(m[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],42,Nc))),128)),s.value.length===0?(e.openBlock(),e.createElementBlock("li",Mc,"No options")):e.createCommentVNode("",!0)],8,Cc)],2))}}),[["__scopeId","data-v-57e05a19"]]),Dc=["for"],sl=F(e.defineComponent({__name:"FloatLabel",props:{label:{},forId:{},active:{type:Boolean}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["fl-wrapper",{"fl-wrapper--active":t.active}])},[e.renderSlot(a.$slots,"default",{},void 0,!0),t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"fl-label mfs-text-muted"},e.toDisplayString(t.label),9,Dc)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-62e5b422"]]),Tc={class:"ifta-wrapper mfs-surface mfs-rounded mfs-shadow-inset"},Lc=["for"],zc={class:"ifta-control"},rl=F(e.defineComponent({__name:"IftaLabel",props:{label:{},forId:{}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",Tc,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"ifta-label mfs-text-muted"},e.toDisplayString(t.label),9,Lc)):e.createCommentVNode("",!0),e.createElementVNode("div",zc,[e.renderSlot(a.$slots,"default",{},void 0,!0)])]))}}),[["__scopeId","data-v-795e4d1e"]]),Ic={key:0,class:"ed-toolbar mfs-surface-subtle",role:"toolbar","aria-label":"Formatting"},Rc=["contenteditable","data-placeholder"],il=F(e.defineComponent({__name:"Editor",props:{modelValue:{default:""},placeholder:{default:"Write something..."},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},minHeight:{default:"140px"}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=o=>{const m=nt(o);!i.value||i.value.innerHTML===m||i.value.replaceChildren(...jt(m))};e.onMounted(()=>r(l.modelValue)),e.watch(()=>l.modelValue,o=>r(o));const s=()=>{i.value&&n("update:modelValue",nt(i.value.innerHTML))},d=o=>{var f,b;if(l.disabled||l.readonly)return;o.preventDefault();const m=(f=o.clipboardData)==null?void 0:f.getData("text/html");if(m)document.execCommand("insertHTML",!1,nt(m));else{const u=((b=o.clipboardData)==null?void 0:b.getData("text/plain"))??"";document.execCommand("insertText",!1,u)}s()},c=o=>{var m;l.disabled||l.readonly||((m=i.value)==null||m.focus(),document.execCommand(o,!1),s())};return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["ed-wrapper mfs-surface mfs-rounded mfs-shadow-inset",{"ed-wrapper--disabled mfs-disabled":t.disabled}])},[t.readonly?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",Ic,[e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bold","aria-label":"Bold",onMousedown:m[0]||(m[0]=e.withModifiers(f=>c("bold"),["prevent"]))},[...m[7]||(m[7]=[e.createElementVNode("strong",null,"B",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Italic","aria-label":"Italic",onMousedown:m[1]||(m[1]=e.withModifiers(f=>c("italic"),["prevent"]))},[...m[8]||(m[8]=[e.createElementVNode("em",null,"I",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Underline","aria-label":"Underline",onMousedown:m[2]||(m[2]=e.withModifiers(f=>c("underline"),["prevent"]))},[...m[9]||(m[9]=[e.createElementVNode("u",null,"U",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Strikethrough","aria-label":"Strikethrough",onMousedown:m[3]||(m[3]=e.withModifiers(f=>c("strikeThrough"),["prevent"]))},[...m[10]||(m[10]=[e.createElementVNode("s",null,"S",-1)])],32),m[11]||(m[11]=e.createElementVNode("span",{class:"ed-sep"},null,-1)),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bullet List","aria-label":"Bullet List",onMousedown:m[4]||(m[4]=e.withModifiers(f=>c("insertUnorderedList"),["prevent"]))}," • List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Numbered List","aria-label":"Numbered List",onMousedown:m[5]||(m[5]=e.withModifiers(f=>c("insertOrderedList"),["prevent"]))}," 1. List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text-muted",title:"Clear Formatting","aria-label":"Clear Formatting",onMousedown:m[6]||(m[6]=e.withModifiers(f=>c("removeFormat"),["prevent"]))}," Clear ",32)])),e.createElementVNode("div",{ref_key:"editorRef",ref:i,class:"ed-content mfs-text",contenteditable:!t.disabled&&!t.readonly,"data-placeholder":t.placeholder,style:e.normalizeStyle({minHeight:t.minHeight}),role:"textbox","aria-multiline":"true",onInput:s,onPaste:d},null,44,Rc)],2))}}),[["__scopeId","data-v-b6f2ee62"]]);/**
|
|
2
2
|
* @license lucide-vue-next v0.460.0 - ISC
|
|
3
3
|
*
|
|
4
4
|
* This source code is licensed under the ISC license.
|
|
@@ -30,4 +30,4 @@
|
|
|
30
30
|
* See the LICENSE file in the root directory of this source tree.
|
|
31
31
|
*/const jc=dl("CopyIcon",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]),Kc={class:"mfs-code-editor__header"},Oc={key:0,class:"mfs-code-editor__tabs",role:"tablist","aria-label":"Code editor files"},Hc=["aria-selected","onClick"],Uc={key:1,class:"mfs-code-editor__tabs"},Wc={key:0,class:"mfs-code-editor__tab mfs-code-editor__tab--active mfs-code-editor__tab--single mfs-font-mono"},Gc={class:"mfs-code-editor__actions"},qc={class:"mfs-code-editor__lang-pill mfs-font-mono"},Yc=["aria-label","title"],Xc={key:0,class:"mfs-code-editor__gutter mfs-font-mono","aria-hidden":"true"},Zc={class:"mfs-code-editor__stage"},Jc=["aria-hidden"],Qc={class:"mfs-code-editor__code"},vc=["value","disabled","placeholder","maxlength","aria-invalid","onKeydown"],em={class:"mfs-code-editor__footer mfs-font-mono"},tm={class:"mfs-code-editor__status-group"},lm={class:"mfs-code-editor__status-group"},nm={class:"mfs-code-editor__mode-badge"},cl=F(e.defineComponent({__name:"CodeEditor",props:{modelValue:{default:""},language:{default:"vue"},filename:{},tabs:{},activeTab:{default:0},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},lineNumbers:{type:Boolean,default:!0},copyable:{type:Boolean,default:!0},placeholder:{default:"Write code here..."},minHeight:{default:"180px"},maxHeight:{default:"420px"},maxLength:{},tabSize:{default:2},invalid:{type:Boolean,default:!1}},emits:["update:modelValue","update:tabs","update:activeTab","tab-change","change","focus","blur","copy"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(!1),d=e.ref(!1),c=e.ref(l.activeTab);let o=null;e.watch(()=>l.activeTab,z=>{c.value=z});const m=e.computed(()=>!!(l.tabs&&l.tabs.length>0)),f=e.computed(()=>!m.value||!l.tabs?0:Math.min(Math.max(0,c.value),l.tabs.length-1)),b=e.computed(()=>m.value&&l.tabs?l.tabs[f.value]:void 0),u=e.computed(()=>{var z;return m.value?((z=b.value)==null?void 0:z.code)??"":l.modelValue??""}),p=e.computed(()=>{var z;return m.value?((z=b.value)==null?void 0:z.language)??l.language:l.language}),g=e.computed(()=>{var z,O;return m.value?((z=b.value)==null?void 0:z.filename)||((O=b.value)==null?void 0:O.label):l.filename}),k=e.computed(()=>{var z;return m.value?((z=b.value)==null?void 0:z.readonly)??l.readonly:l.readonly}),y=e.computed(()=>u.value.split(`
|
|
32
32
|
`)),h=e.computed(()=>Math.max(1,y.value.length)),B=e.computed(()=>u.value.length),$=new Set(["as","async","await","break","case","catch","class","const","continue","debugger","default","delete","do","else","enum","export","extends","false","finally","for","from","function","if","implements","import","in","instanceof","interface","let","new","null","of","package","private","protected","public","readonly","return","static","super","switch","this","throw","true","try","type","typeof","undefined","var","void","while","with","yield"]),_=new Set(["SELECT","FROM","WHERE","INSERT","INTO","VALUES","UPDATE","SET","DELETE","CREATE","TABLE","ALTER","DROP","JOIN","LEFT","RIGHT","INNER","OUTER","ON","AS","AND","OR","NOT","NULL","IS","IN","ORDER","BY","GROUP","HAVING","LIMIT","OFFSET","DISTINCT","COUNT","ASC","DESC","TRUE","FALSE","UNION","ALL","CASE","WHEN","THEN","ELSE","END"]),D=new Set(["if","then","else","elif","fi","for","in","do","done","while","until","case","esac","function","return","export","local","readonly","echo","exit","cd","ls","cat","grep","sed","awk","npm","bun","yarn","npx","git","curl","sudo","chmod","mkdir","rm","cp","mv","true","false"]),S=new Set(["important","inherit","initial","unset","none","auto","block","inline","flex","grid","absolute","relative","fixed","sticky","solid","dashed","transparent","currentColor","var","calc","rgb","rgba","hsl","hsla"]),E=new Set(["true","false","null"]);function w(z,O,Z){if(!Z)return;const Y=z[z.length-1];Y&&Y.type===O?Y.text+=Z:z.push({type:O,text:Z})}function N(z){return/[A-Za-z_$]/.test(z)}function V(z){return/[A-Za-z0-9_$-]/.test(z)}function C(z){return z>="0"&&z<="9"}function P(z,O,Z){if(!z)return[];if(O==="text")return[{type:"plain",text:z}];const Y=[],Q=z.length;let q=0,U=!1;for(;q<Q;){if(Z.inHtmlComment){const G=z.indexOf("-->",q);G===-1?(w(Y,"comment",z.slice(q)),q=Q):(w(Y,"comment",z.slice(q,G+3)),q=G+3,Z.inHtmlComment=!1);continue}if(Z.inBlockComment){const G=z.indexOf("*/",q);G===-1?(w(Y,"comment",z.slice(q)),q=Q):(w(Y,"comment",z.slice(q,G+2)),q=G+2,Z.inBlockComment=!1);continue}const J=z[q],ne=z[q+1]??"";if(J===" "||J===" "||J==="\r"){let G=q+1;for(;G<Q&&(z[G]===" "||z[G]===" "||z[G]==="\r");)G++;w(Y,"plain",z.slice(q,G)),q=G;continue}if((O==="vue"||O==="html")&&z.startsWith("<!--",q)){const G=z.indexOf("-->",q+4);G===-1?(w(Y,"comment",z.slice(q)),Z.inHtmlComment=!0,q=Q):(w(Y,"comment",z.slice(q,G+3)),q=G+3);continue}if((O==="js"||O==="ts"||O==="vue"||O==="css"||O==="sql")&&J==="/"&&ne==="*"){const G=z.indexOf("*/",q+2);G===-1?(w(Y,"comment",z.slice(q)),Z.inBlockComment=!0,q=Q):(w(Y,"comment",z.slice(q,G+2)),q=G+2);continue}if((O==="js"||O==="ts"||O==="vue"||O==="css")&&J==="/"&&ne==="/"){w(Y,"comment",z.slice(q)),q=Q;continue}if(O==="bash"&&J==="#"){w(Y,"comment",z.slice(q)),q=Q;continue}if(O==="sql"&&J==="-"&&ne==="-"){w(Y,"comment",z.slice(q)),q=Q;continue}if(J==='"'||J==="'"||J==="`"&&O!=="sql"){const G=J;let ee=q+1;for(;ee<Q;){if(z[ee]==="\\"&&ee+1<Q){ee+=2;continue}if(z[ee]===G){ee++;break}ee++}w(Y,"string",z.slice(q,ee)),q=ee;continue}if((O==="vue"||O==="html")&&J==="<"){const G=ne==="/";let ee=q+(G?2:1);if(ee<Q&&/[A-Za-z]/.test(z[ee])){for(;ee<Q&&/[A-Za-z0-9_:-]/.test(z[ee]);)ee++;w(Y,"operator",z.slice(q,q+(G?2:1))),w(Y,"tag",z.slice(q+(G?2:1),ee)),U=!G,q=ee;continue}}if((O==="vue"||O==="html")&&U){if(J==="/"&&ne===">"){w(Y,"operator","/>"),U=!1,q+=2;continue}if(J===">"){w(Y,"operator",">"),U=!1,q++;continue}if(/[A-Za-z:@#]/.test(J)){let G=q+1;for(;G<Q&&/[A-Za-z0-9_.:-]/.test(z[G]);)G++;w(Y,"attr",z.slice(q,G)),q=G;continue}}if(O==="css"&&J==="#"&&/[0-9A-Fa-f]/.test(ne)){let G=q+1;for(;G<Q&&/[0-9A-Fa-f]/.test(z[G]);)G++;w(Y,"number",z.slice(q,G)),q=G;continue}if(C(J)||J==="."&&C(ne)){let G=q+1;for(;G<Q&&/[0-9._xXa-fA-F]/.test(z[G]);)G++;w(Y,"number",z.slice(q,G)),q=G;continue}if(N(J)){let G=q+1;for(;G<Q&&V(z[G]);)G++;const ee=z.slice(q,G);let re=!1;O==="js"||O==="ts"||O==="vue"?re=$.has(ee):O==="sql"?re=_.has(ee.toUpperCase()):O==="bash"?re=D.has(ee):O==="css"?re=S.has(ee):O==="json"&&(re=E.has(ee)),O==="json"&&z[G]===void 0?w(Y,re?"keyword":"plain",ee):O==="css"&&z.slice(G).trimStart().startsWith(":")?w(Y,"attr",ee):w(Y,re?"keyword":"plain",ee),q=G;continue}if(/[+\-*/%=<>!&|^~?:]/.test(J)){let G=q+1;for(;G<Q&&/[+\-*/%=<>!&|^~?:]/.test(z[G]);)G++;w(Y,"operator",z.slice(q,G)),q=G;continue}w(Y,"plain",J),q++}return Y}const T=e.computed(()=>{const z={inBlockComment:!1,inHtmlComment:!1};return y.value.map(O=>P(O,p.value,z))}),I=z=>{if(!m.value||!l.tabs)return;const O=l.tabs[z];O&&(c.value=z,n("update:activeTab",z),n("tab-change",{index:z,tab:O}))},j=z=>{if(m.value&&l.tabs){const O=l.tabs.map((Z,Y)=>Y===f.value?{...Z,code:z}:Z);n("update:tabs",O)}else n("update:modelValue",z);n("change",z)},A=()=>{var z;!k.value&&!l.disabled&&((z=r.value)==null||z.focus())},K=z=>{const O=z.target;j(O.value)},W=async z=>{if(k.value||l.disabled)return;const O=z.target,Z=O.selectionStart??0,Y=O.selectionEnd??0,Q=" ".repeat(Math.max(1,l.tabSize)),q=u.value,U=q.slice(0,Z)+Q+q.slice(Y);l.maxLength!==void 0&&U.length>l.maxLength||(j(U),await e.nextTick(),r.value&&(r.value.selectionStart=Z+Q.length,r.value.selectionEnd=Z+Q.length))},v=z=>{s.value=!0,n("focus",z)},te=z=>{s.value=!1,n("blur",z)},oe=async()=>{var Z;const z=u.value;let O=!1;if(typeof navigator<"u"&&((Z=navigator.clipboard)!=null&&Z.writeText))try{await navigator.clipboard.writeText(z),O=!0}catch{O=!1}if(!O&&typeof document<"u"){const Y=document.createElement("textarea");Y.value=z,Y.setAttribute("readonly",""),Y.style.position="fixed",Y.style.opacity="0",document.body.appendChild(Y),Y.select();try{O=document.execCommand("copy")}catch{O=!1}document.body.removeChild(Y)}O&&(d.value=!0,n("copy",z),o&&clearTimeout(o),o=setTimeout(()=>{d.value=!1},1800))};return(z,O)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-code-editor mfs-rounded mfs-shadow-card",{"mfs-code-editor--readonly":k.value,"mfs-code-editor--disabled mfs-disabled":t.disabled,"mfs-code-editor--invalid":t.invalid,"mfs-code-editor--focused":s.value}])},[e.createElementVNode("div",Kc,[O[0]||(O[0]=e.createElementVNode("div",{class:"mfs-code-editor__dots","aria-hidden":"true"},[e.createElementVNode("span",{class:"mfs-code-editor__dot mfs-code-editor__dot--red"}),e.createElementVNode("span",{class:"mfs-code-editor__dot mfs-code-editor__dot--yellow"}),e.createElementVNode("span",{class:"mfs-code-editor__dot mfs-code-editor__dot--green"})],-1)),m.value?(e.openBlock(),e.createElementBlock("div",Oc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.tabs,(Z,Y)=>(e.openBlock(),e.createElementBlock("button",{key:`${Z.filename||Z.label}-${Y}`,type:"button",role:"tab",class:e.normalizeClass(["mfs-code-editor__tab mfs-font-mono",{"mfs-code-editor__tab--active":Y===f.value}]),"aria-selected":Y===f.value,onClick:Q=>I(Y)},e.toDisplayString(Z.filename||Z.label),11,Hc))),128))])):(e.openBlock(),e.createElementBlock("div",Uc,[g.value?(e.openBlock(),e.createElementBlock("span",Wc,e.toDisplayString(g.value),1)):e.createCommentVNode("",!0)])),e.createElementVNode("div",Gc,[e.createElementVNode("span",qc,e.toDisplayString(p.value.toUpperCase()),1),t.copyable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"mfs-code-editor__copy-btn","aria-label":d.value?"Copied":"Copy code",title:d.value?"Copied!":"Copy code",onClick:oe},[d.value?(e.openBlock(),e.createBlock(e.unref(Fc),{key:0,size:14})):(e.openBlock(),e.createBlock(e.unref(jc),{key:1,size:14})),e.createElementVNode("span",null,e.toDisplayString(d.value?"Copied":"Copy"),1)],8,Yc)):e.createCommentVNode("",!0)])]),e.createElementVNode("div",{ref_key:"bodyRef",ref:i,class:"mfs-code-editor__body",style:e.normalizeStyle({minHeight:t.minHeight,maxHeight:t.maxHeight}),onClick:A},[t.lineNumbers?(e.openBlock(),e.createElementBlock("div",Xc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,Z=>(e.openBlock(),e.createElementBlock("div",{key:Z,class:"mfs-code-editor__line-no"},e.toDisplayString(Z),1))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",Zc,[e.createElementVNode("pre",{class:"mfs-code-editor__highlight mfs-font-mono","aria-hidden":!k.value,style:e.normalizeStyle({tabSize:String(t.tabSize)})},[e.createElementVNode("code",Qc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(T.value,(Z,Y)=>(e.openBlock(),e.createElementBlock("span",{key:Y,class:"mfs-code-editor__line"},[Z.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(Z,(Q,q)=>(e.openBlock(),e.createElementBlock("span",{key:q,class:e.normalizeClass(`mfs-tok--${Q.type}`)},e.toDisplayString(Q.text),3))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(""))],64)),O[1]||(O[1]=e.createTextVNode(e.toDisplayString(`
|
|
33
|
-
`),-1))]))),128))])],12,Jc),k.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("textarea",{key:0,ref_key:"textareaRef",ref:r,class:"mfs-code-editor__textarea mfs-font-mono",value:u.value,disabled:t.disabled,placeholder:t.placeholder,maxlength:t.maxLength,style:e.normalizeStyle({tabSize:String(t.tabSize)}),spellcheck:"false",autocomplete:"off",autocapitalize:"off",autocorrect:"off","aria-label":"Code editor","aria-invalid":t.invalid||void 0,onInput:K,onKeydown:e.withKeys(e.withModifiers(W,["prevent"]),["tab"]),onFocus:v,onBlur:te},null,44,vc))])],4),e.createElementVNode("div",em,[e.createElementVNode("div",tm,[e.createElementVNode("span",null,"Lines: "+e.toDisplayString(h.value),1),e.createElementVNode("span",null,[e.createTextVNode(" Chars: "+e.toDisplayString(B.value),1),t.maxLength!==void 0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(" / "+e.toDisplayString(t.maxLength),1)],64)):e.createCommentVNode("",!0)])]),e.createElementVNode("div",lm,[e.createElementVNode("span",null,e.toDisplayString(p.value.toUpperCase()),1),e.createElementVNode("span",nm,e.toDisplayString(k.value?"Readonly":"Editable"),1)])])],2))}}),[["__scopeId","data-v-c5eeb990"]]),om={class:"split-btn"},am=["disabled"],sm=["disabled","aria-expanded"],rm=["disabled","onClick"],im={key:0,class:"split-btn__icon"},ml=F(e.defineComponent({__name:"SplitButton",props:{label:{default:"Action"},items:{default:()=>[]},variant:{default:"primary"},size:{default:"md"},disabled:{type:Boolean,default:!1}},emits:["click","select"],setup(t,{emit:a}){const l=a,n=e.ref(!1),i=e.ref(null),r=e.ref(null),{overlayStyle:s,containsTarget:d}=de(i,r,n,{offset:8,align:"right"}),c=f=>{f.disabled||(n.value=!1,l("select",f))},o=f=>{n.value&&!d(f.target)&&(n.value=!1)},m=f=>{f.key==="Escape"&&n.value&&(n.value=!1)};return e.onMounted(()=>{document.addEventListener("click",o),document.addEventListener("keydown",m)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",o),document.removeEventListener("keydown",m)}),(f,b)=>(e.openBlock(),e.createElementBlock("div",om,[e.createElementVNode("div",{ref_key:"triggerRef",ref:i,class:e.normalizeClass(["split-btn__group","mfs-pill","mfs-shadow",`split-btn--${t.variant}`,`split-btn--${t.size}`])},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["split-btn__main","mfs-interactive","mfs-focus-ring",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,{"mfs-disabled":t.disabled}]),disabled:t.disabled,onClick:b[0]||(b[0]=u=>l("click",u))},[e.renderSlot(f.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)],10,am),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["split-btn__toggle","mfs-interactive","mfs-focus-ring",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,{"mfs-disabled":t.disabled}]),disabled:t.disabled,"aria-haspopup":"menu","aria-expanded":n.value,"aria-label":"More actions",onClick:b[1]||(b[1]=u=>n.value=!n.value)},[...b[2]||(b[2]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"16",height:"16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,sm)],2),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"split-fade"},{default:e.withCtx(()=>[n.value&&t.items.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(s)),class:"split-btn__menu mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur",role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(u,p)=>(e.openBlock(),e.createElementBlock("li",{key:p,role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:"split-btn__item mfs-text",disabled:u.disabled,onClick:g=>c(u)},[u.icon?(e.openBlock(),e.createElementBlock("span",im,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.label),1)],8,rm)]))),128))],4)):e.createCommentVNode("",!0)]),_:1})]))]))}}),[["__scopeId","data-v-54cf96eb"]]),dm=["aria-expanded"],cm={key:0,class:"speed-dial__list mfs-absolute mfs-m-0 mfs-p-0 mfs-list-none mfs-flex mfs-gap-2-5",role:"menu"},mm=["title","aria-label","disabled","onClick"],fl=F(e.defineComponent({__name:"SpeedDial",props:{items:{default:()=>[]},direction:{default:"up"},type:{default:"linear"},radius:{default:76},modelValue:{type:Boolean,default:void 0}},emits:["update:modelValue","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);e.watch(()=>l.modelValue,o=>{o!==void 0&&(i.value=o)});const r=e.computed(()=>l.modelValue!==void 0?l.modelValue:i.value),s=()=>{const o=!r.value;i.value=o,n("update:modelValue",o)},d=o=>{var m;o.disabled||((m=o.action)==null||m.call(o),n("select",o),i.value=!1,n("update:modelValue",!1))},c=o=>{if(l.type!=="radial"||!l.items.length)return;const m=l.items.length,f=l.direction==="up"?-90:l.direction==="down"?90:l.direction==="left"?180:0,b=120,u=m>1?b/(m-1):0,g=(f-b/2+o*u)*Math.PI/180,k=Math.round(Math.cos(g)*l.radius),y=Math.round(Math.sin(g)*l.radius);return{position:"absolute",transform:`translate(${k}px, ${y}px)`}};return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["speed-dial",`speed-dial--${t.direction}`,"mfs-relative","mfs-inline-flex","mfs-items-center","mfs-justify-center"])},[e.createElementVNode("button",{type:"button",class:"speed-dial__fab mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-bg-primary mfs-pill mfs-shadow mfs-interactive mfs-focus-ring","aria-expanded":r.value,"aria-label":"Toggle quick actions",onClick:s},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["speed-dial__plus",{"is-open":r.value}]),viewBox:"0 0 24 24",width:"22",height:"22",fill:"none","aria-hidden":"true"},[...m[0]||(m[0]=[e.createElementVNode("path",{d:"M12 5v14M5 12h14",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round"},null,-1)])],2))],8,dm),r.value?(e.openBlock(),e.createElementBlock("ul",cm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(f,b)=>(e.openBlock(),e.createElementBlock("li",{key:b,class:"speed-dial__entry",style:e.normalizeStyle(c(b)),role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:e.normalizeClass(["speed-dial__item","mfs-inline-flex","mfs-items-center","mfs-justify-center","mfs-text-xs","mfs-font-bold","mfs-surface","mfs-pill","mfs-shadow","mfs-interactive","mfs-focus-ring",{"mfs-disabled":f.disabled}]),title:f.label,"aria-label":f.label,disabled:f.disabled,onClick:u=>d(f)},[e.renderSlot(o.$slots,"item",{item:f,index:b},()=>[e.createElementVNode("span",null,e.toDisplayString(f.icon||f.label.slice(0,2)),1)],!0)],10,mm)],4))),128))])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-0bac52a8"]]),fm={key:0,class:"panel__header"},um={class:"panel__title mfs-title"},pm={class:"panel__actions"},km=["aria-expanded"],hm={class:"panel__collapse"},gm={class:"panel__inner"},ym={class:"panel__body"},bm={key:0,class:"panel__footer mfs-surface-subtle mfs-caption"},ul=F(e.defineComponent({__name:"Panel",props:{header:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);e.watch(()=>l.collapsed,d=>{d!==void 0&&(i.value=d)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:i.value),s=()=>{const d=!r.value;i.value=d,n("update:collapsed",d),n("toggle",d)};return(d,c)=>(e.openBlock(),e.createElementBlock("section",{class:e.normalizeClass(["panel","mfs-surface","mfs-rounded","mfs-shadow-card",{"is-collapsed":r.value}])},[t.header||d.$slots.header||t.toggleable?(e.openBlock(),e.createElementBlock("header",fm,[e.createElementVNode("div",um,[e.renderSlot(d.$slots,"header",{},()=>[e.createTextVNode(e.toDisplayString(t.header),1)],!0)]),e.createElementVNode("div",pm,[e.renderSlot(d.$slots,"icons",{},void 0,!0),t.toggleable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"panel__toggle mfs-surface-subtle mfs-pill mfs-interactive mfs-focus-ring","aria-expanded":!r.value,"aria-label":"Toggle panel",onClick:s},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["panel__chevron",{"is-collapsed":r.value}]),viewBox:"0 0 20 20",width:"16",height:"16",fill:"none","aria-hidden":"true"},[...c[0]||(c[0]=[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2))],8,km)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",hm,[e.createElementVNode("div",gm,[e.createElementVNode("div",ym,[e.renderSlot(d.$slots,"default",{},void 0,!0)]),d.$slots.footer?(e.openBlock(),e.createElementBlock("footer",bm,[e.renderSlot(d.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)])])],2))}}),[["__scopeId","data-v-0ea71fae"]]),Bm={key:0,class:"fieldset__legend mfs-surface-subtle mfs-pill mfs-shadow mfs-title mfs-text-sm mfs-font-bold"},wm=["aria-expanded"],_m={key:1,class:"mfs-text"},Em={class:"fieldset__collapse"},$m={class:"mfs-overflow-hidden"},Vm={class:"mfs-pt-2"},pl=F(e.defineComponent({__name:"Fieldset",props:{legend:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);e.watch(()=>l.collapsed,d=>{d!==void 0&&(i.value=d)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:i.value),s=()=>{const d=!r.value;i.value=d,n("update:collapsed",d),n("toggle",d)};return(d,c)=>(e.openBlock(),e.createElementBlock("fieldset",{class:e.normalizeClass(["fieldset","mfs-surface","mfs-rounded","mfs-shadow-card","mfs-m-0","mfs-min-w-0",{"is-collapsed":r.value}])},[t.legend||d.$slots.legend?(e.openBlock(),e.createElementBlock("legend",Bm,[t.toggleable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"fieldset__btn mfs-inline-flex mfs-items-center mfs-gap-1-5 mfs-border-none mfs-bg-transparent mfs-cursor-pointer mfs-text mfs-focus-ring","aria-expanded":!r.value,onClick:s},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["fieldset__chevron",{"is-collapsed":r.value}]),viewBox:"0 0 20 20",width:"15",height:"15",fill:"none","aria-hidden":"true"},[...c[0]||(c[0]=[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2)),e.renderSlot(d.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)],8,wm)):(e.openBlock(),e.createElementBlock("span",_m,[e.renderSlot(d.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)]))])):e.createCommentVNode("",!0),e.createElementVNode("div",Em,[e.createElementVNode("div",$m,[e.createElementVNode("div",Vm,[e.renderSlot(d.$slots,"default",{},void 0,!0)])])])],2))}}),[["__scopeId","data-v-86bfdaad"]]),xm=["aria-orientation","aria-valuenow","aria-valuemin","aria-valuemax"],Cm={class:"splitter__pane splitter__pane--second"},kl=F(e.defineComponent({__name:"Splitter",props:{layout:{default:"horizontal"},initialSize:{default:50},minSize:{default:15}},emits:["resize"],setup(t,{emit:a}){const l=t,n=a,i=p=>Math.max(l.minSize,Math.min(100-l.minSize,p)),r=e.ref(i(l.initialSize)),s=e.ref(!1),d=e.ref(null),c=e.computed(()=>({flexBasis:`${r.value}%`})),o=p=>{if(!d.value)return;const g=d.value.getBoundingClientRect(),k=l.layout==="horizontal"?(p.clientX-g.left)/g.width*100:(p.clientY-g.top)/g.height*100;r.value=i(k),n("resize",r.value)},m=p=>{s.value=!0,p.currentTarget.setPointerCapture(p.pointerId),o(p)},f=p=>{s.value&&o(p)},b=p=>{s.value&&(s.value=!1,p.currentTarget.hasPointerCapture(p.pointerId)&&p.currentTarget.releasePointerCapture(p.pointerId))},u=p=>{const k=l.layout==="horizontal"?"ArrowLeft":"ArrowUp",y=l.layout==="horizontal"?"ArrowRight":"ArrowDown";p.key===k?(p.preventDefault(),r.value=i(r.value-5),n("resize",r.value)):p.key===y&&(p.preventDefault(),r.value=i(r.value+5),n("resize",r.value))};return(p,g)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:d,class:e.normalizeClass(["splitter",`splitter--${t.layout}`,"mfs-surface","mfs-rounded","mfs-shadow-card"])},[e.createElementVNode("div",{class:"splitter__pane",style:e.normalizeStyle(c.value)},[e.renderSlot(p.$slots,"first",{},void 0,!0)],4),e.createElementVNode("div",{class:"splitter__gutter mfs-surface-subtle mfs-focus-ring",role:"separator",tabindex:"0","aria-orientation":t.layout==="horizontal"?"vertical":"horizontal","aria-valuenow":Math.round(r.value),"aria-valuemin":t.minSize,"aria-valuemax":100-t.minSize,onPointerdown:m,onPointermove:f,onPointerup:b,onPointercancel:b,onKeydown:u},[...g[0]||(g[0]=[e.createElementVNode("span",{class:"splitter__handle mfs-pill"},null,-1)])],40,xm),e.createElementVNode("div",Cm,[e.renderSlot(p.$slots,"second",{},void 0,!0)])],2))}}),[["__scopeId","data-v-6fd2ec7c"]]),Nm={class:"toolbar mfs-surface mfs-rounded mfs-shadow-card",role:"toolbar"},Sm={key:0,class:"toolbar__group toolbar__group--start"},Mm={key:1,class:"toolbar__group toolbar__group--center"},Dm={key:2,class:"toolbar__group toolbar__group--end"},hl=F(e.defineComponent({__name:"Toolbar",setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",Nm,[a.$slots.start||a.$slots.default?(e.openBlock(),e.createElementBlock("div",Sm,[e.renderSlot(a.$slots,"start",{},()=>[e.renderSlot(a.$slots,"default",{},void 0,!0)],!0)])):e.createCommentVNode("",!0),a.$slots.center?(e.openBlock(),e.createElementBlock("div",Mm,[e.renderSlot(a.$slots,"center",{},void 0,!0)])):e.createCommentVNode("",!0),a.$slots.end?(e.openBlock(),e.createElementBlock("div",Dm,[e.renderSlot(a.$slots,"end",{},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cf5eff51"]]),Tm={class:"scroll-panel__content"},gl=F(e.defineComponent({__name:"ScrollPanel",props:{maxHeight:{default:"300px"},width:{}},setup(t){const a=t,l=i=>i===void 0?void 0:typeof i=="number"?`${i}px`:i,n=e.computed(()=>({maxHeight:l(a.maxHeight),width:l(a.width)}));return(i,r)=>(e.openBlock(),e.createElementBlock("div",{class:"scroll-panel mfs-surface mfs-rounded mfs-shadow-card mfs-focus-ring",style:e.normalizeStyle(n.value),tabindex:"0"},[e.createElementVNode("div",Tm,[e.renderSlot(i.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-78b33875"]]),yl=F(e.defineComponent({__name:"Fluid",props:{tag:{default:"div"},padded:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),{class:e.normalizeClass(["fluid","mfs-w-full",{"mfs-px-4":t.padded}])},{default:e.withCtx(()=>[e.renderSlot(a.$slots,"default",{},void 0,!0)]),_:3},8,["class"]))}}),[["__scopeId","data-v-94565fea"]]),We=e.defineComponent({__name:"Deferred",props:{rootMargin:{default:"0px"},threshold:{default:0},once:{type:Boolean,default:!0}},emits:["load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1),r=e.ref(null);let s=null;return e.onMounted(()=>{if(typeof IntersectionObserver>"u"||!r.value){i.value=!0,n("load");return}s=new IntersectionObserver(d=>{const c=d[0];c!=null&&c.isIntersecting&&(i.value=!0,n("load"),l.once&&(s==null||s.disconnect(),s=null))},{rootMargin:l.rootMargin,threshold:l.threshold}),s.observe(r.value)}),e.onBeforeUnmount(()=>{s==null||s.disconnect(),s=null}),(d,c)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"targetRef",ref:r,class:"mfs-w-full"},[i.value?e.renderSlot(d.$slots,"default",{},void 0,void 0,0):e.renderSlot(d.$slots,"placeholder",{},()=>[c[0]||(c[0]=e.createElementVNode("div",{class:"mfs-inset mfs-rounded mfs-p-6 mfs-text-center mfs-text-sm mfs-text-muted"}," Loading... ",-1))],void 0,1)],512))}}),Lm={class:"menu__list"},zm={key:0,class:"menu__separator mfs-divider",role:"separator"},Im={key:1,class:"menu__group",role:"presentation"},Rm={key:0,class:"menu__group-label mfs-text-muted"},Pm={class:"menu__sublist"},Am=["disabled","onClick"],Fm={key:0,class:"menu__icon","aria-hidden":"true"},jm={class:"menu__label"},Km={key:0,class:"menu__icon","aria-hidden":"true"},Om={class:"menu__label"},Hm={key:2,role:"none"},Um=["disabled","onClick"],Wm={key:0,class:"menu__icon","aria-hidden":"true"},Gm={class:"menu__label"},qm={key:0,class:"menu__icon","aria-hidden":"true"},Ym={class:"menu__label"},Xm={class:"menu__list"},Zm={key:0,class:"menu__separator mfs-divider",role:"separator"},Jm={key:1,class:"menu__group",role:"presentation"},Qm={key:0,class:"menu__group-label mfs-text-muted"},vm={class:"menu__sublist"},ef=["disabled","onClick"],tf={key:0,class:"menu__icon","aria-hidden":"true"},lf={class:"menu__label"},nf={key:0,class:"menu__icon","aria-hidden":"true"},of={class:"menu__label"},af={key:2,role:"none"},sf=["disabled","onClick"],rf={key:0,class:"menu__icon","aria-hidden":"true"},df={class:"menu__label"},cf={key:0,class:"menu__icon","aria-hidden":"true"},mf={class:"menu__label"},bl=F(e.defineComponent({__name:"Menu",props:{items:{},popup:{type:Boolean,default:!1}},emits:["select"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(!1),s=e.ref(null),d=e.ref({x:0,y:0}),c=()=>{r.value=!1,g()},o=async k=>{if(!n.popup)return;r.value=!0;const y=k.currentTarget,h=y==null?void 0:y.getBoundingClientRect();if(d.value=h?{x:h.left,y:h.bottom+6}:{x:k.clientX,y:k.clientY},await e.nextTick(),s.value){const B=s.value.getBoundingClientRect(),$=8;d.value={x:Math.max($,Math.min(d.value.x,window.innerWidth-B.width-$)),y:Math.max($,Math.min(d.value.y,window.innerHeight-B.height-$))}}p()},m=k=>{r.value?c():o(k)},f=k=>{var y;k.disabled||((y=k.command)==null||y.call(k),i("select",k),n.popup&&c())},b=k=>{k.key==="Escape"&&n.popup&&c()},u=k=>{s.value&&!s.value.contains(k.target)&&c()},p=()=>{window.addEventListener("pointerdown",u),window.addEventListener("resize",c)},g=()=>{window.removeEventListener("pointerdown",u),window.removeEventListener("resize",c)};return e.onUnmounted(g),a({open:o,close:c,toggle:m}),(k,y)=>t.popup?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:"body"},[e.createVNode(e.Transition,{name:"menu-pop"},{default:e.withCtx(()=>[r.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"menuRef",ref:s,class:"menu menu--popup mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${d.value.x}px`,top:`${d.value.y}px`}),onKeydown:b},[e.createElementVNode("ul",Lm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>{var $;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[h.separator?(e.openBlock(),e.createElementBlock("li",zm)):($=h.items)!=null&&$.length?(e.openBlock(),e.createElementBlock("li",Im,[h.label?(e.openBlock(),e.createElementBlock("div",Rm,e.toDisplayString(h.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Pm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(_,D)=>(e.openBlock(),e.createElementBlock("li",{key:D,role:"none"},[!_.to&&!_.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Fm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",jm,e.toDisplayString(_.label),1)],!0)],10,Am)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:e.unref(se)(_.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Km,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Om,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",Hm,[!h.to&&!h.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",Wm,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Gm,e.toDisplayString(h.label),1)],!0)],10,Um)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.to?"router-link":"a"),{key:1,to:h.to,href:e.unref(se)(h.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",qm,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Ym,e.toDisplayString(h.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],36)):e.createCommentVNode("",!0)]),_:3})])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"menu mfs-surface mfs-rounded-md mfs-blur",role:"menu",onKeydown:b},[e.createElementVNode("ul",Xm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>{var $;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[h.separator?(e.openBlock(),e.createElementBlock("li",Zm)):($=h.items)!=null&&$.length?(e.openBlock(),e.createElementBlock("li",Jm,[h.label?(e.openBlock(),e.createElementBlock("div",Qm,e.toDisplayString(h.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",vm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(_,D)=>(e.openBlock(),e.createElementBlock("li",{key:D,role:"none"},[!_.to&&!_.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",tf,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",lf,e.toDisplayString(_.label),1)],!0)],10,ef)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:e.unref(se)(_.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",nf,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",of,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",af,[!h.to&&!h.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",rf,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",df,e.toDisplayString(h.label),1)],!0)],10,sf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.to?"router-link":"a"),{key:1,to:h.to,href:e.unref(se)(h.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",cf,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",mf,e.toDisplayString(h.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],32))}}),[["__scopeId","data-v-4044b938"]]),ff={class:"tiered-menu__list",role:"menubar"},uf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},pf=["onMouseenter"],kf=["aria-haspopup","aria-expanded","disabled","onClick"],hf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},gf={class:"tiered-menu__label"},yf={key:1,class:"tiered-menu__chevron",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},bf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Bf={class:"tiered-menu__label"},wf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},_f=["onMouseenter"],Ef=["aria-haspopup","aria-expanded","disabled","onClick"],$f={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Vf={class:"tiered-menu__label"},xf={key:1,class:"tiered-menu__chevron",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Cf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Nf={class:"tiered-menu__label"},Sf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},Mf={key:1,role:"none"},Df=["disabled","onClick"],Tf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Lf={class:"tiered-menu__label"},zf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},If={class:"tiered-menu__label"},Bl=F(e.defineComponent({__name:"TieredMenu",props:{items:{}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(null),d=e.ref({}),c=e.ref({}),o=e.ref(null),m=e.ref(null),f=e.ref({top:0,left:0}),b=e.ref({top:0,left:0});let u=null,p=null;const g=(z,O)=>{d.value[z]=O},k=(z,O)=>{c.value[z]=O},y=e.computed(()=>o.value!==null?l.items[o.value]??null:null),h=e.computed(()=>{var z;return m.value===null||!((z=y.value)!=null&&z.items)?null:y.value.items[m.value]??null}),B=(z,O)=>{if(typeof window>"u"||!z)return{top:0,left:0};const Z=z.getBoundingClientRect(),Y=O==null?void 0:O.getBoundingClientRect(),Q=(Y==null?void 0:Y.width)||200,q=(Y==null?void 0:Y.height)||0,U=8,J=6;let ne=Z.right+J;ne+Q>window.innerWidth-U&&(ne=Z.left-Q-J),ne=Math.min(Math.max(U,ne),Math.max(U,window.innerWidth-Q-U));let G=Z.top;return q>0&&G+q>window.innerHeight-U&&(G=Math.max(U,window.innerHeight-q-U)),{top:G,left:ne}},$=()=>{o.value!==null&&(f.value=B(d.value[o.value],r.value))},_=()=>{m.value!==null&&(b.value=B(c.value[m.value],s.value))},D=e.computed(()=>({position:"fixed",top:`${f.value.top}px`,left:`${f.value.left}px`,zIndex:9999})),S=e.computed(()=>({position:"fixed",top:`${b.value.top}px`,left:`${b.value.left}px`,zIndex:9999})),E=()=>{u&&(clearTimeout(u),u=null),p&&(clearTimeout(p),p=null)},w=()=>{u&&clearTimeout(u),u=setTimeout(()=>{o.value=null,m.value=null},120)},N=()=>{p&&clearTimeout(p),p=setTimeout(()=>{m.value=null},120)},V=z=>{E(),o.value!==z&&(m.value=null),o.value=z},C=()=>{w()},P=()=>{u&&(clearTimeout(u),u=null)},T=()=>{w()},I=z=>{E(),m.value=z},j=()=>{N()},A=()=>{E()},K=()=>{N(),w()},W=(z,O,Z)=>{var Y,Q;if(!z.disabled){if((Y=z.items)!=null&&Y.length){E(),O===1?(o.value=o.value===Z?null:Z,m.value=null):O===2&&(m.value=m.value===Z?null:Z);return}(Q=z.command)==null||Q.call(z),n("select",z),o.value=null,m.value=null}},v=z=>{var Z,Y,Q;const O=z.target;O&&((Z=i.value)!=null&&Z.contains(O)||(Y=r.value)!=null&&Y.contains(O)||(Q=s.value)!=null&&Q.contains(O)||(o.value=null,m.value=null))},te=z=>{z.key==="Escape"&&(o.value=null,m.value=null)},oe=()=>{o.value!==null&&$(),m.value!==null&&_()};return e.watch(o,z=>{z!==null&&($(),e.nextTick($))}),e.watch(r,z=>{z&&o.value!==null&&$()}),e.watch(m,z=>{z!==null&&(_(),e.nextTick(_))}),e.watch(s,z=>{z&&m.value!==null&&_()}),e.onMounted(()=>{window.addEventListener("pointerdown",v),window.addEventListener("keydown",te),window.addEventListener("scroll",oe,!0),window.addEventListener("resize",oe)}),e.onUnmounted(()=>{E(),window.removeEventListener("pointerdown",v),window.removeEventListener("keydown",te),window.removeEventListener("scroll",oe,!0),window.removeEventListener("resize",oe)}),(z,O)=>{var Z,Y,Q,q;return e.openBlock(),e.createElementBlock("nav",{ref_key:"rootRef",ref:i,class:"tiered-menu mfs-surface mfs-rounded-md mfs-blur","aria-label":"Tiered menu"},[e.createElementVNode("ul",ff,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(U,J)=>{var ne,G,ee,re;return e.openBlock(),e.createElementBlock(e.Fragment,{key:J},[U.separator?(e.openBlock(),e.createElementBlock("li",uf)):(e.openBlock(),e.createElementBlock("li",{key:1,ref_for:!0,ref:ae=>g(J,ae),class:"tiered-menu__node",role:"none",onMouseenter:ae=>V(J),onMouseleave:C},[(ne=U.items)!=null&&ne.length||!U.to&&!U.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":o.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),"aria-haspopup":(G=U.items)!=null&&G.length?"true":void 0,"aria-expanded":(ee=U.items)!=null&&ee.length?o.value===J:void 0,disabled:U.disabled,onClick:ae=>W(U,1,J)},[U.icon?(e.openBlock(),e.createElementBlock("span",hf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",gf,e.toDisplayString(U.label),1),(re=U.items)!=null&&re.length?(e.openBlock(),e.createElementBlock("svg",yf,[...O[0]||(O[0]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,kf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(U.to?"router-link":"a"),{key:1,to:U.to,href:e.unref(se)(U.href),role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":o.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ae=>W(U,1,J)},{default:e.withCtx(()=>[U.icon?(e.openBlock(),e.createElementBlock("span",bf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Bf,e.toDisplayString(U.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))],40,pf))],64)}),128))]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[(Y=(Z=y.value)==null?void 0:Z.items)!=null&&Y.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"submenu1Ref",ref:r,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",style:e.normalizeStyle(D.value),role:"menu",onMouseenter:P,onMouseleave:T},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value.items,(U,J)=>{var ne,G,ee,re;return e.openBlock(),e.createElementBlock(e.Fragment,{key:J},[U.separator?(e.openBlock(),e.createElementBlock("li",wf)):(e.openBlock(),e.createElementBlock("li",{key:1,ref_for:!0,ref:ae=>k(J,ae),class:"tiered-menu__node",role:"none",onMouseenter:ae=>I(J),onMouseleave:j},[(ne=U.items)!=null&&ne.length||!U.to&&!U.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":m.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),"aria-haspopup":(G=U.items)!=null&&G.length?"true":void 0,"aria-expanded":(ee=U.items)!=null&&ee.length?m.value===J:void 0,disabled:U.disabled,onClick:ae=>W(U,2,J)},[U.icon?(e.openBlock(),e.createElementBlock("span",$f,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Vf,e.toDisplayString(U.label),1),(re=U.items)!=null&&re.length?(e.openBlock(),e.createElementBlock("svg",xf,[...O[1]||(O[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Ef)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(U.to?"router-link":"a"),{key:1,to:U.to,href:e.unref(se)(U.href),role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":m.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ae=>W(U,2,J)},{default:e.withCtx(()=>[U.icon?(e.openBlock(),e.createElementBlock("span",Cf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Nf,e.toDisplayString(U.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))],40,_f))],64)}),128))],36)):e.createCommentVNode("",!0)])),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[(q=(Q=h.value)==null?void 0:Q.items)!=null&&q.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"submenu2Ref",ref:s,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",style:e.normalizeStyle(S.value),role:"menu",onMouseenter:A,onMouseleave:K},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value.items,(U,J)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:J},[U.separator?(e.openBlock(),e.createElementBlock("li",Sf)):(e.openBlock(),e.createElementBlock("li",Mf,[!U.to&&!U.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ne=>W(U,3,J)},[U.icon?(e.openBlock(),e.createElementBlock("span",Tf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Lf,e.toDisplayString(U.label),1)],10,Df)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(U.to?"router-link":"a"),{key:1,to:U.to,href:e.unref(se)(U.href),role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ne=>W(U,3,J)},{default:e.withCtx(()=>[U.icon?(e.openBlock(),e.createElementBlock("span",zf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",If,e.toDisplayString(U.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64))),128))],36)):e.createCommentVNode("",!0)]))],512)}}}),[["__scopeId","data-v-5dd066df"]]),Rf={key:0,class:"slide-menu__header"},Pf={class:"slide-menu__title mfs-title"},Af={class:"slide-menu__viewport"},Ff=["disabled","onClick"],jf={key:0,class:"slide-menu__icon","aria-hidden":"true"},Kf={class:"slide-menu__label"},Of={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Hf={key:0,class:"slide-menu__icon","aria-hidden":"true"},Uf={class:"slide-menu__label"},wl=F(e.defineComponent({__name:"SlideMenu",props:{items:{},backLabel:{default:"Back"},menuWidth:{default:"260px"}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref([]),r=e.ref("forward"),s=e.computed(()=>i.value.length?i.value[i.value.length-1].items:l.items),d=e.computed(()=>i.value.length?i.value[i.value.length-1].title:""),c=m=>{var f,b;if(!m.disabled){if((f=m.items)!=null&&f.length){r.value="forward",i.value.push({title:m.label,items:m.items});return}(b=m.command)==null||b.call(m),n("select",m)}},o=()=>{i.value.length&&(r.value="back",i.value.pop())};return(m,f)=>(e.openBlock(),e.createElementBlock("div",{class:"slide-menu mfs-surface mfs-overlay mfs-rounded-md mfs-blur",style:e.normalizeStyle({width:t.menuWidth})},[i.value.length>0?(e.openBlock(),e.createElementBlock("div",Rf,[e.createElementVNode("button",{type:"button",class:"slide-menu__back mfs-surface-subtle mfs-rounded-sm mfs-interactive mfs-text",onClick:o},[f[0]||(f[0]=e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"15 18 9 12 15 6"})],-1)),e.createElementVNode("span",null,e.toDisplayString(t.backLabel),1)]),e.createElementVNode("span",Pf,e.toDisplayString(d.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",Af,[e.createVNode(e.Transition,{name:r.value==="forward"?"slide-fwd":"slide-bck",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("ul",{key:i.value.length,class:"slide-menu__list",role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(b,u)=>{var p,g;return e.openBlock(),e.createElementBlock("li",{key:u,role:"none"},[(p=b.items)!=null&&p.length||!b.to&&!b.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:k=>c(b)},[b.icon?(e.openBlock(),e.createElementBlock("span",jf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Kf,e.toDisplayString(b.label),1),(g=b.items)!=null&&g.length?(e.openBlock(),e.createElementBlock("svg",Of,[...f[1]||(f[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Ff)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.to?"router-link":"a"),{key:1,to:b.to,href:e.unref(se)(b.href),role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:k=>c(b)},{default:e.withCtx(()=>[b.icon?(e.openBlock(),e.createElementBlock("span",Hf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Uf,e.toDisplayString(b.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))])}),128))]))]),_:1},8,["name"])])],4))}}),[["__scopeId","data-v-84b15d99"]]),Wf={class:"panel-menu","aria-label":"Panel navigation"},Gf=["aria-expanded","disabled","onClick"],qf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Yf={class:"panel-menu__label"},Xf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Zf={class:"panel-menu__label"},Jf={key:0,class:"panel-menu__list"},Qf=["disabled","onClick"],vf={key:0,class:"panel-menu__icon","aria-hidden":"true"},eu={key:0,class:"panel-menu__icon","aria-hidden":"true"},_l=F(e.defineComponent({__name:"PanelMenu",props:{items:{},multiple:{type:Boolean,default:!0},expandedKeys:{}},emits:["update:expandedKeys","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.expandedKeys??[]);e.watch(()=>l.expandedKeys,o=>{o!==void 0&&(i.value=[...o])});const r=(o,m)=>o.key??`${m}-${o.label}`,s=o=>i.value.includes(o),d=(o,m)=>{var f,b;if(!o.disabled){if((f=o.items)!=null&&f.length){const u=r(o,m);let p;s(u)?p=i.value.filter(g=>g!==u):p=l.multiple?[...i.value,u]:[u],i.value=p,n("update:expandedKeys",p);return}(b=o.command)==null||b.call(o),n("select",o)}},c=o=>{var m;o.disabled||((m=o.command)==null||m.call(o),n("select",o))};return(o,m)=>(e.openBlock(),e.createElementBlock("nav",Wf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(f,b)=>{var u,p,g;return e.openBlock(),e.createElementBlock("div",{key:r(f,b),class:"panel-menu__panel mfs-surface mfs-rounded-md mfs-blur"},[(u=f.items)!=null&&u.length||!f.to&&!f.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":f.disabled}]),"aria-expanded":(p=f.items)!=null&&p.length?s(r(f,b)):void 0,disabled:f.disabled,onClick:k=>d(f,b)},[f.icon?(e.openBlock(),e.createElementBlock("span",qf,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Yf,e.toDisplayString(f.label),1),(g=f.items)!=null&&g.length?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(["panel-menu__chevron",{"panel-menu__chevron--open":s(r(f,b))}]),width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[...m[0]||(m[0]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2)):e.createCommentVNode("",!0)],10,Gf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(f.to?"router-link":"a"),{key:1,to:f.to,href:e.unref(se)(f.href),class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":f.disabled}]),disabled:f.disabled,onClick:k=>d(f,b)},{default:e.withCtx(()=>[f.icon?(e.openBlock(),e.createElementBlock("span",Xf,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Zf,e.toDisplayString(f.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"panel-collapse"},{default:e.withCtx(()=>{var k;return[(k=f.items)!=null&&k.length&&s(r(f,b))?(e.openBlock(),e.createElementBlock("ul",Jf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.items,(y,h)=>(e.openBlock(),e.createElementBlock("li",{key:h},[!y.to&&!y.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:B=>c(y)},[y.icon?(e.openBlock(),e.createElementBlock("span",vf,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(y.label),1)],10,Qf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(y.to?"router-link":"a"),{key:1,to:y.to,href:e.unref(se)(y.href),class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:B=>c(y)},{default:e.withCtx(()=>[y.icon?(e.openBlock(),e.createElementBlock("span",eu,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(y.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])):e.createCommentVNode("",!0)]}),_:2},1024)])}),128))]))}}),[["__scopeId","data-v-de7ecfd5"]]),tu={class:"mega-menu__bar mfs-flex mfs-flex-col mfs-gap-2"},lu=["aria-expanded"],nu={key:0,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},ou={key:1,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},au=["onMouseenter"],su=["aria-haspopup","aria-expanded","disabled","onClick"],ru={key:0,"aria-hidden":"true"},iu={key:1,class:"mega-menu__chevron",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},du={key:0,"aria-hidden":"true"},cu={class:"mega-menu__columns"},mu={key:0,class:"mega-menu__col-title mfs-text-muted mfs-font-bold mfs-mb-2 mfs-px-2"},fu={class:"mega-menu__col-list mfs-flex mfs-flex-col mfs-gap-1"},uu=["onClick"],pu={class:"mega-menu__link-label mfs-font-semibold"},ku={key:0,class:"mega-menu__link-desc mfs-text-muted"},hu={class:"mega-menu__link-label mfs-font-semibold"},gu={key:0,class:"mega-menu__link-desc mfs-text-muted"},El=F(e.defineComponent({__name:"MegaMenu",props:{items:{},orientation:{default:"horizontal"}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref({}),d=e.ref(null),c=e.ref(!1),o=e.ref(0),m=e.ref(0);let f=null;const b=(w,N)=>{s.value[w]=N},u=e.computed(()=>d.value!==null?l.items[d.value]??null:null),p=()=>typeof window<"u"&&window.innerWidth<768,g=()=>{f&&(clearTimeout(f),f=null)},k=()=>{var W;if(typeof window>"u"||d.value===null)return;const w=s.value[d.value]??i.value;if(!w)return;const N=w.getBoundingClientRect(),V=(W=r.value)==null?void 0:W.getBoundingClientRect(),C=(V==null?void 0:V.width)||Math.min(480,window.innerWidth-16),P=(V==null?void 0:V.height)||0,T=8,I=6;let j=N.left,A=N.bottom+I;l.orientation==="vertical"&&!p()&&(j=N.right+I,A=N.top,j+C>window.innerWidth-T&&(j=N.left-C-I));const K=Math.max(T,window.innerWidth-C-T);if(j=Math.min(Math.max(T,j),K),P>0&&A+P>window.innerHeight-T)if(l.orientation==="horizontal"||p()){const v=N.top-T-I,te=window.innerHeight-N.bottom-T-I;v>te?A=Math.max(T,N.top-P-I):A=Math.max(T,window.innerHeight-P-T)}else A=Math.max(T,window.innerHeight-P-T);o.value=A,m.value=j},y=e.computed(()=>({position:"fixed",top:`${o.value}px`,left:`${m.value}px`,zIndex:9999})),h=w=>{p()||(g(),d.value=w)},B=()=>{p()||(g(),f=setTimeout(()=>{d.value=null},120))},$=(w,N)=>{var V,C;if(!w.disabled){if((V=w.columns)!=null&&V.length){g(),d.value=d.value===N?null:N;return}(C=w.command)==null||C.call(w),n("select",w),d.value=null,c.value=!1}},_=w=>{var N;(N=w.command)==null||N.call(w),n("select",w),d.value=null,c.value=!1},D=w=>{var V,C;const N=w.target;N&&((V=i.value)!=null&&V.contains(N)||(C=r.value)!=null&&C.contains(N)||(d.value=null))},S=w=>{w.key==="Escape"&&(d.value=null,c.value=!1)},E=()=>{d.value!==null&&k()};return e.watch(d,w=>{w!==null&&(k(),e.nextTick(k))}),e.watch(r,w=>{w&&d.value!==null&&k()}),e.onMounted(()=>{window.addEventListener("pointerdown",D),window.addEventListener("keydown",S),window.addEventListener("scroll",E,!0),window.addEventListener("resize",E)}),e.onUnmounted(()=>{g(),window.removeEventListener("pointerdown",D),window.removeEventListener("keydown",S),window.removeEventListener("scroll",E,!0),window.removeEventListener("resize",E)}),(w,N)=>(e.openBlock(),e.createElementBlock("nav",{ref_key:"rootRef",ref:i,class:e.normalizeClass(["mega-menu mfs-surface mfs-rounded mfs-blur mfs-relative mfs-w-full",`mega-menu--${t.orientation}`]),"aria-label":"Mega menu"},[e.createElementVNode("div",tu,[e.createElementVNode("button",{type:"button",class:"mega-menu__mobile-btn mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-text mfs-inline-flex mfs-items-center mfs-gap-2 mfs-py-2 mfs-px-3 mfs-border-none mfs-bg-transparent mfs-font-semibold","aria-expanded":c.value,"aria-label":"Toggle mega menu",onClick:N[0]||(N[0]=V=>c.value=!c.value)},[c.value?(e.openBlock(),e.createElementBlock("svg",ou,[...N[2]||(N[2]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",nu,[...N[1]||(N[1]=[e.createElementVNode("line",{x1:"3",y1:"6",x2:"21",y2:"6"},null,-1),e.createElementVNode("line",{x1:"3",y1:"12",x2:"21",y2:"12"},null,-1),e.createElementVNode("line",{x1:"3",y1:"18",x2:"21",y2:"18"},null,-1)])])),N[3]||(N[3]=e.createElementVNode("span",null,"Menu",-1))],8,lu),e.createElementVNode("ul",{class:e.normalizeClass(["mega-menu__list mfs-flex-col mfs-gap-1-5",{"mega-menu__list--open":c.value}]),role:"menubar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(V,C)=>{var P,T,I,j;return e.openBlock(),e.createElementBlock("li",{key:C,ref_for:!0,ref:A=>b(C,A),class:"mega-menu__root mfs-relative",role:"none",onMouseenter:A=>h(C),onMouseleave:B},[(P=V.columns)!=null&&P.length||!V.to&&!V.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["mega-menu__trigger mfs-rounded-sm mfs-text mfs-inline-flex mfs-items-center mfs-gap-2 mfs-border-none mfs-bg-transparent mfs-font-semibold mfs-cursor-pointer",{"mega-menu__trigger--active":d.value===C,"mega-menu__trigger--disabled mfs-disabled":V.disabled}]),"aria-haspopup":(T=V.columns)!=null&&T.length?"true":void 0,"aria-expanded":(I=V.columns)!=null&&I.length?d.value===C:void 0,disabled:V.disabled,onClick:A=>$(V,C)},[V.icon?(e.openBlock(),e.createElementBlock("span",ru,e.toDisplayString(V.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(V.label),1),(j=V.columns)!=null&&j.length?(e.openBlock(),e.createElementBlock("svg",iu,[...N[4]||(N[4]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])])):e.createCommentVNode("",!0)],10,su)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(V.to?"router-link":"a"),{key:1,to:V.to,href:e.unref(se)(V.href),role:"menuitem",class:e.normalizeClass(["mega-menu__trigger mfs-rounded-sm mfs-text mfs-inline-flex mfs-items-center mfs-gap-2 mfs-border-none mfs-bg-transparent mfs-font-semibold mfs-cursor-pointer",{"mega-menu__trigger--active":d.value===C,"mega-menu__trigger--disabled mfs-disabled":V.disabled}]),disabled:V.disabled,onClick:A=>$(V,C)},{default:e.withCtx(()=>[V.icon?(e.openBlock(),e.createElementBlock("span",du,e.toDisplayString(V.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(V.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))],40,au)}),128))],2)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mega-fade"},{default:e.withCtx(()=>{var V,C;return[(C=(V=u.value)==null?void 0:V.columns)!=null&&C.length?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"panelRef",ref:r,class:"mega-menu__panel mfs-card mfs-overlay mfs-blur mfs-p-4",style:e.normalizeStyle(y.value),role:"menu",onMouseenter:g,onMouseleave:B},[e.createElementVNode("div",cu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value.columns,(P,T)=>(e.openBlock(),e.createElementBlock("div",{key:T,class:"mega-menu__col"},[P.title?(e.openBlock(),e.createElementBlock("div",mu,e.toDisplayString(P.title),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",fu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(P.items,(I,j)=>(e.openBlock(),e.createElementBlock("li",{key:j,role:"none"},[!I.to&&!I.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:"mega-menu__link mfs-rounded-sm mfs-text mfs-w-full mfs-flex mfs-flex-col mfs-p-2 mfs-border-none mfs-bg-transparent mfs-text-left mfs-cursor-pointer",onClick:A=>_(I)},[e.createElementVNode("span",pu,e.toDisplayString(I.label),1),I.description?(e.openBlock(),e.createElementBlock("span",ku,e.toDisplayString(I.description),1)):e.createCommentVNode("",!0)],8,uu)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I.to?"router-link":"a"),{key:1,to:I.to,href:e.unref(se)(I.href),role:"menuitem",class:"mega-menu__link mfs-rounded-sm mfs-text mfs-w-full mfs-flex mfs-flex-col mfs-p-2 mfs-border-none mfs-bg-transparent mfs-text-left mfs-cursor-pointer",onClick:A=>_(I)},{default:e.withCtx(()=>[e.createElementVNode("span",hu,e.toDisplayString(I.label),1),I.description?(e.openBlock(),e.createElementBlock("span",gu,e.toDisplayString(I.description),1)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","onClick"]))]))),128))])]))),128))])],36)):e.createCommentVNode("",!0)]}),_:1})]))],2))}}),[["__scopeId","data-v-63c60131"]]),yu={class:"dock__list mfs-surface mfs-shadow-card mfs-pill mfs-blur",role:"menubar"},bu=["onMouseenter"],Bu=["aria-label","disabled","onClick"],wu={class:"dock__glyph mfs-text"},_u={key:0,class:"dock__dot","aria-hidden":"true"},Eu={class:"dock__glyph mfs-text"},$u={key:0,class:"dock__dot","aria-hidden":"true"},Vu={class:"dock__tooltip mfs-surface mfs-shadow mfs-rounded-sm mfs-text",role:"tooltip"},$l=F(e.defineComponent({__name:"Dock",props:{items:{},position:{default:"bottom"},magnification:{type:Boolean,default:!0}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=d=>{if(!l.magnification||i.value===null)return{};const c=Math.abs(i.value-d);return c===0?{transform:"scale(1.32)"}:c===1?{transform:"scale(1.14)"}:{}},s=(d,c)=>{var o;d.disabled||((o=d.command)==null||o.call(d),n("select",d,c))};return(d,c)=>(e.openBlock(),e.createElementBlock("nav",{class:e.normalizeClass(["dock",[`dock--${t.position}`]]),"aria-label":"Dock navigation",onMouseleave:c[0]||(c[0]=o=>i.value=null)},[e.createElementVNode("ul",yu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(o,m)=>(e.openBlock(),e.createElementBlock("li",{key:m,class:"dock__item-wrap",role:"none",onMouseenter:f=>i.value=m},[!o.to&&!o.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["dock__item mfs-rounded-sm mfs-text",{"dock__item--active":o.active,"dock__item--disabled mfs-disabled":o.disabled}]),style:e.normalizeStyle(r(m)),"aria-label":o.label,disabled:o.disabled,onClick:f=>s(o,m)},[e.renderSlot(d.$slots,"item",{item:o,index:m,active:!!o.active},()=>[e.createElementVNode("span",wu,e.toDisplayString(o.icon??o.label.slice(0,2).toUpperCase()),1)],!0),o.active?(e.openBlock(),e.createElementBlock("span",_u)):e.createCommentVNode("",!0)],14,Bu)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.to?"router-link":"a"),{key:1,to:o.to,href:e.unref(se)(o.href),role:"menuitem",class:e.normalizeClass(["dock__item mfs-rounded-sm mfs-text",{"dock__item--active":o.active,"dock__item--disabled mfs-disabled":o.disabled}]),style:e.normalizeStyle(r(m)),"aria-label":o.label,disabled:o.disabled,onClick:f=>s(o,m)},{default:e.withCtx(()=>[e.renderSlot(d.$slots,"item",{item:o,index:m,active:!!o.active},()=>[e.createElementVNode("span",Eu,e.toDisplayString(o.icon??o.label.slice(0,2).toUpperCase()),1)],!0),o.active?(e.openBlock(),e.createElementBlock("span",$u)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","class","style","aria-label","disabled","onClick"])),e.createElementVNode("span",Vu,e.toDisplayString(o.label),1)],40,bu))),128))])],34))}}),[["__scopeId","data-v-ecd21506"]]),xu={class:"tab-menu","aria-label":"Tab navigation"},Cu=["aria-selected","aria-disabled","tabindex","onClick"],Nu={key:0,class:"tab-menu__icon","aria-hidden":"true"},Su={key:0,class:"tab-menu__icon","aria-hidden":"true"},Vl=F(e.defineComponent({__name:"TabMenu",props:{items:{},modelValue:{default:0},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=new Map,s=e.ref({left:0,width:0,ready:!1}),d=(p,g)=>{const k=(g==null?void 0:g.$el)??g;k instanceof HTMLElement?r.set(p,k):r.delete(p)},c=e.computed(()=>({transform:`translateX(${s.value.left}px)`,width:`${s.value.width}px`,opacity:s.value.ready&&s.value.width>0?1:0})),o=async(p=!1)=>{await e.nextTick();const g=r.get(l.modelValue);if(!g){s.value={left:0,width:0,ready:!1};return}s.value={left:g.offsetLeft,width:g.offsetWidth,ready:!0},p&&l.scrollable&&g.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},m=(p,g,k)=>{var y;if(p.disabled){k.preventDefault();return}(y=p.command)==null||y.call(p),g!==l.modelValue&&(n("update:modelValue",g),n("change",{index:g,item:p}))},f=p=>{var h;const g=l.items.map((B,$)=>B.disabled?-1:$).filter(B=>B>=0);if(!g.length)return;const k=g.indexOf(l.modelValue);let y=-1;if(p.key==="ArrowRight"?y=g[(k+1)%g.length]:p.key==="ArrowLeft"?y=g[(k-1+g.length)%g.length]:p.key==="Home"?y=g[0]:p.key==="End"&&(y=g[g.length-1]),y>=0){p.preventDefault();const B=l.items[y];n("update:modelValue",y),n("change",{index:y,item:B}),(h=r.get(y))==null||h.focus()}},b=()=>o(!1);let u=null;return e.watch(()=>[l.modelValue,l.items],()=>o(!0),{deep:!0}),e.onMounted(()=>{o(!1),typeof ResizeObserver<"u"&&i.value&&(u=new ResizeObserver(b),u.observe(i.value)),window.addEventListener("resize",b)}),e.onUnmounted(()=>{u==null||u.disconnect(),window.removeEventListener("resize",b)}),(p,g)=>(e.openBlock(),e.createElementBlock("nav",xu,[e.createElementVNode("div",{ref_key:"listRef",ref:i,class:e.normalizeClass(["tab-menu__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tab-menu__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:f},[e.createElementVNode("span",{class:"tab-menu__indicator",style:e.normalizeStyle(c.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(k,y)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:k.key??y},[!k.to&&!k.href?(e.openBlock(),e.createElementBlock("button",{key:0,ref_for:!0,ref:h=>d(y,h),type:"button",role:"tab",class:e.normalizeClass(["tab-menu__item mfs-text",{"tab-menu__item--active":y===t.modelValue,"tab-menu__item--disabled mfs-disabled":k.disabled}]),"aria-selected":y===t.modelValue,"aria-disabled":k.disabled||void 0,tabindex:y===t.modelValue?0:-1,onClick:h=>m(k,y,h)},[k.icon?(e.openBlock(),e.createElementBlock("span",Nu,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(k.label),1)],10,Cu)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(k.to?"router-link":"a"),{key:1,ref_for:!0,ref:h=>d(y,h),to:k.to,href:e.unref(se)(k.href),role:"tab",class:e.normalizeClass(["tab-menu__item mfs-text",{"tab-menu__item--active":y===t.modelValue,"tab-menu__item--disabled mfs-disabled":k.disabled}]),"aria-selected":y===t.modelValue,"aria-disabled":k.disabled||void 0,tabindex:y===t.modelValue?0:-1,onClick:h=>m(k,y,h)},{default:e.withCtx(()=>[k.icon?(e.openBlock(),e.createElementBlock("span",Su,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(k.label),1)]),_:2},1032,["to","href","class","aria-selected","aria-disabled","tabindex","onClick"]))],64))),128))],34)]))}}),[["__scopeId","data-v-97b41a1e"]]),ot=new Map;function Mu(t){ot.set(t.listId,t)}function Du(t){ot.delete(t)}function Ge(t){return ot.get(t)}function Tu(t,a,l,n="vertical"){const i=l.getBoundingClientRect();return n==="horizontal"?t<i.left+i.width/2?"before":"after":a<i.top+i.height/2?"before":"after"}const ie=e.ref(null);function at(t,a){ie.value=a,t.dataTransfer&&(t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/plain",String(a.index)))}function st(){ie.value=null}function Ce(t,a,l="vertical"){const n=a.getBoundingClientRect();return l==="horizontal"?t.clientX<n.left+n.width/2?"before":"after":t.clientY<n.top+n.height/2?"before":"after"}function we(t,a,l){if(a===l||a<0||a>=t.length||l<0||l>=t.length)return[...t];const n=[...t],[i]=n.splice(a,1);return n.splice(l,0,i),n}function Lu(){return{dragState:ie,startDrag:at,endDrag:st,getDropPosition:Ce,reorderArray:we}}const zu={class:"order-list mfs-surface mfs-rounded mfs-shadow-card"},Iu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ru={key:1,class:"order-list__header"},Pu={class:"order-list__title mfs-title"},Au={class:"order-list__body"},Fu={class:"order-list__controls",role:"group","aria-label":"Reorder controls"},ju=["disabled"],Ku=["disabled"],Ou=["disabled"],Hu=["disabled"],Uu={class:"order-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Orderable items"},Wu={key:0,class:"mfs-empty-state"},Gu=["aria-selected","draggable","onClick","onKeydown","onDragstart","onDragover","onDrop"],qu={key:0,class:"order-list__grip","aria-hidden":"true"},Yu={class:"mfs-text"},xl=F(e.defineComponent({__name:"OrderList",props:{modelValue:{},itemKey:{default:"id"},header:{default:""},loading:{type:Boolean,default:!1},emptyText:{default:"No items"},draggable:{type:Boolean,default:!0}},emits:["update:modelValue","reorder"],setup(t,{emit:a}){let l=0;const n=t,i=a,r=`order-list-${++l}`,s=e.ref(null),d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref([]);function f(E,w){m.value[w]=E instanceof HTMLElement?E:null}const b=e.computed(()=>s.value!==null&&s.value>0),u=e.computed(()=>s.value!==null&&s.value<n.modelValue.length-1);function p(E,w){s.value=w,i("update:modelValue",E),i("reorder",E)}function g(){if(!b.value||s.value===null)return;const E=s.value,w=[...n.modelValue];[w[E-1],w[E]]=[w[E],w[E-1]],p(w,E-1)}function k(){if(!u.value||s.value===null)return;const E=s.value,w=[...n.modelValue];[w[E+1],w[E]]=[w[E],w[E+1]],p(w,E+1)}function y(){if(!b.value||s.value===null)return;const E=s.value,w=[...n.modelValue],[N]=w.splice(E,1);w.unshift(N),p(w,0)}function h(){if(!u.value||s.value===null)return;const E=s.value,w=[...n.modelValue],[N]=w.splice(E,1);w.push(N),p(w,w.length-1)}function B(E,w,N){if(!n.draggable){E.preventDefault();return}d.value=N,at(E,{sourceId:r,group:"",index:N,item:w})}function $(E,w){!n.draggable||!ie.value||ie.value.sourceId!==r||(E.preventDefault(),E.dataTransfer&&(E.dataTransfer.dropEffect="move"),c.value=w,o.value=Ce(E,E.currentTarget,"vertical"))}function _(E,w){if(E.preventDefault(),!n.draggable||!ie.value||ie.value.sourceId!==r){D();return}const N=ie.value.index;let C=(o.value??Ce(E,E.currentTarget,"vertical"))==="after"?w+1:w;if(N<C&&(C-=1),C!==N){const P=we(n.modelValue,N,C);p(P,C)}D()}function D(){d.value=null,c.value=null,o.value=null,st()}function S(E,w){if(!n.draggable||!E.altKey||E.key!=="ArrowUp"&&E.key!=="ArrowDown")return;const N=E.target;if(N!=null&&N.closest("input, textarea, select, button, a"))return;E.preventDefault();const V=E.key==="ArrowUp"?-1:1,C=w+V;if(C<0||C>=n.modelValue.length)return;const P=we(n.modelValue,w,C);p(P,C),e.nextTick(()=>{var T;(T=m.value[C])==null||T.focus()})}return(E,w)=>(e.openBlock(),e.createElementBlock("div",zu,[t.loading?(e.openBlock(),e.createElementBlock("div",Iu,[e.renderSlot(E.$slots,"loading",{},()=>[w[0]||(w[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.header||E.$slots.header?(e.openBlock(),e.createElementBlock("div",Ru,[e.renderSlot(E.$slots,"header",{},()=>[e.createElementVNode("span",Pu,e.toDisplayString(t.header),1)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Au,[e.createElementVNode("div",Fu,[e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!b.value,"aria-label":"Move to top",onClick:y},[...w[1]||(w[1]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 3.5H12M8 6V13M5 9L8 6L11 9",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,ju),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!b.value,"aria-label":"Move up",onClick:g},[...w[2]||(w[2]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 10L8 6L12 10",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Ku),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!u.value,"aria-label":"Move down",onClick:k},[...w[3]||(w[3]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Ou),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!u.value,"aria-label":"Move to bottom",onClick:h},[...w[4]||(w[4]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 12.5H12M8 10V3M5 7L8 10L11 7",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Hu)]),e.createElementVNode("ul",Uu,[!t.loading&&t.modelValue.length===0?(e.openBlock(),e.createElementBlock("li",Wu,[e.renderSlot(E.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(N,V)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(Be)(N,V,t.itemKey),ref_for:!0,ref:C=>f(C,V),class:e.normalizeClass(["order-list__item mfs-rounded-sm",{"order-list__item--selected":s.value===V,"order-list__item--dragging":d.value===V,"order-list__item--drop-before":c.value===V&&o.value==="before","order-list__item--drop-after":c.value===V&&o.value==="after"}]),role:"option","aria-selected":s.value===V,tabindex:"0",draggable:t.draggable,onClick:C=>s.value=V,onKeydown:[e.withKeys(e.withModifiers(C=>s.value=V,["prevent"]),["enter"]),e.withKeys(e.withModifiers(C=>s.value=V,["prevent"]),["space"]),C=>S(C,V)],onDragstart:C=>B(C,N,V),onDragover:C=>$(C,V),onDrop:C=>_(C,V),onDragend:D},[t.draggable?(e.openBlock(),e.createElementBlock("span",qu,"⋮⋮")):e.createCommentVNode("",!0),e.renderSlot(E.$slots,"item",{item:N,index:V,selected:s.value===V},()=>[e.createElementVNode("span",Yu,e.toDisplayString(N),1)],!0)],42,Gu))),128))])])]))}}),[["__scopeId","data-v-41107e3e"]]),Xu={class:"pick-list"},Zu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ju={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},Qu={key:0,class:"pick-list__header mfs-text"},vu={key:0,class:"mfs-empty-state"},ep=["aria-selected","draggable","onClick","onKeydown","onDragstart","onDragover","onDrop"],tp={class:"mfs-text"},lp={class:"pick-list__controls",role:"group","aria-label":"Transfer controls"},np=["disabled"],op=["disabled"],ap=["disabled"],sp=["disabled"],rp={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},ip={key:0,class:"pick-list__header mfs-text"},dp={key:0,class:"mfs-empty-state"},cp=["aria-selected","draggable","onClick","onKeydown","onDragstart","onDragover","onDrop"],mp={class:"mfs-text"},Cl=F(e.defineComponent({__name:"PickList",props:{source:{},target:{},itemKey:{default:"id"},sourceHeader:{default:"Available"},targetHeader:{default:"Selected"},loading:{type:Boolean,default:!1},emptySourceText:{default:"No items"},emptyTargetText:{default:"No items"},draggable:{type:Boolean,default:!0}},emits:["update:source","update:target","transfer"],setup(t,{emit:a}){let l=0;const n=t,i=a,r=`pick-list-${++l}`,s=e.ref([]),d=e.ref([]),c=e.ref(null),o=e.ref(null),m=e.ref(null);function f(C,P){return(C==="source"?s.value:d.value).includes(P)}function b(C,P){const T=C==="source"?s:d,I=T.value.indexOf(P);I>=0?T.value.splice(I,1):T.value.push(P)}function u(C,P){s.value=[],d.value=[],i("update:source",C),i("update:target",P),i("transfer",{source:C,target:P})}function p(){const C=new Set(s.value),P=n.source.filter((I,j)=>C.has(j)),T=n.source.filter((I,j)=>!C.has(j));u(T,[...n.target,...P])}function g(){u([],[...n.target,...n.source])}function k(){const C=new Set(d.value),P=n.target.filter((I,j)=>C.has(j)),T=n.target.filter((I,j)=>!C.has(j));u([...n.source,...P],T)}function y(){u([...n.source,...n.target],[])}function h(){return!!(n.draggable&&ie.value&&ie.value.group===r)}function B(){return ie.value?ie.value.sourceId.endsWith(":source")?"source":"target":null}function $(C,P,T,I){if(!n.draggable){C.preventDefault();return}c.value={list:P,index:I},at(C,{sourceId:`${r}:${P}`,group:r,index:I,item:T})}function _(C,P,T){if(!h())return;C.preventDefault(),C.dataTransfer&&(C.dataTransfer.dropEffect="move");const I=Ce(C,C.currentTarget,"vertical");o.value={list:P,index:T,position:I},m.value=P}function D(C,P){const T=ie.value,I=B();if(!T||!I)return;if(I===C){const K=C==="source"?n.source:n.target;let W=P===null?Math.max(0,K.length-1):P;if(P!==null&&T.index<W&&(W-=1),W!==T.index){const v=we(K,T.index,W);C==="source"?u(v,n.target):u(n.source,v)}return}const j=[...n.source],A=[...n.target];if(I==="source"){const[K]=j.splice(T.index,1),W=P===null?A.length:P;A.splice(W,0,K)}else{const[K]=A.splice(T.index,1),W=P===null?j.length:P;j.splice(W,0,K)}u(j,A)}function S(C,P,T){var A;if(C.preventDefault(),C.stopPropagation(),!h()){V();return}const j=(((A=o.value)==null?void 0:A.list)===P&&o.value.index===T?o.value.position:Ce(C,C.currentTarget,"vertical"))==="after"?T+1:T;D(P,j),V()}function E(C,P){h()&&(C.preventDefault(),C.dataTransfer&&(C.dataTransfer.dropEffect="move"),m.value=P)}function w(C,P){var I;!C.currentTarget.contains(C.relatedTarget)&&m.value===P&&(m.value=null,((I=o.value)==null?void 0:I.list)===P&&(o.value=null))}function N(C,P){if(C.preventDefault(),!h()){V();return}D(P,null),V()}function V(){c.value=null,o.value=null,m.value=null,st()}return(C,P)=>(e.openBlock(),e.createElementBlock("div",Xu,[t.loading?(e.openBlock(),e.createElementBlock("div",Zu,[e.renderSlot(C.$slots,"loading",{},()=>[P[6]||(P[6]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Ju,[t.sourceHeader?(e.openBlock(),e.createElementBlock("div",Qu,e.toDisplayString(t.sourceHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",{class:e.normalizeClass(["pick-list__list mfs-inset mfs-rounded-md",{"pick-list__list--drag-over":m.value==="source"}]),role:"listbox","aria-label":"Source items",onDragover:P[0]||(P[0]=T=>E(T,"source")),onDragleave:P[1]||(P[1]=T=>w(T,"source")),onDrop:P[2]||(P[2]=T=>N(T,"source"))},[!t.loading&&t.source.length===0?(e.openBlock(),e.createElementBlock("li",vu,[e.renderSlot(C.$slots,"empty-source",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptySourceText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.source,(T,I)=>{var j,A,K;return e.openBlock(),e.createElementBlock("li",{key:e.unref(Be)(T,I,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":f("source",I),"pick-list__item--dragging":((j=c.value)==null?void 0:j.list)==="source"&&c.value.index===I,"pick-list__item--drop-before":((A=o.value)==null?void 0:A.list)==="source"&&o.value.index===I&&o.value.position==="before","pick-list__item--drop-after":((K=o.value)==null?void 0:K.list)==="source"&&o.value.index===I&&o.value.position==="after"}]),role:"option","aria-selected":f("source",I),tabindex:"0",draggable:t.draggable,onClick:W=>b("source",I),onKeydown:[e.withKeys(e.withModifiers(W=>b("source",I),["prevent"]),["enter"]),e.withKeys(e.withModifiers(W=>b("source",I),["prevent"]),["space"])],onDragstart:W=>$(W,"source",T,I),onDragover:W=>_(W,"source",I),onDrop:W=>S(W,"source",I),onDragend:V},[e.renderSlot(C.$slots,"item",{item:T,index:I,list:"source"},()=>[e.createElementVNode("span",tp,e.toDisplayString(T),1)],!0)],42,ep)}),128))],34)]),e.createElementVNode("div",lp,[e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:s.value.length===0,"aria-label":"Move selected to target",onClick:p},[...P[7]||(P[7]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,np),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:t.source.length===0,"aria-label":"Move all to target",onClick:g},[...P[8]||(P[8]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 4L8 8L4 12M9 4L13 8L9 12",stroke:"currentColor","stroke-width":"1.7","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,op),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:d.value.length===0,"aria-label":"Move selected to source",onClick:k},[...P[9]||(P[9]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M10 4L6 8L10 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,ap),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:t.target.length===0,"aria-label":"Move all to source",onClick:y},[...P[10]||(P[10]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M12 4L8 8L12 12M7 4L3 8L7 12",stroke:"currentColor","stroke-width":"1.7","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,sp)]),e.createElementVNode("div",rp,[t.targetHeader?(e.openBlock(),e.createElementBlock("div",ip,e.toDisplayString(t.targetHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",{class:e.normalizeClass(["pick-list__list mfs-inset mfs-rounded-md",{"pick-list__list--drag-over":m.value==="target"}]),role:"listbox","aria-label":"Target items",onDragover:P[3]||(P[3]=T=>E(T,"target")),onDragleave:P[4]||(P[4]=T=>w(T,"target")),onDrop:P[5]||(P[5]=T=>N(T,"target"))},[!t.loading&&t.target.length===0?(e.openBlock(),e.createElementBlock("li",dp,[e.renderSlot(C.$slots,"empty-target",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyTargetText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.target,(T,I)=>{var j,A,K;return e.openBlock(),e.createElementBlock("li",{key:e.unref(Be)(T,I,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":f("target",I),"pick-list__item--dragging":((j=c.value)==null?void 0:j.list)==="target"&&c.value.index===I,"pick-list__item--drop-before":((A=o.value)==null?void 0:A.list)==="target"&&o.value.index===I&&o.value.position==="before","pick-list__item--drop-after":((K=o.value)==null?void 0:K.list)==="target"&&o.value.index===I&&o.value.position==="after"}]),role:"option","aria-selected":f("target",I),tabindex:"0",draggable:t.draggable,onClick:W=>b("target",I),onKeydown:[e.withKeys(e.withModifiers(W=>b("target",I),["prevent"]),["enter"]),e.withKeys(e.withModifiers(W=>b("target",I),["prevent"]),["space"])],onDragstart:W=>$(W,"target",T,I),onDragover:W=>_(W,"target",I),onDrop:W=>S(W,"target",I),onDragend:V},[e.renderSlot(C.$slots,"item",{item:T,index:I,list:"target"},()=>[e.createElementVNode("span",mp,e.toDisplayString(T),1)],!0)],42,cp)}),128))],34)])]))}}),[["__scopeId","data-v-1e7b14e0"]]),fp={class:"tree-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card"},up={class:"tree-table__wrap"},pp={class:"tree-table__table"},kp={key:0},hp=["colspan"],gp=["aria-expanded","aria-label","onClick"],yp={key:1,class:"tree-table__spacer","aria-hidden":"true"},bp={key:0,class:"mfs-loading-overlay","aria-busy":"true"},Nl=F(e.defineComponent({__name:"TreeTable",props:{columns:{},nodes:{},expandedKeys:{default:()=>[]},emptyText:{default:"No data available"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1}},emits:["update:expandedKeys","node-toggle","lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref([...l.expandedKeys]);e.watch(()=>l.expandedKeys,d=>{i.value=[...d]});const r=e.computed(()=>{const d=[],c=new Set(i.value);function o(m,f){for(const b of m){const u=Array.isArray(b.children)&&b.children.length>0||l.lazy&&b.leaf!==!0,p=u&&c.has(b.key);d.push({node:b,depth:f,hasChildren:u,expanded:p}),p&&b.children&&o(b.children,f+1)}}return o(l.nodes,0),d});function s(d){const c=new Set(i.value),o=!c.has(d.key);o?c.add(d.key):c.delete(d.key);const m=Array.from(c);i.value=m,n("update:expandedKeys",m),n("node-toggle",d,o),o&&l.lazy&&(!d.children||d.children.length===0)&&n("lazy-load",d)}return(d,c)=>(e.openBlock(),e.createElementBlock("div",fp,[e.createElementVNode("div",up,[e.createElementVNode("table",pp,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,o=>(e.openBlock(),e.createElementBlock("th",{key:o.key,class:e.normalizeClass(["tree-table__th mfs-text-muted",o.align?`tree-table__cell--${o.align}`:""]),style:e.normalizeStyle(o.width?{width:o.width}:void 0)},e.toDisplayString(o.label),7))),128))])]),e.createElementVNode("tbody",null,[r.value.length===0?(e.openBlock(),e.createElementBlock("tr",kp,[e.createElementVNode("td",{colspan:t.columns.length,class:"tree-table__empty mfs-text-muted"},[e.renderSlot(d.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)],8,hp)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.value,o=>(e.openBlock(),e.createElementBlock("tr",{key:o.node.key,class:"tree-table__row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,(m,f)=>(e.openBlock(),e.createElementBlock("td",{key:m.key,class:e.normalizeClass(["tree-table__td mfs-text",m.align?`tree-table__cell--${m.align}`:""])},[f===0?(e.openBlock(),e.createElementBlock("div",{key:0,class:"tree-table__first-cell",style:e.normalizeStyle({paddingLeft:`${o.depth*20}px`})},[o.hasChildren?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree-table__toggle mfs-text-muted",{"tree-table__toggle--expanded":o.expanded}]),"aria-expanded":o.expanded,"aria-label":o.expanded?"Collapse row":"Expand row",onClick:b=>s(o.node)},[...c[0]||(c[0]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,gp)):(e.openBlock(),e.createElementBlock("span",yp)),e.renderSlot(d.$slots,`cell-${m.key}`,{node:o.node,value:o.node.data[m.key],depth:o.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(o.node.data[m.key]??""),1)],!0)],4)):e.renderSlot(d.$slots,`cell-${m.key}`,{node:o.node,value:o.node.data[m.key],depth:o.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(o.node.data[m.key]??""),1)],!0,1)],2))),128))]))),128))])])]),t.loading?(e.openBlock(),e.createElementBlock("div",bp,[e.renderSlot(d.$slots,"loading",{},()=>[c[1]||(c[1]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-5d1be205"]]),Bp=["aria-busy"],wp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},_p={key:1,class:"mfs-empty-state"},Ep={class:"org-chart__node-wrap"},$p={class:"org-chart__label mfs-title"},Vp={key:0,class:"org-chart__title mfs-caption"},xp=["aria-expanded","aria-label"],Cp={key:0,class:"org-chart__children"},Sl=F(e.defineComponent({name:"OrganizationChart",__name:"OrganizationChart",props:{value:{default:null},collapsible:{type:Boolean,default:!0},expandedKeys:{default:void 0},level:{default:0},loading:{type:Boolean,default:!1},emptyText:{default:"No data"}},emits:["update:expandedKeys","node-click"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!0),r=e.computed(()=>{var c;return Array.isArray((c=l.value)==null?void 0:c.children)&&l.value.children.length>0}),s=e.computed(()=>l.value?l.expandedKeys?l.expandedKeys.includes(l.value.key):i.value:!1);e.watch(()=>l.expandedKeys,()=>{l.expandedKeys&&l.value&&(i.value=l.expandedKeys.includes(l.value.key))});function d(){if(!(!l.value||!r.value))if(l.expandedKeys){const c=new Set(l.expandedKeys);c.has(l.value.key)?c.delete(l.value.key):c.add(l.value.key),n("update:expandedKeys",Array.from(c))}else i.value=!i.value}return(c,o)=>{const m=e.resolveComponent("OrganizationChart",!0);return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["org-chart mfs-relative",{"org-chart--root":t.level===0,"org-chart--loading-empty":t.level===0&&t.loading&&!t.value}]),"aria-busy":t.level===0&&t.loading?!0:void 0},[t.level===0&&t.loading?(e.openBlock(),e.createElementBlock("div",wp,[e.renderSlot(c.$slots,"loading",{},()=>[o[4]||(o[4]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.value&&!t.loading?(e.openBlock(),e.createElementBlock("div",_p,[e.renderSlot(c.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):t.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("div",Ep,[e.createElementVNode("div",{class:"org-chart__node mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-focus-ring",tabindex:"0",onClick:o[0]||(o[0]=f=>c.$emit("node-click",t.value)),onKeydown:o[1]||(o[1]=e.withKeys(e.withModifiers(f=>c.$emit("node-click",t.value),["prevent"]),["enter"]))},[e.renderSlot(c.$slots,"node",{node:t.value,expanded:s.value},()=>[e.createElementVNode("div",$p,e.toDisplayString(t.value.label),1),t.value.title?(e.openBlock(),e.createElementBlock("div",Vp,e.toDisplayString(t.value.title),1)):e.createCommentVNode("",!0)],!0)],32),t.collapsible&&r.value?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"org-chart__toggle mfs-surface-subtle mfs-pill mfs-shadow","aria-expanded":s.value,"aria-label":s.value?`Collapse ${t.value.label}`:`Expand ${t.value.label}`,onClick:e.withModifiers(d,["stop"])},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass({"org-chart__chevron--collapsed":!s.value}),viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[...o[5]||(o[5]=[e.createElementVNode("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2))],8,xp)):e.createCommentVNode("",!0)]),r.value&&s.value?(e.openBlock(),e.createElementBlock("div",Cp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value.children,f=>(e.openBlock(),e.createElementBlock("div",{key:f.key,class:"org-chart__branch"},[e.createVNode(m,{value:f,collapsible:t.collapsible,"expanded-keys":t.expandedKeys,level:t.level+1,"onUpdate:expandedKeys":o[2]||(o[2]=b=>c.$emit("update:expandedKeys",b)),onNodeClick:o[3]||(o[3]=b=>c.$emit("node-click",b))},e.createSlots({_:2},[c.$slots.node?{name:"node",fn:e.withCtx(b=>[e.renderSlot(c.$slots,"node",e.mergeProps({ref_for:!0},b),void 0,!0)]),key:"0"}:void 0]),1032,["value","collapsible","expanded-keys","level"])]))),128))])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],10,Bp)}}}),[["__scopeId","data-v-426d2664"]]),Np={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Sp={key:1,class:"mfs-empty-state"},Mp={class:"mfs-text"},Ml=F(e.defineComponent({__name:"VirtualScroller",props:{items:{},itemSize:{},height:{default:"300px"},buffer:{default:3},itemKey:{default:"id"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No items"}},emits:["lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(0),s=e.ref(300);e.onMounted(()=>{i.value&&(s.value=i.value.clientHeight||300)});function d(){i.value&&(r.value=i.value.scrollTop,s.value=i.value.clientHeight||s.value,l.lazy&&n("lazy-load",{first:o.value,last:m.value}))}const c=e.computed(()=>l.items.length*l.itemSize),o=e.computed(()=>{const u=Math.floor(r.value/l.itemSize)-l.buffer;return Math.max(0,u)}),m=e.computed(()=>{const u=Math.ceil(s.value/l.itemSize),p=Math.floor(r.value/l.itemSize)+u+l.buffer;return Math.min(l.items.length,p)}),f=e.computed(()=>o.value*l.itemSize),b=e.computed(()=>l.items.slice(o.value,m.value).map((u,p)=>({item:u,index:o.value+p})));return(u,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:i,class:"virtual-scroller mfs-surface mfs-rounded mfs-shadow-card",style:e.normalizeStyle({height:t.height}),onScroll:d},[t.loading?(e.openBlock(),e.createElementBlock("div",Np,[e.renderSlot(u.$slots,"loading",{},()=>[p[0]||(p[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):t.items.length===0?(e.openBlock(),e.createElementBlock("div",Sp,[e.renderSlot(u.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"virtual-scroller__spacer",style:e.normalizeStyle({height:`${c.value}px`})},[e.createElementVNode("div",{class:"virtual-scroller__content",style:e.normalizeStyle({transform:`translateY(${f.value}px)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,g=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(Be)(g.item,g.index,t.itemKey),class:"virtual-scroller__item",style:e.normalizeStyle({height:`${t.itemSize}px`})},[e.renderSlot(u.$slots,"item",{item:g.item,index:g.index},()=>[e.createElementVNode("span",Mp,e.toDisplayString(g.item),1)],!0)],4))),128))],4)],4))],36))}}),[["__scopeId","data-v-5a8d047c"]]),Dp={class:"meter-group mfs-card"},Tp=["aria-valuenow","aria-valuemax"],Lp=["title"],zp={key:0,class:"meter-group__legend"},Ip={class:"meter-group__label mfs-text"},Rp={class:"meter-group__value mfs-text-muted"},Dl=F(e.defineComponent({__name:"MeterGroup",props:{values:{},max:{default:100},showLegend:{type:Boolean,default:!0}},setup(t){const a=t,l=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)"],n=e.computed(()=>a.values.reduce((s,d)=>s+Math.max(0,d.value),0));function i(s){const d=a.max>0?a.max:100;return Math.min(100,Math.max(0,s/d*100))}function r(s){return l[s%l.length]}return(s,d)=>(e.openBlock(),e.createElementBlock("div",Dp,[e.createElementVNode("div",{class:"meter-group__track mfs-inset mfs-pill",role:"progressbar","aria-valuenow":n.value,"aria-valuemin":"0","aria-valuemax":t.max},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(c,o)=>(e.openBlock(),e.createElementBlock("div",{key:c.label,class:"meter-group__segment",style:e.normalizeStyle({width:`${i(c.value)}%`,backgroundColor:c.color||r(o)}),title:`${c.label}: ${c.value}`},null,12,Lp))),128))],8,Tp),t.showLegend?(e.openBlock(),e.createElementBlock("ol",zp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(c,o)=>(e.openBlock(),e.createElementBlock("li",{key:c.label,class:"meter-group__legend-item"},[e.createElementVNode("span",{class:"meter-group__dot mfs-pill",style:e.normalizeStyle({backgroundColor:c.color||r(o)}),"aria-hidden":"true"},null,4),e.createElementVNode("span",Ip,e.toDisplayString(c.label),1),e.createElementVNode("span",Rp,e.toDisplayString(c.value)+" ("+e.toDisplayString(Math.round(i(c.value)))+"%)",1)]))),128))])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7ff895f3"]]),Pp={class:"inplace"},Ap=["tabindex","aria-disabled","onKeydown"],Fp={class:"inplace__inner"},Tl=F(e.defineComponent({__name:"Inplace",props:{active:{type:Boolean,default:!1},closable:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["update:active","open","close"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.active);e.watch(()=>l.active,c=>{i.value=c});const r=e.computed(()=>i.value);function s(){l.disabled||r.value||(i.value=!0,n("update:active",!0),n("open"))}function d(){r.value&&(i.value=!1,n("update:active",!1),n("close"))}return(c,o)=>(e.openBlock(),e.createElementBlock("div",Pp,[r.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"inplace__content mfs-surface mfs-rounded-md mfs-shadow",onKeydown:e.withKeys(d,["esc"])},[e.createElementVNode("div",Fp,[e.renderSlot(c.$slots,"content",{},void 0,!0)]),t.closable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"inplace__close mfs-surface-subtle mfs-rounded-sm mfs-interactive","aria-label":"Close",onClick:d},[...o[1]||(o[1]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 4L12 12M12 4L4 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round"})],-1)])])):e.createCommentVNode("",!0)],32)):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["inplace__display mfs-surface-subtle mfs-rounded-sm mfs-interactive mfs-focus-ring",{"inplace__display--disabled mfs-disabled":t.disabled}]),role:"button",tabindex:t.disabled?-1:0,"aria-disabled":t.disabled||void 0,onClick:s,onKeydown:[e.withKeys(e.withModifiers(s,["prevent"]),["enter"]),e.withKeys(e.withModifiers(s,["prevent"]),["space"])]},[e.renderSlot(c.$slots,"display",{},()=>[o[0]||(o[0]=e.createElementVNode("span",{class:"mfs-text-muted"},"Click to edit",-1))],!0)],42,Ap))]))}}),[["__scopeId","data-v-befa9d74"]]),jp={class:"sortable-list__sr-only","aria-live":"polite"},Kp={key:0,class:"mfs-empty-state mfs-text-muted"},Op=["data-sortable-index","aria-grabbed","tabindex","onPointerdown","onKeydown"],qe=F(e.defineComponent({__name:"SortableList",props:{modelValue:{},itemKey:{default:"id"},group:{default:""},handle:{default:""},disabled:{type:Boolean,default:!1},orientation:{default:"vertical"},emptyText:{default:"Drop items here"}},emits:["update:modelValue","reorder","transfer"],setup(t,{emit:a}){let l=0;const n=t,i=a,r=`sortable-${++l}`,s=e.ref(null),d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref(!1),f=e.ref(""),b=e.ref([]);let u=null,p=null,g=null,k=null;function y(T,I){b.value[I]=T instanceof HTMLElement?T:null}function h(T,I,j){c.value=T,o.value=I,m.value=j}function B(T,I){const j=we(n.modelValue,T,I);i("update:modelValue",j),i("reorder",{value:j,fromIndex:T,toIndex:I})}function $(T){const I=[...n.modelValue];I.splice(T,1),i("update:modelValue",I)}function _(T,I,j,A){const K=[...n.modelValue],W=j<0||j>K.length?K.length:j;K.splice(W,0,T),i("update:modelValue",K),i("transfer",{item:T,fromIndex:I,toIndex:W,fromGroup:A})}e.onMounted(()=>{Mu({listId:r,getGroup:()=>n.group,getOrientation:()=>n.orientation,isDisabled:()=>n.disabled,setDropIndicator:h,onReorder:B,onReceive:_,onRemove:$})}),e.onUnmounted(()=>{C(),Du(r)});function D(T,I){const j=T.cloneNode(!0);return j.classList.add("sortable-list__floating-preview"),j.style.width=`${I.width}px`,j.style.height=`${I.height}px`,j.style.position="fixed",j.style.top="0",j.style.left="0",j.style.margin="0",j.style.pointerEvents="none",j.style.zIndex="9999",document.body.appendChild(j),j}function S(T,I,j){if(!T||!u)return;const A=I-u.offsetX,K=j-u.offsetY;T.style.transform=`translate3d(${A}px, ${K}px, 0) scale(1.02) rotate(0.75deg)`}function E(T,I,j){if(n.disabled||T.button!==0)return;const A=T.target;if(n.handle){if(!(A!=null&&A.closest(n.handle)))return}else if(A!=null&&A.closest("input, textarea, select, button, a"))return;C();const K=T.currentTarget,W=K.getBoundingClientRect();u={item:I,index:j,itemEl:K,rect:W,startX:T.clientX,startY:T.clientY,offsetX:T.clientX-W.left,offsetY:T.clientY-W.top,started:!1,previewEl:null},window.addEventListener("pointermove",w),window.addEventListener("pointerup",N),window.addEventListener("pointercancel",V)}function w(T){var te;if(!u)return;if(!u.started){const oe=T.clientX-u.startX,z=T.clientY-u.startY;if(Math.hypot(oe,z)<=4)return;u.started=!0,s.value=u.index,u.previewEl=D(u.itemEl,u.rect)}S(u.previewEl,T.clientX,T.clientY);const I=document.elementFromPoint(T.clientX,T.clientY),j=I==null?void 0:I.closest("[data-sortable-id]"),A=(j==null?void 0:j.dataset.sortableId)??null,K=A?Ge(A):void 0,W=!!(K&&!K.isDisabled()&&(K.listId===r||n.group&&K.getGroup()===n.group));if(p&&p!==(W?A:null)&&((te=Ge(p))==null||te.setDropIndicator(null,null,!1)),!W||!K){p=null,g=null,k=null;return}p=K.listId;const v=I==null?void 0:I.closest("[data-sortable-index]");if(v&&(j!=null&&j.contains(v))){const oe=Number(v.dataset.sortableIndex),z=Tu(T.clientX,T.clientY,v,K.getOrientation());g=oe,k=z,K.setDropIndicator(oe,z,!0)}else g=null,k=null,K.setDropIndicator(null,null,!0)}function N(){if(u!=null&&u.started&&p){const T=Ge(p);if(T)if(T.listId===r){let I=g!==null&&k!==null?k==="after"?g+1:g:Math.max(0,n.modelValue.length-1);g!==null&&u.index<I&&(I-=1),I!==u.index&&T.onReorder(u.index,I)}else{const I=g!==null&&k!==null?k==="after"?g+1:g:-1;$(u.index),T.onReceive(u.item,u.index,I,n.group)}}C()}function V(){C()}function C(){var T;window.removeEventListener("pointermove",w),window.removeEventListener("pointerup",N),window.removeEventListener("pointercancel",V),p&&((T=Ge(p))==null||T.setDropIndicator(null,null,!1)),u!=null&&u.previewEl&&u.previewEl.remove(),u=null,p=null,g=null,k=null,s.value=null,h(null,null,!1)}function P(T,I){if(n.disabled)return;const j=T.target;if(j!=null&&j.closest("input, textarea, select, button, a"))return;if(T.key===" "||T.code==="Space"){T.preventDefault(),d.value===I?(d.value=null,f.value=`Item dropped at position ${I+1}`):(d.value=I,f.value=`Item grabbed at position ${I+1} of ${n.modelValue.length}`);return}if(T.key==="Escape"&&d.value!==null){T.preventDefault(),d.value=null,f.value="Reorder cancelled";return}const A=n.orientation==="horizontal"?"ArrowLeft":"ArrowUp",K=n.orientation==="horizontal"?"ArrowRight":"ArrowDown";if((T.key===A||T.key===K)&&(d.value===I||T.altKey)){T.preventDefault();const W=T.key===A?-1:1,v=I+W;if(v<0||v>=n.modelValue.length)return;const te=we(n.modelValue,I,v);d.value===I&&(d.value=v),i("update:modelValue",te),i("reorder",{value:te,fromIndex:I,toIndex:v}),f.value=`Moved item to position ${v+1} of ${te.length}`,e.nextTick(()=>{var oe;(oe=b.value[v])==null||oe.focus()})}}return(T,I)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["sortable-list mfs-inset mfs-rounded-md mfs-p-2 mfs-flex mfs-gap-2",[t.orientation==="horizontal"?"sortable-list--horizontal":"mfs-flex-col sortable-list--vertical",{"sortable-list--drag-over":m.value,"sortable-list--disabled":t.disabled}]]),"data-sortable-id":r,role:"list"},[e.createElementVNode("span",jp,e.toDisplayString(f.value),1),t.modelValue.length===0?(e.openBlock(),e.createElementBlock("div",Kp,[e.renderSlot(T.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(j,A)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(Be)(j,A,t.itemKey),ref_for:!0,ref:K=>y(K,A),class:e.normalizeClass(["sortable-list__item mfs-surface mfs-rounded-sm mfs-text",{"sortable-list__item--no-handle":!t.handle&&!t.disabled,"sortable-list__item--dragging":s.value===A,"sortable-list__item--grabbed":d.value===A,"sortable-list__item--drop-before":c.value===A&&o.value==="before","sortable-list__item--drop-after":c.value===A&&o.value==="after"}]),"data-sortable-index":A,role:"listitem","aria-roledescription":"sortable item","aria-grabbed":d.value===A,tabindex:t.disabled?-1:0,onPointerdown:K=>E(K,j,A),onKeydown:K=>P(K,A)},[e.renderSlot(T.$slots,"item",{item:j,index:A,dragging:s.value===A,grabbed:d.value===A},()=>[e.createElementVNode("span",null,e.toDisplayString(j),1)],!0)],42,Op))),128))],2))}}),[["__scopeId","data-v-58181902"]]),Hp={class:"mfs-flex mfs-items-start mfs-gap-2-5 mfs-mb-3"},Up={class:"mfs-confirm-popup__message mfs-text mfs-m-0"},Wp={class:"mfs-flex mfs-justify-end mfs-gap-2"},Ll=F(e.defineComponent({__name:"ConfirmPopup",props:{modelValue:{type:Boolean,default:void 0},target:{default:null},message:{default:"Are you sure you want to proceed?"},acceptLabel:{default:"Yes"},rejectLabel:{default:"No"},variant:{default:"primary"}},emits:["update:modelValue","accept","reject"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(null),s=e.ref(!1),d=e.ref(null),c=e.ref({}),o=e.ref({top:0,left:0}),m=e.computed(()=>n.modelValue!==void 0),f=e.computed(()=>m.value?!!n.modelValue:s.value),b=e.computed(()=>c.value.message??n.message),u=e.computed(()=>c.value.acceptLabel??n.acceptLabel),p=e.computed(()=>c.value.rejectLabel??n.rejectLabel),g=e.computed(()=>c.value.variant??n.variant),k=e.computed(()=>({top:`${o.value.top}px`,left:`${o.value.left}px`}));function y(N){return N?N instanceof HTMLElement?N:N.currentTarget??N.target:null}async function h(){var I;await e.nextTick();const N=d.value??y(n.target);if(!N||typeof window>"u")return;const V=N.getBoundingClientRect(),C=((I=r.value)==null?void 0:I.offsetWidth)??260,P=Math.min(Math.max(12,V.left+V.width/2-C/2),window.innerWidth-C-12),T=V.bottom+10;o.value={top:T,left:P}}function B(N){m.value||(s.value=N),i("update:modelValue",N)}function $(N,V={}){d.value=y(N),c.value=V,B(!0),h()}function _(){B(!1)}function D(){var N,V;(V=(N=c.value).onAccept)==null||V.call(N),i("accept"),_()}function S(){var N,V;(V=(N=c.value).onReject)==null||V.call(N),i("reject"),_()}const E=N=>{var P;const V=N.target,C=d.value??y(n.target);(P=r.value)!=null&&P.contains(V)||C!=null&&C.contains(V)||_()},w=N=>{N.key==="Escape"&&_()};return e.watch(f,N=>{typeof document>"u"||(N?(h(),document.addEventListener("pointerdown",E),document.addEventListener("keydown",w)):(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",w)))}),e.onBeforeUnmount(()=>{typeof document<"u"&&(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",w))}),a({show:$,hide:_}),(N,V)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-popup"},{default:e.withCtx(()=>[f.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"popupRef",ref:r,class:"mfs-confirm-popup mfs-fixed mfs-overlay mfs-surface mfs-rounded mfs-shadow-card mfs-blur",style:e.normalizeStyle(k.value),role:"alertdialog","aria-modal":"false"},[e.createElementVNode("div",Hp,[e.createElementVNode("span",{class:e.normalizeClass(["mfs-confirm-popup__icon mfs-shrink-0",[`mfs-text-${g.value}`]]),"aria-hidden":"true"},[...V[0]||(V[0]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"}),e.createElementVNode("path",{d:"M12 8v4"}),e.createElementVNode("path",{d:"M12 16h.01"})],-1)])],2),e.createElementVNode("p",Up,e.toDisplayString(b.value),1)]),e.createElementVNode("div",Wp,[e.createElementVNode("button",{type:"button",class:"mfs-confirm-popup__btn mfs-surface-subtle mfs-pill mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",onClick:S},e.toDisplayString(p.value),1),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-confirm-popup__btn mfs-pill mfs-shadow mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",[`mfs-bg-${g.value}`]]),onClick:D},e.toDisplayString(u.value),3)])],4)):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-57b1abca"]]),Gp={class:"mfs-inline-msg__icon","aria-hidden":"true"},qp={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Yp={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Xp={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Zp={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Jp={class:"mfs-inline-msg__text"},zl=F(e.defineComponent({__name:"InlineMessage",props:{severity:{default:"info"},text:{default:""}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["mfs-inline-msg mfs-rounded-sm",[`mfs-inline-msg--${t.severity}`,t.severity==="info"?"mfs-soft-primary":`mfs-soft-${t.severity}`]]),role:"status"},[e.createElementVNode("span",Gp,[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",qp,[...l[0]||(l[0]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):t.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",Yp,[...l[1]||(l[1]=[e.createElementVNode("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"},null,-1),e.createElementVNode("path",{d:"M12 9v4"},null,-1),e.createElementVNode("path",{d:"M12 17h.01"},null,-1)])])):t.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",Xp,[...l[2]||(l[2]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m15 9-6 6"},null,-1),e.createElementVNode("path",{d:"m9 9 6 6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Zp,[...l[3]||(l[3]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"M12 16v-4"},null,-1),e.createElementVNode("path",{d:"M12 8h.01"},null,-1)])]))]),e.createElementVNode("span",Jp,[e.renderSlot(a.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.text),1)],!0)])],2))}}),[["__scopeId","data-v-40ba4b5c"]]),Qp=["aria-busy"],vp=["aria-label"],ek={class:"mfs-blockui__content mfs-surface mfs-rounded mfs-shadow"},tk={key:0,class:"mfs-blockui__label mfs-text"},Il=F(e.defineComponent({__name:"BlockUI",props:{blocked:{type:Boolean,default:!1},fullScreen:{type:Boolean,default:!1},label:{default:""}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-blockui","aria-busy":t.blocked},[e.renderSlot(a.$slots,"default",{},void 0,!0),(e.openBlock(),e.createBlock(e.Teleport,{to:"body",disabled:!t.fullScreen},[e.createVNode(e.Transition,{name:"mfs-blockui-fade"},{default:e.withCtx(()=>[t.blocked?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-blockui__overlay mfs-backdrop",{"mfs-blockui__overlay--fullscreen":t.fullScreen,"mfs-rounded":!t.fullScreen}]),role:"status","aria-label":t.label||"Loading"},[e.renderSlot(a.$slots,"overlay",{},()=>[e.createElementVNode("div",ek,[l[0]||(l[0]=e.createElementVNode("span",{class:"mfs-blockui__spinner","aria-hidden":"true"},[e.createElementVNode("svg",{viewBox:"0 0 50 50"},[e.createElementVNode("circle",{cx:"25",cy:"25",r:"20",fill:"none",stroke:"currentColor","stroke-width":"4","stroke-linecap":"round","stroke-dasharray":"90 150"})])],-1)),t.label?(e.openBlock(),e.createElementBlock("span",tk,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)])],!0)],10,vp)):e.createCommentVNode("",!0)]),_:3})],8,["disabled"]))],8,Qp))}}),[["__scopeId","data-v-59ef354e"]]),lk=["aria-busy","onKeydown"],nk={class:"mfs-galleria__stage"},ok={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ak={key:1,class:"mfs-empty-state"},sk=["src","alt"],rk=["aria-label"],ik={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},dk={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},ck={key:4,class:"mfs-galleria__caption"},mk={key:0,class:"mfs-galleria__thumbs"},fk=["aria-label","onClick"],uk=["src","alt"],Rl=F(e.defineComponent({__name:"Galleria",props:{images:{default:()=>[]},activeIndex:{default:0},showThumbnails:{type:Boolean,default:!0},fullscreen:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},emptyText:{default:"No images"}},emits:["update:activeIndex"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.activeIndex),r=e.ref(l.fullscreen);e.watch(()=>l.activeIndex,m=>{i.value=m});const s=e.computed(()=>l.images[i.value]??null),d=m=>{if(l.images.length===0)return;const f=(m+l.images.length)%l.images.length;i.value=f,n("update:activeIndex",f)},c=()=>d(i.value-1),o=()=>d(i.value+1);return(m,f)=>{var b;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-galleria mfs-surface mfs-rounded mfs-shadow-card mfs-blur",{"mfs-galleria--fullscreen":r.value}]),"aria-busy":t.loading||void 0,tabindex:"0",onKeydown:[e.withKeys(e.withModifiers(c,["prevent"]),["left"]),e.withKeys(e.withModifiers(o,["prevent"]),["right"]),f[1]||(f[1]=e.withKeys(u=>r.value=!1,["escape"]))]},[e.createElementVNode("div",nk,[t.loading?(e.openBlock(),e.createElementBlock("div",ok,[e.renderSlot(m.$slots,"loading",{},()=>[f[2]||(f[2]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.images.length===0?(e.openBlock(),e.createElementBlock("div",ak,[e.renderSlot(m.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[s.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:s.value.src,alt:s.value.alt||s.value.title||"Gallery image",class:"mfs-galleria__image"},null,8,sk)):e.createCommentVNode("",!0),t.images.length>1?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"mfs-galleria__nav mfs-galleria__nav--prev mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":"Previous image",onClick:c},[...f[3]||(f[3]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"m15 18-6-6 6-6"})],-1)])])):e.createCommentVNode("",!0),t.images.length>1?(e.openBlock(),e.createElementBlock("button",{key:2,type:"button",class:"mfs-galleria__nav mfs-galleria__nav--next mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":"Next image",onClick:o},[...f[4]||(f[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"m9 18 6-6-6-6"})],-1)])])):e.createCommentVNode("",!0),t.images.length>0?(e.openBlock(),e.createElementBlock("button",{key:3,type:"button",class:"mfs-galleria__fs mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":r.value?"Exit fullscreen":"Enter fullscreen",onClick:f[0]||(f[0]=u=>r.value=!r.value)},[r.value?(e.openBlock(),e.createElementBlock("svg",dk,[...f[6]||(f[6]=[e.createElementVNode("path",{d:"M4 14h6v6M20 10h-6V4M14 10l7-7M3 21l7-7"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",ik,[...f[5]||(f[5]=[e.createElementVNode("path",{d:"M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"},null,-1)])]))],8,rk)):e.createCommentVNode("",!0),(b=s.value)!=null&&b.title?(e.openBlock(),e.createElementBlock("div",ck,e.toDisplayString(s.value.title),1)):e.createCommentVNode("",!0)],64))]),t.showThumbnails&&t.images.length>1?(e.openBlock(),e.createElementBlock("div",mk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(u,p)=>(e.openBlock(),e.createElementBlock("button",{key:p,type:"button",class:e.normalizeClass(["mfs-galleria__thumb mfs-rounded-sm",{"mfs-galleria__thumb--active":p===i.value}]),"aria-label":`View image ${p+1}`,onClick:g=>d(p)},[e.createElementVNode("img",{src:u.thumbnail||u.src,alt:u.alt||`Thumbnail ${p+1}`},null,8,uk)],10,fk))),128))])):e.createCommentVNode("",!0)],42,lk)}}}),[["__scopeId","data-v-c26e7cc6"]]),pk=["disabled"],kk=["onKeydown"],hk=["src"],gk={key:2,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},yk={key:3,class:"mfs-cropper__controls mfs-flex mfs-flex-col mfs-gap-3"},bk={class:"mfs-row mfs-justify-between"},Bk={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-1 mfs-min-w-0"},wk=["disabled"],_k=["disabled"],Ek=["disabled"],$k={class:"mfs-flex mfs-items-center mfs-gap-1-5 mfs-shrink-0"},Vk=["disabled"],xk=["disabled"],Ck=["disabled"],Nk={class:"mfs-row mfs-justify-between mfs-flex-wrap mfs-gap-2"},Sk={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-wrap"},Mk=["disabled"],Dk={key:0,class:"mfs-cropper__shape-toggle mfs-inline-flex mfs-surface-subtle mfs-rounded-sm mfs-border mfs-gap-1",role:"group","aria-label":"Crop shape"},Tk=["aria-pressed","disabled"],Lk=["aria-pressed","disabled"],zk={class:"mfs-flex mfs-items-center mfs-gap-2"},Ik=["disabled"],Rk=["disabled"],rt=F(e.defineComponent({__name:"ImageCropper",props:{modelValue:{default:null},src:{default:null},aspectRatio:{default:1},shape:{default:"rect"},allowShapeToggle:{type:Boolean,default:!0},outputType:{default:"image/png"},outputSize:{default:512},quality:{default:.92},fileName:{default:"cropped-image.png"},showControls:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","update:shape","crop","cancel","error"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref(!1),f=e.ref(null),b=e.ref(!1),u=e.ref(!1),p=e.ref(0),g=e.ref(0),k=e.ref(320),y=e.ref(260),h=e.ref(1),B=e.ref(0),$=e.ref(0),_=e.ref(0),D=e.ref(!1);let S=0,E=0,w=0,N=0,V=null;const C=e.ref(n.shape);e.watch(()=>n.shape,M=>{C.value=M});function P(M){n.disabled||C.value===M||(C.value=M,i("update:shape",M))}const T=e.computed(()=>o.value?o.value:n.src?n.src:typeof n.modelValue=="string"&&n.modelValue?n.modelValue:c.value?c.value:null),I=e.computed(()=>C.value==="circle"?1:n.aspectRatio>0?n.aspectRatio:1),j=e.computed(()=>{const M=Math.max(80,k.value*.82),x=Math.max(80,y.value*.82),R=I.value;let H=M,X=H/R;return X>x&&(X=x,H=X*R),{width:H,height:X}}),A=e.computed(()=>Math.abs(B.value%180)===90),K=e.computed(()=>{if(!p.value||!g.value)return 1;const M=A.value?g.value:p.value,x=A.value?p.value:g.value;return Math.max(j.value.width/M,j.value.height/x)}),W=e.computed(()=>K.value*h.value);function v(M,x,R){return Math.min(R,Math.max(x,M))}function te(){if(!p.value||!g.value)return;const M=A.value?g.value:p.value,x=A.value?p.value:g.value,R=M*W.value,H=x*W.value,X=Math.max(0,(R-j.value.width)/2),le=Math.max(0,(H-j.value.height)/2);$.value=v($.value,-X,X),_.value=v(_.value,-le,le)}const oe=e.computed(()=>({width:`${p.value}px`,height:`${g.value}px`,marginLeft:`${-p.value/2}px`,marginTop:`${-g.value/2}px`,transform:`translate(${$.value}px, ${_.value}px) rotate(${B.value}deg) scale(${W.value})`})),z=e.computed(()=>({width:`${j.value.width}px`,height:`${j.value.height}px`}));function O(){c.value&&(URL.revokeObjectURL(c.value),c.value=null)}function Z(M){if(!(M.type.startsWith("image/")||/\.(png|jpe?g|webp|gif|bmp|svg|avif)$/i.test(M.name))){const H=`Unsupported file type: ${M.name}`;f.value=H,i("error",H);return}O(),f.value=null,m.value=!1;const R=URL.createObjectURL(M);c.value=R,o.value=R,me()}function Y(){var M;n.disabled||(M=r.value)==null||M.click()}function Q(M){var H;const x=M.target,R=(H=x.files)==null?void 0:H[0];R&&Z(R),x.value=""}function q(M){var R,H;if(b.value=!1,n.disabled)return;const x=(H=(R=M.dataTransfer)==null?void 0:R.files)==null?void 0:H[0];x&&Z(x)}function U(){const M=d.value;M&&(p.value=M.naturalWidth,g.value=M.naturalHeight,m.value=!0,f.value=null,te())}function J(){m.value=!1;const M="Failed to load image";f.value=M,i("error",M)}function ne(M){if(n.disabled||!m.value)return;const x=s.value;x&&(D.value=!0,S=M.clientX,E=M.clientY,w=$.value,N=_.value,x.setPointerCapture(M.pointerId))}function G(M){D.value&&($.value=w+(M.clientX-S),_.value=N+(M.clientY-E),te())}function ee(M){var x;D.value&&(D.value=!1,(x=s.value)==null||x.releasePointerCapture(M.pointerId))}function re(M){if(n.disabled||!m.value)return;const x=M.deltaY<0?.1:-.1;ae(x)}function ae(M){h.value=Number(v(h.value+M,1,3).toFixed(2))}function Me(M){B.value=(B.value+M)%360,te()}function me(){h.value=1,B.value=0,$.value=0,_.value=0,te()}async function Je(){const M=d.value;if(!M||!m.value||u.value)return null;u.value=!0,f.value=null;try{const x=I.value,R=x>=1?n.outputSize:Math.round(n.outputSize*x),H=x>=1?Math.round(n.outputSize/x):n.outputSize,X=document.createElement("canvas");X.width=R,X.height=H;const le=X.getContext("2d");if(!le)throw new Error("Canvas 2D context is unavailable");n.outputType==="image/jpeg"&&(le.fillStyle="#ffffff",le.fillRect(0,0,R,H)),C.value==="circle"&&(le.beginPath(),le.arc(R/2,H/2,Math.min(R,H)/2,0,Math.PI*2),le.clip());const ce=R/j.value.width;le.save(),le.translate(R/2+$.value*ce,H/2+_.value*ce),le.rotate(B.value*Math.PI/180);const De=W.value*ce;le.scale(De,De),le.drawImage(M,-p.value/2,-g.value/2,p.value,g.value),le.restore();const wn=await new Promise((Ig,Rg)=>{X.toBlob($n=>$n?Ig($n):Rg(new Error("Failed to export cropped image")),n.outputType,n.quality)}),zg=X.toDataURL(n.outputType,n.quality),_n=new File([wn],n.fileName,{type:n.outputType}),En={blob:wn,dataUrl:zg,file:_n};return i("update:modelValue",_n),i("crop",En),En}catch(x){const R=x instanceof Error?x.message:"Failed to crop image";return f.value=R,i("error",R),null}finally{u.value=!1}}function he(){const M=s.value;if(!M)return;const x=M.getBoundingClientRect();x.width>0&&x.height>0&&(k.value=x.width,y.value=x.height,te())}function Qe(){V==null||V.disconnect(),!(!s.value||typeof ResizeObserver>"u")&&(V=new ResizeObserver(he),V.observe(s.value),he())}return e.watch(()=>n.modelValue,M=>{o.value=null,O(),m.value=!1,M instanceof File&&(c.value=URL.createObjectURL(M)),me()},{immediate:!0}),e.watch(()=>n.src,()=>{o.value=null,m.value=!1,me()}),e.watch([h,I],()=>{te()}),e.watch(s,M=>{M&&Qe()}),e.onMounted(()=>{Qe()}),e.onBeforeUnmount(()=>{V==null||V.disconnect(),O()}),a({crop:Je,reset:me}),(M,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-cropper mfs-surface mfs-rounded mfs-shadow-card mfs-p-4 mfs-flex mfs-flex-col mfs-gap-3",{"mfs-disabled":t.disabled}])},[e.createElementVNode("input",{ref_key:"fileInputRef",ref:r,type:"file",accept:"image/*",class:"mfs-sr-only",disabled:t.disabled,onChange:Q},null,40,pk),T.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"stageRef",ref:s,class:e.normalizeClass(["mfs-cropper__stage mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none",D.value?"mfs-cropper__stage--grabbing":"mfs-cropper__stage--grab"]),onPointerdown:ne,onPointermove:G,onPointerup:ee,onPointercancel:ee,onWheel:e.withModifiers(re,["prevent"])},[e.createElementVNode("img",{ref_key:"imgRef",ref:d,src:T.value,alt:"Crop source",draggable:"false",class:"mfs-cropper__img",style:e.normalizeStyle(oe.value),onLoad:U,onError:J},null,44,hk),m.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__viewport mfs-absolute",{"mfs-cropper__viewport--circle":C.value==="circle"}]),style:e.normalizeStyle(z.value),"aria-hidden":"true"},[...x[11]||(x[11]=[e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--h1"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--h2"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--v1"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--v2"},null,-1)])],6)):e.createCommentVNode("",!0)],34)):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__empty mfs-surface-subtle mfs-rounded mfs-border mfs-flex mfs-flex-col mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-6 mfs-text-center mfs-cursor-pointer mfs-focus-ring",{"mfs-border-primary":b.value}]),role:"button",tabindex:"0","aria-label":"Select an image to crop",onClick:Y,onKeydown:[e.withKeys(e.withModifiers(Y,["prevent"]),["enter"]),e.withKeys(e.withModifiers(Y,["prevent"]),["space"])],onDragover:x[0]||(x[0]=e.withModifiers(R=>b.value=!0,["prevent"])),onDragleave:x[1]||(x[1]=e.withModifiers(R=>b.value=!1,["prevent"])),onDrop:e.withModifiers(q,["prevent"])},[...x[10]||(x[10]=[e.createStaticVNode('<svg viewBox="0 0 24 24" width="36" height="36" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round" class="mfs-text-primary" aria-hidden="true" data-v-4a71ca25><rect x="3" y="3" width="18" height="18" rx="3" data-v-4a71ca25></rect><circle cx="8.5" cy="8.5" r="1.5" data-v-4a71ca25></circle><path d="m21 15-5-5L5 21" data-v-4a71ca25></path></svg><p class="mfs-m-0 mfs-font-semibold mfs-text" data-v-4a71ca25> Click or drop an image to crop </p><span class="mfs-caption" data-v-4a71ca25>PNG, JPG, WEBP supported</span>',3)])],42,kk)),f.value?(e.openBlock(),e.createElementBlock("div",gk,e.toDisplayString(f.value),1)):e.createCommentVNode("",!0),t.showControls&&T.value?(e.openBlock(),e.createElementBlock("div",yk,[e.createElementVNode("div",bk,[e.createElementVNode("div",Bk,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Zoom out",disabled:t.disabled||h.value<=1,onClick:x[2]||(x[2]=R=>ae(-.15))},[...x[12]||(x[12]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,wk),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":x[3]||(x[3]=R=>h.value=R),type:"range",min:"1",max:"3",step:"0.05","aria-label":"Zoom level",class:"mfs-cropper__slider mfs-flex-1 mfs-min-w-0",disabled:t.disabled},null,8,_k),[[e.vModelText,h.value,void 0,{number:!0}]]),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Zoom in",disabled:t.disabled||h.value>=3,onClick:x[4]||(x[4]=R=>ae(.15))},[...x[13]||(x[13]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,Ek)]),e.createElementVNode("div",$k,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Rotate left 90 degrees",title:"Rotate -90°",disabled:t.disabled,onClick:x[5]||(x[5]=R=>Me(-90))},[...x[14]||(x[14]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}),e.createElementVNode("path",{d:"M3 3v5h5"})],-1)])],8,Vk),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Rotate right 90 degrees",title:"Rotate +90°",disabled:t.disabled,onClick:x[6]||(x[6]=R=>Me(90))},[...x[15]||(x[15]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8"}),e.createElementVNode("path",{d:"M21 3v5h-5"})],-1)])],8,xk),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text-muted mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center mfs-px-2 mfs-text-xs mfs-font-semibold",disabled:t.disabled,onClick:me}," Reset ",8,Ck)])]),e.createElementVNode("div",Nk,[e.createElementVNode("div",Sk,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__action mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-text-sm mfs-font-medium mfs-cursor-pointer mfs-focus-ring mfs-px-3 mfs-py-2",disabled:t.disabled,onClick:Y}," Change Image ",8,Mk),t.allowShapeToggle?(e.openBlock(),e.createElementBlock("div",Dk,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-cropper__shape-btn mfs-rounded-sm mfs-border-none mfs-text-xs mfs-font-semibold mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-gap-1",C.value==="rect"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":C.value==="rect",disabled:t.disabled,onClick:x[7]||(x[7]=R=>P("rect"))},[...x[16]||(x[16]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",width:"13",height:"13",fill:"none",stroke:"currentColor","stroke-width":"1.8","aria-hidden":"true"},[e.createElementVNode("rect",{x:"2.5",y:"2.5",width:"11",height:"11",rx:"1.5"})],-1),e.createTextVNode(" Square ",-1)])],10,Tk),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-cropper__shape-btn mfs-rounded-sm mfs-border-none mfs-text-xs mfs-font-semibold mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-gap-1",C.value==="circle"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":C.value==="circle",disabled:t.disabled,onClick:x[8]||(x[8]=R=>P("circle"))},[...x[17]||(x[17]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",width:"13",height:"13",fill:"none",stroke:"currentColor","stroke-width":"1.8","aria-hidden":"true"},[e.createElementVNode("circle",{cx:"8",cy:"8",r:"5.5"})],-1),e.createTextVNode(" Circle ",-1)])],10,Lk)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",zk,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__action mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-text-sm mfs-font-medium mfs-cursor-pointer mfs-focus-ring mfs-px-3 mfs-py-2",disabled:t.disabled,onClick:x[9]||(x[9]=R=>i("cancel"))}," Cancel ",8,Ik),e.createElementVNode("button",{type:"button",class:"mfs-cropper__action mfs-bg-primary mfs-rounded-sm mfs-border-none mfs-text-sm mfs-font-semibold mfs-cursor-pointer mfs-focus-ring mfs-px-4 mfs-py-2",disabled:t.disabled||!m.value||u.value,onClick:Je},e.toDisplayString(u.value?"Cropping...":"Crop"),9,Rk)])])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4a71ca25"]]),Pk=["aria-busy"],Ak={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Fk=["onKeydown"],jk=["accept","multiple","disabled"],Kk={key:0,class:"mfs-upload__hint mfs-caption mfs-m-0"},Ok={key:0},Hk={key:1},Uk={key:2},Wk={key:1,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},Gk={key:2,class:"mfs-upload__progress-wrap mfs-flex mfs-items-center mfs-gap-2-5"},qk={class:"mfs-upload__progress-track mfs-pill mfs-shadow-inset mfs-flex-1 mfs-overflow-hidden"},Yk={class:"mfs-upload__progress-text mfs-text-muted mfs-font-bold"},Xk={key:3,class:"mfs-upload__list mfs-m-0 mfs-p-0 mfs-flex mfs-flex-col mfs-gap-2"},Zk={class:"mfs-upload__file-info mfs-flex mfs-flex-col mfs-min-w-0"},Jk={class:"mfs-upload__file-name mfs-text mfs-font-semibold mfs-truncate"},Qk={class:"mfs-upload__file-size mfs-caption"},vk=["onClick"],Pl=F(e.defineComponent({__name:"FileUpload",props:{modelValue:{},accept:{},multiple:{type:Boolean,default:!1},maxFileSize:{},disabled:{type:Boolean,default:!1},progress:{},loading:{type:Boolean,default:!1},error:{},crop:{type:Boolean,default:!1},cropShape:{default:"rect"},cropAspectRatio:{default:1}},emits:["update:modelValue","select","remove","error","clear"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(l.modelValue?[...l.modelValue]:[]),s=e.ref([]),d=e.ref(!1),c=e.ref(null),o=e.computed(()=>l.error||c.value),m=e.computed(()=>s.value[0]??null),f=e.computed(()=>m.value!==null),b=e.computed(()=>{const S=m.value;return S?`${S.name.replace(/\.[^.]+$/,"")||"cropped-image"}.png`:"cropped-image.png"});e.watch(()=>l.modelValue,S=>{S&&(r.value=[...S])});function u(S){return S<1024?`${S} B`:S<1024*1024?`${(S/1024).toFixed(1)} KB`:`${(S/(1024*1024)).toFixed(1)} MB`}function p(S,E){if(!E)return!0;const w=E.split(",").map(C=>C.trim().toLowerCase()).filter(Boolean);if(w.length===0)return!0;const N=S.name.toLowerCase(),V=S.type.toLowerCase();return w.some(C=>C.startsWith(".")?N.endsWith(C):C.endsWith("/*")?V.startsWith(C.slice(0,-1)):V===C)}function g(S){if(!S||l.disabled||l.loading)return;c.value=null;const E=[];for(const w of Array.from(S)){if(!p(w,l.accept)){const N=`Invalid file type: ${w.name}`;c.value=N,n("error",N);continue}if(l.maxFileSize&&w.size>l.maxFileSize){const N=`File too large: ${w.name} (max ${u(l.maxFileSize)})`;c.value=N,n("error",N);continue}E.push(w)}if(E.length!==0){if(l.crop){const w=l.multiple?E:[E[0]],N=w.filter(C=>C.type.startsWith("image/")),V=w.filter(C=>!C.type.startsWith("image/"));V.length>0&&(r.value=l.multiple?[...r.value,...V]:[V[0]],n("update:modelValue",r.value),n("select",r.value)),N.length>0&&(s.value=l.multiple?[...s.value,...N]:[N[0]]);return}r.value=l.multiple?[...r.value,...E]:[E[0]],n("update:modelValue",r.value),n("select",r.value)}}function k(S){r.value=l.multiple?[...r.value,S.file]:[S.file],n("update:modelValue",r.value),n("select",r.value),s.value.shift()}function y(){s.value.shift()}const h=()=>{var S;!l.disabled&&!l.loading&&((S=i.value)==null||S.click())},B=S=>{const E=S.target;g(E.files),E.value=""},$=()=>{!l.disabled&&!l.loading&&(d.value=!0)},_=S=>{var E;d.value=!1,g(((E=S.dataTransfer)==null?void 0:E.files)??null)},D=S=>{const[E]=r.value.splice(S,1);n("update:modelValue",r.value),E&&n("remove",E),r.value.length===0&&n("clear")};return(S,E)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-upload mfs-relative mfs-surface mfs-rounded mfs-shadow-card mfs-blur mfs-p-4 mfs-flex mfs-flex-col mfs-gap-3","aria-busy":t.loading||void 0},[t.loading?(e.openBlock(),e.createElementBlock("div",Ak,[...E[1]||(E[1]=[e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["mfs-upload__dropzone mfs-surface-subtle mfs-rounded mfs-focus-ring mfs-relative mfs-text-center mfs-cursor-pointer",{"mfs-upload__dropzone--dragging":d.value,"mfs-upload__dropzone--disabled mfs-disabled":t.disabled||t.loading}]),role:"button",tabindex:"0","aria-label":"Upload files",onClick:h,onKeydown:[e.withKeys(e.withModifiers(h,["prevent"]),["enter"]),e.withKeys(e.withModifiers(h,["prevent"]),["space"])],onDragover:e.withModifiers($,["prevent"]),onDragleave:E[0]||(E[0]=e.withModifiers(w=>d.value=!1,["prevent"])),onDrop:e.withModifiers(_,["prevent"])},[e.createElementVNode("input",{ref_key:"inputRef",ref:i,type:"file",class:"mfs-upload__input",accept:t.accept,multiple:t.multiple,disabled:t.disabled||t.loading,onChange:B},null,40,jk),E[2]||(E[2]=e.createStaticVNode('<span class="mfs-upload__icon mfs-inline-flex mfs-text-primary mfs-mb-2" aria-hidden="true" data-v-071de6a6><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-v-071de6a6><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" data-v-071de6a6></path><polyline points="17 8 12 3 7 8" data-v-071de6a6></polyline><line x1="12" x2="12" y1="3" y2="15" data-v-071de6a6></line></svg></span><p class="mfs-upload__title mfs-title mfs-m-0 mfs-font-semibold" data-v-071de6a6> Drag & drop files here or <span class="mfs-upload__link mfs-text-primary" data-v-071de6a6>browse</span></p>',2)),t.accept||t.maxFileSize?(e.openBlock(),e.createElementBlock("p",Kk,[t.accept?(e.openBlock(),e.createElementBlock("span",Ok,"Accepted: "+e.toDisplayString(t.accept),1)):e.createCommentVNode("",!0),t.accept&&t.maxFileSize?(e.openBlock(),e.createElementBlock("span",Hk," · ")):e.createCommentVNode("",!0),t.maxFileSize?(e.openBlock(),e.createElementBlock("span",Uk,"Max: "+e.toDisplayString(u(t.maxFileSize)),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],42,Fk),o.value?(e.openBlock(),e.createElementBlock("div",Wk,e.toDisplayString(o.value),1)):e.createCommentVNode("",!0),typeof t.progress=="number"&&t.progress>0?(e.openBlock(),e.createElementBlock("div",Gk,[e.createElementVNode("div",qk,[e.createElementVNode("div",{class:"mfs-upload__progress-bar mfs-pill mfs-h-full mfs-bg-primary",style:e.normalizeStyle({width:`${Math.min(100,Math.max(0,t.progress))}%`})},null,4)]),e.createElementVNode("span",Yk,e.toDisplayString(Math.round(t.progress))+"%",1)])):e.createCommentVNode("",!0),r.value.length>0?(e.openBlock(),e.createElementBlock("ul",Xk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(w,N)=>(e.openBlock(),e.createElementBlock("li",{key:`${w.name}-${w.size}-${N}`,class:"mfs-upload__item mfs-surface-subtle mfs-rounded-sm mfs-flex mfs-items-center mfs-justify-between mfs-gap-2-5 mfs-py-2 mfs-px-3"},[e.createElementVNode("div",Zk,[e.createElementVNode("span",Jk,e.toDisplayString(w.name),1),e.createElementVNode("span",Qk,e.toDisplayString(u(w.size)),1)]),e.createElementVNode("button",{type:"button",class:"mfs-upload__remove mfs-pill mfs-focus-ring mfs-shrink-0 mfs-border-none mfs-bg-transparent mfs-text-muted mfs-inline-flex mfs-items-center mfs-justify-center mfs-cursor-pointer","aria-label":"Remove file",onClick:V=>D(N)},[...E[3]||(E[3]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])],8,vk)]))),128))])):e.createCommentVNode("",!0),e.createVNode(ye,{"model-value":f.value,title:"Crop Image",size:"md","close-on-backdrop":!1,onClose:y},{default:e.withCtx(()=>[m.value?(e.openBlock(),e.createBlock(rt,{key:0,"model-value":m.value,shape:t.cropShape,"aspect-ratio":t.cropAspectRatio,"file-name":b.value,onCrop:k,onCancel:y},null,8,["model-value","shape","aspect-ratio","file-name"])):e.createCommentVNode("",!0)]),_:1},8,["model-value"])],8,Pk))}}),[["__scopeId","data-v-071de6a6"]]),eh={key:0,class:"mfs-terminal__welcome mfs-text-muted"},th={class:"mfs-flex mfs-gap-2"},lh={class:"mfs-text-primary mfs-font-bold mfs-select-none"},nh={class:"mfs-terminal__cmd"},oh={key:0,class:"mfs-terminal__response"},ah={class:"mfs-text-primary mfs-font-bold mfs-select-none"},sh=["onKeydown"],Al=F(e.defineComponent({__name:"Terminal",props:{welcomeMessage:{default:""},prompt:{default:"$"},commands:{}},emits:["command"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref([]),s=e.ref([]),d=e.ref(-1),c=e.ref(""),o=e.ref(null),m=e.ref(null),f=()=>{var k;(k=o.value)==null||k.focus()},b=async()=>{await e.nextTick(),m.value&&(m.value.scrollTop=m.value.scrollHeight)},u=async()=>{const k=c.value.trim();if(!k)return;c.value="",s.value.push(k),d.value=s.value.length;const[y,...h]=k.split(/\s+/);if(y==="clear"){r.value=[];return}const B={command:k};r.value.push(B);const $=r.value.length-1,_=D=>{r.value[$].response=D,b()};if(n.commands&&y in n.commands){const D=await n.commands[y](h);_(D)}else i("command",{command:y,args:h,raw:k,respond:_});b()},p=()=>{s.value.length!==0&&(d.value=Math.max(0,d.value-1),c.value=s.value[d.value]??"")},g=()=>{s.value.length!==0&&(d.value=Math.min(s.value.length,d.value+1),c.value=s.value[d.value]??"")};return a({clear:()=>{r.value=[]}}),(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-terminal mfs-surface mfs-font-mono mfs-rounded mfs-shadow-card mfs-blur mfs-p-4",onClick:f},[t.welcomeMessage?(e.openBlock(),e.createElementBlock("div",eh,e.toDisplayString(t.welcomeMessage),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"logRef",ref:m,class:"mfs-terminal__logs mfs-overflow-y-auto mfs-flex mfs-flex-col mfs-gap-1-5"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(h,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"mfs-terminal__entry"},[e.createElementVNode("div",th,[e.createElementVNode("span",lh,e.toDisplayString(t.prompt),1),e.createElementVNode("span",nh,e.toDisplayString(h.command),1)]),h.response?(e.openBlock(),e.createElementBlock("div",oh,e.toDisplayString(h.response),1)):e.createCommentVNode("",!0)]))),128))],512),e.createElementVNode("form",{class:"mfs-flex mfs-items-center mfs-gap-2 mfs-mt-2",onSubmit:e.withModifiers(u,["prevent"])},[e.createElementVNode("span",ah,e.toDisplayString(t.prompt),1),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:o,"onUpdate:modelValue":y[0]||(y[0]=h=>c.value=h),type:"text",class:"mfs-terminal__input mfs-flex-1 mfs-bg-transparent mfs-border-none mfs-outline-none",autocomplete:"off",spellcheck:"false","aria-label":"Terminal command input",onKeydown:[e.withKeys(e.withModifiers(p,["prevent"]),["up"]),e.withKeys(e.withModifiers(g,["prevent"]),["down"])]},null,40,sh),[[e.vModelText,c.value]])],32)]))}}),[["__scopeId","data-v-7db4de65"]]),rh=["aria-busy"],ih={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},dh=["viewBox","aria-label"],ch=["x2","y1","y2"],mh=["x","y"],fh=["x","y","width","height","fill","onMouseenter"],uh=["x","y","width","height","fill"],ph=["stroke","points"],kh=["cx","cy","fill","onMouseenter"],hh=["cx","cy"],gh=["transform"],yh=["d","fill","onMouseenter"],bh=["d","fill"],Bh={key:0,class:"mfs-chart__legend mfs-flex mfs-flex-wrap mfs-gap-3 mfs-justify-center"},_e=480,Ne=24,it=24,Ee=20,Se=30,Fl=F(e.defineComponent({__name:"Chart",props:{type:{default:"bar"},data:{default:null},height:{default:240},loading:{type:Boolean,default:!1},emptyText:{default:"No chart data"}},setup(t){const a=t,l=e.computed(()=>{var D;return((D=a.data)==null?void 0:D.labels)??[]}),n=e.computed(()=>{var D;return((D=a.data)==null?void 0:D.datasets)??[]}),i=e.computed(()=>n.value.length===0?!0:n.value.every(D=>!D.data||D.data.length===0)),r=e.computed(()=>a.height),s=Math.random().toString(36).slice(2,8),d=`mfs-chart-clay-${s}`,c=`mfs-chart-clay-pt-${s}`,o=`mfs-chart-clay-gloss-${s}`,m={"--mfs-clay-filter":`url(#${d})`,"--mfs-clay-point-filter":`url(#${c})`},f=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)","color-mix(in srgb, var(--primary) 65%, transparent)"],b=e.ref(null),u=e.computed(()=>{const D=n.value.flatMap(S=>S.data);return Math.max(1,...D)}),p=D=>{const S=Math.max(1,l.value.length),E=_e-Ne-it;return S===1?Ne+E/2:Ne+E*(D+.5)/S},g=D=>{const S=r.value-Ee-Se;return Ee+S-D/u.value*S},k=e.computed(()=>{const D=Math.max(1,l.value.length),S=Math.max(1,n.value.length),E=(_e-Ne-it)/D;return Math.max(6,Math.min(34,E*.68/S))}),y=(D,S)=>{const E=Math.max(1,n.value.length),w=E*k.value+(E-1)*4;return p(D)-w/2+S*(k.value+4)},h=D=>D.map((S,E)=>`${p(E)},${g(S)}`).join(" "),B=e.computed(()=>{const D=n.value[0];if(!D)return[];const S=D.data.reduce((V,C)=>V+Math.max(0,C),0)||1,E=Math.min(_e,r.value)*.4,w=a.type==="doughnut"?E*.55:0;let N=-Math.PI/2;return D.data.map((V,C)=>{const P=Math.max(0,V)/S*Math.PI*2,T=N+P,I=P>Math.PI?1:0,j=Math.cos(N)*E,A=Math.sin(N)*E,K=Math.cos(T)*E,W=Math.sin(T)*E;let v="";if(w>0){const te=Math.cos(T)*w,oe=Math.sin(T)*w,z=Math.cos(N)*w,O=Math.sin(N)*w;v=`M ${j} ${A} A ${E} ${E} 0 ${I} 1 ${K} ${W} L ${te} ${oe} A ${w} ${w} 0 ${I} 0 ${z} ${O} Z`}else v=`M 0 0 L ${j} ${A} A ${E} ${E} 0 ${I} 1 ${K} ${W} Z`;return N=T,{d:v,value:V,label:l.value[C]??`Item ${C+1}`,color:f[C%f.length]}})}),$=e.computed(()=>a.type==="pie"||a.type==="doughnut"?l.value.map((D,S)=>({label:D,color:f[S%f.length]})):n.value.map((D,S)=>({label:D.label??`Series ${S+1}`,color:D.color??f[S%f.length]}))),_=(D,S)=>{const E=D.currentTarget.closest(".mfs-chart__canvas");if(!E)return;const w=E.getBoundingClientRect();b.value={x:D.clientX-w.left+10,y:D.clientY-w.top-28,text:S}};return(D,S)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-chart mfs-surface mfs-rounded mfs-shadow-card mfs-blur mfs-flex mfs-flex-col mfs-gap-3 mfs-p-4",style:m,"aria-busy":t.loading||void 0},[e.createElementVNode("div",{class:"mfs-chart__canvas mfs-relative mfs-w-full",style:e.normalizeStyle(t.loading&&i.value?{minHeight:`${t.height}px`}:void 0)},[t.loading?(e.openBlock(),e.createElementBlock("div",ih,[e.renderSlot(D.$slots,"loading",{},()=>[S[3]||(S[3]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&i.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"mfs-empty-state",style:e.normalizeStyle({minHeight:`${t.height}px`})},[e.renderSlot(D.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)],4)):(e.openBlock(),e.createElementBlock("svg",{key:2,class:"mfs-chart__svg",viewBox:`0 0 ${_e} ${r.value}`,role:"img","aria-label":`${t.type} chart`},[e.createElementVNode("defs",null,[e.createElementVNode("filter",{id:d,x:"-25%",y:"-25%",width:"150%",height:"150%"},[...S[4]||(S[4]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="3.5" result="dropBlur" data-v-878d5047></feGaussianBlur><feOffset dx="2" dy="5" in="dropBlur" result="dropOffset" data-v-878d5047></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.24" result="dropColor" data-v-878d5047></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-878d5047></feComposite><feOffset dx="2" dy="2.5" in="SourceAlpha" result="hlOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="2" in="hlOffset" result="hlBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-878d5047></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.72" result="hlColor" data-v-878d5047></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-878d5047></feComposite><feOffset dx="-2" dy="-2.5" in="SourceAlpha" result="shOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="2.2" in="shOffset" result="shBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-878d5047></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.28" result="shColor" data-v-878d5047></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-878d5047></feComposite><feMerge data-v-878d5047><feMergeNode in="dropShadow" data-v-878d5047></feMergeNode><feMergeNode in="SourceGraphic" data-v-878d5047></feMergeNode><feMergeNode in="innerShade" data-v-878d5047></feMergeNode><feMergeNode in="innerHighlight" data-v-878d5047></feMergeNode></feMerge>',15)])]),e.createElementVNode("filter",{id:c,x:"-40%",y:"-40%",width:"180%",height:"180%"},[...S[5]||(S[5]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="2" result="dropBlur" data-v-878d5047></feGaussianBlur><feOffset dx="1.5" dy="2.5" in="dropBlur" result="dropOffset" data-v-878d5047></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.26" result="dropColor" data-v-878d5047></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-878d5047></feComposite><feOffset dx="1.2" dy="1.4" in="SourceAlpha" result="hlOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="1.1" in="hlOffset" result="hlBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-878d5047></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.8" result="hlColor" data-v-878d5047></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-878d5047></feComposite><feOffset dx="-1.2" dy="-1.4" in="SourceAlpha" result="shOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="1.2" in="shOffset" result="shBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-878d5047></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.3" result="shColor" data-v-878d5047></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-878d5047></feComposite><feMerge data-v-878d5047><feMergeNode in="dropShadow" data-v-878d5047></feMergeNode><feMergeNode in="SourceGraphic" data-v-878d5047></feMergeNode><feMergeNode in="innerShade" data-v-878d5047></feMergeNode><feMergeNode in="innerHighlight" data-v-878d5047></feMergeNode></feMerge>',15)])]),e.createElementVNode("linearGradient",{id:o,x1:"0%",y1:"0%",x2:"0%",y2:"100%"},[...S[6]||(S[6]=[e.createElementVNode("stop",{offset:"0%","stop-color":"#ffffff","stop-opacity":"0.45"},null,-1),e.createElementVNode("stop",{offset:"55%","stop-color":"#ffffff","stop-opacity":"0.08"},null,-1),e.createElementVNode("stop",{offset:"100%","stop-color":"#ffffff","stop-opacity":"0"},null,-1)])])]),t.type==="bar"||t.type==="line"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(4,E=>e.createElementVNode("line",{key:E,x1:Ne,x2:_e-it,y1:Ee+(r.value-Ee-Se)*(E-1)/3,y2:Ee+(r.value-Ee-Se)*(E-1)/3,class:"mfs-chart__grid"},null,8,ch)),64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(E,w)=>(e.openBlock(),e.createElementBlock("text",{key:w,x:p(w),y:r.value-8,"text-anchor":"middle",class:"mfs-chart__label"},e.toDisplayString(E),9,mh))),128))],64)):e.createCommentVNode("",!0),t.type==="bar"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(n.value,(E,w)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:w},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(N,V)=>(e.openBlock(),e.createElementBlock("g",{key:V},[e.createElementVNode("rect",{x:y(V,w),y:g(N),width:k.value,height:Math.max(2,r.value-Se-g(N)),fill:E.color||f[w%f.length],rx:"4",class:"mfs-chart__bar",onMouseenter:C=>_(C,`${l.value[V]??V}: ${N}`),onMouseleave:S[0]||(S[0]=C=>b.value=null)},null,40,fh),e.createElementVNode("rect",{x:y(V,w)+2,y:g(N)+2,width:Math.max(0,k.value-4),height:Math.max(0,Math.min(14,(r.value-Se-g(N))*.45)),fill:`url(#${o})`,rx:"4",class:"mfs-chart__clay-gloss"},null,8,uh)]))),128))],64))),128)):t.type==="line"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(n.value,(E,w)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:w},[e.createElementVNode("polyline",{fill:"none",stroke:E.color||f[w%f.length],"stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round",points:h(E.data),class:"mfs-chart__line"},null,8,ph),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(N,V)=>(e.openBlock(),e.createElementBlock("g",{key:V},[e.createElementVNode("circle",{cx:p(V),cy:g(N),r:"5",fill:E.color||f[w%f.length],class:"mfs-chart__point",onMouseenter:C=>_(C,`${l.value[V]??V}: ${N}`),onMouseleave:S[1]||(S[1]=C=>b.value=null)},null,40,kh),e.createElementVNode("circle",{cx:p(V)-1.5,cy:g(N)-1.5,r:"1.6",fill:"var(--bevel-light, currentColor)","fill-opacity":"0.7",class:"mfs-chart__clay-gloss"},null,8,hh)]))),128))],64))),128)):(e.openBlock(),e.createElementBlock("g",{key:3,transform:`translate(${_e/2}, ${r.value/2})`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,w)=>(e.openBlock(),e.createElementBlock("path",{key:w,d:E.d,fill:E.color,class:"mfs-chart__slice",onMouseenter:N=>_(N,`${E.label}: ${E.value}`),onMouseleave:S[2]||(S[2]=N=>b.value=null)},null,40,yh))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,w)=>(e.openBlock(),e.createElementBlock("path",{key:`gloss-${w}`,d:E.d,fill:`url(#${o})`,class:"mfs-chart__clay-gloss"},null,8,bh))),128))],8,gh))],8,dh)),b.value?(e.openBlock(),e.createElementBlock("div",{key:3,class:"mfs-chart__tooltip mfs-surface mfs-rounded-sm mfs-shadow-card mfs-blur mfs-whitespace-nowrap mfs-font-semibold",style:e.normalizeStyle({left:`${b.value.x}px`,top:`${b.value.y}px`})},e.toDisplayString(b.value.text),5)):e.createCommentVNode("",!0)],4),!i.value&&$.value.length>0?(e.openBlock(),e.createElementBlock("div",Bh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.value,(E,w)=>(e.openBlock(),e.createElementBlock("span",{key:w,class:"mfs-caption mfs-font-semibold mfs-inline-flex mfs-items-center mfs-gap-1-5"},[e.createElementVNode("span",{class:"mfs-chart__swatch mfs-rounded-full",style:e.normalizeStyle({backgroundColor:E.color})},null,4),e.createTextVNode(" "+e.toDisplayString(E.label),1)]))),128))])):e.createCommentVNode("",!0)],8,rh))}}),[["__scopeId","data-v-878d5047"]]),jl=F(e.defineComponent({__name:"AvatarGroup",props:{max:{},size:{default:"md"},items:{}},setup(t){const a=t,l=e.computed(()=>a.items?a.max!==void 0&&a.max>=0&&a.items.length>a.max?a.items.slice(0,a.max):a.items:[]),n=e.computed(()=>!a.items||a.max===void 0||a.max<0?0:Math.max(0,a.items.length-a.max));return(i,r)=>{var s;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-avatar-group",`mfs-avatar-group--${t.size}`,"mfs-inline-flex","mfs-items-center"]),role:"group"},[(s=t.items)!=null&&s.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(d,c)=>(e.openBlock(),e.createBlock(Ie,{key:c,src:d.src,label:d.label,size:t.size},null,8,["src","label","size"]))),128)),n.value>0?(e.openBlock(),e.createBlock(Ie,{key:0,size:t.size,label:`+${n.value} more`,class:"mfs-avatar-group__overflow"},{default:e.withCtx(()=>[e.createTextVNode(" +"+e.toDisplayString(n.value),1)]),_:1},8,["size","label"])):e.createCommentVNode("",!0)],64)):e.renderSlot(i.$slots,"default",{},void 0,!0,1)],2)}}}),[["__scopeId","data-v-865c01f7"]]),wh={class:"mfs-overlay-badge mfs-relative mfs-inline-flex"},Kl=F(e.defineComponent({__name:"OverlayBadge",props:{value:{},variant:{default:"primary"},size:{default:"sm"}},setup(t){const a=t,l=e.computed(()=>a.value!==void 0&&a.value!=="");return(n,i)=>(e.openBlock(),e.createElementBlock("span",wh,[e.renderSlot(n.$slots,"default",{},void 0,!0),l.value?(e.openBlock(),e.createBlock(ve,{key:0,variant:t.variant,size:t.size,class:"mfs-overlay-badge__badge mfs-absolute mfs-top-0 mfs-right-0 mfs-z-1 mfs-pointer-events-none mfs-shadow"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.value),1)]),_:1},8,["variant","size"])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cfa3d641"]]),_h=["src","alt"],Eh=["src","alt"],$h=["value"],Ol=F(e.defineComponent({__name:"ImageCompare",props:{leftSrc:{},rightSrc:{},leftAlt:{default:"Before image"},rightAlt:{default:"After image"},modelValue:{default:50}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=p=>Math.min(100,Math.max(0,p)),r=e.ref(null),s=e.ref(i(l.modelValue)),d=e.ref(!1);e.watch(()=>l.modelValue,p=>{s.value=i(p)});const c=p=>{const g=Math.round(i(p)*10)/10;s.value=g,n("update:modelValue",g)},o=p=>{const g=r.value;if(!g)return;const k=g.getBoundingClientRect();if(k.width<=0)return;const y=(p-k.left)/k.width*100;c(y)},m=p=>{var g,k;d.value=!0,(k=(g=p.currentTarget)==null?void 0:g.setPointerCapture)==null||k.call(g,p.pointerId),o(p.clientX)},f=p=>{d.value&&o(p.clientX)},b=p=>{var g,k;d.value&&(d.value=!1,(k=(g=p.currentTarget)==null?void 0:g.releasePointerCapture)==null||k.call(g,p.pointerId))},u=p=>{const g=p.target;c(Number(g.value))};return(p,g)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:r,class:"mfs-image-compare mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none mfs-surface mfs-shadow",onPointerdown:m,onPointermove:f,onPointerup:b,onPointercancel:b},[e.createElementVNode("img",{src:t.rightSrc,alt:t.rightAlt,class:"mfs-image-compare__img mfs-w-full mfs-h-full",draggable:"false"},null,8,_h),e.createElementVNode("img",{src:t.leftSrc,alt:t.leftAlt,class:"mfs-image-compare__img mfs-image-compare__img--left mfs-absolute mfs-inset-0 mfs-w-full mfs-h-full",style:e.normalizeStyle({clipPath:`inset(0 ${100-s.value}% 0 0)`}),draggable:"false"},null,12,Eh),e.createElementVNode("div",{class:"mfs-image-compare__divider mfs-absolute",style:e.normalizeStyle({left:`${s.value}%`}),"aria-hidden":"true"},[...g[0]||(g[0]=[e.createElementVNode("div",{class:"mfs-image-compare__line"},null,-1),e.createElementVNode("div",{class:"mfs-image-compare__handle mfs-surface mfs-pill mfs-shadow mfs-flex mfs-items-center mfs-justify-center"},[e.createElementVNode("span",{class:"mfs-image-compare__arrows"},"‹ ›")],-1)])],4),e.createElementVNode("input",{type:"range",min:"0",max:"100",step:"1",value:s.value,class:"mfs-image-compare__range mfs-sr-only","aria-label":"Image comparison slider",onInput:u},null,40,$h)],544))}}),[["__scopeId","data-v-6ec473fb"]]),Hl=e.defineComponent({__name:"Portal",props:{appendTo:{default:"body"},disabled:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createBlock(e.Teleport,{to:t.appendTo,disabled:t.disabled},[e.renderSlot(a.$slots,"default")],8,["to","disabled"]))}}),Vh=["for"],xh=["id","placeholder","disabled","aria-invalid"],Ch={key:1,class:"mfs-chips-msg mfs-text-danger"},Nh={key:2,class:"mfs-chips-msg mfs-caption"},Ye=F(e.defineComponent({__name:"Chips",props:{modelValue:{default:()=>[]},placeholder:{default:""},separator:{default:","},max:{},allowDuplicate:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},invalid:{type:Boolean,default:!1},label:{},hint:{},error:{}},emits:["update:modelValue","add","remove"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.ref(null),s=e.ref(""),d=e.computed(()=>l.max!==void 0&&l.modelValue.length>=l.max),c=()=>{var p;l.disabled||(p=r.value)==null||p.focus()},o=p=>{if(l.disabled)return;const g=l.separator?p.split(l.separator):[p],k=[...l.modelValue],y=[];for(const h of g){const B=h.trim();if(B){if(l.max!==void 0&&k.length>=l.max)break;!l.allowDuplicate&&k.includes(B)||(k.push(B),y.push(B))}}if(y.length>0){n("update:modelValue",k);for(const h of y)n("add",h)}s.value=""},m=p=>{if(l.disabled)return;const g=l.modelValue[p];if(g===void 0)return;const k=l.modelValue.filter((y,h)=>h!==p);n("update:modelValue",k),n("remove",g)},f=p=>{if(!l.disabled){if(p.key==="Enter"||l.separator&&p.key===l.separator){p.preventDefault(),s.value.trim()&&o(s.value);return}p.key==="Backspace"&&s.value===""&&l.modelValue.length>0&&(p.preventDefault(),m(l.modelValue.length-1))}},b=()=>{l.separator&&s.value.includes(l.separator)&&o(s.value)},u=()=>{s.value.trim()&&o(s.value)};return(p,g)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-chips-wrapper",{"mfs-chips-wrapper--disabled mfs-disabled":t.disabled,"mfs-chips-wrapper--invalid":t.invalid||!!t.error}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:e.unref(i),class:"mfs-chips-label mfs-text"},e.toDisplayString(t.label),9,Vh)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["mfs-chips-box mfs-inset mfs-rounded",{"mfs-chips-box--disabled mfs-disabled":t.disabled}]),onClick:c},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(k,y)=>(e.openBlock(),e.createBlock(Ve,{key:`${k}-${y}`,label:k,removable:!t.disabled,onRemove:h=>m(y)},null,8,["label","removable","onRemove"]))),128)),e.withDirectives(e.createElementVNode("input",{id:e.unref(i),ref_key:"inputRef",ref:r,"onUpdate:modelValue":g[0]||(g[0]=k=>s.value=k),type:"text",class:"mfs-chips-input mfs-text",placeholder:d.value?"":t.placeholder,disabled:t.disabled||d.value,"aria-invalid":t.invalid||!!t.error||void 0,onKeydown:f,onInput:b,onBlur:u},null,40,xh),[[e.vModelText,s.value]])],2),t.error?(e.openBlock(),e.createElementBlock("p",Ch,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Nh,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-e2023636"]]),Sh=["aria-invalid"],Mh=Symbol("CheckboxGroup"),Ul=F(e.defineComponent({__name:"CheckboxGroup",props:{modelValue:{default:()=>[]},name:{},direction:{default:"row"},disabled:{type:Boolean,default:!1},invalid:{type:Boolean,default:!1},options:{default:()=>[]}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=s=>{if(l.disabled)return;const c=l.modelValue.includes(s)?l.modelValue.filter(o=>o!==s):[...l.modelValue,s];n("update:modelValue",c),n("change",c)},r=s=>{l.disabled||!Array.isArray(s)||(n("update:modelValue",s),n("change",s))};return e.provide(Mh,{modelValue:e.computed(()=>l.modelValue),name:e.computed(()=>l.name),disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),toggleValue:i}),(s,d)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-checkbox-group",[t.direction==="column"?"mfs-flex mfs-flex-col mfs-gap-2":"mfs-row",{"mfs-checkbox-group--disabled mfs-disabled":t.disabled,"mfs-checkbox-group--invalid":t.invalid}]]),role:"group","aria-invalid":t.invalid||void 0},[e.renderSlot(s.$slots,t.name,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,toggleValue:i},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(c,o)=>(e.openBlock(),e.createBlock(fe,{key:o,"model-value":t.modelValue,value:c.value,label:c.label,disabled:t.disabled||c.disabled,"onUpdate:modelValue":r},null,8,["model-value","value","label","disabled"]))),128))],!0)],10,Sh))}}),[["__scopeId","data-v-bde4c6e4"]]),Dh=["aria-invalid"],Th=Symbol("RadioButtonGroup"),Wl=F(e.defineComponent({__name:"RadioButtonGroup",props:{modelValue:{},name:{},direction:{default:"row"},disabled:{type:Boolean,default:!1},invalid:{type:Boolean,default:!1},options:{default:()=>[]}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-radio-group-${e.useId()}`,r=e.computed(()=>l.name||i),s=d=>{l.disabled||(n("update:modelValue",d),n("change",d))};return e.provide(Th,{modelValue:e.computed(()=>l.modelValue),name:r,disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),selectValue:s}),(d,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-radio-group",[t.direction==="column"?"mfs-flex mfs-flex-col mfs-gap-2":"mfs-row",{"mfs-radio-group--disabled mfs-disabled":t.disabled,"mfs-radio-group--invalid":t.invalid}]]),role:"radiogroup","aria-invalid":t.invalid||void 0},[e.renderSlot(d.$slots,r.value,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,selectValue:s},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(o,m)=>(e.openBlock(),e.createBlock(et,{key:m,"model-value":t.modelValue,value:o.value,name:r.value,label:o.label,disabled:t.disabled||o.disabled,"onUpdate:modelValue":s},null,8,["model-value","value","name","label","disabled"]))),128))],!0)],10,Dh))}}),[["__scopeId","data-v-2e9ea155"]]),ke=e.ref([]);let Lh=1;function zh(t,a={}){const l=`mfs-dialog-${Lh++}`;return ke.value=[...ke.value,{id:l,component:e.markRaw(t),options:a}],l}function Ih(t,a){var i,r;const l=ke.value.findIndex(s=>s.id===t);if(l===-1)return;const n=ke.value[l];ke.value=ke.value.filter(s=>s.id!==t),(r=(i=n.options).onClose)==null||r.call(i,a)}function Gl(){return{dialogs:e.readonly(ke),open:zh,close:Ih}}const ql=e.defineComponent({__name:"DynamicDialog",setup(t){const{dialogs:a,close:l}=Gl(),n=e.defineComponent({name:"MfsDynamicDialogContent",props:{component:{type:Object,required:!0},componentProps:{type:Object,default:()=>({})},onClose:{type:Function,required:!0}},setup(i){const r={close:s=>i.onClose(s)};return e.provide("dialogRef",r),()=>e.h(i.component,i.componentProps)}});return(i,r)=>(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(a),s=>(e.openBlock(),e.createBlock(ye,{key:s.id,"model-value":!0,title:s.options.header,"onUpdate:modelValue":d=>!d&&e.unref(l)(s.id)},{default:e.withCtx(()=>[e.createElementVNode("div",{style:e.normalizeStyle(s.options.width?{width:s.options.width,maxWidth:"100%"}:void 0)},[e.createVNode(e.unref(n),{component:s.component,"component-props":s.options.props,"on-close":d=>e.unref(l)(s.id,d)},null,8,["component","component-props","on-close"])],4)]),_:2},1032,["title","onUpdate:modelValue"]))),128))}}),Rh={class:"cmd-header mfs-flex mfs-items-center mfs-gap-2 mfs-border-b"},Ph=["placeholder"],Ah={key:0,class:"mfs-spinner mfs-spinner--sm",role:"status","aria-label":"Loading"},Fh={key:1,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},jh={key:0,class:"mfs-empty-state"},Kh={key:1,class:"mfs-empty-state"},Oh={key:0,class:"cmd-group-label mfs-text-muted"},Hh=["aria-selected","aria-disabled","disabled","onMouseenter","onClick"],Uh={class:"cmd-item-main mfs-flex mfs-flex-col"},Wh={class:"cmd-item-label"},Gh={key:0,class:"cmd-item-desc mfs-text-muted"},qh={key:0,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},Yl=F(e.defineComponent({__name:"CommandPalette",props:{modelValue:{type:Boolean,default:!1},items:{default:()=>[]},remote:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},placeholder:{default:"Type a command or search..."},emptyText:{default:"No results found."},shortcut:{type:Boolean,default:!0}},emits:["update:modelValue","search","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(""),r=e.ref(-1),s=e.ref(null),d=e.ref(null),c=new Map,o=(_,D)=>{D?c.set(_,D):c.delete(_)},m=e.computed(()=>{if(l.remote)return l.items;const _=i.value.trim().toLowerCase();return _?l.items.filter(D=>D.label.toLowerCase().includes(_)||D.description&&D.description.toLowerCase().includes(_)||D.group&&D.group.toLowerCase().includes(_)):l.items}),f=e.computed(()=>{const _=new Map;let D=0;for(const S of m.value){const E=S.group??"";_.has(E)||_.set(E,[]),_.get(E).push({item:S,flatIndex:D++})}return Array.from(_.entries()).map(([S,E])=>({group:S,entries:E}))}),b=e.computed(()=>f.value.flatMap(_=>_.entries.map(D=>D.item))),u=_=>_.findIndex(D=>!D.disabled);e.watch(b,_=>{c.clear(),r.value=u(_)},{immediate:!0});const p=()=>{n("update:modelValue",!1)},g=()=>{n("search",i.value)},k=(_,D)=>{D.disabled||(r.value=_)},y=_=>{_.disabled||(n("select",_),p())},h=_=>{var w;const D=b.value,S=D.length;if(S===0)return;let E=r.value;for(let N=0;N<S;N++)if(E=(E+_+S)%S,!((w=D[E])!=null&&w.disabled)){r.value=E,e.nextTick(()=>{var V;(V=c.get(E))==null||V.scrollIntoView({block:"nearest"})});return}},B=_=>{if(_.key==="ArrowDown")_.preventDefault(),h(1);else if(_.key==="ArrowUp")_.preventDefault(),h(-1);else if(_.key==="Enter"){const D=b.value[r.value];D&&!D.disabled&&(_.preventDefault(),y(D))}else _.key==="Escape"&&(_.preventDefault(),p())},$=_=>{l.shortcut&&(_.metaKey||_.ctrlKey)&&_.key.toLowerCase()==="k"&&(_.preventDefault(),n("update:modelValue",!l.modelValue))};return e.watch(()=>l.modelValue,async _=>{var D;_&&(i.value="",r.value=u(b.value),await e.nextTick(),(D=s.value)==null||D.focus())}),e.onMounted(()=>{typeof window<"u"&&window.addEventListener("keydown",$)}),e.onBeforeUnmount(()=>{typeof window<"u"&&window.removeEventListener("keydown",$)}),(_,D)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-cmd-fade"},{default:e.withCtx(()=>[t.modelValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:"cmd-backdrop mfs-backdrop mfs-flex mfs-justify-center mfs-p-4",onClick:p},[e.createElementVNode("div",{class:"cmd-dialog mfs-overlay mfs-surface mfs-rounded-lg mfs-shadow-card mfs-w-full mfs-flex mfs-flex-col mfs-overflow-hidden",role:"dialog","aria-modal":"true","aria-label":"Command palette",onClick:D[1]||(D[1]=e.withModifiers(()=>{},["stop"])),onKeydown:B},[e.createElementVNode("div",Rh,[D[2]||(D[2]=e.createElementVNode("svg",{class:"cmd-search-icon mfs-text-muted",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("circle",{cx:"11",cy:"11",r:"8"}),e.createElementVNode("path",{d:"m21 21-4.3-4.3"})],-1)),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:s,"onUpdate:modelValue":D[0]||(D[0]=S=>i.value=S),type:"text",class:"cmd-input mfs-text mfs-bg-transparent mfs-border-none mfs-outline-none mfs-w-full",placeholder:t.placeholder,autocomplete:"off",spellcheck:"false",onInput:g},null,40,Ph),[[e.vModelText,i.value]]),t.loading?(e.openBlock(),e.createElementBlock("span",Ah)):(e.openBlock(),e.createElementBlock("kbd",Fh,"ESC"))]),e.createElementVNode("div",{ref_key:"listRef",ref:d,class:"cmd-list",role:"listbox"},[t.loading&&b.value.length===0?(e.openBlock(),e.createElementBlock("div",jh,[...D[3]||(D[3]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-label":"Loading"},null,-1)])])):b.value.length===0?(e.openBlock(),e.createElementBlock("div",Kh,[e.renderSlot(_.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(f.value,S=>(e.openBlock(),e.createElementBlock("div",{key:S.group,class:"cmd-group",role:"group"},[S.group?(e.openBlock(),e.createElementBlock("div",Oh,e.toDisplayString(S.group),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.entries,E=>(e.openBlock(),e.createElementBlock("button",{key:E.item.id,ref_for:!0,ref:w=>o(E.flatIndex,w),type:"button",role:"option","aria-selected":r.value===E.flatIndex,"aria-disabled":E.item.disabled||void 0,disabled:E.item.disabled,class:e.normalizeClass(["cmd-item mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-rounded-sm mfs-w-full mfs-text mfs-transition",{"cmd-item--active":r.value===E.flatIndex,"mfs-disabled":E.item.disabled,"mfs-cursor-pointer":!E.item.disabled}]),onMouseenter:w=>k(E.flatIndex,E.item),onClick:w=>y(E.item)},[e.createElementVNode("div",Uh,[e.createElementVNode("span",Wh,e.toDisplayString(E.item.label),1),E.item.description?(e.openBlock(),e.createElementBlock("span",Gh,e.toDisplayString(E.item.description),1)):e.createCommentVNode("",!0)]),E.item.shortcut?(e.openBlock(),e.createElementBlock("kbd",qh,e.toDisplayString(E.item.shortcut),1)):e.createCommentVNode("",!0)],42,Hh))),128))]))),128))],512)],32)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-652034ed"]]),Yh={class:"infinite-scroll mfs-flex mfs-flex-col"},Xh={key:0,class:"mfs-empty-state"},Zh={key:1,class:"infinite-scroll__status mfs-flex mfs-items-center mfs-justify-center mfs-p-4",role:"status","aria-live":"polite"},Jh={key:2,class:"mfs-soft-danger mfs-rounded mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-p-3",role:"alert"},Qh={class:"mfs-text-sm mfs-font-medium"},vh={key:3,class:"mfs-text-sm mfs-text-muted mfs-text-center mfs-p-4"},Xl=e.defineComponent({__name:"InfiniteScroll",props:{loading:{type:Boolean,default:!1},hasMore:{type:Boolean,default:!0},error:{default:void 0},isEmpty:{type:Boolean,default:!1},emptyText:{default:"No items yet."},finishedText:{default:"All items loaded"},rootMargin:{default:"120px"}},emits:["load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null);let r=null;const s=()=>{n("load")},d=()=>l.hasMore&&!l.loading&&!l.error,c=()=>{r==null||r.disconnect(),r=null,!(typeof IntersectionObserver>"u"||!i.value)&&(r=new IntersectionObserver(o=>{o.some(m=>m.isIntersecting)&&d()&&s()},{rootMargin:l.rootMargin}),r.observe(i.value))};return e.watch(()=>l.rootMargin,c),e.onMounted(()=>{c()}),e.onBeforeUnmount(()=>{r==null||r.disconnect(),r=null}),(o,m)=>(e.openBlock(),e.createElementBlock("div",Yh,[e.renderSlot(o.$slots,"default"),t.isEmpty&&!t.loading&&!t.error?(e.openBlock(),e.createElementBlock("div",Xh,[e.renderSlot(o.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Zh,[e.renderSlot(o.$slots,"loading",{},()=>[m[0]||(m[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))])])):t.error?(e.openBlock(),e.createElementBlock("div",Jh,[e.renderSlot(o.$slots,"error",{error:t.error,retry:s},()=>[e.createElementVNode("span",Qh,e.toDisplayString(t.error),1),e.createVNode($e,{size:"sm",variant:"danger",onClick:s},{default:e.withCtx(()=>[...m[1]||(m[1]=[e.createTextVNode("Retry",-1)])]),_:1})])])):!t.hasMore&&!t.isEmpty?(e.openBlock(),e.createElementBlock("div",vh,[e.renderSlot(o.$slots,"finished",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.finishedText),1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"sentinelRef",ref:i,class:"mfs-w-full mfs-h-px mfs-pointer-events-none","aria-hidden":"true"},null,512)]))}}),eg=["value","placeholder","rows","disabled","aria-expanded"],tg={key:0,class:"mfs-mentions__loading mfs-flex mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-3"},lg={key:1,class:"mfs-mentions__list"},ng=["aria-selected","onMousedown","onMouseenter"],og={class:"mfs-mentions__label mfs-text mfs-text-sm mfs-font-medium"},ag={key:0,class:"mfs-mentions__desc mfs-text-muted mfs-text-xs"},sg={key:2,class:"mfs-empty-state",role:"status"},Zl=F(e.defineComponent({__name:"Mentions",props:{modelValue:{default:""},options:{default:()=>[]},triggers:{default:()=>["@"]},remote:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},emptyText:{default:"No matches found"},placeholder:{default:""},rows:{default:3},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","search","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(!1),o=e.ref(0),m=e.ref(""),f=e.ref(-1),b=e.ref(""),{overlayStyle:u,containsTarget:p}=de(r,s,c,{matchWidth:!0}),g=e.computed(()=>{if(l.remote)return l.options;const S=b.value.trim().toLowerCase();return S?l.options.filter(E=>{var w;return E.label.toLowerCase().includes(S)||E.value.toLowerCase().includes(S)||(((w=E.description)==null?void 0:w.toLowerCase().includes(S))??!1)}):l.options});e.watch(g,S=>{S.length===0?o.value=-1:(o.value<0||o.value>=S.length)&&(o.value=0)});const k=(S,E)=>{const w=S.slice(0,E),N=[...l.triggers].filter(Boolean).sort((V,C)=>C.length-V.length);if(!N.length)return null;for(let V=w.length-1;V>=0;V--){const C=w[V];if(/\s/.test(C))return null;for(const P of N){const T=V-P.length+1;if(!(T<0)&&w.slice(T,V+1)===P){const I=T===0?"":w[T-1];if(T===0||/\s/.test(I))return{trigger:P,start:T,query:w.slice(V+1)}}}}return null},y=()=>{const S=d.value;if(!S||l.disabled){c.value=!1;return}const E=S.selectionStart??(l.modelValue??"").length,w=k(S.value,E);w?(m.value=w.trigger,f.value=w.start,b.value=w.query,c.value=!0,o.value=g.value.length?0:-1,n("search",{trigger:w.trigger,query:w.query})):(c.value=!1,m.value="",f.value=-1,b.value="")},h=S=>{const E=S.target;n("update:modelValue",E.value),y()},B=S=>{["ArrowUp","ArrowDown","Enter","Escape"].includes(S.key)||y()},$=S=>{const E=d.value,w=E?E.value:l.modelValue??"",N=(E==null?void 0:E.selectionStart)??w.length,V=f.value>=0?f.value:N,C=`${m.value}${S.value} `,P=w.slice(0,V)+C+w.slice(N),T=V+C.length;n("update:modelValue",P),n("select",S),c.value=!1,m.value="",f.value=-1,b.value="",e.nextTick(()=>{d.value&&(d.value.focus(),d.value.setSelectionRange(T,T))})},_=S=>{if(!c.value)return;const E=g.value.length;if(S.key==="Escape")S.preventDefault(),c.value=!1;else if(S.key==="ArrowDown")S.preventDefault(),E>0&&(o.value=(o.value+1)%E);else if(S.key==="ArrowUp")S.preventDefault(),E>0&&(o.value=(o.value-1+E)%E);else if(S.key==="Enter"&&E>0&&o.value>=0){S.preventDefault();const w=g.value[o.value];w&&$(w)}},D=S=>{p(S.target)||(c.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",D)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",D)),(S,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:i,class:e.normalizeClass(["mfs-mentions mfs-flex mfs-flex-col mfs-w-full",{"mfs-disabled":t.disabled}])},[e.createElementVNode("div",{ref_key:"triggerRef",ref:r,class:"mfs-mentions__box mfs-surface mfs-rounded mfs-shadow-inset mfs-w-full"},[e.createElementVNode("textarea",{ref_key:"textareaRef",ref:d,value:t.modelValue,placeholder:t.placeholder,rows:t.rows,disabled:t.disabled,role:"combobox","aria-autocomplete":"list","aria-expanded":c.value,class:"mfs-mentions__textarea mfs-w-full mfs-border-none mfs-text",onInput:h,onClick:y,onKeyup:B,onKeydown:_},null,40,eg)],512),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-mentions-pop"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:s,style:e.normalizeStyle(e.unref(u)),role:"listbox",class:"mfs-mentions__dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading?(e.openBlock(),e.createElementBlock("div",tg,[...E[0]||(E[0]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1),e.createElementVNode("span",{class:"mfs-text-muted mfs-text-sm"},"Loading...",-1)])])):g.value.length?(e.openBlock(),e.createElementBlock("ul",lg,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(w,N)=>(e.openBlock(),e.createElementBlock("li",{key:`${w.value}-${N}`,role:"option","aria-selected":N===o.value,class:e.normalizeClass(["mfs-mentions__option mfs-flex mfs-flex-col mfs-rounded-sm mfs-cursor-pointer",{"mfs-mentions__option--active":N===o.value}]),onMousedown:e.withModifiers(V=>$(w),["prevent"]),onMouseenter:V=>o.value=N},[e.createElementVNode("span",og,e.toDisplayString(w.label),1),w.description?(e.openBlock(),e.createElementBlock("span",ag,e.toDisplayString(w.description),1)):e.createCommentVNode("",!0)],42,ng))),128))])):(e.openBlock(),e.createElementBlock("div",sg,[e.renderSlot(S.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)]))],4)):e.createCommentVNode("",!0)]),_:3})]))],2))}}),[["__scopeId","data-v-495bfd88"]]),rg={class:"mfs-signature__stage mfs-inset mfs-rounded-sm mfs-relative"},ig=["width","height"],dg={key:0,class:"mfs-signature__hint mfs-text-muted mfs-text-sm mfs-select-none"},cg={class:"mfs-signature__actions mfs-flex mfs-items-center mfs-justify-end mfs-gap-2"},Jl=F(e.defineComponent({__name:"SignaturePad",props:{modelValue:{default:null},width:{default:480},height:{default:180},penColor:{default:"currentColor"},lineWidth:{default:2.5},outputType:{default:"image/png"},fileName:{default:"signature.png"},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(null),s=e.ref(!1),d=e.ref(!0),c=()=>{var h;return((h=r.value)==null?void 0:h.getContext("2d"))??null},o=h=>{if(n.penColor&&n.penColor!=="currentColor")return n.penColor;if(typeof window<"u"){const B=window.getComputedStyle(h).color;if(B)return B}return"#0f172a"},m=h=>{const B=r.value,$=B.getBoundingClientRect(),_=$.width>0?B.width/$.width:1,D=$.height>0?B.height/$.height:1;return{x:(h.clientX-$.left)*_,y:(h.clientY-$.top)*D}},f=h=>{var D;if(n.disabled)return;const B=r.value,$=c();if(!B||!$)return;(D=B.setPointerCapture)==null||D.call(B,h.pointerId);const _=m(h);$.strokeStyle=o(B),$.lineWidth=n.lineWidth,$.lineCap="round",$.lineJoin="round",$.beginPath(),$.moveTo(_.x,_.y),$.lineTo(_.x+.01,_.y+.01),$.stroke(),s.value=!0,d.value=!1},b=h=>{if(!s.value||n.disabled)return;const B=c();if(!B)return;const $=m(h);B.lineTo($.x,$.y),B.stroke()},u=h=>{var $;if(!s.value)return;const B=r.value;($=B==null?void 0:B.hasPointerCapture)!=null&&$.call(B,h.pointerId)&&B.releasePointerCapture(h.pointerId),s.value=!1},p=()=>d.value,g=()=>{const h=r.value,B=c();h&&B&&B.clearRect(0,0,h.width,h.height),s.value=!1,d.value=!0,i("update:modelValue",null),i("change",{blob:null,dataUrl:null,file:null})},k=()=>{const h=r.value;if(!h||d.value){const $={blob:null,dataUrl:null,file:null};return i("update:modelValue",null),i("change",$),Promise.resolve($)}const B=h.toDataURL(n.outputType);return new Promise($=>{h.toBlob(_=>{const D=_?new File([_],n.fileName,{type:n.outputType}):null,S={blob:_,dataUrl:B,file:D};i("update:modelValue",B),i("change",S),$(S)},n.outputType)})},y=h=>{const B=r.value,$=c();if(!B||!$)return;if($.clearRect(0,0,B.width,B.height),!h){d.value=!0;return}const _=new Image;_.onload=()=>{$.clearRect(0,0,B.width,B.height),$.drawImage(_,0,0,B.width,B.height),d.value=!1},_.src=h};return e.watch(()=>n.modelValue,h=>{if(h)r.value&&r.value.toDataURL(n.outputType)!==h&&y(h);else{const B=r.value,$=c();B&&$&&$.clearRect(0,0,B.width,B.height),d.value=!0}}),e.onMounted(()=>{n.modelValue&&y(n.modelValue)}),a({clear:g,isEmpty:p,exportSignature:k}),(h,B)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-signature mfs-surface mfs-rounded mfs-shadow-card mfs-flex mfs-flex-col mfs-gap-3",{"mfs-disabled":t.disabled}])},[e.createElementVNode("div",rg,[e.createElementVNode("canvas",{ref_key:"canvasRef",ref:r,width:t.width,height:t.height,class:"mfs-signature__canvas mfs-w-full",onPointerdown:f,onPointermove:b,onPointerup:u,onPointercancel:u,onPointerleave:u},null,40,ig),d.value?(e.openBlock(),e.createElementBlock("span",dg," Sign here ")):e.createCommentVNode("",!0)]),e.createElementVNode("div",cg,[e.createVNode($e,{variant:"surface",size:"sm",disabled:t.disabled||d.value,onClick:g},{default:e.withCtx(()=>[...B[0]||(B[0]=[e.createTextVNode(" Clear ",-1)])]),_:1},8,["disabled"]),e.createVNode($e,{variant:"primary",size:"sm",disabled:t.disabled||d.value,onClick:k},{default:e.withCtx(()=>[...B[1]||(B[1]=[e.createTextVNode(" Save ",-1)])]),_:1},8,["disabled"])])],2))}}),[["__scopeId","data-v-7b44dca2"]]),Ql=e.defineComponent({__name:"Form",props:{initialValues:{},errors:{},resolver:{},submitting:{type:Boolean,default:!1},validateOnSubmit:{type:Boolean,default:!0}},emits:["submit","reset"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.reactive({...n.initialValues??{}}),s=e.reactive({}),d=g=>{for(const k of Object.keys(s))delete s[k];for(const[k,y]of Object.entries(g))(Array.isArray(y)?y.length>0:y)&&(s[k]=y)};e.watch(()=>n.errors,g=>{d(g??{})},{immediate:!0,deep:!0});const c=(g,k)=>{r[g]=k,g in s&&delete s[g]},o=(g,k)=>{(Array.isArray(k)?k.length>0:k)?s[g]=k:delete s[g]},m=g=>{if(g!==void 0){delete s[g];return}for(const k of Object.keys(s))delete s[k]},f=()=>{if(m(),!n.resolver)return!0;const g=n.resolver({...r});for(const[k,y]of Object.entries(g))y&&(s[k]=y);return Object.keys(s).length===0},b=()=>{const g=n.initialValues??{};for(const k of Object.keys(r))k in g||delete r[k];for(const[k,y]of Object.entries(g))r[k]=y;m(),i("reset")},u=()=>{const g={};for(const[k,y]of Object.entries(s)){const h=Array.isArray(y)?y[0]:y;h&&(g[k]=h)}return g},p=()=>{const g=n.validateOnSubmit?f():!0;i("submit",{values:{...r},valid:g,errors:u()})};return e.provide("mfsFormContext",{values:r,errors:s,submitting:e.computed(()=>n.submitting),setFieldValue:c,setFieldError:o,clearErrors:m,reset:b}),a({values:r,errors:s,validate:f,reset:b,setErrors:d}),(g,k)=>(e.openBlock(),e.createElementBlock("form",{class:"mfs-form mfs-flex mfs-flex-col mfs-gap-4",novalidate:"",onSubmit:e.withModifiers(p,["prevent"])},[e.renderSlot(g.$slots,"default",{values:r,errors:s,submitting:t.submitting,reset:b,validate:f})],32))}}),mg={class:"mfs-form-field mfs-flex mfs-flex-col mfs-gap-1-5"},fg=["for"],ug={key:0,class:"mfs-text-danger"},pg={key:1,class:"mfs-form-field__msg mfs-text-danger mfs-text-xs mfs-font-medium mfs-m-0"},kg={key:2,class:"mfs-form-field__msg mfs-caption mfs-m-0"},vl=e.defineComponent({__name:"FormField",props:{name:{},label:{},hint:{},error:{},required:{type:Boolean,default:!1}},setup(t){const a=t,l=e.inject("mfsFormContext",null),n=e.computed(()=>l==null?void 0:l.values[a.name]),i=e.computed(()=>{if(a.error)return a.error;const s=l==null?void 0:l.errors[a.name];return Array.isArray(s)?s[0]||void 0:s||void 0}),r=s=>{l==null||l.setFieldValue(a.name,s)};return(s,d)=>(e.openBlock(),e.createElementBlock("div",mg,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.name,class:"mfs-form-field__label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",ug,"*")):e.createCommentVNode("",!0)],8,fg)):e.createCommentVNode("",!0),e.renderSlot(s.$slots,"default",{value:n.value,error:i.value,setValue:r}),i.value?(e.openBlock(),e.createElementBlock("p",pg,e.toDisplayString(i.value),1)):t.hint?(e.openBlock(),e.createElementBlock("p",kg,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)]))}}),dt=[{id:"clay",name:"Claymorphism",description:"3D inflated soft surfaces, playful pastel aesthetics, and tactile curves.",icon:"Layers",previewBg:"linear-gradient(135deg, #e0e7ff 0%, #ede9fe 50%, #fce7f3 100%)"},{id:"glass",name:"Glassmorphism",description:"Frosted translucent glass, backdrop blurs, glow accents, and dark sleek UI.",icon:"Sparkles",previewBg:"radial-gradient(circle at 20% 20%, #1e1b4b 0%, #0f172a 60%, #020617 100%)"},{id:"neo",name:"Neumorphism",description:"Minimalist soft UI with extruded tactile elevations and dual directional lights.",icon:"Circle",previewBg:"linear-gradient(135deg, #e6ecf5 0%, #e2e8f0 100%)"},{id:"minimalism",name:"Minimalism",description:"Ultra-clean monochrome surfaces, hairline borders, and generous whitespace.",icon:"Minus",previewBg:"linear-gradient(135deg, #ffffff 0%, #f4f4f5 100%)"},{id:"brutalism",name:"Neubrutalism",description:"High-contrast bold borders, hard offset shadows, and vivid flat colors.",icon:"Square",previewBg:"linear-gradient(135deg, #fef08a 0%, #fde047 100%)"},{id:"bento",name:"Bento Grid",description:"Modular Apple-inspired rounded tiles with crisp spacing and subtle depth.",icon:"LayoutGrid",previewBg:"linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%)"},{id:"cyberpunk",name:"Cyberpunk",description:"Neon-lit dark HUD surfaces, sharp chamfered edges, and electric glows.",icon:"Zap",previewBg:"linear-gradient(135deg, #09090b 0%, #1e1b4b 60%, #3b0764 100%)"},{id:"retro",name:"Retro 90s",description:"Classic desktop bevels, pixel-sharp borders, and nostalgic system grays.",icon:"Monitor",previewBg:"linear-gradient(135deg, #d4d0c8 0%, #c0c0c0 100%)"},{id:"swiss",name:"Swiss Style",description:"Grid-disciplined typography, stark white planes, and bold red accents.",icon:"Grid",previewBg:"linear-gradient(135deg, #ffffff 0%, #f5f5f5 100%)"},{id:"skeuomorphism",name:"Skeuomorphism",description:"Rich physical textures, brushed gradients, and realistic specular highlights.",icon:"Box",previewBg:"linear-gradient(135deg, #e5e7eb 0%, #cbd5e1 100%)"},{id:"liquid-glass",name:"Liquid Glass",description:"Translucent refractive glass, specular rim highlights, and deep backdrop blur.",icon:"Droplets",previewBg:"radial-gradient(circle at 18% 20%, #1e3a8a 0%, #0b1020 58%, #881337 100%)"},{id:"material-you",name:"Material You",description:"Dynamic tonal pastel surfaces, expressive pill radii, and soft elevation.",icon:"Palette",previewBg:"linear-gradient(135deg, #f6f2fa 0%, #ede7f6 55%, #e8f0fe 100%)"},{id:"terminal",name:"Terminal",description:"Phosphor green CRT aesthetic, monospace typography, and crisp sharp edges.",icon:"Terminal",previewBg:"radial-gradient(circle at 50% 30%, #09170d 0%, #040805 100%)"},{id:"hand-drawn",name:"Hand-Drawn",description:"Warm sketchbook paper, charcoal ink strokes, and playful offset shadows.",icon:"PenTool",previewBg:"linear-gradient(180deg, #fdfbf7 0%, #f7f3e8 100%)"},{id:"y2k-chrome",name:"Y2K Chrome",description:"Early-2000s metallic silver, glossy bevels, electric cobalt, and cyber lime.",icon:"Disc",previewBg:"linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 50%, #dbeafe 100%)"},{id:"bauhaus",name:"Bauhaus",description:"Geometric modernism with primary red, blue, yellow, and stark black framing.",icon:"Shapes",previewBg:"linear-gradient(135deg, #f4f1ea 0%, #d92b2b 50%, #1d4ed8 100%)"},{id:"pixel-art",name:"Pixel Art",description:"8-bit and 16-bit arcade UI with stepped pixel borders and retro palette.",icon:"Gamepad2",previewBg:"linear-gradient(135deg, #1a1c2c 0%, #29366f 100%)"},{id:"aurora-gradient",name:"Aurora",description:"Northern lights dark glass with iridescent emerald, cyan, and violet glows.",icon:"Sunrise",previewBg:"radial-gradient(circle at 20% 20%, #10b981 0%, #070b19 60%, #8b5cf6 100%)"},{id:"vaporwave",name:"Vaporwave",description:"Retro-futuristic synth aesthetic with hot magenta, cyan neon, and sunset purple.",icon:"Radio",previewBg:"linear-gradient(155deg, #1a0b2e 0%, #431259 60%, #ff4ecd 100%)"},{id:"manga",name:"Manga",description:"High-contrast black and white ink panels with halftone depth and crimson accents.",icon:"BookOpen",previewBg:"linear-gradient(135deg, #ffffff 0%, #f3f4f6 70%, #dc2626 100%)"}],ct=dt.map(t=>t.id),en=ct.map(t=>`theme-${t}`),Xe=e.ref("clay");let tn=!1;const ln=t=>{if(typeof document>"u")return;const a=document.documentElement,l=document.body;a.classList.remove(...en),a.classList.add(`theme-${t}`),l==null||l.classList.remove(...en)};function nn(){const t=l=>{if(Xe.value=l,typeof document<"u"){const n=document.documentElement;n.getAttribute("data-theme")!==l&&n.setAttribute("data-theme",l),ln(l),localStorage.setItem("active-theme",l)}};return{currentTheme:Xe,themeOptions:dt,setTheme:t,initTheme:(l="clay")=>{if(typeof window<"u"){const n=localStorage.getItem("active-theme");n&&ct.includes(n)?t(n):t(l),!tn&&typeof MutationObserver<"u"&&(tn=!0,new MutationObserver(()=>{const r=document.documentElement.getAttribute("data-theme");r&&ct.includes(r)&&(Xe.value!==r&&(Xe.value=r),ln(r))}).observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}))}}}}let hg=1;function gg(t,a={}){const l=a.id??`mfs-style-${hg++}`,n=a.name,i=e.ref(!1);let r=null;function s(){if(typeof document>"u")return;const c=document.getElementById(l);if(c instanceof HTMLStyleElement){c.textContent=t,r=c,i.value=!0;return}const o=document.createElement("style");o.id=l,o.type="text/css",n&&o.setAttribute("data-mfs-style",n),o.textContent=t,document.head.appendChild(o),r=o,i.value=!0}function d(){if(typeof document>"u")return;const c=r??document.getElementById(l);c&&c.parentNode&&c.parentNode.removeChild(c),r=null,i.value=!1}return(a.immediate??!0)&&s(),e.getCurrentInstance()&&e.onUnmounted(d),{id:l,name:n,css:t,isLoaded:e.readonly(i),load:s,unload:d}}function on(t){return t===!1?{disabled:!0,color:"currentColor"}:typeof t=="object"&&t!==null?{disabled:!!t.disabled,color:t.color??"currentColor"}:{disabled:!1,color:"currentColor"}}const an={mounted(t,a){const l=on(a.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color;const n=getComputedStyle(t);n.position==="static"&&(t.style.position="relative"),n.overflow!=="hidden"&&(t.style.overflow="hidden");const i=r=>{if(t.__mfsRippleDisabled)return;const s=t.getBoundingClientRect(),d=Math.max(s.width,s.height)*2,c=r.clientX-s.left-d/2,o=r.clientY-s.top-d/2,m=document.createElement("span");m.style.position="absolute",m.style.width=`${d}px`,m.style.height=`${d}px`,m.style.left=`${c}px`,m.style.top=`${o}px`,m.style.borderRadius="50%",m.style.pointerEvents="none",m.style.backgroundColor=t.__mfsRippleColor??"currentColor",m.style.opacity="0.25",m.style.transform="scale(0)",t.appendChild(m);const f=m.animate([{transform:"scale(0)",opacity:.28},{transform:"scale(1)",opacity:0}],{duration:500,easing:"cubic-bezier(0.22, 1, 0.36, 1)"});f.onfinish=()=>m.remove()};t.__mfsRippleHandler=i,t.addEventListener("pointerdown",i)},updated(t,a){const l=on(a.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color},unmounted(t){t.__mfsRippleHandler&&(t.removeEventListener("pointerdown",t.__mfsRippleHandler),delete t.__mfsRippleHandler)}};function yg(t){return t.right?"right":t.bottom?"bottom":t.left?"left":"top"}function sn(t){const a=yg(t.modifiers),l=t.value;return typeof l=="string"?{text:l,disabled:!1,placement:a}:l&&typeof l=="object"?{text:l.value??"",disabled:!!l.disabled,placement:a,customClass:l.class}:{text:"",disabled:!0,placement:a}}function rn(t,a,l){const n=t.getBoundingClientRect(),i=a.getBoundingClientRect(),r=8;let s=0,d=0;switch(l){case"bottom":s=n.bottom+r,d=n.left+n.width/2-i.width/2;break;case"left":s=n.top+n.height/2-i.height/2,d=n.left-i.width-r;break;case"right":s=n.top+n.height/2-i.height/2,d=n.right+r;break;case"top":default:s=n.top-i.height-r,d=n.left+n.width/2-i.width/2;break}const c=Math.max(8,window.innerWidth-i.width-8),o=Math.max(8,window.innerHeight-i.height-8);a.style.top=`${Math.min(Math.max(8,s),o)}px`,a.style.left=`${Math.min(Math.max(8,d),c)}px`}function Ze(t){t.tipEl&&(t.tipEl.remove(),t.tipEl=void 0)}const mt={mounted(t,a){const n={...sn(a),show:()=>{if(n.disabled||!n.text)return;Ze(n);const i=document.createElement("div");i.setAttribute("role","tooltip"),i.textContent=n.text,n.customClass&&(i.className=n.customClass),Object.assign(i.style,{position:"fixed",zIndex:"10020",padding:"6px 10px",borderRadius:"var(--radius-sm, 8px)",backgroundColor:"var(--tooltip-bg, #0f172a)",color:"var(--tooltip-text, #f8fafc)",border:"1px solid var(--tooltip-border, rgba(255, 255, 255, 0.14))",fontSize:"0.78rem",fontWeight:"600",lineHeight:"1.35",maxWidth:"min(260px, 80vw)",pointerEvents:"none",boxShadow:"0 6px 18px rgba(0, 0, 0, 0.2)",whiteSpace:"nowrap"}),document.body.appendChild(i),rn(t,i,n.placement),n.tipEl=i},hide:()=>Ze(n)};t.__mfsTooltipState=n,t.addEventListener("mouseenter",n.show),t.addEventListener("mouseleave",n.hide),t.addEventListener("focusin",n.show),t.addEventListener("focusout",n.hide)},updated(t,a){const l=t.__mfsTooltipState;if(!l)return;const n=sn(a);l.text=n.text,l.disabled=n.disabled,l.placement=n.placement,l.customClass=n.customClass,l.disabled||!l.text?Ze(l):l.tipEl&&(l.tipEl.textContent=l.text,rn(t,l.tipEl,l.placement))},unmounted(t){const a=t.__mfsTooltipState;a&&(t.removeEventListener("mouseenter",a.show),t.removeEventListener("mouseleave",a.hide),t.removeEventListener("focusin",a.show),t.removeEventListener("focusout",a.hide),Ze(a),delete t.__mfsTooltipState)}},bg=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(",");function dn(t){return Array.from(t.querySelectorAll(bg)).filter(a=>a.offsetParent!==null||a===document.activeElement)}function cn(t){if(t.__mfsTrapActive)return;t.__mfsTrapActive=!0,t.__mfsPrevFocus=document.activeElement;const a=dn(t);a.length>0&&a[0].focus();const l=n=>{if(n.key!=="Tab")return;const i=dn(t);if(i.length===0){n.preventDefault();return}const r=i[0],s=i[i.length-1];n.shiftKey&&document.activeElement===r?(n.preventDefault(),s.focus()):!n.shiftKey&&document.activeElement===s&&(n.preventDefault(),r.focus())};t.__mfsFocusTrapHandler=l,t.addEventListener("keydown",l)}function mn(t){t.__mfsTrapActive&&(t.__mfsTrapActive=!1,t.__mfsFocusTrapHandler&&(t.removeEventListener("keydown",t.__mfsFocusTrapHandler),delete t.__mfsFocusTrapHandler),t.__mfsPrevFocus&&typeof t.__mfsPrevFocus.focus=="function"&&t.__mfsPrevFocus.focus(),t.__mfsPrevFocus=null)}const fn={mounted(t,a){a.value!==!1&&cn(t)},updated(t,a){a.value===!1?mn(t):cn(t)},unmounted(t){mn(t)}},Bg=new Set(["fade-up","fade-down","fade-left","fade-right","zoom-in"]),un="cubic-bezier(0.22, 1, 0.36, 1)";function wg(t){return typeof t=="string"&&Bg.has(t)}function pn(t,a){switch(t){case"fade-down":return`translate3d(0, -${a}px, 0)`;case"fade-left":return`translate3d(${a}px, 0, 0)`;case"fade-right":return`translate3d(-${a}px, 0, 0)`;case"zoom-in":return"scale(0.92)";case"fade-up":default:return`translate3d(0, ${a}px, 0)`}}function _g(t){return t==="zoom-in"?"scale(1)":"translate3d(0, 0, 0)"}const kn={mounted(t,a){var p;if(typeof IntersectionObserver>"u")return;const l=typeof a.value=="string"?wg(a.value)?{animation:a.value}:{enterClass:a.value}:a.value??{},n=l.enterClass===void 0,i=l.animation??"fade-up",r=l.duration??500,s=l.delay??0,d=l.distance??24,c=l.threshold??.1,o=l.once??!0,m=(l.enterClass??"").split(/\s+/).filter(Boolean),f=(l.leaveClass??"").split(/\s+/).filter(Boolean),b=typeof window<"u"&&((p=window.matchMedia)==null?void 0:p.call(window,"(prefers-reduced-motion: reduce)").matches);n&&!b&&(t.style.opacity="0",t.style.transform=pn(i,d),t.style.transition=`opacity ${r}ms ${un} ${s}ms, transform ${r}ms ${un} ${s}ms`);const u=new IntersectionObserver(g=>{for(const k of g)k.isIntersecting?(f.length&&t.classList.remove(...f),m.length&&t.classList.add(...m),n&&(t.style.opacity="1",t.style.transform=_g(i)),o&&u.unobserve(t)):o||(m.length&&t.classList.remove(...m),f.length&&t.classList.add(...f),n&&!b&&(t.style.opacity="0",t.style.transform=pn(i,d)))},{threshold:c});t.__mfsAosObserver=u,u.observe(t)},unmounted(t){t.__mfsAosObserver&&(t.__mfsAosObserver.disconnect(),delete t.__mfsAosObserver)}};function Eg(t,a){var l;if(!a||a==="@self")return t;if(a==="@next")return t.nextElementSibling;if(a==="@prev")return t.previousElementSibling;if(a==="@parent")return t.parentElement;if(a==="@grandparent")return((l=t.parentElement)==null?void 0:l.parentElement)??null;try{return document.querySelector(a)}catch{return null}}function hn(t){return typeof t=="string"?{toggleClass:t}:t}const gn={mounted(t,a){t.__mfsStyleClassOpts=hn(a.value);const l=()=>{const n=t.__mfsStyleClassOpts;if(!n)return;const i=Eg(t,n.selector);i&&(n.toggleClass?n.toggleClass.split(/\s+/).filter(Boolean).forEach(r=>i.classList.toggle(r)):(n.leaveClass&&n.leaveClass.split(/\s+/).filter(Boolean).forEach(r=>i.classList.remove(r)),n.enterClass&&n.enterClass.split(/\s+/).filter(Boolean).forEach(r=>i.classList.add(r))))};t.__mfsStyleClassHandler=l,t.addEventListener("click",l)},updated(t,a){t.__mfsStyleClassOpts=hn(a.value)},unmounted(t){t.__mfsStyleClassHandler&&(t.removeEventListener("click",t.__mfsStyleClassHandler),delete t.__mfsStyleClassHandler)}},yn={primary:{bg:"var(--primary, #3b82f6)",color:"var(--primary-text, #ffffff)"},secondary:{bg:"var(--secondary, #64748b)",color:"var(--secondary-text, #ffffff)"},success:{bg:"var(--success, #22c55e)",color:"var(--success-text, #ffffff)"},warning:{bg:"var(--warning, #f59e0b)",color:"var(--warning-text, #1e293b)"},danger:{bg:"var(--danger, #ef4444)",color:"var(--danger-text, #ffffff)"}};function $g(t){const a=t.value;return a==null||a===""?null:typeof a=="string"||typeof a=="number"?{text:String(a),severity:"primary"}:typeof a=="object"?a.value===null||a.value===void 0||a.value===""?null:{text:String(a.value),severity:a.severity??"primary"}:null}function Vg(t,a){if(typeof window>"u")return;getComputedStyle(t).position==="static"&&(a.hadStaticPosition=!0,a.previousPosition=t.style.position,t.style.position="relative")}function xg(){const t=document.createElement("span");return Object.assign(t.style,{position:"absolute",top:"0",right:"0",transform:"translate(40%, -40%)",zIndex:"1",pointerEvents:"none",display:"inline-flex",alignItems:"center",justifyContent:"center",minWidth:"18px",height:"18px",padding:"0 6px",borderRadius:"9999px",fontSize:"0.72rem",fontWeight:"700",lineHeight:"1",whiteSpace:"nowrap",userSelect:"none",boxShadow:"0 2px 6px rgba(0, 0, 0, 0.18)"}),t}function bn(t,a,l){const n=$g(a);if(!n){l.badgeEl&&(l.badgeEl.remove(),l.badgeEl=void 0);return}Vg(t,l),l.badgeEl||(l.badgeEl=xg(),t.appendChild(l.badgeEl));const i=yn[n.severity]??yn.primary;l.badgeEl.className=`mfs-badge mfs-pill mfs-bg-${n.severity}`,l.badgeEl.style.backgroundColor=i.bg,l.badgeEl.style.color=i.color,l.badgeEl.textContent=n.text}const ft={mounted(t,a){const l={hadStaticPosition:!1,previousPosition:""};t.__mfsBadgeState=l,bn(t,a,l)},updated(t,a){const l=t.__mfsBadgeState;l&&bn(t,a,l)},unmounted(t){const a=t.__mfsBadgeState;a&&(a.badgeEl&&(a.badgeEl.remove(),a.badgeEl=void 0),a.hadStaticPosition&&(t.style.position=a.previousPosition),delete t.__mfsBadgeState)}},Cg=ft,Bn={int:{charPattern:/^[\d-]$/,pastePattern:/^-?\d+$/},pint:{charPattern:/^\d$/,pastePattern:/^\d+$/},num:{charPattern:/^[\d.-]$/,pastePattern:/^-?\d*(\.\d*)?$/},pnum:{charPattern:/^[\d.]$/,pastePattern:/^\d*(\.\d*)?$/},money:{charPattern:/^[\d.,\s]$/,pastePattern:/^[\d.,\s]+$/},hex:{charPattern:/^[0-9a-fA-F]$/,pastePattern:/^[0-9a-fA-F]+$/},alpha:{charPattern:/^[a-zA-Z]$/,pastePattern:/^[a-zA-Z]+$/},alphanum:{charPattern:/^[a-zA-Z0-9]$/,pastePattern:/^[a-zA-Z0-9]+$/}};function ut(t,a){return(t.global||t.sticky)&&(t.lastIndex=0),t.test(a)}function Ng(t,a){if(!a)return!0;if(a instanceof RegExp)return ut(a,t);const l=Bn[a];return l?l.charPattern.test(t):!0}function Sg(t,a){if(!a||t==="")return!0;if(a instanceof RegExp)return a.source.startsWith("^")||a.source.endsWith("$")?ut(a,t):[...t].every(n=>ut(a,n));const l=Bn[a];return l?l.pastePattern.test(t):!0}const pt={mounted(t,a){const l={filter:a.value,onKeyPress(n){n.ctrlKey||n.metaKey||n.altKey||n.key.length!==1||Ng(n.key,l.filter)||n.preventDefault()},onPaste(n){var r;const i=((r=n.clipboardData)==null?void 0:r.getData("text"))??"";Sg(i,l.filter)||n.preventDefault()}};t.__mfsKeyFilterState=l,t.addEventListener("keypress",l.onKeyPress),t.addEventListener("paste",l.onPaste)},updated(t,a){t.__mfsKeyFilterState&&(t.__mfsKeyFilterState.filter=a.value)},unmounted(t){const a=t.__mfsKeyFilterState;a&&(t.removeEventListener("keypress",a.onKeyPress),t.removeEventListener("paste",a.onPaste),delete t.__mfsKeyFilterState)}},Mg=pt,Dg={Button:$e,ButtonGroup:kt,Card:ht,Input:Te,InputText:Te,Badge:ve,Switch:ge,ToggleSwitch:ge,InputSwitch:ge,Modal:ye,Dialog:ye,Textarea:gt,InputNumber:yt,Password:bt,Checkbox:fe,RadioButton:et,Select:Le,Dropdown:Le,MultiSelect:Bt,Slider:wt,Rating:_t,ColorPicker:Et,DatePicker:ze,Calendar:ze,Avatar:Ie,Chip:Ve,Tag:Ve,Divider:$t,Accordion:Vt,Timeline:xt,Carousel:Ct,Image:Nt,Toast:Dt,Alert:Re,Message:Re,Tooltip:Tt,Drawer:Pe,Sidebar:Pe,Popover:Ae,OverlayPanel:Ae,Skeleton:Lt,ProgressBar:zt,ProgressSpinner:It,ConfirmDialog:At,Navbar:je,Menubar:je,Tabs:Ke,TabView:Ke,Breadcrumb:Kt,Pagination:xe,Paginator:xe,Steps:Oe,Stepper:Oe,ContextMenu:Ot,ScrollTop:Ht,DataTable:Ut,Column:Wt,DataView:Gt,Tree:qt,AutoComplete:Yt,Cascader:He,CascadeSelect:He,TreeSelect:Xt,Knob:Zt,SelectButton:Jt,ToggleButton:Qt,InputOtp:vt,InputMask:el,InputGroup:tl,InputGroupAddon:ll,IconField:nl,InputIcon:ol,Listbox:al,FloatLabel:sl,IftaLabel:rl,Editor:il,CodeEditor:cl,SplitButton:ml,SpeedDial:fl,Panel:ul,Fieldset:pl,Splitter:kl,Toolbar:hl,ScrollPanel:gl,Fluid:yl,Deferred:We,DeferredContent:We,Menu:bl,TieredMenu:Bl,SlideMenu:wl,PanelMenu:_l,MegaMenu:El,Dock:$l,TabMenu:Vl,OrderList:xl,PickList:Cl,TreeTable:Nl,OrganizationChart:Sl,VirtualScroller:Ml,MeterGroup:Dl,Inplace:Tl,SortableList:qe,Draggable:qe,ConfirmPopup:Ll,InlineMessage:zl,BlockUI:Il,Galleria:Rl,FileUpload:Pl,Terminal:Al,Chart:Fl,ImageCropper:rt,AvatarGroup:jl,OverlayBadge:Kl,ImageCompare:Ol,Portal:Hl,Chips:Ye,InputChips:Ye,CheckboxGroup:Ul,RadioButtonGroup:Wl,DynamicDialog:ql,CommandPalette:Yl,InfiniteScroll:Xl,Mentions:Zl,SignaturePad:Jl,Form:Ql,FormField:vl},Tg={ripple:an,tooltip:mt,focustrap:fn,animateonscroll:kn,styleclass:gn,badge:ft,keyfilter:pt},Lg={install(t,a={}){for(const[l,n]of Object.entries(Dg))t.component(l,n);for(const[l,n]of Object.entries(Tg))t.directive(l,n);if(typeof window<"u"){const{initTheme:l}=nn();l(a.defaultTheme||"clay")}}};L.Accordion=Vt,L.Alert=Re,L.AutoComplete=Yt,L.Avatar=Ie,L.AvatarGroup=jl,L.Badge=ve,L.BadgeDirective=Cg,L.BlockUI=Il,L.Breadcrumb=Kt,L.Button=$e,L.ButtonGroup=kt,L.Calendar=ze,L.Card=ht,L.Carousel=Ct,L.CascadeSelect=He,L.Cascader=He,L.Chart=Fl,L.Checkbox=fe,L.CheckboxGroup=Ul,L.Chip=Ve,L.Chips=Ye,L.CodeEditor=cl,L.ColorPicker=Et,L.Column=Wt,L.CommandPalette=Yl,L.ConfirmDialog=At,L.ConfirmPopup=Ll,L.ContextMenu=Ot,L.DataTable=Ut,L.DataView=Gt,L.DatePicker=ze,L.Deferred=We,L.DeferredContent=We,L.Dialog=ye,L.Divider=$t,L.Dock=$l,L.Draggable=qe,L.Drawer=Pe,L.Dropdown=Le,L.DynamicDialog=ql,L.Editor=il,L.Fieldset=pl,L.FileUpload=Pl,L.FloatLabel=sl,L.Fluid=yl,L.Form=Ql,L.FormField=vl,L.Galleria=Rl,L.IconField=nl,L.IftaLabel=rl,L.Image=Nt,L.ImageCompare=Ol,L.ImageCropper=rt,L.InfiniteScroll=Xl,L.InlineMessage=zl,L.Inplace=Tl,L.Input=Te,L.InputChips=Ye,L.InputGroup=tl,L.InputGroupAddon=ll,L.InputIcon=ol,L.InputMask=el,L.InputNumber=yt,L.InputOtp=vt,L.InputSwitch=ge,L.InputText=Te,L.KeyFilter=Mg,L.Knob=Zt,L.Listbox=al,L.MegaMenu=El,L.Mentions=Zl,L.Menu=bl,L.Menubar=je,L.Message=Re,L.MeterGroup=Dl,L.Modal=ye,L.MultiSelect=Bt,L.Navbar=je,L.OrderList=xl,L.OrganizationChart=Sl,L.OverlayBadge=Kl,L.OverlayPanel=Ae,L.Pagination=xe,L.Paginator=xe,L.Panel=ul,L.PanelMenu=_l,L.Password=bt,L.PickList=Cl,L.Popover=Ae,L.Portal=Hl,L.ProgressBar=zt,L.ProgressSpinner=It,L.RadioButton=et,L.RadioButtonGroup=Wl,L.Rating=_t,L.ScrollPanel=gl,L.ScrollTop=Ht,L.Select=Le,L.SelectButton=Jt,L.Sidebar=Pe,L.SignaturePad=Jl,L.Skeleton=Lt,L.SlideMenu=wl,L.Slider=wt,L.SortableList=qe,L.SpeedDial=fl,L.SplitButton=ml,L.Splitter=kl,L.Stepper=Oe,L.Steps=Oe,L.Switch=ge,L.THEME_OPTIONS=dt,L.TabMenu=Vl,L.TabView=Ke,L.Tabs=Ke,L.Tag=Ve,L.Terminal=Al,L.Textarea=gt,L.TieredMenu=Bl,L.Timeline=xt,L.Toast=Dt,L.ToggleButton=Qt,L.ToggleSwitch=ge,L.Toolbar=hl,L.Tooltip=Tt,L.TooltipDirective=mt,L.Tree=qt,L.TreeSelect=Xt,L.TreeTable=Nl,L.VirtualScroller=Ml,L.default=Lg,L.useConfirm=Pt,L.useDialog=Gl,L.useDragDrop=Lu,L.useStyle=gg,L.useTheme=nn,L.useToast=Mt,L.vAnimateOnScroll=kn,L.vBadge=ft,L.vFocusTrap=fn,L.vKeyFilter=pt,L.vRipple=an,L.vStyleClass=gn,L.vTooltip=mt,Object.defineProperties(L,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
|
|
33
|
+
`),-1))]))),128))])],12,Jc),k.value?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("textarea",{key:0,ref_key:"textareaRef",ref:r,class:"mfs-code-editor__textarea mfs-font-mono",value:u.value,disabled:t.disabled,placeholder:t.placeholder,maxlength:t.maxLength,style:e.normalizeStyle({tabSize:String(t.tabSize)}),spellcheck:"false",autocomplete:"off",autocapitalize:"off",autocorrect:"off","aria-label":"Code editor","aria-invalid":t.invalid||void 0,onInput:K,onKeydown:e.withKeys(e.withModifiers(W,["prevent"]),["tab"]),onFocus:v,onBlur:te},null,44,vc))])],4),e.createElementVNode("div",em,[e.createElementVNode("div",tm,[e.createElementVNode("span",null,"Lines: "+e.toDisplayString(h.value),1),e.createElementVNode("span",null,[e.createTextVNode(" Chars: "+e.toDisplayString(B.value),1),t.maxLength!==void 0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(" / "+e.toDisplayString(t.maxLength),1)],64)):e.createCommentVNode("",!0)])]),e.createElementVNode("div",lm,[e.createElementVNode("span",null,e.toDisplayString(p.value.toUpperCase()),1),e.createElementVNode("span",nm,e.toDisplayString(k.value?"Readonly":"Editable"),1)])])],2))}}),[["__scopeId","data-v-d4480db0"]]),om={class:"split-btn"},am=["disabled"],sm=["disabled","aria-expanded"],rm=["disabled","onClick"],im={key:0,class:"split-btn__icon"},ml=F(e.defineComponent({__name:"SplitButton",props:{label:{default:"Action"},items:{default:()=>[]},variant:{default:"primary"},size:{default:"md"},disabled:{type:Boolean,default:!1}},emits:["click","select"],setup(t,{emit:a}){const l=a,n=e.ref(!1),i=e.ref(null),r=e.ref(null),{overlayStyle:s,containsTarget:d}=de(i,r,n,{offset:8,align:"right"}),c=f=>{f.disabled||(n.value=!1,l("select",f))},o=f=>{n.value&&!d(f.target)&&(n.value=!1)},m=f=>{f.key==="Escape"&&n.value&&(n.value=!1)};return e.onMounted(()=>{document.addEventListener("click",o),document.addEventListener("keydown",m)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",o),document.removeEventListener("keydown",m)}),(f,b)=>(e.openBlock(),e.createElementBlock("div",om,[e.createElementVNode("div",{ref_key:"triggerRef",ref:i,class:e.normalizeClass(["split-btn__group","mfs-pill","mfs-shadow",`split-btn--${t.variant}`,`split-btn--${t.size}`])},[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["split-btn__main","mfs-interactive","mfs-focus-ring",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,{"mfs-disabled":t.disabled}]),disabled:t.disabled,onClick:b[0]||(b[0]=u=>l("click",u))},[e.renderSlot(f.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)],10,am),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["split-btn__toggle","mfs-interactive","mfs-focus-ring",t.variant==="surface"?"mfs-surface":`mfs-bg-${t.variant}`,{"mfs-disabled":t.disabled}]),disabled:t.disabled,"aria-haspopup":"menu","aria-expanded":n.value,"aria-label":"More actions",onClick:b[1]||(b[1]=u=>n.value=!n.value)},[...b[2]||(b[2]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"16",height:"16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,sm)],2),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"split-fade"},{default:e.withCtx(()=>[n.value&&t.items.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(s)),class:"split-btn__menu mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur",role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(u,p)=>(e.openBlock(),e.createElementBlock("li",{key:p,role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:"split-btn__item mfs-text",disabled:u.disabled,onClick:g=>c(u)},[u.icon?(e.openBlock(),e.createElementBlock("span",im,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.label),1)],8,rm)]))),128))],4)):e.createCommentVNode("",!0)]),_:1})]))]))}}),[["__scopeId","data-v-54cf96eb"]]),dm=["aria-expanded"],cm={key:0,class:"speed-dial__list mfs-absolute mfs-m-0 mfs-p-0 mfs-list-none mfs-flex mfs-gap-2-5",role:"menu"},mm=["title","aria-label","disabled","onClick"],fl=F(e.defineComponent({__name:"SpeedDial",props:{items:{default:()=>[]},direction:{default:"up"},type:{default:"linear"},radius:{default:76},modelValue:{type:Boolean,default:void 0}},emits:["update:modelValue","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);e.watch(()=>l.modelValue,o=>{o!==void 0&&(i.value=o)});const r=e.computed(()=>l.modelValue!==void 0?l.modelValue:i.value),s=()=>{const o=!r.value;i.value=o,n("update:modelValue",o)},d=o=>{var m;o.disabled||((m=o.action)==null||m.call(o),n("select",o),i.value=!1,n("update:modelValue",!1))},c=o=>{if(l.type!=="radial"||!l.items.length)return;const m=l.items.length,f=l.direction==="up"?-90:l.direction==="down"?90:l.direction==="left"?180:0,b=120,u=m>1?b/(m-1):0,g=(f-b/2+o*u)*Math.PI/180,k=Math.round(Math.cos(g)*l.radius),y=Math.round(Math.sin(g)*l.radius);return{position:"absolute",transform:`translate(${k}px, ${y}px)`}};return(o,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["speed-dial",`speed-dial--${t.direction}`,"mfs-relative","mfs-inline-flex","mfs-items-center","mfs-justify-center"])},[e.createElementVNode("button",{type:"button",class:"speed-dial__fab mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-bg-primary mfs-pill mfs-shadow mfs-interactive mfs-focus-ring","aria-expanded":r.value,"aria-label":"Toggle quick actions",onClick:s},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["speed-dial__plus",{"is-open":r.value}]),viewBox:"0 0 24 24",width:"22",height:"22",fill:"none","aria-hidden":"true"},[...m[0]||(m[0]=[e.createElementVNode("path",{d:"M12 5v14M5 12h14",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round"},null,-1)])],2))],8,dm),r.value?(e.openBlock(),e.createElementBlock("ul",cm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(f,b)=>(e.openBlock(),e.createElementBlock("li",{key:b,class:"speed-dial__entry",style:e.normalizeStyle(c(b)),role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:e.normalizeClass(["speed-dial__item","mfs-inline-flex","mfs-items-center","mfs-justify-center","mfs-text-xs","mfs-font-bold","mfs-surface","mfs-pill","mfs-shadow","mfs-interactive","mfs-focus-ring",{"mfs-disabled":f.disabled}]),title:f.label,"aria-label":f.label,disabled:f.disabled,onClick:u=>d(f)},[e.renderSlot(o.$slots,"item",{item:f,index:b},()=>[e.createElementVNode("span",null,e.toDisplayString(f.icon||f.label.slice(0,2)),1)],!0)],10,mm)],4))),128))])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-0bac52a8"]]),fm={key:0,class:"panel__header"},um={class:"panel__title mfs-title"},pm={class:"panel__actions"},km=["aria-expanded"],hm={class:"panel__collapse"},gm={class:"panel__inner"},ym={class:"panel__body"},bm={key:0,class:"panel__footer mfs-surface-subtle mfs-caption"},ul=F(e.defineComponent({__name:"Panel",props:{header:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);e.watch(()=>l.collapsed,d=>{d!==void 0&&(i.value=d)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:i.value),s=()=>{const d=!r.value;i.value=d,n("update:collapsed",d),n("toggle",d)};return(d,c)=>(e.openBlock(),e.createElementBlock("section",{class:e.normalizeClass(["panel","mfs-surface","mfs-rounded","mfs-shadow-card",{"is-collapsed":r.value}])},[t.header||d.$slots.header||t.toggleable?(e.openBlock(),e.createElementBlock("header",fm,[e.createElementVNode("div",um,[e.renderSlot(d.$slots,"header",{},()=>[e.createTextVNode(e.toDisplayString(t.header),1)],!0)]),e.createElementVNode("div",pm,[e.renderSlot(d.$slots,"icons",{},void 0,!0),t.toggleable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"panel__toggle mfs-surface-subtle mfs-pill mfs-interactive mfs-focus-ring","aria-expanded":!r.value,"aria-label":"Toggle panel",onClick:s},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["panel__chevron",{"is-collapsed":r.value}]),viewBox:"0 0 20 20",width:"16",height:"16",fill:"none","aria-hidden":"true"},[...c[0]||(c[0]=[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2))],8,km)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",hm,[e.createElementVNode("div",gm,[e.createElementVNode("div",ym,[e.renderSlot(d.$slots,"default",{},void 0,!0)]),d.$slots.footer?(e.openBlock(),e.createElementBlock("footer",bm,[e.renderSlot(d.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)])])],2))}}),[["__scopeId","data-v-0ea71fae"]]),Bm={key:0,class:"fieldset__legend mfs-surface-subtle mfs-pill mfs-shadow mfs-title mfs-text-sm mfs-font-bold"},wm=["aria-expanded"],_m={key:1,class:"mfs-text"},Em={class:"fieldset__collapse"},$m={class:"mfs-overflow-hidden"},Vm={class:"mfs-pt-2"},pl=F(e.defineComponent({__name:"Fieldset",props:{legend:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1);e.watch(()=>l.collapsed,d=>{d!==void 0&&(i.value=d)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:i.value),s=()=>{const d=!r.value;i.value=d,n("update:collapsed",d),n("toggle",d)};return(d,c)=>(e.openBlock(),e.createElementBlock("fieldset",{class:e.normalizeClass(["fieldset","mfs-surface","mfs-rounded","mfs-shadow-card","mfs-m-0","mfs-min-w-0",{"is-collapsed":r.value}])},[t.legend||d.$slots.legend?(e.openBlock(),e.createElementBlock("legend",Bm,[t.toggleable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"fieldset__btn mfs-inline-flex mfs-items-center mfs-gap-1-5 mfs-border-none mfs-bg-transparent mfs-cursor-pointer mfs-text mfs-focus-ring","aria-expanded":!r.value,onClick:s},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["fieldset__chevron",{"is-collapsed":r.value}]),viewBox:"0 0 20 20",width:"15",height:"15",fill:"none","aria-hidden":"true"},[...c[0]||(c[0]=[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2)),e.renderSlot(d.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)],8,wm)):(e.openBlock(),e.createElementBlock("span",_m,[e.renderSlot(d.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)]))])):e.createCommentVNode("",!0),e.createElementVNode("div",Em,[e.createElementVNode("div",$m,[e.createElementVNode("div",Vm,[e.renderSlot(d.$slots,"default",{},void 0,!0)])])])],2))}}),[["__scopeId","data-v-86bfdaad"]]),xm=["aria-orientation","aria-valuenow","aria-valuemin","aria-valuemax"],Cm={class:"splitter__pane splitter__pane--second"},kl=F(e.defineComponent({__name:"Splitter",props:{layout:{default:"horizontal"},initialSize:{default:50},minSize:{default:15}},emits:["resize"],setup(t,{emit:a}){const l=t,n=a,i=p=>Math.max(l.minSize,Math.min(100-l.minSize,p)),r=e.ref(i(l.initialSize)),s=e.ref(!1),d=e.ref(null),c=e.computed(()=>({flexBasis:`${r.value}%`})),o=p=>{if(!d.value)return;const g=d.value.getBoundingClientRect(),k=l.layout==="horizontal"?(p.clientX-g.left)/g.width*100:(p.clientY-g.top)/g.height*100;r.value=i(k),n("resize",r.value)},m=p=>{s.value=!0,p.currentTarget.setPointerCapture(p.pointerId),o(p)},f=p=>{s.value&&o(p)},b=p=>{s.value&&(s.value=!1,p.currentTarget.hasPointerCapture(p.pointerId)&&p.currentTarget.releasePointerCapture(p.pointerId))},u=p=>{const k=l.layout==="horizontal"?"ArrowLeft":"ArrowUp",y=l.layout==="horizontal"?"ArrowRight":"ArrowDown";p.key===k?(p.preventDefault(),r.value=i(r.value-5),n("resize",r.value)):p.key===y&&(p.preventDefault(),r.value=i(r.value+5),n("resize",r.value))};return(p,g)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:d,class:e.normalizeClass(["splitter",`splitter--${t.layout}`,"mfs-surface","mfs-rounded","mfs-shadow-card"])},[e.createElementVNode("div",{class:"splitter__pane",style:e.normalizeStyle(c.value)},[e.renderSlot(p.$slots,"first",{},void 0,!0)],4),e.createElementVNode("div",{class:"splitter__gutter mfs-surface-subtle mfs-focus-ring",role:"separator",tabindex:"0","aria-orientation":t.layout==="horizontal"?"vertical":"horizontal","aria-valuenow":Math.round(r.value),"aria-valuemin":t.minSize,"aria-valuemax":100-t.minSize,onPointerdown:m,onPointermove:f,onPointerup:b,onPointercancel:b,onKeydown:u},[...g[0]||(g[0]=[e.createElementVNode("span",{class:"splitter__handle mfs-pill"},null,-1)])],40,xm),e.createElementVNode("div",Cm,[e.renderSlot(p.$slots,"second",{},void 0,!0)])],2))}}),[["__scopeId","data-v-6fd2ec7c"]]),Nm={class:"toolbar mfs-surface mfs-rounded mfs-shadow-card",role:"toolbar"},Sm={key:0,class:"toolbar__group toolbar__group--start"},Mm={key:1,class:"toolbar__group toolbar__group--center"},Dm={key:2,class:"toolbar__group toolbar__group--end"},hl=F(e.defineComponent({__name:"Toolbar",setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",Nm,[a.$slots.start||a.$slots.default?(e.openBlock(),e.createElementBlock("div",Sm,[e.renderSlot(a.$slots,"start",{},()=>[e.renderSlot(a.$slots,"default",{},void 0,!0)],!0)])):e.createCommentVNode("",!0),a.$slots.center?(e.openBlock(),e.createElementBlock("div",Mm,[e.renderSlot(a.$slots,"center",{},void 0,!0)])):e.createCommentVNode("",!0),a.$slots.end?(e.openBlock(),e.createElementBlock("div",Dm,[e.renderSlot(a.$slots,"end",{},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cf5eff51"]]),Tm={class:"scroll-panel__content"},gl=F(e.defineComponent({__name:"ScrollPanel",props:{maxHeight:{default:"300px"},width:{}},setup(t){const a=t,l=i=>i===void 0?void 0:typeof i=="number"?`${i}px`:i,n=e.computed(()=>({maxHeight:l(a.maxHeight),width:l(a.width)}));return(i,r)=>(e.openBlock(),e.createElementBlock("div",{class:"scroll-panel mfs-surface mfs-rounded mfs-shadow-card mfs-focus-ring",style:e.normalizeStyle(n.value),tabindex:"0"},[e.createElementVNode("div",Tm,[e.renderSlot(i.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-78b33875"]]),yl=F(e.defineComponent({__name:"Fluid",props:{tag:{default:"div"},padded:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.tag),{class:e.normalizeClass(["fluid","mfs-w-full",{"mfs-px-4":t.padded}])},{default:e.withCtx(()=>[e.renderSlot(a.$slots,"default",{},void 0,!0)]),_:3},8,["class"]))}}),[["__scopeId","data-v-94565fea"]]),We=e.defineComponent({__name:"Deferred",props:{rootMargin:{default:"0px"},threshold:{default:0},once:{type:Boolean,default:!0}},emits:["load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!1),r=e.ref(null);let s=null;return e.onMounted(()=>{if(typeof IntersectionObserver>"u"||!r.value){i.value=!0,n("load");return}s=new IntersectionObserver(d=>{const c=d[0];c!=null&&c.isIntersecting&&(i.value=!0,n("load"),l.once&&(s==null||s.disconnect(),s=null))},{rootMargin:l.rootMargin,threshold:l.threshold}),s.observe(r.value)}),e.onBeforeUnmount(()=>{s==null||s.disconnect(),s=null}),(d,c)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"targetRef",ref:r,class:"mfs-w-full"},[i.value?e.renderSlot(d.$slots,"default",{},void 0,void 0,0):e.renderSlot(d.$slots,"placeholder",{},()=>[c[0]||(c[0]=e.createElementVNode("div",{class:"mfs-inset mfs-rounded mfs-p-6 mfs-text-center mfs-text-sm mfs-text-muted"}," Loading... ",-1))],void 0,1)],512))}}),Lm={class:"menu__list"},zm={key:0,class:"menu__separator mfs-divider",role:"separator"},Im={key:1,class:"menu__group",role:"presentation"},Rm={key:0,class:"menu__group-label mfs-text-muted"},Pm={class:"menu__sublist"},Am=["disabled","onClick"],Fm={key:0,class:"menu__icon","aria-hidden":"true"},jm={class:"menu__label"},Km={key:0,class:"menu__icon","aria-hidden":"true"},Om={class:"menu__label"},Hm={key:2,role:"none"},Um=["disabled","onClick"],Wm={key:0,class:"menu__icon","aria-hidden":"true"},Gm={class:"menu__label"},qm={key:0,class:"menu__icon","aria-hidden":"true"},Ym={class:"menu__label"},Xm={class:"menu__list"},Zm={key:0,class:"menu__separator mfs-divider",role:"separator"},Jm={key:1,class:"menu__group",role:"presentation"},Qm={key:0,class:"menu__group-label mfs-text-muted"},vm={class:"menu__sublist"},ef=["disabled","onClick"],tf={key:0,class:"menu__icon","aria-hidden":"true"},lf={class:"menu__label"},nf={key:0,class:"menu__icon","aria-hidden":"true"},of={class:"menu__label"},af={key:2,role:"none"},sf=["disabled","onClick"],rf={key:0,class:"menu__icon","aria-hidden":"true"},df={class:"menu__label"},cf={key:0,class:"menu__icon","aria-hidden":"true"},mf={class:"menu__label"},bl=F(e.defineComponent({__name:"Menu",props:{items:{},popup:{type:Boolean,default:!1}},emits:["select"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(!1),s=e.ref(null),d=e.ref({x:0,y:0}),c=()=>{r.value=!1,g()},o=async k=>{if(!n.popup)return;r.value=!0;const y=k.currentTarget,h=y==null?void 0:y.getBoundingClientRect();if(d.value=h?{x:h.left,y:h.bottom+6}:{x:k.clientX,y:k.clientY},await e.nextTick(),s.value){const B=s.value.getBoundingClientRect(),$=8;d.value={x:Math.max($,Math.min(d.value.x,window.innerWidth-B.width-$)),y:Math.max($,Math.min(d.value.y,window.innerHeight-B.height-$))}}p()},m=k=>{r.value?c():o(k)},f=k=>{var y;k.disabled||((y=k.command)==null||y.call(k),i("select",k),n.popup&&c())},b=k=>{k.key==="Escape"&&n.popup&&c()},u=k=>{s.value&&!s.value.contains(k.target)&&c()},p=()=>{window.addEventListener("pointerdown",u),window.addEventListener("resize",c)},g=()=>{window.removeEventListener("pointerdown",u),window.removeEventListener("resize",c)};return e.onUnmounted(g),a({open:o,close:c,toggle:m}),(k,y)=>t.popup?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:"body"},[e.createVNode(e.Transition,{name:"menu-pop"},{default:e.withCtx(()=>[r.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"menuRef",ref:s,class:"menu menu--popup mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${d.value.x}px`,top:`${d.value.y}px`}),onKeydown:b},[e.createElementVNode("ul",Lm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>{var $;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[h.separator?(e.openBlock(),e.createElementBlock("li",zm)):($=h.items)!=null&&$.length?(e.openBlock(),e.createElementBlock("li",Im,[h.label?(e.openBlock(),e.createElementBlock("div",Rm,e.toDisplayString(h.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Pm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(_,D)=>(e.openBlock(),e.createElementBlock("li",{key:D,role:"none"},[!_.to&&!_.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Fm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",jm,e.toDisplayString(_.label),1)],!0)],10,Am)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:e.unref(se)(_.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Km,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Om,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",Hm,[!h.to&&!h.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",Wm,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Gm,e.toDisplayString(h.label),1)],!0)],10,Um)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.to?"router-link":"a"),{key:1,to:h.to,href:e.unref(se)(h.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",qm,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Ym,e.toDisplayString(h.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],36)):e.createCommentVNode("",!0)]),_:3})])):(e.openBlock(),e.createElementBlock("div",{key:1,class:"menu mfs-surface mfs-rounded-md mfs-blur",role:"menu",onKeydown:b},[e.createElementVNode("ul",Xm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,B)=>{var $;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[h.separator?(e.openBlock(),e.createElementBlock("li",Zm)):($=h.items)!=null&&$.length?(e.openBlock(),e.createElementBlock("li",Jm,[h.label?(e.openBlock(),e.createElementBlock("div",Qm,e.toDisplayString(h.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",vm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(_,D)=>(e.openBlock(),e.createElementBlock("li",{key:D,role:"none"},[!_.to&&!_.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",tf,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",lf,e.toDisplayString(_.label),1)],!0)],10,ef)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:e.unref(se)(_.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":_.disabled}]),disabled:_.disabled,onClick:S=>f(_)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",nf,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",of,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",af,[!h.to&&!h.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",rf,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",df,e.toDisplayString(h.label),1)],!0)],10,sf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.to?"router-link":"a"),{key:1,to:h.to,href:e.unref(se)(h.href),role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:_=>f(h)},{default:e.withCtx(()=>[e.renderSlot(k.$slots,"item",{item:h},()=>[h.icon?(e.openBlock(),e.createElementBlock("span",cf,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",mf,e.toDisplayString(h.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],32))}}),[["__scopeId","data-v-4044b938"]]),ff={class:"tiered-menu__list",role:"menubar"},uf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},pf=["onMouseenter"],kf=["aria-haspopup","aria-expanded","disabled","onClick"],hf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},gf={class:"tiered-menu__label"},yf={key:1,class:"tiered-menu__chevron",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},bf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Bf={class:"tiered-menu__label"},wf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},_f=["onMouseenter"],Ef=["aria-haspopup","aria-expanded","disabled","onClick"],$f={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Vf={class:"tiered-menu__label"},xf={key:1,class:"tiered-menu__chevron",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Cf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Nf={class:"tiered-menu__label"},Sf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},Mf={key:1,role:"none"},Df=["disabled","onClick"],Tf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Lf={class:"tiered-menu__label"},zf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},If={class:"tiered-menu__label"},Bl=F(e.defineComponent({__name:"TieredMenu",props:{items:{}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(null),d=e.ref({}),c=e.ref({}),o=e.ref(null),m=e.ref(null),f=e.ref({top:0,left:0}),b=e.ref({top:0,left:0});let u=null,p=null;const g=(z,O)=>{d.value[z]=O},k=(z,O)=>{c.value[z]=O},y=e.computed(()=>o.value!==null?l.items[o.value]??null:null),h=e.computed(()=>{var z;return m.value===null||!((z=y.value)!=null&&z.items)?null:y.value.items[m.value]??null}),B=(z,O)=>{if(typeof window>"u"||!z)return{top:0,left:0};const Z=z.getBoundingClientRect(),Y=O==null?void 0:O.getBoundingClientRect(),Q=(Y==null?void 0:Y.width)||200,q=(Y==null?void 0:Y.height)||0,U=8,J=6;let ne=Z.right+J;ne+Q>window.innerWidth-U&&(ne=Z.left-Q-J),ne=Math.min(Math.max(U,ne),Math.max(U,window.innerWidth-Q-U));let G=Z.top;return q>0&&G+q>window.innerHeight-U&&(G=Math.max(U,window.innerHeight-q-U)),{top:G,left:ne}},$=()=>{o.value!==null&&(f.value=B(d.value[o.value],r.value))},_=()=>{m.value!==null&&(b.value=B(c.value[m.value],s.value))},D=e.computed(()=>({position:"fixed",top:`${f.value.top}px`,left:`${f.value.left}px`,zIndex:9999})),S=e.computed(()=>({position:"fixed",top:`${b.value.top}px`,left:`${b.value.left}px`,zIndex:9999})),E=()=>{u&&(clearTimeout(u),u=null),p&&(clearTimeout(p),p=null)},w=()=>{u&&clearTimeout(u),u=setTimeout(()=>{o.value=null,m.value=null},120)},N=()=>{p&&clearTimeout(p),p=setTimeout(()=>{m.value=null},120)},V=z=>{E(),o.value!==z&&(m.value=null),o.value=z},C=()=>{w()},P=()=>{u&&(clearTimeout(u),u=null)},T=()=>{w()},I=z=>{E(),m.value=z},j=()=>{N()},A=()=>{E()},K=()=>{N(),w()},W=(z,O,Z)=>{var Y,Q;if(!z.disabled){if((Y=z.items)!=null&&Y.length){E(),O===1?(o.value=o.value===Z?null:Z,m.value=null):O===2&&(m.value=m.value===Z?null:Z);return}(Q=z.command)==null||Q.call(z),n("select",z),o.value=null,m.value=null}},v=z=>{var Z,Y,Q;const O=z.target;O&&((Z=i.value)!=null&&Z.contains(O)||(Y=r.value)!=null&&Y.contains(O)||(Q=s.value)!=null&&Q.contains(O)||(o.value=null,m.value=null))},te=z=>{z.key==="Escape"&&(o.value=null,m.value=null)},oe=()=>{o.value!==null&&$(),m.value!==null&&_()};return e.watch(o,z=>{z!==null&&($(),e.nextTick($))}),e.watch(r,z=>{z&&o.value!==null&&$()}),e.watch(m,z=>{z!==null&&(_(),e.nextTick(_))}),e.watch(s,z=>{z&&m.value!==null&&_()}),e.onMounted(()=>{window.addEventListener("pointerdown",v),window.addEventListener("keydown",te),window.addEventListener("scroll",oe,!0),window.addEventListener("resize",oe)}),e.onUnmounted(()=>{E(),window.removeEventListener("pointerdown",v),window.removeEventListener("keydown",te),window.removeEventListener("scroll",oe,!0),window.removeEventListener("resize",oe)}),(z,O)=>{var Z,Y,Q,q;return e.openBlock(),e.createElementBlock("nav",{ref_key:"rootRef",ref:i,class:"tiered-menu mfs-surface mfs-rounded-md mfs-blur","aria-label":"Tiered menu"},[e.createElementVNode("ul",ff,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(U,J)=>{var ne,G,ee,re;return e.openBlock(),e.createElementBlock(e.Fragment,{key:J},[U.separator?(e.openBlock(),e.createElementBlock("li",uf)):(e.openBlock(),e.createElementBlock("li",{key:1,ref_for:!0,ref:ae=>g(J,ae),class:"tiered-menu__node",role:"none",onMouseenter:ae=>V(J),onMouseleave:C},[(ne=U.items)!=null&&ne.length||!U.to&&!U.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":o.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),"aria-haspopup":(G=U.items)!=null&&G.length?"true":void 0,"aria-expanded":(ee=U.items)!=null&&ee.length?o.value===J:void 0,disabled:U.disabled,onClick:ae=>W(U,1,J)},[U.icon?(e.openBlock(),e.createElementBlock("span",hf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",gf,e.toDisplayString(U.label),1),(re=U.items)!=null&&re.length?(e.openBlock(),e.createElementBlock("svg",yf,[...O[0]||(O[0]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,kf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(U.to?"router-link":"a"),{key:1,to:U.to,href:e.unref(se)(U.href),role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":o.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ae=>W(U,1,J)},{default:e.withCtx(()=>[U.icon?(e.openBlock(),e.createElementBlock("span",bf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Bf,e.toDisplayString(U.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))],40,pf))],64)}),128))]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[(Y=(Z=y.value)==null?void 0:Z.items)!=null&&Y.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"submenu1Ref",ref:r,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",style:e.normalizeStyle(D.value),role:"menu",onMouseenter:P,onMouseleave:T},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value.items,(U,J)=>{var ne,G,ee,re;return e.openBlock(),e.createElementBlock(e.Fragment,{key:J},[U.separator?(e.openBlock(),e.createElementBlock("li",wf)):(e.openBlock(),e.createElementBlock("li",{key:1,ref_for:!0,ref:ae=>k(J,ae),class:"tiered-menu__node",role:"none",onMouseenter:ae=>I(J),onMouseleave:j},[(ne=U.items)!=null&&ne.length||!U.to&&!U.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":m.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),"aria-haspopup":(G=U.items)!=null&&G.length?"true":void 0,"aria-expanded":(ee=U.items)!=null&&ee.length?m.value===J:void 0,disabled:U.disabled,onClick:ae=>W(U,2,J)},[U.icon?(e.openBlock(),e.createElementBlock("span",$f,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Vf,e.toDisplayString(U.label),1),(re=U.items)!=null&&re.length?(e.openBlock(),e.createElementBlock("svg",xf,[...O[1]||(O[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Ef)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(U.to?"router-link":"a"),{key:1,to:U.to,href:e.unref(se)(U.href),role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":m.value===J,"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ae=>W(U,2,J)},{default:e.withCtx(()=>[U.icon?(e.openBlock(),e.createElementBlock("span",Cf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Nf,e.toDisplayString(U.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))],40,_f))],64)}),128))],36)):e.createCommentVNode("",!0)])),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[(q=(Q=h.value)==null?void 0:Q.items)!=null&&q.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"submenu2Ref",ref:s,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",style:e.normalizeStyle(S.value),role:"menu",onMouseenter:A,onMouseleave:K},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value.items,(U,J)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:J},[U.separator?(e.openBlock(),e.createElementBlock("li",Sf)):(e.openBlock(),e.createElementBlock("li",Mf,[!U.to&&!U.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ne=>W(U,3,J)},[U.icon?(e.openBlock(),e.createElementBlock("span",Tf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Lf,e.toDisplayString(U.label),1)],10,Df)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(U.to?"router-link":"a"),{key:1,to:U.to,href:e.unref(se)(U.href),role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--disabled mfs-disabled":U.disabled}]),disabled:U.disabled,onClick:ne=>W(U,3,J)},{default:e.withCtx(()=>[U.icon?(e.openBlock(),e.createElementBlock("span",zf,e.toDisplayString(U.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",If,e.toDisplayString(U.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64))),128))],36)):e.createCommentVNode("",!0)]))],512)}}}),[["__scopeId","data-v-5dd066df"]]),Rf={key:0,class:"slide-menu__header"},Pf={class:"slide-menu__title mfs-title"},Af={class:"slide-menu__viewport"},Ff=["disabled","onClick"],jf={key:0,class:"slide-menu__icon","aria-hidden":"true"},Kf={class:"slide-menu__label"},Of={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},Hf={key:0,class:"slide-menu__icon","aria-hidden":"true"},Uf={class:"slide-menu__label"},wl=F(e.defineComponent({__name:"SlideMenu",props:{items:{},backLabel:{default:"Back"},menuWidth:{default:"260px"}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref([]),r=e.ref("forward"),s=e.computed(()=>i.value.length?i.value[i.value.length-1].items:l.items),d=e.computed(()=>i.value.length?i.value[i.value.length-1].title:""),c=m=>{var f,b;if(!m.disabled){if((f=m.items)!=null&&f.length){r.value="forward",i.value.push({title:m.label,items:m.items});return}(b=m.command)==null||b.call(m),n("select",m)}},o=()=>{i.value.length&&(r.value="back",i.value.pop())};return(m,f)=>(e.openBlock(),e.createElementBlock("div",{class:"slide-menu mfs-surface mfs-overlay mfs-rounded-md mfs-blur",style:e.normalizeStyle({width:t.menuWidth})},[i.value.length>0?(e.openBlock(),e.createElementBlock("div",Rf,[e.createElementVNode("button",{type:"button",class:"slide-menu__back mfs-surface-subtle mfs-rounded-sm mfs-interactive mfs-text",onClick:o},[f[0]||(f[0]=e.createElementVNode("svg",{width:"15",height:"15",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("polyline",{points:"15 18 9 12 15 6"})],-1)),e.createElementVNode("span",null,e.toDisplayString(t.backLabel),1)]),e.createElementVNode("span",Pf,e.toDisplayString(d.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",Af,[e.createVNode(e.Transition,{name:r.value==="forward"?"slide-fwd":"slide-bck",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("ul",{key:i.value.length,class:"slide-menu__list",role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(b,u)=>{var p,g;return e.openBlock(),e.createElementBlock("li",{key:u,role:"none"},[(p=b.items)!=null&&p.length||!b.to&&!b.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:k=>c(b)},[b.icon?(e.openBlock(),e.createElementBlock("span",jf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Kf,e.toDisplayString(b.label),1),(g=b.items)!=null&&g.length?(e.openBlock(),e.createElementBlock("svg",Of,[...f[1]||(f[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Ff)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.to?"router-link":"a"),{key:1,to:b.to,href:e.unref(se)(b.href),role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:k=>c(b)},{default:e.withCtx(()=>[b.icon?(e.openBlock(),e.createElementBlock("span",Hf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Uf,e.toDisplayString(b.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))])}),128))]))]),_:1},8,["name"])])],4))}}),[["__scopeId","data-v-84b15d99"]]),Wf={class:"panel-menu","aria-label":"Panel navigation"},Gf=["aria-expanded","disabled","onClick"],qf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Yf={class:"panel-menu__label"},Xf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Zf={class:"panel-menu__label"},Jf={key:0,class:"panel-menu__list"},Qf=["disabled","onClick"],vf={key:0,class:"panel-menu__icon","aria-hidden":"true"},eu={key:0,class:"panel-menu__icon","aria-hidden":"true"},_l=F(e.defineComponent({__name:"PanelMenu",props:{items:{},multiple:{type:Boolean,default:!0},expandedKeys:{}},emits:["update:expandedKeys","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.expandedKeys??[]);e.watch(()=>l.expandedKeys,o=>{o!==void 0&&(i.value=[...o])});const r=(o,m)=>o.key??`${m}-${o.label}`,s=o=>i.value.includes(o),d=(o,m)=>{var f,b;if(!o.disabled){if((f=o.items)!=null&&f.length){const u=r(o,m);let p;s(u)?p=i.value.filter(g=>g!==u):p=l.multiple?[...i.value,u]:[u],i.value=p,n("update:expandedKeys",p);return}(b=o.command)==null||b.call(o),n("select",o)}},c=o=>{var m;o.disabled||((m=o.command)==null||m.call(o),n("select",o))};return(o,m)=>(e.openBlock(),e.createElementBlock("nav",Wf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(f,b)=>{var u,p,g;return e.openBlock(),e.createElementBlock("div",{key:r(f,b),class:"panel-menu__panel mfs-surface mfs-rounded-md mfs-blur"},[(u=f.items)!=null&&u.length||!f.to&&!f.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":f.disabled}]),"aria-expanded":(p=f.items)!=null&&p.length?s(r(f,b)):void 0,disabled:f.disabled,onClick:k=>d(f,b)},[f.icon?(e.openBlock(),e.createElementBlock("span",qf,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Yf,e.toDisplayString(f.label),1),(g=f.items)!=null&&g.length?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(["panel-menu__chevron",{"panel-menu__chevron--open":s(r(f,b))}]),width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[...m[0]||(m[0]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2)):e.createCommentVNode("",!0)],10,Gf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(f.to?"router-link":"a"),{key:1,to:f.to,href:e.unref(se)(f.href),class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":f.disabled}]),disabled:f.disabled,onClick:k=>d(f,b)},{default:e.withCtx(()=>[f.icon?(e.openBlock(),e.createElementBlock("span",Xf,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Zf,e.toDisplayString(f.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"panel-collapse"},{default:e.withCtx(()=>{var k;return[(k=f.items)!=null&&k.length&&s(r(f,b))?(e.openBlock(),e.createElementBlock("ul",Jf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.items,(y,h)=>(e.openBlock(),e.createElementBlock("li",{key:h},[!y.to&&!y.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:B=>c(y)},[y.icon?(e.openBlock(),e.createElementBlock("span",vf,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(y.label),1)],10,Qf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(y.to?"router-link":"a"),{key:1,to:y.to,href:e.unref(se)(y.href),class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:B=>c(y)},{default:e.withCtx(()=>[y.icon?(e.openBlock(),e.createElementBlock("span",eu,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(y.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])):e.createCommentVNode("",!0)]}),_:2},1024)])}),128))]))}}),[["__scopeId","data-v-de7ecfd5"]]),tu={class:"mega-menu__bar mfs-flex mfs-flex-col mfs-gap-2"},lu=["aria-expanded"],nu={key:0,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},ou={key:1,width:"20",height:"20",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},au=["onMouseenter"],su=["aria-haspopup","aria-expanded","disabled","onClick"],ru={key:0,"aria-hidden":"true"},iu={key:1,class:"mega-menu__chevron",width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},du={key:0,"aria-hidden":"true"},cu={class:"mega-menu__columns"},mu={key:0,class:"mega-menu__col-title mfs-text-muted mfs-font-bold mfs-mb-2 mfs-px-2"},fu={class:"mega-menu__col-list mfs-flex mfs-flex-col mfs-gap-1"},uu=["onClick"],pu={class:"mega-menu__link-label mfs-font-semibold"},ku={key:0,class:"mega-menu__link-desc mfs-text-muted"},hu={class:"mega-menu__link-label mfs-font-semibold"},gu={key:0,class:"mega-menu__link-desc mfs-text-muted"},El=F(e.defineComponent({__name:"MegaMenu",props:{items:{},orientation:{default:"horizontal"}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref({}),d=e.ref(null),c=e.ref(!1),o=e.ref(0),m=e.ref(0);let f=null;const b=(w,N)=>{s.value[w]=N},u=e.computed(()=>d.value!==null?l.items[d.value]??null:null),p=()=>typeof window<"u"&&window.innerWidth<768,g=()=>{f&&(clearTimeout(f),f=null)},k=()=>{var W;if(typeof window>"u"||d.value===null)return;const w=s.value[d.value]??i.value;if(!w)return;const N=w.getBoundingClientRect(),V=(W=r.value)==null?void 0:W.getBoundingClientRect(),C=(V==null?void 0:V.width)||Math.min(480,window.innerWidth-16),P=(V==null?void 0:V.height)||0,T=8,I=6;let j=N.left,A=N.bottom+I;l.orientation==="vertical"&&!p()&&(j=N.right+I,A=N.top,j+C>window.innerWidth-T&&(j=N.left-C-I));const K=Math.max(T,window.innerWidth-C-T);if(j=Math.min(Math.max(T,j),K),P>0&&A+P>window.innerHeight-T)if(l.orientation==="horizontal"||p()){const v=N.top-T-I,te=window.innerHeight-N.bottom-T-I;v>te?A=Math.max(T,N.top-P-I):A=Math.max(T,window.innerHeight-P-T)}else A=Math.max(T,window.innerHeight-P-T);o.value=A,m.value=j},y=e.computed(()=>({position:"fixed",top:`${o.value}px`,left:`${m.value}px`,zIndex:9999})),h=w=>{p()||(g(),d.value=w)},B=()=>{p()||(g(),f=setTimeout(()=>{d.value=null},120))},$=(w,N)=>{var V,C;if(!w.disabled){if((V=w.columns)!=null&&V.length){g(),d.value=d.value===N?null:N;return}(C=w.command)==null||C.call(w),n("select",w),d.value=null,c.value=!1}},_=w=>{var N;(N=w.command)==null||N.call(w),n("select",w),d.value=null,c.value=!1},D=w=>{var V,C;const N=w.target;N&&((V=i.value)!=null&&V.contains(N)||(C=r.value)!=null&&C.contains(N)||(d.value=null))},S=w=>{w.key==="Escape"&&(d.value=null,c.value=!1)},E=()=>{d.value!==null&&k()};return e.watch(d,w=>{w!==null&&(k(),e.nextTick(k))}),e.watch(r,w=>{w&&d.value!==null&&k()}),e.onMounted(()=>{window.addEventListener("pointerdown",D),window.addEventListener("keydown",S),window.addEventListener("scroll",E,!0),window.addEventListener("resize",E)}),e.onUnmounted(()=>{g(),window.removeEventListener("pointerdown",D),window.removeEventListener("keydown",S),window.removeEventListener("scroll",E,!0),window.removeEventListener("resize",E)}),(w,N)=>(e.openBlock(),e.createElementBlock("nav",{ref_key:"rootRef",ref:i,class:e.normalizeClass(["mega-menu mfs-surface mfs-rounded mfs-blur mfs-relative mfs-w-full",`mega-menu--${t.orientation}`]),"aria-label":"Mega menu"},[e.createElementVNode("div",tu,[e.createElementVNode("button",{type:"button",class:"mega-menu__mobile-btn mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-text mfs-inline-flex mfs-items-center mfs-gap-2 mfs-py-2 mfs-px-3 mfs-border-none mfs-bg-transparent mfs-font-semibold","aria-expanded":c.value,"aria-label":"Toggle mega menu",onClick:N[0]||(N[0]=V=>c.value=!c.value)},[c.value?(e.openBlock(),e.createElementBlock("svg",ou,[...N[2]||(N[2]=[e.createElementVNode("line",{x1:"18",y1:"6",x2:"6",y2:"18"},null,-1),e.createElementVNode("line",{x1:"6",y1:"6",x2:"18",y2:"18"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",nu,[...N[1]||(N[1]=[e.createElementVNode("line",{x1:"3",y1:"6",x2:"21",y2:"6"},null,-1),e.createElementVNode("line",{x1:"3",y1:"12",x2:"21",y2:"12"},null,-1),e.createElementVNode("line",{x1:"3",y1:"18",x2:"21",y2:"18"},null,-1)])])),N[3]||(N[3]=e.createElementVNode("span",null,"Menu",-1))],8,lu),e.createElementVNode("ul",{class:e.normalizeClass(["mega-menu__list mfs-flex-col mfs-gap-1-5",{"mega-menu__list--open":c.value}]),role:"menubar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(V,C)=>{var P,T,I,j;return e.openBlock(),e.createElementBlock("li",{key:C,ref_for:!0,ref:A=>b(C,A),class:"mega-menu__root mfs-relative",role:"none",onMouseenter:A=>h(C),onMouseleave:B},[(P=V.columns)!=null&&P.length||!V.to&&!V.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["mega-menu__trigger mfs-rounded-sm mfs-text mfs-inline-flex mfs-items-center mfs-gap-2 mfs-border-none mfs-bg-transparent mfs-font-semibold mfs-cursor-pointer",{"mega-menu__trigger--active":d.value===C,"mega-menu__trigger--disabled mfs-disabled":V.disabled}]),"aria-haspopup":(T=V.columns)!=null&&T.length?"true":void 0,"aria-expanded":(I=V.columns)!=null&&I.length?d.value===C:void 0,disabled:V.disabled,onClick:A=>$(V,C)},[V.icon?(e.openBlock(),e.createElementBlock("span",ru,e.toDisplayString(V.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(V.label),1),(j=V.columns)!=null&&j.length?(e.openBlock(),e.createElementBlock("svg",iu,[...N[4]||(N[4]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])])):e.createCommentVNode("",!0)],10,su)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(V.to?"router-link":"a"),{key:1,to:V.to,href:e.unref(se)(V.href),role:"menuitem",class:e.normalizeClass(["mega-menu__trigger mfs-rounded-sm mfs-text mfs-inline-flex mfs-items-center mfs-gap-2 mfs-border-none mfs-bg-transparent mfs-font-semibold mfs-cursor-pointer",{"mega-menu__trigger--active":d.value===C,"mega-menu__trigger--disabled mfs-disabled":V.disabled}]),disabled:V.disabled,onClick:A=>$(V,C)},{default:e.withCtx(()=>[V.icon?(e.openBlock(),e.createElementBlock("span",du,e.toDisplayString(V.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(V.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))],40,au)}),128))],2)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mega-fade"},{default:e.withCtx(()=>{var V,C;return[(C=(V=u.value)==null?void 0:V.columns)!=null&&C.length?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"panelRef",ref:r,class:"mega-menu__panel mfs-card mfs-overlay mfs-blur mfs-p-4",style:e.normalizeStyle(y.value),role:"menu",onMouseenter:g,onMouseleave:B},[e.createElementVNode("div",cu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value.columns,(P,T)=>(e.openBlock(),e.createElementBlock("div",{key:T,class:"mega-menu__col"},[P.title?(e.openBlock(),e.createElementBlock("div",mu,e.toDisplayString(P.title),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",fu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(P.items,(I,j)=>(e.openBlock(),e.createElementBlock("li",{key:j,role:"none"},[!I.to&&!I.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:"mega-menu__link mfs-rounded-sm mfs-text mfs-w-full mfs-flex mfs-flex-col mfs-p-2 mfs-border-none mfs-bg-transparent mfs-text-left mfs-cursor-pointer",onClick:A=>_(I)},[e.createElementVNode("span",pu,e.toDisplayString(I.label),1),I.description?(e.openBlock(),e.createElementBlock("span",ku,e.toDisplayString(I.description),1)):e.createCommentVNode("",!0)],8,uu)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(I.to?"router-link":"a"),{key:1,to:I.to,href:e.unref(se)(I.href),role:"menuitem",class:"mega-menu__link mfs-rounded-sm mfs-text mfs-w-full mfs-flex mfs-flex-col mfs-p-2 mfs-border-none mfs-bg-transparent mfs-text-left mfs-cursor-pointer",onClick:A=>_(I)},{default:e.withCtx(()=>[e.createElementVNode("span",hu,e.toDisplayString(I.label),1),I.description?(e.openBlock(),e.createElementBlock("span",gu,e.toDisplayString(I.description),1)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","onClick"]))]))),128))])]))),128))])],36)):e.createCommentVNode("",!0)]}),_:1})]))],2))}}),[["__scopeId","data-v-63c60131"]]),yu={class:"dock__list mfs-surface mfs-shadow-card mfs-pill mfs-blur",role:"menubar"},bu=["onMouseenter"],Bu=["aria-label","disabled","onClick"],wu={class:"dock__glyph mfs-text"},_u={key:0,class:"dock__dot","aria-hidden":"true"},Eu={class:"dock__glyph mfs-text"},$u={key:0,class:"dock__dot","aria-hidden":"true"},Vu={class:"dock__tooltip mfs-surface mfs-shadow mfs-rounded-sm mfs-text",role:"tooltip"},$l=F(e.defineComponent({__name:"Dock",props:{items:{},position:{default:"bottom"},magnification:{type:Boolean,default:!0}},emits:["select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=d=>{if(!l.magnification||i.value===null)return{};const c=Math.abs(i.value-d);return c===0?{transform:"scale(1.32)"}:c===1?{transform:"scale(1.14)"}:{}},s=(d,c)=>{var o;d.disabled||((o=d.command)==null||o.call(d),n("select",d,c))};return(d,c)=>(e.openBlock(),e.createElementBlock("nav",{class:e.normalizeClass(["dock",[`dock--${t.position}`]]),"aria-label":"Dock navigation",onMouseleave:c[0]||(c[0]=o=>i.value=null)},[e.createElementVNode("ul",yu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(o,m)=>(e.openBlock(),e.createElementBlock("li",{key:m,class:"dock__item-wrap",role:"none",onMouseenter:f=>i.value=m},[!o.to&&!o.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["dock__item mfs-rounded-sm mfs-text",{"dock__item--active":o.active,"dock__item--disabled mfs-disabled":o.disabled}]),style:e.normalizeStyle(r(m)),"aria-label":o.label,disabled:o.disabled,onClick:f=>s(o,m)},[e.renderSlot(d.$slots,"item",{item:o,index:m,active:!!o.active},()=>[e.createElementVNode("span",wu,e.toDisplayString(o.icon??o.label.slice(0,2).toUpperCase()),1)],!0),o.active?(e.openBlock(),e.createElementBlock("span",_u)):e.createCommentVNode("",!0)],14,Bu)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.to?"router-link":"a"),{key:1,to:o.to,href:e.unref(se)(o.href),role:"menuitem",class:e.normalizeClass(["dock__item mfs-rounded-sm mfs-text",{"dock__item--active":o.active,"dock__item--disabled mfs-disabled":o.disabled}]),style:e.normalizeStyle(r(m)),"aria-label":o.label,disabled:o.disabled,onClick:f=>s(o,m)},{default:e.withCtx(()=>[e.renderSlot(d.$slots,"item",{item:o,index:m,active:!!o.active},()=>[e.createElementVNode("span",Eu,e.toDisplayString(o.icon??o.label.slice(0,2).toUpperCase()),1)],!0),o.active?(e.openBlock(),e.createElementBlock("span",$u)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","class","style","aria-label","disabled","onClick"])),e.createElementVNode("span",Vu,e.toDisplayString(o.label),1)],40,bu))),128))])],34))}}),[["__scopeId","data-v-ecd21506"]]),xu={class:"tab-menu","aria-label":"Tab navigation"},Cu=["aria-selected","aria-disabled","tabindex","onClick"],Nu={key:0,class:"tab-menu__icon","aria-hidden":"true"},Su={key:0,class:"tab-menu__icon","aria-hidden":"true"},Vl=F(e.defineComponent({__name:"TabMenu",props:{items:{},modelValue:{default:0},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=new Map,s=e.ref({left:0,width:0,ready:!1}),d=(p,g)=>{const k=(g==null?void 0:g.$el)??g;k instanceof HTMLElement?r.set(p,k):r.delete(p)},c=e.computed(()=>({transform:`translateX(${s.value.left}px)`,width:`${s.value.width}px`,opacity:s.value.ready&&s.value.width>0?1:0})),o=async(p=!1)=>{await e.nextTick();const g=r.get(l.modelValue);if(!g){s.value={left:0,width:0,ready:!1};return}s.value={left:g.offsetLeft,width:g.offsetWidth,ready:!0},p&&l.scrollable&&g.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},m=(p,g,k)=>{var y;if(p.disabled){k.preventDefault();return}(y=p.command)==null||y.call(p),g!==l.modelValue&&(n("update:modelValue",g),n("change",{index:g,item:p}))},f=p=>{var h;const g=l.items.map((B,$)=>B.disabled?-1:$).filter(B=>B>=0);if(!g.length)return;const k=g.indexOf(l.modelValue);let y=-1;if(p.key==="ArrowRight"?y=g[(k+1)%g.length]:p.key==="ArrowLeft"?y=g[(k-1+g.length)%g.length]:p.key==="Home"?y=g[0]:p.key==="End"&&(y=g[g.length-1]),y>=0){p.preventDefault();const B=l.items[y];n("update:modelValue",y),n("change",{index:y,item:B}),(h=r.get(y))==null||h.focus()}},b=()=>o(!1);let u=null;return e.watch(()=>[l.modelValue,l.items],()=>o(!0),{deep:!0}),e.onMounted(()=>{o(!1),typeof ResizeObserver<"u"&&i.value&&(u=new ResizeObserver(b),u.observe(i.value)),window.addEventListener("resize",b)}),e.onUnmounted(()=>{u==null||u.disconnect(),window.removeEventListener("resize",b)}),(p,g)=>(e.openBlock(),e.createElementBlock("nav",xu,[e.createElementVNode("div",{ref_key:"listRef",ref:i,class:e.normalizeClass(["tab-menu__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tab-menu__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:f},[e.createElementVNode("span",{class:"tab-menu__indicator",style:e.normalizeStyle(c.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(k,y)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:k.key??y},[!k.to&&!k.href?(e.openBlock(),e.createElementBlock("button",{key:0,ref_for:!0,ref:h=>d(y,h),type:"button",role:"tab",class:e.normalizeClass(["tab-menu__item mfs-text",{"tab-menu__item--active":y===t.modelValue,"tab-menu__item--disabled mfs-disabled":k.disabled}]),"aria-selected":y===t.modelValue,"aria-disabled":k.disabled||void 0,tabindex:y===t.modelValue?0:-1,onClick:h=>m(k,y,h)},[k.icon?(e.openBlock(),e.createElementBlock("span",Nu,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(k.label),1)],10,Cu)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(k.to?"router-link":"a"),{key:1,ref_for:!0,ref:h=>d(y,h),to:k.to,href:e.unref(se)(k.href),role:"tab",class:e.normalizeClass(["tab-menu__item mfs-text",{"tab-menu__item--active":y===t.modelValue,"tab-menu__item--disabled mfs-disabled":k.disabled}]),"aria-selected":y===t.modelValue,"aria-disabled":k.disabled||void 0,tabindex:y===t.modelValue?0:-1,onClick:h=>m(k,y,h)},{default:e.withCtx(()=>[k.icon?(e.openBlock(),e.createElementBlock("span",Su,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(k.label),1)]),_:2},1032,["to","href","class","aria-selected","aria-disabled","tabindex","onClick"]))],64))),128))],34)]))}}),[["__scopeId","data-v-97b41a1e"]]),ot=new Map;function Mu(t){ot.set(t.listId,t)}function Du(t){ot.delete(t)}function Ge(t){return ot.get(t)}function Tu(t,a,l,n="vertical"){const i=l.getBoundingClientRect();return n==="horizontal"?t<i.left+i.width/2?"before":"after":a<i.top+i.height/2?"before":"after"}const ie=e.ref(null);function at(t,a){ie.value=a,t.dataTransfer&&(t.dataTransfer.effectAllowed="move",t.dataTransfer.setData("text/plain",String(a.index)))}function st(){ie.value=null}function Ce(t,a,l="vertical"){const n=a.getBoundingClientRect();return l==="horizontal"?t.clientX<n.left+n.width/2?"before":"after":t.clientY<n.top+n.height/2?"before":"after"}function we(t,a,l){if(a===l||a<0||a>=t.length||l<0||l>=t.length)return[...t];const n=[...t],[i]=n.splice(a,1);return n.splice(l,0,i),n}function Lu(){return{dragState:ie,startDrag:at,endDrag:st,getDropPosition:Ce,reorderArray:we}}const zu={class:"order-list mfs-surface mfs-rounded mfs-shadow-card"},Iu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ru={key:1,class:"order-list__header"},Pu={class:"order-list__title mfs-title"},Au={class:"order-list__body"},Fu={class:"order-list__controls",role:"group","aria-label":"Reorder controls"},ju=["disabled"],Ku=["disabled"],Ou=["disabled"],Hu=["disabled"],Uu={class:"order-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Orderable items"},Wu={key:0,class:"mfs-empty-state"},Gu=["aria-selected","draggable","onClick","onKeydown","onDragstart","onDragover","onDrop"],qu={key:0,class:"order-list__grip","aria-hidden":"true"},Yu={class:"mfs-text"},xl=F(e.defineComponent({__name:"OrderList",props:{modelValue:{},itemKey:{default:"id"},header:{default:""},loading:{type:Boolean,default:!1},emptyText:{default:"No items"},draggable:{type:Boolean,default:!0}},emits:["update:modelValue","reorder"],setup(t,{emit:a}){let l=0;const n=t,i=a,r=`order-list-${++l}`,s=e.ref(null),d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref([]);function f(E,w){m.value[w]=E instanceof HTMLElement?E:null}const b=e.computed(()=>s.value!==null&&s.value>0),u=e.computed(()=>s.value!==null&&s.value<n.modelValue.length-1);function p(E,w){s.value=w,i("update:modelValue",E),i("reorder",E)}function g(){if(!b.value||s.value===null)return;const E=s.value,w=[...n.modelValue];[w[E-1],w[E]]=[w[E],w[E-1]],p(w,E-1)}function k(){if(!u.value||s.value===null)return;const E=s.value,w=[...n.modelValue];[w[E+1],w[E]]=[w[E],w[E+1]],p(w,E+1)}function y(){if(!b.value||s.value===null)return;const E=s.value,w=[...n.modelValue],[N]=w.splice(E,1);w.unshift(N),p(w,0)}function h(){if(!u.value||s.value===null)return;const E=s.value,w=[...n.modelValue],[N]=w.splice(E,1);w.push(N),p(w,w.length-1)}function B(E,w,N){if(!n.draggable){E.preventDefault();return}d.value=N,at(E,{sourceId:r,group:"",index:N,item:w})}function $(E,w){!n.draggable||!ie.value||ie.value.sourceId!==r||(E.preventDefault(),E.dataTransfer&&(E.dataTransfer.dropEffect="move"),c.value=w,o.value=Ce(E,E.currentTarget,"vertical"))}function _(E,w){if(E.preventDefault(),!n.draggable||!ie.value||ie.value.sourceId!==r){D();return}const N=ie.value.index;let C=(o.value??Ce(E,E.currentTarget,"vertical"))==="after"?w+1:w;if(N<C&&(C-=1),C!==N){const P=we(n.modelValue,N,C);p(P,C)}D()}function D(){d.value=null,c.value=null,o.value=null,st()}function S(E,w){if(!n.draggable||!E.altKey||E.key!=="ArrowUp"&&E.key!=="ArrowDown")return;const N=E.target;if(N!=null&&N.closest("input, textarea, select, button, a"))return;E.preventDefault();const V=E.key==="ArrowUp"?-1:1,C=w+V;if(C<0||C>=n.modelValue.length)return;const P=we(n.modelValue,w,C);p(P,C),e.nextTick(()=>{var T;(T=m.value[C])==null||T.focus()})}return(E,w)=>(e.openBlock(),e.createElementBlock("div",zu,[t.loading?(e.openBlock(),e.createElementBlock("div",Iu,[e.renderSlot(E.$slots,"loading",{},()=>[w[0]||(w[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.header||E.$slots.header?(e.openBlock(),e.createElementBlock("div",Ru,[e.renderSlot(E.$slots,"header",{},()=>[e.createElementVNode("span",Pu,e.toDisplayString(t.header),1)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Au,[e.createElementVNode("div",Fu,[e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!b.value,"aria-label":"Move to top",onClick:y},[...w[1]||(w[1]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 3.5H12M8 6V13M5 9L8 6L11 9",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,ju),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!b.value,"aria-label":"Move up",onClick:g},[...w[2]||(w[2]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 10L8 6L12 10",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Ku),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!u.value,"aria-label":"Move down",onClick:k},[...w[3]||(w[3]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Ou),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!u.value,"aria-label":"Move to bottom",onClick:h},[...w[4]||(w[4]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 12.5H12M8 10V3M5 7L8 10L11 7",stroke:"currentColor","stroke-width":"1.6","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,Hu)]),e.createElementVNode("ul",Uu,[!t.loading&&t.modelValue.length===0?(e.openBlock(),e.createElementBlock("li",Wu,[e.renderSlot(E.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(N,V)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(Be)(N,V,t.itemKey),ref_for:!0,ref:C=>f(C,V),class:e.normalizeClass(["order-list__item mfs-rounded-sm",{"order-list__item--selected":s.value===V,"order-list__item--dragging":d.value===V,"order-list__item--drop-before":c.value===V&&o.value==="before","order-list__item--drop-after":c.value===V&&o.value==="after"}]),role:"option","aria-selected":s.value===V,tabindex:"0",draggable:t.draggable,onClick:C=>s.value=V,onKeydown:[e.withKeys(e.withModifiers(C=>s.value=V,["prevent"]),["enter"]),e.withKeys(e.withModifiers(C=>s.value=V,["prevent"]),["space"]),C=>S(C,V)],onDragstart:C=>B(C,N,V),onDragover:C=>$(C,V),onDrop:C=>_(C,V),onDragend:D},[t.draggable?(e.openBlock(),e.createElementBlock("span",qu,"⋮⋮")):e.createCommentVNode("",!0),e.renderSlot(E.$slots,"item",{item:N,index:V,selected:s.value===V},()=>[e.createElementVNode("span",Yu,e.toDisplayString(N),1)],!0)],42,Gu))),128))])])]))}}),[["__scopeId","data-v-41107e3e"]]),Xu={class:"pick-list"},Zu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ju={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},Qu={key:0,class:"pick-list__header mfs-text"},vu={key:0,class:"mfs-empty-state"},ep=["aria-selected","draggable","onClick","onKeydown","onDragstart","onDragover","onDrop"],tp={class:"mfs-text"},lp={class:"pick-list__controls",role:"group","aria-label":"Transfer controls"},np=["disabled"],op=["disabled"],ap=["disabled"],sp=["disabled"],rp={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},ip={key:0,class:"pick-list__header mfs-text"},dp={key:0,class:"mfs-empty-state"},cp=["aria-selected","draggable","onClick","onKeydown","onDragstart","onDragover","onDrop"],mp={class:"mfs-text"},Cl=F(e.defineComponent({__name:"PickList",props:{source:{},target:{},itemKey:{default:"id"},sourceHeader:{default:"Available"},targetHeader:{default:"Selected"},loading:{type:Boolean,default:!1},emptySourceText:{default:"No items"},emptyTargetText:{default:"No items"},draggable:{type:Boolean,default:!0}},emits:["update:source","update:target","transfer"],setup(t,{emit:a}){let l=0;const n=t,i=a,r=`pick-list-${++l}`,s=e.ref([]),d=e.ref([]),c=e.ref(null),o=e.ref(null),m=e.ref(null);function f(C,P){return(C==="source"?s.value:d.value).includes(P)}function b(C,P){const T=C==="source"?s:d,I=T.value.indexOf(P);I>=0?T.value.splice(I,1):T.value.push(P)}function u(C,P){s.value=[],d.value=[],i("update:source",C),i("update:target",P),i("transfer",{source:C,target:P})}function p(){const C=new Set(s.value),P=n.source.filter((I,j)=>C.has(j)),T=n.source.filter((I,j)=>!C.has(j));u(T,[...n.target,...P])}function g(){u([],[...n.target,...n.source])}function k(){const C=new Set(d.value),P=n.target.filter((I,j)=>C.has(j)),T=n.target.filter((I,j)=>!C.has(j));u([...n.source,...P],T)}function y(){u([...n.source,...n.target],[])}function h(){return!!(n.draggable&&ie.value&&ie.value.group===r)}function B(){return ie.value?ie.value.sourceId.endsWith(":source")?"source":"target":null}function $(C,P,T,I){if(!n.draggable){C.preventDefault();return}c.value={list:P,index:I},at(C,{sourceId:`${r}:${P}`,group:r,index:I,item:T})}function _(C,P,T){if(!h())return;C.preventDefault(),C.dataTransfer&&(C.dataTransfer.dropEffect="move");const I=Ce(C,C.currentTarget,"vertical");o.value={list:P,index:T,position:I},m.value=P}function D(C,P){const T=ie.value,I=B();if(!T||!I)return;if(I===C){const K=C==="source"?n.source:n.target;let W=P===null?Math.max(0,K.length-1):P;if(P!==null&&T.index<W&&(W-=1),W!==T.index){const v=we(K,T.index,W);C==="source"?u(v,n.target):u(n.source,v)}return}const j=[...n.source],A=[...n.target];if(I==="source"){const[K]=j.splice(T.index,1),W=P===null?A.length:P;A.splice(W,0,K)}else{const[K]=A.splice(T.index,1),W=P===null?j.length:P;j.splice(W,0,K)}u(j,A)}function S(C,P,T){var A;if(C.preventDefault(),C.stopPropagation(),!h()){V();return}const j=(((A=o.value)==null?void 0:A.list)===P&&o.value.index===T?o.value.position:Ce(C,C.currentTarget,"vertical"))==="after"?T+1:T;D(P,j),V()}function E(C,P){h()&&(C.preventDefault(),C.dataTransfer&&(C.dataTransfer.dropEffect="move"),m.value=P)}function w(C,P){var I;!C.currentTarget.contains(C.relatedTarget)&&m.value===P&&(m.value=null,((I=o.value)==null?void 0:I.list)===P&&(o.value=null))}function N(C,P){if(C.preventDefault(),!h()){V();return}D(P,null),V()}function V(){c.value=null,o.value=null,m.value=null,st()}return(C,P)=>(e.openBlock(),e.createElementBlock("div",Xu,[t.loading?(e.openBlock(),e.createElementBlock("div",Zu,[e.renderSlot(C.$slots,"loading",{},()=>[P[6]||(P[6]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Ju,[t.sourceHeader?(e.openBlock(),e.createElementBlock("div",Qu,e.toDisplayString(t.sourceHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",{class:e.normalizeClass(["pick-list__list mfs-inset mfs-rounded-md",{"pick-list__list--drag-over":m.value==="source"}]),role:"listbox","aria-label":"Source items",onDragover:P[0]||(P[0]=T=>E(T,"source")),onDragleave:P[1]||(P[1]=T=>w(T,"source")),onDrop:P[2]||(P[2]=T=>N(T,"source"))},[!t.loading&&t.source.length===0?(e.openBlock(),e.createElementBlock("li",vu,[e.renderSlot(C.$slots,"empty-source",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptySourceText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.source,(T,I)=>{var j,A,K;return e.openBlock(),e.createElementBlock("li",{key:e.unref(Be)(T,I,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":f("source",I),"pick-list__item--dragging":((j=c.value)==null?void 0:j.list)==="source"&&c.value.index===I,"pick-list__item--drop-before":((A=o.value)==null?void 0:A.list)==="source"&&o.value.index===I&&o.value.position==="before","pick-list__item--drop-after":((K=o.value)==null?void 0:K.list)==="source"&&o.value.index===I&&o.value.position==="after"}]),role:"option","aria-selected":f("source",I),tabindex:"0",draggable:t.draggable,onClick:W=>b("source",I),onKeydown:[e.withKeys(e.withModifiers(W=>b("source",I),["prevent"]),["enter"]),e.withKeys(e.withModifiers(W=>b("source",I),["prevent"]),["space"])],onDragstart:W=>$(W,"source",T,I),onDragover:W=>_(W,"source",I),onDrop:W=>S(W,"source",I),onDragend:V},[e.renderSlot(C.$slots,"item",{item:T,index:I,list:"source"},()=>[e.createElementVNode("span",tp,e.toDisplayString(T),1)],!0)],42,ep)}),128))],34)]),e.createElementVNode("div",lp,[e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:s.value.length===0,"aria-label":"Move selected to target",onClick:p},[...P[7]||(P[7]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,np),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:t.source.length===0,"aria-label":"Move all to target",onClick:g},[...P[8]||(P[8]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 4L8 8L4 12M9 4L13 8L9 12",stroke:"currentColor","stroke-width":"1.7","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,op),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:d.value.length===0,"aria-label":"Move selected to source",onClick:k},[...P[9]||(P[9]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M10 4L6 8L10 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,ap),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:t.target.length===0,"aria-label":"Move all to source",onClick:y},[...P[10]||(P[10]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M12 4L8 8L12 12M7 4L3 8L7 12",stroke:"currentColor","stroke-width":"1.7","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,sp)]),e.createElementVNode("div",rp,[t.targetHeader?(e.openBlock(),e.createElementBlock("div",ip,e.toDisplayString(t.targetHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",{class:e.normalizeClass(["pick-list__list mfs-inset mfs-rounded-md",{"pick-list__list--drag-over":m.value==="target"}]),role:"listbox","aria-label":"Target items",onDragover:P[3]||(P[3]=T=>E(T,"target")),onDragleave:P[4]||(P[4]=T=>w(T,"target")),onDrop:P[5]||(P[5]=T=>N(T,"target"))},[!t.loading&&t.target.length===0?(e.openBlock(),e.createElementBlock("li",dp,[e.renderSlot(C.$slots,"empty-target",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyTargetText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.target,(T,I)=>{var j,A,K;return e.openBlock(),e.createElementBlock("li",{key:e.unref(Be)(T,I,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":f("target",I),"pick-list__item--dragging":((j=c.value)==null?void 0:j.list)==="target"&&c.value.index===I,"pick-list__item--drop-before":((A=o.value)==null?void 0:A.list)==="target"&&o.value.index===I&&o.value.position==="before","pick-list__item--drop-after":((K=o.value)==null?void 0:K.list)==="target"&&o.value.index===I&&o.value.position==="after"}]),role:"option","aria-selected":f("target",I),tabindex:"0",draggable:t.draggable,onClick:W=>b("target",I),onKeydown:[e.withKeys(e.withModifiers(W=>b("target",I),["prevent"]),["enter"]),e.withKeys(e.withModifiers(W=>b("target",I),["prevent"]),["space"])],onDragstart:W=>$(W,"target",T,I),onDragover:W=>_(W,"target",I),onDrop:W=>S(W,"target",I),onDragend:V},[e.renderSlot(C.$slots,"item",{item:T,index:I,list:"target"},()=>[e.createElementVNode("span",mp,e.toDisplayString(T),1)],!0)],42,cp)}),128))],34)])]))}}),[["__scopeId","data-v-1e7b14e0"]]),fp={class:"tree-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card"},up={class:"tree-table__wrap"},pp={class:"tree-table__table"},kp={key:0},hp=["colspan"],gp=["aria-expanded","aria-label","onClick"],yp={key:1,class:"tree-table__spacer","aria-hidden":"true"},bp={key:0,class:"mfs-loading-overlay","aria-busy":"true"},Nl=F(e.defineComponent({__name:"TreeTable",props:{columns:{},nodes:{},expandedKeys:{default:()=>[]},emptyText:{default:"No data available"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1}},emits:["update:expandedKeys","node-toggle","lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref([...l.expandedKeys]);e.watch(()=>l.expandedKeys,d=>{i.value=[...d]});const r=e.computed(()=>{const d=[],c=new Set(i.value);function o(m,f){for(const b of m){const u=Array.isArray(b.children)&&b.children.length>0||l.lazy&&b.leaf!==!0,p=u&&c.has(b.key);d.push({node:b,depth:f,hasChildren:u,expanded:p}),p&&b.children&&o(b.children,f+1)}}return o(l.nodes,0),d});function s(d){const c=new Set(i.value),o=!c.has(d.key);o?c.add(d.key):c.delete(d.key);const m=Array.from(c);i.value=m,n("update:expandedKeys",m),n("node-toggle",d,o),o&&l.lazy&&(!d.children||d.children.length===0)&&n("lazy-load",d)}return(d,c)=>(e.openBlock(),e.createElementBlock("div",fp,[e.createElementVNode("div",up,[e.createElementVNode("table",pp,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,o=>(e.openBlock(),e.createElementBlock("th",{key:o.key,class:e.normalizeClass(["tree-table__th mfs-text-muted",o.align?`tree-table__cell--${o.align}`:""]),style:e.normalizeStyle(o.width?{width:o.width}:void 0)},e.toDisplayString(o.label),7))),128))])]),e.createElementVNode("tbody",null,[r.value.length===0?(e.openBlock(),e.createElementBlock("tr",kp,[e.createElementVNode("td",{colspan:t.columns.length,class:"tree-table__empty mfs-text-muted"},[e.renderSlot(d.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)],8,hp)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.value,o=>(e.openBlock(),e.createElementBlock("tr",{key:o.node.key,class:"tree-table__row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,(m,f)=>(e.openBlock(),e.createElementBlock("td",{key:m.key,class:e.normalizeClass(["tree-table__td mfs-text",m.align?`tree-table__cell--${m.align}`:""])},[f===0?(e.openBlock(),e.createElementBlock("div",{key:0,class:"tree-table__first-cell",style:e.normalizeStyle({paddingLeft:`${o.depth*20}px`})},[o.hasChildren?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree-table__toggle mfs-text-muted",{"tree-table__toggle--expanded":o.expanded}]),"aria-expanded":o.expanded,"aria-label":o.expanded?"Collapse row":"Expand row",onClick:b=>s(o.node)},[...c[0]||(c[0]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,gp)):(e.openBlock(),e.createElementBlock("span",yp)),e.renderSlot(d.$slots,`cell-${m.key}`,{node:o.node,value:o.node.data[m.key],depth:o.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(o.node.data[m.key]??""),1)],!0)],4)):e.renderSlot(d.$slots,`cell-${m.key}`,{node:o.node,value:o.node.data[m.key],depth:o.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(o.node.data[m.key]??""),1)],!0,1)],2))),128))]))),128))])])]),t.loading?(e.openBlock(),e.createElementBlock("div",bp,[e.renderSlot(d.$slots,"loading",{},()=>[c[1]||(c[1]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-5d1be205"]]),Bp=["aria-busy"],wp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},_p={key:1,class:"mfs-empty-state"},Ep={class:"org-chart__node-wrap"},$p={class:"org-chart__label mfs-title"},Vp={key:0,class:"org-chart__title mfs-caption"},xp=["aria-expanded","aria-label"],Cp={key:0,class:"org-chart__children"},Sl=F(e.defineComponent({name:"OrganizationChart",__name:"OrganizationChart",props:{value:{default:null},collapsible:{type:Boolean,default:!0},expandedKeys:{default:void 0},level:{default:0},loading:{type:Boolean,default:!1},emptyText:{default:"No data"}},emits:["update:expandedKeys","node-click"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(!0),r=e.computed(()=>{var c;return Array.isArray((c=l.value)==null?void 0:c.children)&&l.value.children.length>0}),s=e.computed(()=>l.value?l.expandedKeys?l.expandedKeys.includes(l.value.key):i.value:!1);e.watch(()=>l.expandedKeys,()=>{l.expandedKeys&&l.value&&(i.value=l.expandedKeys.includes(l.value.key))});function d(){if(!(!l.value||!r.value))if(l.expandedKeys){const c=new Set(l.expandedKeys);c.has(l.value.key)?c.delete(l.value.key):c.add(l.value.key),n("update:expandedKeys",Array.from(c))}else i.value=!i.value}return(c,o)=>{const m=e.resolveComponent("OrganizationChart",!0);return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["org-chart mfs-relative",{"org-chart--root":t.level===0,"org-chart--loading-empty":t.level===0&&t.loading&&!t.value}]),"aria-busy":t.level===0&&t.loading?!0:void 0},[t.level===0&&t.loading?(e.openBlock(),e.createElementBlock("div",wp,[e.renderSlot(c.$slots,"loading",{},()=>[o[4]||(o[4]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.value&&!t.loading?(e.openBlock(),e.createElementBlock("div",_p,[e.renderSlot(c.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):t.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("div",Ep,[e.createElementVNode("div",{class:"org-chart__node mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-focus-ring",tabindex:"0",onClick:o[0]||(o[0]=f=>c.$emit("node-click",t.value)),onKeydown:o[1]||(o[1]=e.withKeys(e.withModifiers(f=>c.$emit("node-click",t.value),["prevent"]),["enter"]))},[e.renderSlot(c.$slots,"node",{node:t.value,expanded:s.value},()=>[e.createElementVNode("div",$p,e.toDisplayString(t.value.label),1),t.value.title?(e.openBlock(),e.createElementBlock("div",Vp,e.toDisplayString(t.value.title),1)):e.createCommentVNode("",!0)],!0)],32),t.collapsible&&r.value?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"org-chart__toggle mfs-surface-subtle mfs-pill mfs-shadow","aria-expanded":s.value,"aria-label":s.value?`Collapse ${t.value.label}`:`Expand ${t.value.label}`,onClick:e.withModifiers(d,["stop"])},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass({"org-chart__chevron--collapsed":!s.value}),viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[...o[5]||(o[5]=[e.createElementVNode("path",{d:"M4 6L8 10L12 6",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])],2))],8,xp)):e.createCommentVNode("",!0)]),r.value&&s.value?(e.openBlock(),e.createElementBlock("div",Cp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value.children,f=>(e.openBlock(),e.createElementBlock("div",{key:f.key,class:"org-chart__branch"},[e.createVNode(m,{value:f,collapsible:t.collapsible,"expanded-keys":t.expandedKeys,level:t.level+1,"onUpdate:expandedKeys":o[2]||(o[2]=b=>c.$emit("update:expandedKeys",b)),onNodeClick:o[3]||(o[3]=b=>c.$emit("node-click",b))},e.createSlots({_:2},[c.$slots.node?{name:"node",fn:e.withCtx(b=>[e.renderSlot(c.$slots,"node",e.mergeProps({ref_for:!0},b),void 0,!0)]),key:"0"}:void 0]),1032,["value","collapsible","expanded-keys","level"])]))),128))])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],10,Bp)}}}),[["__scopeId","data-v-122ffff5"]]),Np={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Sp={key:1,class:"mfs-empty-state"},Mp={class:"mfs-text"},Ml=F(e.defineComponent({__name:"VirtualScroller",props:{items:{},itemSize:{},height:{default:"300px"},buffer:{default:3},itemKey:{default:"id"},loading:{type:Boolean,default:!1},lazy:{type:Boolean,default:!1},emptyText:{default:"No items"}},emits:["lazy-load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(0),s=e.ref(300);e.onMounted(()=>{i.value&&(s.value=i.value.clientHeight||300)});function d(){i.value&&(r.value=i.value.scrollTop,s.value=i.value.clientHeight||s.value,l.lazy&&n("lazy-load",{first:o.value,last:m.value}))}const c=e.computed(()=>l.items.length*l.itemSize),o=e.computed(()=>{const u=Math.floor(r.value/l.itemSize)-l.buffer;return Math.max(0,u)}),m=e.computed(()=>{const u=Math.ceil(s.value/l.itemSize),p=Math.floor(r.value/l.itemSize)+u+l.buffer;return Math.min(l.items.length,p)}),f=e.computed(()=>o.value*l.itemSize),b=e.computed(()=>l.items.slice(o.value,m.value).map((u,p)=>({item:u,index:o.value+p})));return(u,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:i,class:"virtual-scroller mfs-surface mfs-rounded mfs-shadow-card",style:e.normalizeStyle({height:t.height}),onScroll:d},[t.loading?(e.openBlock(),e.createElementBlock("div",Np,[e.renderSlot(u.$slots,"loading",{},()=>[p[0]||(p[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):t.items.length===0?(e.openBlock(),e.createElementBlock("div",Sp,[e.renderSlot(u.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",{key:2,class:"virtual-scroller__spacer",style:e.normalizeStyle({height:`${c.value}px`})},[e.createElementVNode("div",{class:"virtual-scroller__content",style:e.normalizeStyle({transform:`translateY(${f.value}px)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,g=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(Be)(g.item,g.index,t.itemKey),class:"virtual-scroller__item",style:e.normalizeStyle({height:`${t.itemSize}px`})},[e.renderSlot(u.$slots,"item",{item:g.item,index:g.index},()=>[e.createElementVNode("span",Mp,e.toDisplayString(g.item),1)],!0)],4))),128))],4)],4))],36))}}),[["__scopeId","data-v-5a8d047c"]]),Dp={class:"meter-group mfs-card"},Tp=["aria-valuenow","aria-valuemax"],Lp=["title"],zp={key:0,class:"meter-group__legend"},Ip={class:"meter-group__label mfs-text"},Rp={class:"meter-group__value mfs-text-muted"},Dl=F(e.defineComponent({__name:"MeterGroup",props:{values:{},max:{default:100},showLegend:{type:Boolean,default:!0}},setup(t){const a=t,l=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)"],n=e.computed(()=>a.values.reduce((s,d)=>s+Math.max(0,d.value),0));function i(s){const d=a.max>0?a.max:100;return Math.min(100,Math.max(0,s/d*100))}function r(s){return l[s%l.length]}return(s,d)=>(e.openBlock(),e.createElementBlock("div",Dp,[e.createElementVNode("div",{class:"meter-group__track mfs-inset mfs-pill",role:"progressbar","aria-valuenow":n.value,"aria-valuemin":"0","aria-valuemax":t.max},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(c,o)=>(e.openBlock(),e.createElementBlock("div",{key:c.label,class:"meter-group__segment",style:e.normalizeStyle({width:`${i(c.value)}%`,backgroundColor:c.color||r(o)}),title:`${c.label}: ${c.value}`},null,12,Lp))),128))],8,Tp),t.showLegend?(e.openBlock(),e.createElementBlock("ol",zp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(c,o)=>(e.openBlock(),e.createElementBlock("li",{key:c.label,class:"meter-group__legend-item"},[e.createElementVNode("span",{class:"meter-group__dot mfs-pill",style:e.normalizeStyle({backgroundColor:c.color||r(o)}),"aria-hidden":"true"},null,4),e.createElementVNode("span",Ip,e.toDisplayString(c.label),1),e.createElementVNode("span",Rp,e.toDisplayString(c.value)+" ("+e.toDisplayString(Math.round(i(c.value)))+"%)",1)]))),128))])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7ff895f3"]]),Pp={class:"inplace"},Ap=["tabindex","aria-disabled","onKeydown"],Fp={class:"inplace__inner"},Tl=F(e.defineComponent({__name:"Inplace",props:{active:{type:Boolean,default:!1},closable:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["update:active","open","close"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.active);e.watch(()=>l.active,c=>{i.value=c});const r=e.computed(()=>i.value);function s(){l.disabled||r.value||(i.value=!0,n("update:active",!0),n("open"))}function d(){r.value&&(i.value=!1,n("update:active",!1),n("close"))}return(c,o)=>(e.openBlock(),e.createElementBlock("div",Pp,[r.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"inplace__content mfs-surface mfs-rounded-md mfs-shadow",onKeydown:e.withKeys(d,["esc"])},[e.createElementVNode("div",Fp,[e.renderSlot(c.$slots,"content",{},void 0,!0)]),t.closable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"inplace__close mfs-surface-subtle mfs-rounded-sm mfs-interactive","aria-label":"Close",onClick:d},[...o[1]||(o[1]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M4 4L12 12M12 4L4 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round"})],-1)])])):e.createCommentVNode("",!0)],32)):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["inplace__display mfs-surface-subtle mfs-rounded-sm mfs-interactive mfs-focus-ring",{"inplace__display--disabled mfs-disabled":t.disabled}]),role:"button",tabindex:t.disabled?-1:0,"aria-disabled":t.disabled||void 0,onClick:s,onKeydown:[e.withKeys(e.withModifiers(s,["prevent"]),["enter"]),e.withKeys(e.withModifiers(s,["prevent"]),["space"])]},[e.renderSlot(c.$slots,"display",{},()=>[o[0]||(o[0]=e.createElementVNode("span",{class:"mfs-text-muted"},"Click to edit",-1))],!0)],42,Ap))]))}}),[["__scopeId","data-v-befa9d74"]]),jp={class:"sortable-list__sr-only","aria-live":"polite"},Kp={key:0,class:"mfs-empty-state mfs-text-muted"},Op=["data-sortable-index","aria-grabbed","tabindex","onPointerdown","onKeydown"],qe=F(e.defineComponent({__name:"SortableList",props:{modelValue:{},itemKey:{default:"id"},group:{default:""},handle:{default:""},disabled:{type:Boolean,default:!1},orientation:{default:"vertical"},emptyText:{default:"Drop items here"}},emits:["update:modelValue","reorder","transfer"],setup(t,{emit:a}){let l=0;const n=t,i=a,r=`sortable-${++l}`,s=e.ref(null),d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref(!1),f=e.ref(""),b=e.ref([]);let u=null,p=null,g=null,k=null;function y(T,I){b.value[I]=T instanceof HTMLElement?T:null}function h(T,I,j){c.value=T,o.value=I,m.value=j}function B(T,I){const j=we(n.modelValue,T,I);i("update:modelValue",j),i("reorder",{value:j,fromIndex:T,toIndex:I})}function $(T){const I=[...n.modelValue];I.splice(T,1),i("update:modelValue",I)}function _(T,I,j,A){const K=[...n.modelValue],W=j<0||j>K.length?K.length:j;K.splice(W,0,T),i("update:modelValue",K),i("transfer",{item:T,fromIndex:I,toIndex:W,fromGroup:A})}e.onMounted(()=>{Mu({listId:r,getGroup:()=>n.group,getOrientation:()=>n.orientation,isDisabled:()=>n.disabled,setDropIndicator:h,onReorder:B,onReceive:_,onRemove:$})}),e.onUnmounted(()=>{C(),Du(r)});function D(T,I){const j=T.cloneNode(!0);return j.classList.add("sortable-list__floating-preview"),j.style.width=`${I.width}px`,j.style.height=`${I.height}px`,j.style.position="fixed",j.style.top="0",j.style.left="0",j.style.margin="0",j.style.pointerEvents="none",j.style.zIndex="9999",document.body.appendChild(j),j}function S(T,I,j){if(!T||!u)return;const A=I-u.offsetX,K=j-u.offsetY;T.style.transform=`translate3d(${A}px, ${K}px, 0) scale(1.02) rotate(0.75deg)`}function E(T,I,j){if(n.disabled||T.button!==0)return;const A=T.target;if(n.handle){if(!(A!=null&&A.closest(n.handle)))return}else if(A!=null&&A.closest("input, textarea, select, button, a"))return;C();const K=T.currentTarget,W=K.getBoundingClientRect();u={item:I,index:j,itemEl:K,rect:W,startX:T.clientX,startY:T.clientY,offsetX:T.clientX-W.left,offsetY:T.clientY-W.top,started:!1,previewEl:null},window.addEventListener("pointermove",w),window.addEventListener("pointerup",N),window.addEventListener("pointercancel",V)}function w(T){var te;if(!u)return;if(!u.started){const oe=T.clientX-u.startX,z=T.clientY-u.startY;if(Math.hypot(oe,z)<=4)return;u.started=!0,s.value=u.index,u.previewEl=D(u.itemEl,u.rect)}S(u.previewEl,T.clientX,T.clientY);const I=document.elementFromPoint(T.clientX,T.clientY),j=I==null?void 0:I.closest("[data-sortable-id]"),A=(j==null?void 0:j.dataset.sortableId)??null,K=A?Ge(A):void 0,W=!!(K&&!K.isDisabled()&&(K.listId===r||n.group&&K.getGroup()===n.group));if(p&&p!==(W?A:null)&&((te=Ge(p))==null||te.setDropIndicator(null,null,!1)),!W||!K){p=null,g=null,k=null;return}p=K.listId;const v=I==null?void 0:I.closest("[data-sortable-index]");if(v&&(j!=null&&j.contains(v))){const oe=Number(v.dataset.sortableIndex),z=Tu(T.clientX,T.clientY,v,K.getOrientation());g=oe,k=z,K.setDropIndicator(oe,z,!0)}else g=null,k=null,K.setDropIndicator(null,null,!0)}function N(){if(u!=null&&u.started&&p){const T=Ge(p);if(T)if(T.listId===r){let I=g!==null&&k!==null?k==="after"?g+1:g:Math.max(0,n.modelValue.length-1);g!==null&&u.index<I&&(I-=1),I!==u.index&&T.onReorder(u.index,I)}else{const I=g!==null&&k!==null?k==="after"?g+1:g:-1;$(u.index),T.onReceive(u.item,u.index,I,n.group)}}C()}function V(){C()}function C(){var T;window.removeEventListener("pointermove",w),window.removeEventListener("pointerup",N),window.removeEventListener("pointercancel",V),p&&((T=Ge(p))==null||T.setDropIndicator(null,null,!1)),u!=null&&u.previewEl&&u.previewEl.remove(),u=null,p=null,g=null,k=null,s.value=null,h(null,null,!1)}function P(T,I){if(n.disabled)return;const j=T.target;if(j!=null&&j.closest("input, textarea, select, button, a"))return;if(T.key===" "||T.code==="Space"){T.preventDefault(),d.value===I?(d.value=null,f.value=`Item dropped at position ${I+1}`):(d.value=I,f.value=`Item grabbed at position ${I+1} of ${n.modelValue.length}`);return}if(T.key==="Escape"&&d.value!==null){T.preventDefault(),d.value=null,f.value="Reorder cancelled";return}const A=n.orientation==="horizontal"?"ArrowLeft":"ArrowUp",K=n.orientation==="horizontal"?"ArrowRight":"ArrowDown";if((T.key===A||T.key===K)&&(d.value===I||T.altKey)){T.preventDefault();const W=T.key===A?-1:1,v=I+W;if(v<0||v>=n.modelValue.length)return;const te=we(n.modelValue,I,v);d.value===I&&(d.value=v),i("update:modelValue",te),i("reorder",{value:te,fromIndex:I,toIndex:v}),f.value=`Moved item to position ${v+1} of ${te.length}`,e.nextTick(()=>{var oe;(oe=b.value[v])==null||oe.focus()})}}return(T,I)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["sortable-list mfs-inset mfs-rounded-md mfs-p-2 mfs-flex mfs-gap-2",[t.orientation==="horizontal"?"sortable-list--horizontal":"mfs-flex-col sortable-list--vertical",{"sortable-list--drag-over":m.value,"sortable-list--disabled":t.disabled}]]),"data-sortable-id":r,role:"list"},[e.createElementVNode("span",jp,e.toDisplayString(f.value),1),t.modelValue.length===0?(e.openBlock(),e.createElementBlock("div",Kp,[e.renderSlot(T.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(j,A)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(Be)(j,A,t.itemKey),ref_for:!0,ref:K=>y(K,A),class:e.normalizeClass(["sortable-list__item mfs-surface mfs-rounded-sm mfs-text",{"sortable-list__item--no-handle":!t.handle&&!t.disabled,"sortable-list__item--dragging":s.value===A,"sortable-list__item--grabbed":d.value===A,"sortable-list__item--drop-before":c.value===A&&o.value==="before","sortable-list__item--drop-after":c.value===A&&o.value==="after"}]),"data-sortable-index":A,role:"listitem","aria-roledescription":"sortable item","aria-grabbed":d.value===A,tabindex:t.disabled?-1:0,onPointerdown:K=>E(K,j,A),onKeydown:K=>P(K,A)},[e.renderSlot(T.$slots,"item",{item:j,index:A,dragging:s.value===A,grabbed:d.value===A},()=>[e.createElementVNode("span",null,e.toDisplayString(j),1)],!0)],42,Op))),128))],2))}}),[["__scopeId","data-v-58181902"]]),Hp={class:"mfs-flex mfs-items-start mfs-gap-2-5 mfs-mb-3"},Up={class:"mfs-confirm-popup__message mfs-text mfs-m-0"},Wp={class:"mfs-flex mfs-justify-end mfs-gap-2"},Ll=F(e.defineComponent({__name:"ConfirmPopup",props:{modelValue:{type:Boolean,default:void 0},target:{default:null},message:{default:"Are you sure you want to proceed?"},acceptLabel:{default:"Yes"},rejectLabel:{default:"No"},variant:{default:"primary"}},emits:["update:modelValue","accept","reject"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(null),s=e.ref(!1),d=e.ref(null),c=e.ref({}),o=e.ref({top:0,left:0}),m=e.computed(()=>n.modelValue!==void 0),f=e.computed(()=>m.value?!!n.modelValue:s.value),b=e.computed(()=>c.value.message??n.message),u=e.computed(()=>c.value.acceptLabel??n.acceptLabel),p=e.computed(()=>c.value.rejectLabel??n.rejectLabel),g=e.computed(()=>c.value.variant??n.variant),k=e.computed(()=>({top:`${o.value.top}px`,left:`${o.value.left}px`}));function y(N){return N?N instanceof HTMLElement?N:N.currentTarget??N.target:null}async function h(){var I;await e.nextTick();const N=d.value??y(n.target);if(!N||typeof window>"u")return;const V=N.getBoundingClientRect(),C=((I=r.value)==null?void 0:I.offsetWidth)??260,P=Math.min(Math.max(12,V.left+V.width/2-C/2),window.innerWidth-C-12),T=V.bottom+10;o.value={top:T,left:P}}function B(N){m.value||(s.value=N),i("update:modelValue",N)}function $(N,V={}){d.value=y(N),c.value=V,B(!0),h()}function _(){B(!1)}function D(){var N,V;(V=(N=c.value).onAccept)==null||V.call(N),i("accept"),_()}function S(){var N,V;(V=(N=c.value).onReject)==null||V.call(N),i("reject"),_()}const E=N=>{var P;const V=N.target,C=d.value??y(n.target);(P=r.value)!=null&&P.contains(V)||C!=null&&C.contains(V)||_()},w=N=>{N.key==="Escape"&&_()};return e.watch(f,N=>{typeof document>"u"||(N?(h(),document.addEventListener("pointerdown",E),document.addEventListener("keydown",w)):(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",w)))}),e.onBeforeUnmount(()=>{typeof document<"u"&&(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",w))}),a({show:$,hide:_}),(N,V)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-popup"},{default:e.withCtx(()=>[f.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"popupRef",ref:r,class:"mfs-confirm-popup mfs-fixed mfs-overlay mfs-surface mfs-rounded mfs-shadow-card mfs-blur",style:e.normalizeStyle(k.value),role:"alertdialog","aria-modal":"false"},[e.createElementVNode("div",Hp,[e.createElementVNode("span",{class:e.normalizeClass(["mfs-confirm-popup__icon mfs-shrink-0",[`mfs-text-${g.value}`]]),"aria-hidden":"true"},[...V[0]||(V[0]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"}),e.createElementVNode("path",{d:"M12 8v4"}),e.createElementVNode("path",{d:"M12 16h.01"})],-1)])],2),e.createElementVNode("p",Up,e.toDisplayString(b.value),1)]),e.createElementVNode("div",Wp,[e.createElementVNode("button",{type:"button",class:"mfs-confirm-popup__btn mfs-surface-subtle mfs-pill mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",onClick:S},e.toDisplayString(p.value),1),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-confirm-popup__btn mfs-pill mfs-shadow mfs-focus-ring mfs-cursor-pointer mfs-font-semibold",[`mfs-bg-${g.value}`]]),onClick:D},e.toDisplayString(u.value),3)])],4)):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-57b1abca"]]),Gp={class:"mfs-inline-msg__icon","aria-hidden":"true"},qp={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Yp={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Xp={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Zp={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Jp={class:"mfs-inline-msg__text"},zl=F(e.defineComponent({__name:"InlineMessage",props:{severity:{default:"info"},text:{default:""}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["mfs-inline-msg mfs-rounded-sm",[`mfs-inline-msg--${t.severity}`,t.severity==="info"?"mfs-soft-primary":`mfs-soft-${t.severity}`]]),role:"status"},[e.createElementVNode("span",Gp,[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",qp,[...l[0]||(l[0]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):t.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",Yp,[...l[1]||(l[1]=[e.createElementVNode("path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"},null,-1),e.createElementVNode("path",{d:"M12 9v4"},null,-1),e.createElementVNode("path",{d:"M12 17h.01"},null,-1)])])):t.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",Xp,[...l[2]||(l[2]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m15 9-6 6"},null,-1),e.createElementVNode("path",{d:"m9 9 6 6"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Zp,[...l[3]||(l[3]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"M12 16v-4"},null,-1),e.createElementVNode("path",{d:"M12 8h.01"},null,-1)])]))]),e.createElementVNode("span",Jp,[e.renderSlot(a.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.text),1)],!0)])],2))}}),[["__scopeId","data-v-40ba4b5c"]]),Qp=["aria-busy"],vp=["aria-label"],ek={class:"mfs-blockui__content mfs-surface mfs-rounded mfs-shadow"},tk={key:0,class:"mfs-blockui__label mfs-text"},Il=F(e.defineComponent({__name:"BlockUI",props:{blocked:{type:Boolean,default:!1},fullScreen:{type:Boolean,default:!1},label:{default:""}},setup(t){return(a,l)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-blockui","aria-busy":t.blocked},[e.renderSlot(a.$slots,"default",{},void 0,!0),(e.openBlock(),e.createBlock(e.Teleport,{to:"body",disabled:!t.fullScreen},[e.createVNode(e.Transition,{name:"mfs-blockui-fade"},{default:e.withCtx(()=>[t.blocked?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-blockui__overlay mfs-backdrop",{"mfs-blockui__overlay--fullscreen":t.fullScreen,"mfs-rounded":!t.fullScreen}]),role:"status","aria-label":t.label||"Loading"},[e.renderSlot(a.$slots,"overlay",{},()=>[e.createElementVNode("div",ek,[l[0]||(l[0]=e.createElementVNode("span",{class:"mfs-blockui__spinner","aria-hidden":"true"},[e.createElementVNode("svg",{viewBox:"0 0 50 50"},[e.createElementVNode("circle",{cx:"25",cy:"25",r:"20",fill:"none",stroke:"currentColor","stroke-width":"4","stroke-linecap":"round","stroke-dasharray":"90 150"})])],-1)),t.label?(e.openBlock(),e.createElementBlock("span",tk,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)])],!0)],10,vp)):e.createCommentVNode("",!0)]),_:3})],8,["disabled"]))],8,Qp))}}),[["__scopeId","data-v-59ef354e"]]),lk=["aria-busy","onKeydown"],nk={class:"mfs-galleria__stage"},ok={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ak={key:1,class:"mfs-empty-state"},sk=["src","alt"],rk=["aria-label"],ik={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},dk={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},ck={key:4,class:"mfs-galleria__caption"},mk={key:0,class:"mfs-galleria__thumbs"},fk=["aria-label","onClick"],uk=["src","alt"],Rl=F(e.defineComponent({__name:"Galleria",props:{images:{default:()=>[]},activeIndex:{default:0},showThumbnails:{type:Boolean,default:!0},fullscreen:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},emptyText:{default:"No images"}},emits:["update:activeIndex"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(l.activeIndex),r=e.ref(l.fullscreen);e.watch(()=>l.activeIndex,m=>{i.value=m});const s=e.computed(()=>l.images[i.value]??null),d=m=>{if(l.images.length===0)return;const f=(m+l.images.length)%l.images.length;i.value=f,n("update:activeIndex",f)},c=()=>d(i.value-1),o=()=>d(i.value+1);return(m,f)=>{var b;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-galleria mfs-surface mfs-rounded mfs-shadow-card mfs-blur",{"mfs-galleria--fullscreen":r.value}]),"aria-busy":t.loading||void 0,tabindex:"0",onKeydown:[e.withKeys(e.withModifiers(c,["prevent"]),["left"]),e.withKeys(e.withModifiers(o,["prevent"]),["right"]),f[1]||(f[1]=e.withKeys(u=>r.value=!1,["escape"]))]},[e.createElementVNode("div",nk,[t.loading?(e.openBlock(),e.createElementBlock("div",ok,[e.renderSlot(m.$slots,"loading",{},()=>[f[2]||(f[2]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.images.length===0?(e.openBlock(),e.createElementBlock("div",ak,[e.renderSlot(m.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[s.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:s.value.src,alt:s.value.alt||s.value.title||"Gallery image",class:"mfs-galleria__image"},null,8,sk)):e.createCommentVNode("",!0),t.images.length>1?(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"mfs-galleria__nav mfs-galleria__nav--prev mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":"Previous image",onClick:c},[...f[3]||(f[3]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"m15 18-6-6 6-6"})],-1)])])):e.createCommentVNode("",!0),t.images.length>1?(e.openBlock(),e.createElementBlock("button",{key:2,type:"button",class:"mfs-galleria__nav mfs-galleria__nav--next mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":"Next image",onClick:o},[...f[4]||(f[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"m9 18 6-6-6-6"})],-1)])])):e.createCommentVNode("",!0),t.images.length>0?(e.openBlock(),e.createElementBlock("button",{key:3,type:"button",class:"mfs-galleria__fs mfs-surface-subtle mfs-pill mfs-focus-ring","aria-label":r.value?"Exit fullscreen":"Enter fullscreen",onClick:f[0]||(f[0]=u=>r.value=!r.value)},[r.value?(e.openBlock(),e.createElementBlock("svg",dk,[...f[6]||(f[6]=[e.createElementVNode("path",{d:"M4 14h6v6M20 10h-6V4M14 10l7-7M3 21l7-7"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",ik,[...f[5]||(f[5]=[e.createElementVNode("path",{d:"M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"},null,-1)])]))],8,rk)):e.createCommentVNode("",!0),(b=s.value)!=null&&b.title?(e.openBlock(),e.createElementBlock("div",ck,e.toDisplayString(s.value.title),1)):e.createCommentVNode("",!0)],64))]),t.showThumbnails&&t.images.length>1?(e.openBlock(),e.createElementBlock("div",mk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(u,p)=>(e.openBlock(),e.createElementBlock("button",{key:p,type:"button",class:e.normalizeClass(["mfs-galleria__thumb mfs-rounded-sm",{"mfs-galleria__thumb--active":p===i.value}]),"aria-label":`View image ${p+1}`,onClick:g=>d(p)},[e.createElementVNode("img",{src:u.thumbnail||u.src,alt:u.alt||`Thumbnail ${p+1}`},null,8,uk)],10,fk))),128))])):e.createCommentVNode("",!0)],42,lk)}}}),[["__scopeId","data-v-c26e7cc6"]]),pk=["disabled"],kk=["onKeydown"],hk=["src"],gk={key:2,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},yk={key:3,class:"mfs-cropper__controls mfs-flex mfs-flex-col mfs-gap-3"},bk={class:"mfs-row mfs-justify-between"},Bk={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-1 mfs-min-w-0"},wk=["disabled"],_k=["disabled"],Ek=["disabled"],$k={class:"mfs-flex mfs-items-center mfs-gap-1-5 mfs-shrink-0"},Vk=["disabled"],xk=["disabled"],Ck=["disabled"],Nk={class:"mfs-row mfs-justify-between mfs-flex-wrap mfs-gap-2"},Sk={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-wrap"},Mk=["disabled"],Dk={key:0,class:"mfs-cropper__shape-toggle mfs-inline-flex mfs-surface-subtle mfs-rounded-sm mfs-border mfs-gap-1",role:"group","aria-label":"Crop shape"},Tk=["aria-pressed","disabled"],Lk=["aria-pressed","disabled"],zk={class:"mfs-flex mfs-items-center mfs-gap-2"},Ik=["disabled"],Rk=["disabled"],rt=F(e.defineComponent({__name:"ImageCropper",props:{modelValue:{default:null},src:{default:null},aspectRatio:{default:1},shape:{default:"rect"},allowShapeToggle:{type:Boolean,default:!0},outputType:{default:"image/png"},outputSize:{default:512},quality:{default:.92},fileName:{default:"cropped-image.png"},showControls:{type:Boolean,default:!0},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","update:shape","crop","cancel","error"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(null),o=e.ref(null),m=e.ref(!1),f=e.ref(null),b=e.ref(!1),u=e.ref(!1),p=e.ref(0),g=e.ref(0),k=e.ref(320),y=e.ref(260),h=e.ref(1),B=e.ref(0),$=e.ref(0),_=e.ref(0),D=e.ref(!1);let S=0,E=0,w=0,N=0,V=null;const C=e.ref(n.shape);e.watch(()=>n.shape,M=>{C.value=M});function P(M){n.disabled||C.value===M||(C.value=M,i("update:shape",M))}const T=e.computed(()=>o.value?o.value:n.src?n.src:typeof n.modelValue=="string"&&n.modelValue?n.modelValue:c.value?c.value:null),I=e.computed(()=>C.value==="circle"?1:n.aspectRatio>0?n.aspectRatio:1),j=e.computed(()=>{const M=Math.max(80,k.value*.82),x=Math.max(80,y.value*.82),R=I.value;let H=M,X=H/R;return X>x&&(X=x,H=X*R),{width:H,height:X}}),A=e.computed(()=>Math.abs(B.value%180)===90),K=e.computed(()=>{if(!p.value||!g.value)return 1;const M=A.value?g.value:p.value,x=A.value?p.value:g.value;return Math.max(j.value.width/M,j.value.height/x)}),W=e.computed(()=>K.value*h.value);function v(M,x,R){return Math.min(R,Math.max(x,M))}function te(){if(!p.value||!g.value)return;const M=A.value?g.value:p.value,x=A.value?p.value:g.value,R=M*W.value,H=x*W.value,X=Math.max(0,(R-j.value.width)/2),le=Math.max(0,(H-j.value.height)/2);$.value=v($.value,-X,X),_.value=v(_.value,-le,le)}const oe=e.computed(()=>({width:`${p.value}px`,height:`${g.value}px`,marginLeft:`${-p.value/2}px`,marginTop:`${-g.value/2}px`,transform:`translate(${$.value}px, ${_.value}px) rotate(${B.value}deg) scale(${W.value})`})),z=e.computed(()=>({width:`${j.value.width}px`,height:`${j.value.height}px`}));function O(){c.value&&(URL.revokeObjectURL(c.value),c.value=null)}function Z(M){if(!(M.type.startsWith("image/")||/\.(png|jpe?g|webp|gif|bmp|svg|avif)$/i.test(M.name))){const H=`Unsupported file type: ${M.name}`;f.value=H,i("error",H);return}O(),f.value=null,m.value=!1;const R=URL.createObjectURL(M);c.value=R,o.value=R,me()}function Y(){var M;n.disabled||(M=r.value)==null||M.click()}function Q(M){var H;const x=M.target,R=(H=x.files)==null?void 0:H[0];R&&Z(R),x.value=""}function q(M){var R,H;if(b.value=!1,n.disabled)return;const x=(H=(R=M.dataTransfer)==null?void 0:R.files)==null?void 0:H[0];x&&Z(x)}function U(){const M=d.value;M&&(p.value=M.naturalWidth,g.value=M.naturalHeight,m.value=!0,f.value=null,te())}function J(){m.value=!1;const M="Failed to load image";f.value=M,i("error",M)}function ne(M){if(n.disabled||!m.value)return;const x=s.value;x&&(D.value=!0,S=M.clientX,E=M.clientY,w=$.value,N=_.value,x.setPointerCapture(M.pointerId))}function G(M){D.value&&($.value=w+(M.clientX-S),_.value=N+(M.clientY-E),te())}function ee(M){var x;D.value&&(D.value=!1,(x=s.value)==null||x.releasePointerCapture(M.pointerId))}function re(M){if(n.disabled||!m.value)return;const x=M.deltaY<0?.1:-.1;ae(x)}function ae(M){h.value=Number(v(h.value+M,1,3).toFixed(2))}function Me(M){B.value=(B.value+M)%360,te()}function me(){h.value=1,B.value=0,$.value=0,_.value=0,te()}async function Je(){const M=d.value;if(!M||!m.value||u.value)return null;u.value=!0,f.value=null;try{const x=I.value,R=x>=1?n.outputSize:Math.round(n.outputSize*x),H=x>=1?Math.round(n.outputSize/x):n.outputSize,X=document.createElement("canvas");X.width=R,X.height=H;const le=X.getContext("2d");if(!le)throw new Error("Canvas 2D context is unavailable");n.outputType==="image/jpeg"&&(le.fillStyle="#ffffff",le.fillRect(0,0,R,H)),C.value==="circle"&&(le.beginPath(),le.arc(R/2,H/2,Math.min(R,H)/2,0,Math.PI*2),le.clip());const ce=R/j.value.width;le.save(),le.translate(R/2+$.value*ce,H/2+_.value*ce),le.rotate(B.value*Math.PI/180);const De=W.value*ce;le.scale(De,De),le.drawImage(M,-p.value/2,-g.value/2,p.value,g.value),le.restore();const wn=await new Promise((Ig,Rg)=>{X.toBlob($n=>$n?Ig($n):Rg(new Error("Failed to export cropped image")),n.outputType,n.quality)}),zg=X.toDataURL(n.outputType,n.quality),_n=new File([wn],n.fileName,{type:n.outputType}),En={blob:wn,dataUrl:zg,file:_n};return i("update:modelValue",_n),i("crop",En),En}catch(x){const R=x instanceof Error?x.message:"Failed to crop image";return f.value=R,i("error",R),null}finally{u.value=!1}}function he(){const M=s.value;if(!M)return;const x=M.getBoundingClientRect();x.width>0&&x.height>0&&(k.value=x.width,y.value=x.height,te())}function Qe(){V==null||V.disconnect(),!(!s.value||typeof ResizeObserver>"u")&&(V=new ResizeObserver(he),V.observe(s.value),he())}return e.watch(()=>n.modelValue,M=>{o.value=null,O(),m.value=!1,M instanceof File&&(c.value=URL.createObjectURL(M)),me()},{immediate:!0}),e.watch(()=>n.src,()=>{o.value=null,m.value=!1,me()}),e.watch([h,I],()=>{te()}),e.watch(s,M=>{M&&Qe()}),e.onMounted(()=>{Qe()}),e.onBeforeUnmount(()=>{V==null||V.disconnect(),O()}),a({crop:Je,reset:me}),(M,x)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-cropper mfs-surface mfs-rounded mfs-shadow-card mfs-p-4 mfs-flex mfs-flex-col mfs-gap-3",{"mfs-disabled":t.disabled}])},[e.createElementVNode("input",{ref_key:"fileInputRef",ref:r,type:"file",accept:"image/*",class:"mfs-sr-only",disabled:t.disabled,onChange:Q},null,40,pk),T.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"stageRef",ref:s,class:e.normalizeClass(["mfs-cropper__stage mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none",D.value?"mfs-cropper__stage--grabbing":"mfs-cropper__stage--grab"]),onPointerdown:ne,onPointermove:G,onPointerup:ee,onPointercancel:ee,onWheel:e.withModifiers(re,["prevent"])},[e.createElementVNode("img",{ref_key:"imgRef",ref:d,src:T.value,alt:"Crop source",draggable:"false",class:"mfs-cropper__img",style:e.normalizeStyle(oe.value),onLoad:U,onError:J},null,44,hk),m.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__viewport mfs-absolute",{"mfs-cropper__viewport--circle":C.value==="circle"}]),style:e.normalizeStyle(z.value),"aria-hidden":"true"},[...x[11]||(x[11]=[e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--h1"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--h2"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--v1"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--v2"},null,-1)])],6)):e.createCommentVNode("",!0)],34)):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__empty mfs-surface-subtle mfs-rounded mfs-border mfs-flex mfs-flex-col mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-6 mfs-text-center mfs-cursor-pointer mfs-focus-ring",{"mfs-border-primary":b.value}]),role:"button",tabindex:"0","aria-label":"Select an image to crop",onClick:Y,onKeydown:[e.withKeys(e.withModifiers(Y,["prevent"]),["enter"]),e.withKeys(e.withModifiers(Y,["prevent"]),["space"])],onDragover:x[0]||(x[0]=e.withModifiers(R=>b.value=!0,["prevent"])),onDragleave:x[1]||(x[1]=e.withModifiers(R=>b.value=!1,["prevent"])),onDrop:e.withModifiers(q,["prevent"])},[...x[10]||(x[10]=[e.createStaticVNode('<svg viewBox="0 0 24 24" width="36" height="36" fill="none" stroke="currentColor" stroke-width="1.8" stroke-linecap="round" stroke-linejoin="round" class="mfs-text-primary" aria-hidden="true" data-v-4a71ca25><rect x="3" y="3" width="18" height="18" rx="3" data-v-4a71ca25></rect><circle cx="8.5" cy="8.5" r="1.5" data-v-4a71ca25></circle><path d="m21 15-5-5L5 21" data-v-4a71ca25></path></svg><p class="mfs-m-0 mfs-font-semibold mfs-text" data-v-4a71ca25> Click or drop an image to crop </p><span class="mfs-caption" data-v-4a71ca25>PNG, JPG, WEBP supported</span>',3)])],42,kk)),f.value?(e.openBlock(),e.createElementBlock("div",gk,e.toDisplayString(f.value),1)):e.createCommentVNode("",!0),t.showControls&&T.value?(e.openBlock(),e.createElementBlock("div",yk,[e.createElementVNode("div",bk,[e.createElementVNode("div",Bk,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Zoom out",disabled:t.disabled||h.value<=1,onClick:x[2]||(x[2]=R=>ae(-.15))},[...x[12]||(x[12]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,wk),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":x[3]||(x[3]=R=>h.value=R),type:"range",min:"1",max:"3",step:"0.05","aria-label":"Zoom level",class:"mfs-cropper__slider mfs-flex-1 mfs-min-w-0",disabled:t.disabled},null,8,_k),[[e.vModelText,h.value,void 0,{number:!0}]]),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Zoom in",disabled:t.disabled||h.value>=3,onClick:x[4]||(x[4]=R=>ae(.15))},[...x[13]||(x[13]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,Ek)]),e.createElementVNode("div",$k,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Rotate left 90 degrees",title:"Rotate -90°",disabled:t.disabled,onClick:x[5]||(x[5]=R=>Me(-90))},[...x[14]||(x[14]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8"}),e.createElementVNode("path",{d:"M3 3v5h5"})],-1)])],8,Vk),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center","aria-label":"Rotate right 90 degrees",title:"Rotate +90°",disabled:t.disabled,onClick:x[6]||(x[6]=R=>Me(90))},[...x[15]||(x[15]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M21 12a9 9 0 1 1-9-9c2.52 0 4.93 1 6.74 2.74L21 8"}),e.createElementVNode("path",{d:"M21 3v5h-5"})],-1)])],8,xk),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text-muted mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center mfs-px-2 mfs-text-xs mfs-font-semibold",disabled:t.disabled,onClick:me}," Reset ",8,Ck)])]),e.createElementVNode("div",Nk,[e.createElementVNode("div",Sk,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__action mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-text-sm mfs-font-medium mfs-cursor-pointer mfs-focus-ring mfs-px-3 mfs-py-2",disabled:t.disabled,onClick:Y}," Change Image ",8,Mk),t.allowShapeToggle?(e.openBlock(),e.createElementBlock("div",Dk,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-cropper__shape-btn mfs-rounded-sm mfs-border-none mfs-text-xs mfs-font-semibold mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-gap-1",C.value==="rect"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":C.value==="rect",disabled:t.disabled,onClick:x[7]||(x[7]=R=>P("rect"))},[...x[16]||(x[16]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",width:"13",height:"13",fill:"none",stroke:"currentColor","stroke-width":"1.8","aria-hidden":"true"},[e.createElementVNode("rect",{x:"2.5",y:"2.5",width:"11",height:"11",rx:"1.5"})],-1),e.createTextVNode(" Square ",-1)])],10,Tk),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-cropper__shape-btn mfs-rounded-sm mfs-border-none mfs-text-xs mfs-font-semibold mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-gap-1",C.value==="circle"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":C.value==="circle",disabled:t.disabled,onClick:x[8]||(x[8]=R=>P("circle"))},[...x[17]||(x[17]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",width:"13",height:"13",fill:"none",stroke:"currentColor","stroke-width":"1.8","aria-hidden":"true"},[e.createElementVNode("circle",{cx:"8",cy:"8",r:"5.5"})],-1),e.createTextVNode(" Circle ",-1)])],10,Lk)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",zk,[e.createElementVNode("button",{type:"button",class:"mfs-cropper__action mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text mfs-text-sm mfs-font-medium mfs-cursor-pointer mfs-focus-ring mfs-px-3 mfs-py-2",disabled:t.disabled,onClick:x[9]||(x[9]=R=>i("cancel"))}," Cancel ",8,Ik),e.createElementVNode("button",{type:"button",class:"mfs-cropper__action mfs-bg-primary mfs-rounded-sm mfs-border-none mfs-text-sm mfs-font-semibold mfs-cursor-pointer mfs-focus-ring mfs-px-4 mfs-py-2",disabled:t.disabled||!m.value||u.value,onClick:Je},e.toDisplayString(u.value?"Cropping...":"Crop"),9,Rk)])])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4a71ca25"]]),Pk=["aria-busy"],Ak={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Fk=["onKeydown"],jk=["accept","multiple","disabled"],Kk={key:0,class:"mfs-upload__hint mfs-caption mfs-m-0"},Ok={key:0},Hk={key:1},Uk={key:2},Wk={key:1,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},Gk={key:2,class:"mfs-upload__progress-wrap mfs-flex mfs-items-center mfs-gap-2-5"},qk={class:"mfs-upload__progress-track mfs-pill mfs-shadow-inset mfs-flex-1 mfs-overflow-hidden"},Yk={class:"mfs-upload__progress-text mfs-text-muted mfs-font-bold"},Xk={key:3,class:"mfs-upload__list mfs-m-0 mfs-p-0 mfs-flex mfs-flex-col mfs-gap-2"},Zk={class:"mfs-upload__file-info mfs-flex mfs-flex-col mfs-min-w-0"},Jk={class:"mfs-upload__file-name mfs-text mfs-font-semibold mfs-truncate"},Qk={class:"mfs-upload__file-size mfs-caption"},vk=["onClick"],Pl=F(e.defineComponent({__name:"FileUpload",props:{modelValue:{},accept:{},multiple:{type:Boolean,default:!1},maxFileSize:{},disabled:{type:Boolean,default:!1},progress:{},loading:{type:Boolean,default:!1},error:{},crop:{type:Boolean,default:!1},cropShape:{default:"rect"},cropAspectRatio:{default:1}},emits:["update:modelValue","select","remove","error","clear"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(l.modelValue?[...l.modelValue]:[]),s=e.ref([]),d=e.ref(!1),c=e.ref(null),o=e.computed(()=>l.error||c.value),m=e.computed(()=>s.value[0]??null),f=e.computed(()=>m.value!==null),b=e.computed(()=>{const S=m.value;return S?`${S.name.replace(/\.[^.]+$/,"")||"cropped-image"}.png`:"cropped-image.png"});e.watch(()=>l.modelValue,S=>{S&&(r.value=[...S])});function u(S){return S<1024?`${S} B`:S<1024*1024?`${(S/1024).toFixed(1)} KB`:`${(S/(1024*1024)).toFixed(1)} MB`}function p(S,E){if(!E)return!0;const w=E.split(",").map(C=>C.trim().toLowerCase()).filter(Boolean);if(w.length===0)return!0;const N=S.name.toLowerCase(),V=S.type.toLowerCase();return w.some(C=>C.startsWith(".")?N.endsWith(C):C.endsWith("/*")?V.startsWith(C.slice(0,-1)):V===C)}function g(S){if(!S||l.disabled||l.loading)return;c.value=null;const E=[];for(const w of Array.from(S)){if(!p(w,l.accept)){const N=`Invalid file type: ${w.name}`;c.value=N,n("error",N);continue}if(l.maxFileSize&&w.size>l.maxFileSize){const N=`File too large: ${w.name} (max ${u(l.maxFileSize)})`;c.value=N,n("error",N);continue}E.push(w)}if(E.length!==0){if(l.crop){const w=l.multiple?E:[E[0]],N=w.filter(C=>C.type.startsWith("image/")),V=w.filter(C=>!C.type.startsWith("image/"));V.length>0&&(r.value=l.multiple?[...r.value,...V]:[V[0]],n("update:modelValue",r.value),n("select",r.value)),N.length>0&&(s.value=l.multiple?[...s.value,...N]:[N[0]]);return}r.value=l.multiple?[...r.value,...E]:[E[0]],n("update:modelValue",r.value),n("select",r.value)}}function k(S){r.value=l.multiple?[...r.value,S.file]:[S.file],n("update:modelValue",r.value),n("select",r.value),s.value.shift()}function y(){s.value.shift()}const h=()=>{var S;!l.disabled&&!l.loading&&((S=i.value)==null||S.click())},B=S=>{const E=S.target;g(E.files),E.value=""},$=()=>{!l.disabled&&!l.loading&&(d.value=!0)},_=S=>{var E;d.value=!1,g(((E=S.dataTransfer)==null?void 0:E.files)??null)},D=S=>{const[E]=r.value.splice(S,1);n("update:modelValue",r.value),E&&n("remove",E),r.value.length===0&&n("clear")};return(S,E)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-upload mfs-relative mfs-surface mfs-rounded mfs-shadow-card mfs-blur mfs-p-4 mfs-flex mfs-flex-col mfs-gap-3","aria-busy":t.loading||void 0},[t.loading?(e.openBlock(),e.createElementBlock("div",Ak,[...E[1]||(E[1]=[e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["mfs-upload__dropzone mfs-surface-subtle mfs-rounded mfs-focus-ring mfs-relative mfs-text-center mfs-cursor-pointer",{"mfs-upload__dropzone--dragging":d.value,"mfs-upload__dropzone--disabled mfs-disabled":t.disabled||t.loading}]),role:"button",tabindex:"0","aria-label":"Upload files",onClick:h,onKeydown:[e.withKeys(e.withModifiers(h,["prevent"]),["enter"]),e.withKeys(e.withModifiers(h,["prevent"]),["space"])],onDragover:e.withModifiers($,["prevent"]),onDragleave:E[0]||(E[0]=e.withModifiers(w=>d.value=!1,["prevent"])),onDrop:e.withModifiers(_,["prevent"])},[e.createElementVNode("input",{ref_key:"inputRef",ref:i,type:"file",class:"mfs-upload__input",accept:t.accept,multiple:t.multiple,disabled:t.disabled||t.loading,onChange:B},null,40,jk),E[2]||(E[2]=e.createStaticVNode('<span class="mfs-upload__icon mfs-inline-flex mfs-text-primary mfs-mb-2" aria-hidden="true" data-v-071de6a6><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-v-071de6a6><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" data-v-071de6a6></path><polyline points="17 8 12 3 7 8" data-v-071de6a6></polyline><line x1="12" x2="12" y1="3" y2="15" data-v-071de6a6></line></svg></span><p class="mfs-upload__title mfs-title mfs-m-0 mfs-font-semibold" data-v-071de6a6> Drag & drop files here or <span class="mfs-upload__link mfs-text-primary" data-v-071de6a6>browse</span></p>',2)),t.accept||t.maxFileSize?(e.openBlock(),e.createElementBlock("p",Kk,[t.accept?(e.openBlock(),e.createElementBlock("span",Ok,"Accepted: "+e.toDisplayString(t.accept),1)):e.createCommentVNode("",!0),t.accept&&t.maxFileSize?(e.openBlock(),e.createElementBlock("span",Hk," · ")):e.createCommentVNode("",!0),t.maxFileSize?(e.openBlock(),e.createElementBlock("span",Uk,"Max: "+e.toDisplayString(u(t.maxFileSize)),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],42,Fk),o.value?(e.openBlock(),e.createElementBlock("div",Wk,e.toDisplayString(o.value),1)):e.createCommentVNode("",!0),typeof t.progress=="number"&&t.progress>0?(e.openBlock(),e.createElementBlock("div",Gk,[e.createElementVNode("div",qk,[e.createElementVNode("div",{class:"mfs-upload__progress-bar mfs-pill mfs-h-full mfs-bg-primary",style:e.normalizeStyle({width:`${Math.min(100,Math.max(0,t.progress))}%`})},null,4)]),e.createElementVNode("span",Yk,e.toDisplayString(Math.round(t.progress))+"%",1)])):e.createCommentVNode("",!0),r.value.length>0?(e.openBlock(),e.createElementBlock("ul",Xk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(w,N)=>(e.openBlock(),e.createElementBlock("li",{key:`${w.name}-${w.size}-${N}`,class:"mfs-upload__item mfs-surface-subtle mfs-rounded-sm mfs-flex mfs-items-center mfs-justify-between mfs-gap-2-5 mfs-py-2 mfs-px-3"},[e.createElementVNode("div",Zk,[e.createElementVNode("span",Jk,e.toDisplayString(w.name),1),e.createElementVNode("span",Qk,e.toDisplayString(u(w.size)),1)]),e.createElementVNode("button",{type:"button",class:"mfs-upload__remove mfs-pill mfs-focus-ring mfs-shrink-0 mfs-border-none mfs-bg-transparent mfs-text-muted mfs-inline-flex mfs-items-center mfs-justify-center mfs-cursor-pointer","aria-label":"Remove file",onClick:V=>D(N)},[...E[3]||(E[3]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},[e.createElementVNode("path",{d:"M18 6 6 18"}),e.createElementVNode("path",{d:"m6 6 12 12"})],-1)])],8,vk)]))),128))])):e.createCommentVNode("",!0),e.createVNode(ye,{"model-value":f.value,title:"Crop Image",size:"md","close-on-backdrop":!1,onClose:y},{default:e.withCtx(()=>[m.value?(e.openBlock(),e.createBlock(rt,{key:0,"model-value":m.value,shape:t.cropShape,"aspect-ratio":t.cropAspectRatio,"file-name":b.value,onCrop:k,onCancel:y},null,8,["model-value","shape","aspect-ratio","file-name"])):e.createCommentVNode("",!0)]),_:1},8,["model-value"])],8,Pk))}}),[["__scopeId","data-v-071de6a6"]]),eh={key:0,class:"mfs-terminal__welcome mfs-text-muted"},th={class:"mfs-flex mfs-gap-2"},lh={class:"mfs-text-primary mfs-font-bold mfs-select-none"},nh={class:"mfs-terminal__cmd"},oh={key:0,class:"mfs-terminal__response"},ah={class:"mfs-text-primary mfs-font-bold mfs-select-none"},sh=["onKeydown"],Al=F(e.defineComponent({__name:"Terminal",props:{welcomeMessage:{default:""},prompt:{default:"$"},commands:{}},emits:["command"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref([]),s=e.ref([]),d=e.ref(-1),c=e.ref(""),o=e.ref(null),m=e.ref(null),f=()=>{var k;(k=o.value)==null||k.focus()},b=async()=>{await e.nextTick(),m.value&&(m.value.scrollTop=m.value.scrollHeight)},u=async()=>{const k=c.value.trim();if(!k)return;c.value="",s.value.push(k),d.value=s.value.length;const[y,...h]=k.split(/\s+/);if(y==="clear"){r.value=[];return}const B={command:k};r.value.push(B);const $=r.value.length-1,_=D=>{r.value[$].response=D,b()};if(n.commands&&y in n.commands){const D=await n.commands[y](h);_(D)}else i("command",{command:y,args:h,raw:k,respond:_});b()},p=()=>{s.value.length!==0&&(d.value=Math.max(0,d.value-1),c.value=s.value[d.value]??"")},g=()=>{s.value.length!==0&&(d.value=Math.min(s.value.length,d.value+1),c.value=s.value[d.value]??"")};return a({clear:()=>{r.value=[]}}),(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-terminal mfs-surface mfs-font-mono mfs-rounded mfs-shadow-card mfs-blur mfs-p-4",onClick:f},[t.welcomeMessage?(e.openBlock(),e.createElementBlock("div",eh,e.toDisplayString(t.welcomeMessage),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"logRef",ref:m,class:"mfs-terminal__logs mfs-overflow-y-auto mfs-flex mfs-flex-col mfs-gap-1-5"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(h,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"mfs-terminal__entry"},[e.createElementVNode("div",th,[e.createElementVNode("span",lh,e.toDisplayString(t.prompt),1),e.createElementVNode("span",nh,e.toDisplayString(h.command),1)]),h.response?(e.openBlock(),e.createElementBlock("div",oh,e.toDisplayString(h.response),1)):e.createCommentVNode("",!0)]))),128))],512),e.createElementVNode("form",{class:"mfs-flex mfs-items-center mfs-gap-2 mfs-mt-2",onSubmit:e.withModifiers(u,["prevent"])},[e.createElementVNode("span",ah,e.toDisplayString(t.prompt),1),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:o,"onUpdate:modelValue":y[0]||(y[0]=h=>c.value=h),type:"text",class:"mfs-terminal__input mfs-flex-1 mfs-bg-transparent mfs-border-none mfs-outline-none",autocomplete:"off",spellcheck:"false","aria-label":"Terminal command input",onKeydown:[e.withKeys(e.withModifiers(p,["prevent"]),["up"]),e.withKeys(e.withModifiers(g,["prevent"]),["down"])]},null,40,sh),[[e.vModelText,c.value]])],32)]))}}),[["__scopeId","data-v-7db4de65"]]),rh=["aria-busy"],ih={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},dh=["viewBox","aria-label"],ch=["x2","y1","y2"],mh=["x","y"],fh=["x","y","width","height","fill","onMouseenter"],uh=["x","y","width","height","fill"],ph=["stroke","points"],kh=["cx","cy","fill","onMouseenter"],hh=["cx","cy"],gh=["transform"],yh=["d","fill","onMouseenter"],bh=["d","fill"],Bh={key:0,class:"mfs-chart__legend mfs-flex mfs-flex-wrap mfs-gap-3 mfs-justify-center"},_e=480,Ne=24,it=24,Ee=20,Se=30,Fl=F(e.defineComponent({__name:"Chart",props:{type:{default:"bar"},data:{default:null},height:{default:240},loading:{type:Boolean,default:!1},emptyText:{default:"No chart data"}},setup(t){const a=t,l=e.computed(()=>{var D;return((D=a.data)==null?void 0:D.labels)??[]}),n=e.computed(()=>{var D;return((D=a.data)==null?void 0:D.datasets)??[]}),i=e.computed(()=>n.value.length===0?!0:n.value.every(D=>!D.data||D.data.length===0)),r=e.computed(()=>a.height),s=Math.random().toString(36).slice(2,8),d=`mfs-chart-clay-${s}`,c=`mfs-chart-clay-pt-${s}`,o=`mfs-chart-clay-gloss-${s}`,m={"--mfs-clay-filter":`url(#${d})`,"--mfs-clay-point-filter":`url(#${c})`},f=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)","color-mix(in srgb, var(--primary) 65%, transparent)"],b=e.ref(null),u=e.computed(()=>{const D=n.value.flatMap(S=>S.data);return Math.max(1,...D)}),p=D=>{const S=Math.max(1,l.value.length),E=_e-Ne-it;return S===1?Ne+E/2:Ne+E*(D+.5)/S},g=D=>{const S=r.value-Ee-Se;return Ee+S-D/u.value*S},k=e.computed(()=>{const D=Math.max(1,l.value.length),S=Math.max(1,n.value.length),E=(_e-Ne-it)/D;return Math.max(6,Math.min(34,E*.68/S))}),y=(D,S)=>{const E=Math.max(1,n.value.length),w=E*k.value+(E-1)*4;return p(D)-w/2+S*(k.value+4)},h=D=>D.map((S,E)=>`${p(E)},${g(S)}`).join(" "),B=e.computed(()=>{const D=n.value[0];if(!D)return[];const S=D.data.reduce((V,C)=>V+Math.max(0,C),0)||1,E=Math.min(_e,r.value)*.4,w=a.type==="doughnut"?E*.55:0;let N=-Math.PI/2;return D.data.map((V,C)=>{const P=Math.max(0,V)/S*Math.PI*2,T=N+P,I=P>Math.PI?1:0,j=Math.cos(N)*E,A=Math.sin(N)*E,K=Math.cos(T)*E,W=Math.sin(T)*E;let v="";if(w>0){const te=Math.cos(T)*w,oe=Math.sin(T)*w,z=Math.cos(N)*w,O=Math.sin(N)*w;v=`M ${j} ${A} A ${E} ${E} 0 ${I} 1 ${K} ${W} L ${te} ${oe} A ${w} ${w} 0 ${I} 0 ${z} ${O} Z`}else v=`M 0 0 L ${j} ${A} A ${E} ${E} 0 ${I} 1 ${K} ${W} Z`;return N=T,{d:v,value:V,label:l.value[C]??`Item ${C+1}`,color:f[C%f.length]}})}),$=e.computed(()=>a.type==="pie"||a.type==="doughnut"?l.value.map((D,S)=>({label:D,color:f[S%f.length]})):n.value.map((D,S)=>({label:D.label??`Series ${S+1}`,color:D.color??f[S%f.length]}))),_=(D,S)=>{const E=D.currentTarget.closest(".mfs-chart__canvas");if(!E)return;const w=E.getBoundingClientRect();b.value={x:D.clientX-w.left+10,y:D.clientY-w.top-28,text:S}};return(D,S)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-chart mfs-surface mfs-rounded mfs-shadow-card mfs-blur mfs-flex mfs-flex-col mfs-gap-3 mfs-p-4",style:m,"aria-busy":t.loading||void 0},[e.createElementVNode("div",{class:"mfs-chart__canvas mfs-relative mfs-w-full",style:e.normalizeStyle(t.loading&&i.value?{minHeight:`${t.height}px`}:void 0)},[t.loading?(e.openBlock(),e.createElementBlock("div",ih,[e.renderSlot(D.$slots,"loading",{},()=>[S[3]||(S[3]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&i.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"mfs-empty-state",style:e.normalizeStyle({minHeight:`${t.height}px`})},[e.renderSlot(D.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)],4)):(e.openBlock(),e.createElementBlock("svg",{key:2,class:"mfs-chart__svg",viewBox:`0 0 ${_e} ${r.value}`,role:"img","aria-label":`${t.type} chart`},[e.createElementVNode("defs",null,[e.createElementVNode("filter",{id:d,x:"-25%",y:"-25%",width:"150%",height:"150%"},[...S[4]||(S[4]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="3.5" result="dropBlur" data-v-878d5047></feGaussianBlur><feOffset dx="2" dy="5" in="dropBlur" result="dropOffset" data-v-878d5047></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.24" result="dropColor" data-v-878d5047></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-878d5047></feComposite><feOffset dx="2" dy="2.5" in="SourceAlpha" result="hlOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="2" in="hlOffset" result="hlBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-878d5047></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.72" result="hlColor" data-v-878d5047></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-878d5047></feComposite><feOffset dx="-2" dy="-2.5" in="SourceAlpha" result="shOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="2.2" in="shOffset" result="shBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-878d5047></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.28" result="shColor" data-v-878d5047></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-878d5047></feComposite><feMerge data-v-878d5047><feMergeNode in="dropShadow" data-v-878d5047></feMergeNode><feMergeNode in="SourceGraphic" data-v-878d5047></feMergeNode><feMergeNode in="innerShade" data-v-878d5047></feMergeNode><feMergeNode in="innerHighlight" data-v-878d5047></feMergeNode></feMerge>',15)])]),e.createElementVNode("filter",{id:c,x:"-40%",y:"-40%",width:"180%",height:"180%"},[...S[5]||(S[5]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="2" result="dropBlur" data-v-878d5047></feGaussianBlur><feOffset dx="1.5" dy="2.5" in="dropBlur" result="dropOffset" data-v-878d5047></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.26" result="dropColor" data-v-878d5047></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-878d5047></feComposite><feOffset dx="1.2" dy="1.4" in="SourceAlpha" result="hlOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="1.1" in="hlOffset" result="hlBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-878d5047></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.8" result="hlColor" data-v-878d5047></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-878d5047></feComposite><feOffset dx="-1.2" dy="-1.4" in="SourceAlpha" result="shOffset" data-v-878d5047></feOffset><feGaussianBlur stdDeviation="1.2" in="shOffset" result="shBlur" data-v-878d5047></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-878d5047></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.3" result="shColor" data-v-878d5047></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-878d5047></feComposite><feMerge data-v-878d5047><feMergeNode in="dropShadow" data-v-878d5047></feMergeNode><feMergeNode in="SourceGraphic" data-v-878d5047></feMergeNode><feMergeNode in="innerShade" data-v-878d5047></feMergeNode><feMergeNode in="innerHighlight" data-v-878d5047></feMergeNode></feMerge>',15)])]),e.createElementVNode("linearGradient",{id:o,x1:"0%",y1:"0%",x2:"0%",y2:"100%"},[...S[6]||(S[6]=[e.createElementVNode("stop",{offset:"0%","stop-color":"#ffffff","stop-opacity":"0.45"},null,-1),e.createElementVNode("stop",{offset:"55%","stop-color":"#ffffff","stop-opacity":"0.08"},null,-1),e.createElementVNode("stop",{offset:"100%","stop-color":"#ffffff","stop-opacity":"0"},null,-1)])])]),t.type==="bar"||t.type==="line"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(4,E=>e.createElementVNode("line",{key:E,x1:Ne,x2:_e-it,y1:Ee+(r.value-Ee-Se)*(E-1)/3,y2:Ee+(r.value-Ee-Se)*(E-1)/3,class:"mfs-chart__grid"},null,8,ch)),64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(E,w)=>(e.openBlock(),e.createElementBlock("text",{key:w,x:p(w),y:r.value-8,"text-anchor":"middle",class:"mfs-chart__label"},e.toDisplayString(E),9,mh))),128))],64)):e.createCommentVNode("",!0),t.type==="bar"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(n.value,(E,w)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:w},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(N,V)=>(e.openBlock(),e.createElementBlock("g",{key:V},[e.createElementVNode("rect",{x:y(V,w),y:g(N),width:k.value,height:Math.max(2,r.value-Se-g(N)),fill:E.color||f[w%f.length],rx:"4",class:"mfs-chart__bar",onMouseenter:C=>_(C,`${l.value[V]??V}: ${N}`),onMouseleave:S[0]||(S[0]=C=>b.value=null)},null,40,fh),e.createElementVNode("rect",{x:y(V,w)+2,y:g(N)+2,width:Math.max(0,k.value-4),height:Math.max(0,Math.min(14,(r.value-Se-g(N))*.45)),fill:`url(#${o})`,rx:"4",class:"mfs-chart__clay-gloss"},null,8,uh)]))),128))],64))),128)):t.type==="line"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(n.value,(E,w)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:w},[e.createElementVNode("polyline",{fill:"none",stroke:E.color||f[w%f.length],"stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round",points:h(E.data),class:"mfs-chart__line"},null,8,ph),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(N,V)=>(e.openBlock(),e.createElementBlock("g",{key:V},[e.createElementVNode("circle",{cx:p(V),cy:g(N),r:"5",fill:E.color||f[w%f.length],class:"mfs-chart__point",onMouseenter:C=>_(C,`${l.value[V]??V}: ${N}`),onMouseleave:S[1]||(S[1]=C=>b.value=null)},null,40,kh),e.createElementVNode("circle",{cx:p(V)-1.5,cy:g(N)-1.5,r:"1.6",fill:"var(--bevel-light, currentColor)","fill-opacity":"0.7",class:"mfs-chart__clay-gloss"},null,8,hh)]))),128))],64))),128)):(e.openBlock(),e.createElementBlock("g",{key:3,transform:`translate(${_e/2}, ${r.value/2})`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,w)=>(e.openBlock(),e.createElementBlock("path",{key:w,d:E.d,fill:E.color,class:"mfs-chart__slice",onMouseenter:N=>_(N,`${E.label}: ${E.value}`),onMouseleave:S[2]||(S[2]=N=>b.value=null)},null,40,yh))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,w)=>(e.openBlock(),e.createElementBlock("path",{key:`gloss-${w}`,d:E.d,fill:`url(#${o})`,class:"mfs-chart__clay-gloss"},null,8,bh))),128))],8,gh))],8,dh)),b.value?(e.openBlock(),e.createElementBlock("div",{key:3,class:"mfs-chart__tooltip mfs-surface mfs-rounded-sm mfs-shadow-card mfs-blur mfs-whitespace-nowrap mfs-font-semibold",style:e.normalizeStyle({left:`${b.value.x}px`,top:`${b.value.y}px`})},e.toDisplayString(b.value.text),5)):e.createCommentVNode("",!0)],4),!i.value&&$.value.length>0?(e.openBlock(),e.createElementBlock("div",Bh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.value,(E,w)=>(e.openBlock(),e.createElementBlock("span",{key:w,class:"mfs-caption mfs-font-semibold mfs-inline-flex mfs-items-center mfs-gap-1-5"},[e.createElementVNode("span",{class:"mfs-chart__swatch mfs-rounded-full",style:e.normalizeStyle({backgroundColor:E.color})},null,4),e.createTextVNode(" "+e.toDisplayString(E.label),1)]))),128))])):e.createCommentVNode("",!0)],8,rh))}}),[["__scopeId","data-v-878d5047"]]),jl=F(e.defineComponent({__name:"AvatarGroup",props:{max:{},size:{default:"md"},items:{}},setup(t){const a=t,l=e.computed(()=>a.items?a.max!==void 0&&a.max>=0&&a.items.length>a.max?a.items.slice(0,a.max):a.items:[]),n=e.computed(()=>!a.items||a.max===void 0||a.max<0?0:Math.max(0,a.items.length-a.max));return(i,r)=>{var s;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-avatar-group",`mfs-avatar-group--${t.size}`,"mfs-inline-flex","mfs-items-center"]),role:"group"},[(s=t.items)!=null&&s.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(d,c)=>(e.openBlock(),e.createBlock(Ie,{key:c,src:d.src,label:d.label,size:t.size},null,8,["src","label","size"]))),128)),n.value>0?(e.openBlock(),e.createBlock(Ie,{key:0,size:t.size,label:`+${n.value} more`,class:"mfs-avatar-group__overflow"},{default:e.withCtx(()=>[e.createTextVNode(" +"+e.toDisplayString(n.value),1)]),_:1},8,["size","label"])):e.createCommentVNode("",!0)],64)):e.renderSlot(i.$slots,"default",{},void 0,!0,1)],2)}}}),[["__scopeId","data-v-865c01f7"]]),wh={class:"mfs-overlay-badge mfs-relative mfs-inline-flex"},Kl=F(e.defineComponent({__name:"OverlayBadge",props:{value:{},variant:{default:"primary"},size:{default:"sm"}},setup(t){const a=t,l=e.computed(()=>a.value!==void 0&&a.value!=="");return(n,i)=>(e.openBlock(),e.createElementBlock("span",wh,[e.renderSlot(n.$slots,"default",{},void 0,!0),l.value?(e.openBlock(),e.createBlock(ve,{key:0,variant:t.variant,size:t.size,class:"mfs-overlay-badge__badge mfs-absolute mfs-top-0 mfs-right-0 mfs-z-1 mfs-pointer-events-none mfs-shadow"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.value),1)]),_:1},8,["variant","size"])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cfa3d641"]]),_h=["src","alt"],Eh=["src","alt"],$h=["value"],Ol=F(e.defineComponent({__name:"ImageCompare",props:{leftSrc:{},rightSrc:{},leftAlt:{default:"Before image"},rightAlt:{default:"After image"},modelValue:{default:50}},emits:["update:modelValue"],setup(t,{emit:a}){const l=t,n=a,i=p=>Math.min(100,Math.max(0,p)),r=e.ref(null),s=e.ref(i(l.modelValue)),d=e.ref(!1);e.watch(()=>l.modelValue,p=>{s.value=i(p)});const c=p=>{const g=Math.round(i(p)*10)/10;s.value=g,n("update:modelValue",g)},o=p=>{const g=r.value;if(!g)return;const k=g.getBoundingClientRect();if(k.width<=0)return;const y=(p-k.left)/k.width*100;c(y)},m=p=>{var g,k;d.value=!0,(k=(g=p.currentTarget)==null?void 0:g.setPointerCapture)==null||k.call(g,p.pointerId),o(p.clientX)},f=p=>{d.value&&o(p.clientX)},b=p=>{var g,k;d.value&&(d.value=!1,(k=(g=p.currentTarget)==null?void 0:g.releasePointerCapture)==null||k.call(g,p.pointerId))},u=p=>{const g=p.target;c(Number(g.value))};return(p,g)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:r,class:"mfs-image-compare mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none mfs-surface mfs-shadow",onPointerdown:m,onPointermove:f,onPointerup:b,onPointercancel:b},[e.createElementVNode("img",{src:t.rightSrc,alt:t.rightAlt,class:"mfs-image-compare__img mfs-w-full mfs-h-full",draggable:"false"},null,8,_h),e.createElementVNode("img",{src:t.leftSrc,alt:t.leftAlt,class:"mfs-image-compare__img mfs-image-compare__img--left mfs-absolute mfs-inset-0 mfs-w-full mfs-h-full",style:e.normalizeStyle({clipPath:`inset(0 ${100-s.value}% 0 0)`}),draggable:"false"},null,12,Eh),e.createElementVNode("div",{class:"mfs-image-compare__divider mfs-absolute",style:e.normalizeStyle({left:`${s.value}%`}),"aria-hidden":"true"},[...g[0]||(g[0]=[e.createElementVNode("div",{class:"mfs-image-compare__line"},null,-1),e.createElementVNode("div",{class:"mfs-image-compare__handle mfs-surface mfs-pill mfs-shadow mfs-flex mfs-items-center mfs-justify-center"},[e.createElementVNode("span",{class:"mfs-image-compare__arrows"},"‹ ›")],-1)])],4),e.createElementVNode("input",{type:"range",min:"0",max:"100",step:"1",value:s.value,class:"mfs-image-compare__range mfs-sr-only","aria-label":"Image comparison slider",onInput:u},null,40,$h)],544))}}),[["__scopeId","data-v-6ec473fb"]]),Hl=e.defineComponent({__name:"Portal",props:{appendTo:{default:"body"},disabled:{type:Boolean,default:!1}},setup(t){return(a,l)=>(e.openBlock(),e.createBlock(e.Teleport,{to:t.appendTo,disabled:t.disabled},[e.renderSlot(a.$slots,"default")],8,["to","disabled"]))}}),Vh=["for"],xh=["id","placeholder","disabled","aria-invalid"],Ch={key:1,class:"mfs-chips-msg mfs-text-danger"},Nh={key:2,class:"mfs-chips-msg mfs-caption"},Ye=F(e.defineComponent({__name:"Chips",props:{modelValue:{default:()=>[]},placeholder:{default:""},separator:{default:","},max:{},allowDuplicate:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},invalid:{type:Boolean,default:!1},label:{},hint:{},error:{}},emits:["update:modelValue","add","remove"],setup(t,{emit:a}){const l=t,n=a,i=e.useId(),r=e.ref(null),s=e.ref(""),d=e.computed(()=>l.max!==void 0&&l.modelValue.length>=l.max),c=()=>{var p;l.disabled||(p=r.value)==null||p.focus()},o=p=>{if(l.disabled)return;const g=l.separator?p.split(l.separator):[p],k=[...l.modelValue],y=[];for(const h of g){const B=h.trim();if(B){if(l.max!==void 0&&k.length>=l.max)break;!l.allowDuplicate&&k.includes(B)||(k.push(B),y.push(B))}}if(y.length>0){n("update:modelValue",k);for(const h of y)n("add",h)}s.value=""},m=p=>{if(l.disabled)return;const g=l.modelValue[p];if(g===void 0)return;const k=l.modelValue.filter((y,h)=>h!==p);n("update:modelValue",k),n("remove",g)},f=p=>{if(!l.disabled){if(p.key==="Enter"||l.separator&&p.key===l.separator){p.preventDefault(),s.value.trim()&&o(s.value);return}p.key==="Backspace"&&s.value===""&&l.modelValue.length>0&&(p.preventDefault(),m(l.modelValue.length-1))}},b=()=>{l.separator&&s.value.includes(l.separator)&&o(s.value)},u=()=>{s.value.trim()&&o(s.value)};return(p,g)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-chips-wrapper",{"mfs-chips-wrapper--disabled mfs-disabled":t.disabled,"mfs-chips-wrapper--invalid":t.invalid||!!t.error}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:e.unref(i),class:"mfs-chips-label mfs-text"},e.toDisplayString(t.label),9,Vh)):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["mfs-chips-box mfs-inset mfs-rounded",{"mfs-chips-box--disabled mfs-disabled":t.disabled}]),onClick:c},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(k,y)=>(e.openBlock(),e.createBlock(Ve,{key:`${k}-${y}`,label:k,removable:!t.disabled,onRemove:h=>m(y)},null,8,["label","removable","onRemove"]))),128)),e.withDirectives(e.createElementVNode("input",{id:e.unref(i),ref_key:"inputRef",ref:r,"onUpdate:modelValue":g[0]||(g[0]=k=>s.value=k),type:"text",class:"mfs-chips-input mfs-text",placeholder:d.value?"":t.placeholder,disabled:t.disabled||d.value,"aria-invalid":t.invalid||!!t.error||void 0,onKeydown:f,onInput:b,onBlur:u},null,40,xh),[[e.vModelText,s.value]])],2),t.error?(e.openBlock(),e.createElementBlock("p",Ch,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Nh,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-e2023636"]]),Sh=["aria-invalid"],Mh=Symbol("CheckboxGroup"),Ul=F(e.defineComponent({__name:"CheckboxGroup",props:{modelValue:{default:()=>[]},name:{},direction:{default:"row"},disabled:{type:Boolean,default:!1},invalid:{type:Boolean,default:!1},options:{default:()=>[]}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=s=>{if(l.disabled)return;const c=l.modelValue.includes(s)?l.modelValue.filter(o=>o!==s):[...l.modelValue,s];n("update:modelValue",c),n("change",c)},r=s=>{l.disabled||!Array.isArray(s)||(n("update:modelValue",s),n("change",s))};return e.provide(Mh,{modelValue:e.computed(()=>l.modelValue),name:e.computed(()=>l.name),disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),toggleValue:i}),(s,d)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-checkbox-group",[t.direction==="column"?"mfs-flex mfs-flex-col mfs-gap-2":"mfs-row",{"mfs-checkbox-group--disabled mfs-disabled":t.disabled,"mfs-checkbox-group--invalid":t.invalid}]]),role:"group","aria-invalid":t.invalid||void 0},[e.renderSlot(s.$slots,t.name,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,toggleValue:i},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(c,o)=>(e.openBlock(),e.createBlock(fe,{key:o,"model-value":t.modelValue,value:c.value,label:c.label,disabled:t.disabled||c.disabled,"onUpdate:modelValue":r},null,8,["model-value","value","label","disabled"]))),128))],!0)],10,Sh))}}),[["__scopeId","data-v-bde4c6e4"]]),Dh=["aria-invalid"],Th=Symbol("RadioButtonGroup"),Wl=F(e.defineComponent({__name:"RadioButtonGroup",props:{modelValue:{},name:{},direction:{default:"row"},disabled:{type:Boolean,default:!1},invalid:{type:Boolean,default:!1},options:{default:()=>[]}},emits:["update:modelValue","change"],setup(t,{emit:a}){const l=t,n=a,i=`mfs-radio-group-${e.useId()}`,r=e.computed(()=>l.name||i),s=d=>{l.disabled||(n("update:modelValue",d),n("change",d))};return e.provide(Th,{modelValue:e.computed(()=>l.modelValue),name:r,disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),selectValue:s}),(d,c)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-radio-group",[t.direction==="column"?"mfs-flex mfs-flex-col mfs-gap-2":"mfs-row",{"mfs-radio-group--disabled mfs-disabled":t.disabled,"mfs-radio-group--invalid":t.invalid}]]),role:"radiogroup","aria-invalid":t.invalid||void 0},[e.renderSlot(d.$slots,r.value,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,selectValue:s},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(o,m)=>(e.openBlock(),e.createBlock(et,{key:m,"model-value":t.modelValue,value:o.value,name:r.value,label:o.label,disabled:t.disabled||o.disabled,"onUpdate:modelValue":s},null,8,["model-value","value","name","label","disabled"]))),128))],!0)],10,Dh))}}),[["__scopeId","data-v-2e9ea155"]]),ke=e.ref([]);let Lh=1;function zh(t,a={}){const l=`mfs-dialog-${Lh++}`;return ke.value=[...ke.value,{id:l,component:e.markRaw(t),options:a}],l}function Ih(t,a){var i,r;const l=ke.value.findIndex(s=>s.id===t);if(l===-1)return;const n=ke.value[l];ke.value=ke.value.filter(s=>s.id!==t),(r=(i=n.options).onClose)==null||r.call(i,a)}function Gl(){return{dialogs:e.readonly(ke),open:zh,close:Ih}}const ql=e.defineComponent({__name:"DynamicDialog",setup(t){const{dialogs:a,close:l}=Gl(),n=e.defineComponent({name:"MfsDynamicDialogContent",props:{component:{type:Object,required:!0},componentProps:{type:Object,default:()=>({})},onClose:{type:Function,required:!0}},setup(i){const r={close:s=>i.onClose(s)};return e.provide("dialogRef",r),()=>e.h(i.component,i.componentProps)}});return(i,r)=>(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(a),s=>(e.openBlock(),e.createBlock(ye,{key:s.id,"model-value":!0,title:s.options.header,"onUpdate:modelValue":d=>!d&&e.unref(l)(s.id)},{default:e.withCtx(()=>[e.createElementVNode("div",{style:e.normalizeStyle(s.options.width?{width:s.options.width,maxWidth:"100%"}:void 0)},[e.createVNode(e.unref(n),{component:s.component,"component-props":s.options.props,"on-close":d=>e.unref(l)(s.id,d)},null,8,["component","component-props","on-close"])],4)]),_:2},1032,["title","onUpdate:modelValue"]))),128))}}),Rh={class:"cmd-header mfs-flex mfs-items-center mfs-gap-2 mfs-border-b"},Ph=["placeholder"],Ah={key:0,class:"mfs-spinner mfs-spinner--sm",role:"status","aria-label":"Loading"},Fh={key:1,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},jh={key:0,class:"mfs-empty-state"},Kh={key:1,class:"mfs-empty-state"},Oh={key:0,class:"cmd-group-label mfs-text-muted"},Hh=["aria-selected","aria-disabled","disabled","onMouseenter","onClick"],Uh={class:"cmd-item-main mfs-flex mfs-flex-col"},Wh={class:"cmd-item-label"},Gh={key:0,class:"cmd-item-desc mfs-text-muted"},qh={key:0,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},Yl=F(e.defineComponent({__name:"CommandPalette",props:{modelValue:{type:Boolean,default:!1},items:{default:()=>[]},remote:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},placeholder:{default:"Type a command or search..."},emptyText:{default:"No results found."},shortcut:{type:Boolean,default:!0}},emits:["update:modelValue","search","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(""),r=e.ref(-1),s=e.ref(null),d=e.ref(null),c=new Map,o=(_,D)=>{D?c.set(_,D):c.delete(_)},m=e.computed(()=>{if(l.remote)return l.items;const _=i.value.trim().toLowerCase();return _?l.items.filter(D=>D.label.toLowerCase().includes(_)||D.description&&D.description.toLowerCase().includes(_)||D.group&&D.group.toLowerCase().includes(_)):l.items}),f=e.computed(()=>{const _=new Map;let D=0;for(const S of m.value){const E=S.group??"";_.has(E)||_.set(E,[]),_.get(E).push({item:S,flatIndex:D++})}return Array.from(_.entries()).map(([S,E])=>({group:S,entries:E}))}),b=e.computed(()=>f.value.flatMap(_=>_.entries.map(D=>D.item))),u=_=>_.findIndex(D=>!D.disabled);e.watch(b,_=>{c.clear(),r.value=u(_)},{immediate:!0});const p=()=>{n("update:modelValue",!1)},g=()=>{n("search",i.value)},k=(_,D)=>{D.disabled||(r.value=_)},y=_=>{_.disabled||(n("select",_),p())},h=_=>{var w;const D=b.value,S=D.length;if(S===0)return;let E=r.value;for(let N=0;N<S;N++)if(E=(E+_+S)%S,!((w=D[E])!=null&&w.disabled)){r.value=E,e.nextTick(()=>{var V;(V=c.get(E))==null||V.scrollIntoView({block:"nearest"})});return}},B=_=>{if(_.key==="ArrowDown")_.preventDefault(),h(1);else if(_.key==="ArrowUp")_.preventDefault(),h(-1);else if(_.key==="Enter"){const D=b.value[r.value];D&&!D.disabled&&(_.preventDefault(),y(D))}else _.key==="Escape"&&(_.preventDefault(),p())},$=_=>{l.shortcut&&(_.metaKey||_.ctrlKey)&&_.key.toLowerCase()==="k"&&(_.preventDefault(),n("update:modelValue",!l.modelValue))};return e.watch(()=>l.modelValue,async _=>{var D;_&&(i.value="",r.value=u(b.value),await e.nextTick(),(D=s.value)==null||D.focus())}),e.onMounted(()=>{typeof window<"u"&&window.addEventListener("keydown",$)}),e.onBeforeUnmount(()=>{typeof window<"u"&&window.removeEventListener("keydown",$)}),(_,D)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-cmd-fade"},{default:e.withCtx(()=>[t.modelValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:"cmd-backdrop mfs-backdrop mfs-flex mfs-justify-center mfs-p-4",onClick:p},[e.createElementVNode("div",{class:"cmd-dialog mfs-overlay mfs-surface mfs-rounded-lg mfs-shadow-card mfs-w-full mfs-flex mfs-flex-col mfs-overflow-hidden",role:"dialog","aria-modal":"true","aria-label":"Command palette",onClick:D[1]||(D[1]=e.withModifiers(()=>{},["stop"])),onKeydown:B},[e.createElementVNode("div",Rh,[D[2]||(D[2]=e.createElementVNode("svg",{class:"cmd-search-icon mfs-text-muted",width:"18",height:"18",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[e.createElementVNode("circle",{cx:"11",cy:"11",r:"8"}),e.createElementVNode("path",{d:"m21 21-4.3-4.3"})],-1)),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:s,"onUpdate:modelValue":D[0]||(D[0]=S=>i.value=S),type:"text",class:"cmd-input mfs-text mfs-bg-transparent mfs-border-none mfs-outline-none mfs-w-full",placeholder:t.placeholder,autocomplete:"off",spellcheck:"false",onInput:g},null,40,Ph),[[e.vModelText,i.value]]),t.loading?(e.openBlock(),e.createElementBlock("span",Ah)):(e.openBlock(),e.createElementBlock("kbd",Fh,"ESC"))]),e.createElementVNode("div",{ref_key:"listRef",ref:d,class:"cmd-list",role:"listbox"},[t.loading&&b.value.length===0?(e.openBlock(),e.createElementBlock("div",jh,[...D[3]||(D[3]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-label":"Loading"},null,-1)])])):b.value.length===0?(e.openBlock(),e.createElementBlock("div",Kh,[e.renderSlot(_.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(f.value,S=>(e.openBlock(),e.createElementBlock("div",{key:S.group,class:"cmd-group",role:"group"},[S.group?(e.openBlock(),e.createElementBlock("div",Oh,e.toDisplayString(S.group),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(S.entries,E=>(e.openBlock(),e.createElementBlock("button",{key:E.item.id,ref_for:!0,ref:w=>o(E.flatIndex,w),type:"button",role:"option","aria-selected":r.value===E.flatIndex,"aria-disabled":E.item.disabled||void 0,disabled:E.item.disabled,class:e.normalizeClass(["cmd-item mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-rounded-sm mfs-w-full mfs-text mfs-transition",{"cmd-item--active":r.value===E.flatIndex,"mfs-disabled":E.item.disabled,"mfs-cursor-pointer":!E.item.disabled}]),onMouseenter:w=>k(E.flatIndex,E.item),onClick:w=>y(E.item)},[e.createElementVNode("div",Uh,[e.createElementVNode("span",Wh,e.toDisplayString(E.item.label),1),E.item.description?(e.openBlock(),e.createElementBlock("span",Gh,e.toDisplayString(E.item.description),1)):e.createCommentVNode("",!0)]),E.item.shortcut?(e.openBlock(),e.createElementBlock("kbd",qh,e.toDisplayString(E.item.shortcut),1)):e.createCommentVNode("",!0)],42,Hh))),128))]))),128))],512)],32)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-652034ed"]]),Yh={class:"infinite-scroll mfs-flex mfs-flex-col"},Xh={key:0,class:"mfs-empty-state"},Zh={key:1,class:"infinite-scroll__status mfs-flex mfs-items-center mfs-justify-center mfs-p-4",role:"status","aria-live":"polite"},Jh={key:2,class:"mfs-soft-danger mfs-rounded mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-p-3",role:"alert"},Qh={class:"mfs-text-sm mfs-font-medium"},vh={key:3,class:"mfs-text-sm mfs-text-muted mfs-text-center mfs-p-4"},Xl=e.defineComponent({__name:"InfiniteScroll",props:{loading:{type:Boolean,default:!1},hasMore:{type:Boolean,default:!0},error:{default:void 0},isEmpty:{type:Boolean,default:!1},emptyText:{default:"No items yet."},finishedText:{default:"All items loaded"},rootMargin:{default:"120px"}},emits:["load"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null);let r=null;const s=()=>{n("load")},d=()=>l.hasMore&&!l.loading&&!l.error,c=()=>{r==null||r.disconnect(),r=null,!(typeof IntersectionObserver>"u"||!i.value)&&(r=new IntersectionObserver(o=>{o.some(m=>m.isIntersecting)&&d()&&s()},{rootMargin:l.rootMargin}),r.observe(i.value))};return e.watch(()=>l.rootMargin,c),e.onMounted(()=>{c()}),e.onBeforeUnmount(()=>{r==null||r.disconnect(),r=null}),(o,m)=>(e.openBlock(),e.createElementBlock("div",Yh,[e.renderSlot(o.$slots,"default"),t.isEmpty&&!t.loading&&!t.error?(e.openBlock(),e.createElementBlock("div",Xh,[e.renderSlot(o.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Zh,[e.renderSlot(o.$slots,"loading",{},()=>[m[0]||(m[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))])])):t.error?(e.openBlock(),e.createElementBlock("div",Jh,[e.renderSlot(o.$slots,"error",{error:t.error,retry:s},()=>[e.createElementVNode("span",Qh,e.toDisplayString(t.error),1),e.createVNode($e,{size:"sm",variant:"danger",onClick:s},{default:e.withCtx(()=>[...m[1]||(m[1]=[e.createTextVNode("Retry",-1)])]),_:1})])])):!t.hasMore&&!t.isEmpty?(e.openBlock(),e.createElementBlock("div",vh,[e.renderSlot(o.$slots,"finished",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.finishedText),1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"sentinelRef",ref:i,class:"mfs-w-full mfs-h-px mfs-pointer-events-none","aria-hidden":"true"},null,512)]))}}),eg=["value","placeholder","rows","disabled","aria-expanded"],tg={key:0,class:"mfs-mentions__loading mfs-flex mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-3"},lg={key:1,class:"mfs-mentions__list"},ng=["aria-selected","onMousedown","onMouseenter"],og={class:"mfs-mentions__label mfs-text mfs-text-sm mfs-font-medium"},ag={key:0,class:"mfs-mentions__desc mfs-text-muted mfs-text-xs"},sg={key:2,class:"mfs-empty-state",role:"status"},Zl=F(e.defineComponent({__name:"Mentions",props:{modelValue:{default:""},options:{default:()=>[]},triggers:{default:()=>["@"]},remote:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},emptyText:{default:"No matches found"},placeholder:{default:""},rows:{default:3},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","search","select"],setup(t,{emit:a}){const l=t,n=a,i=e.ref(null),r=e.ref(null),s=e.ref(null),d=e.ref(null),c=e.ref(!1),o=e.ref(0),m=e.ref(""),f=e.ref(-1),b=e.ref(""),{overlayStyle:u,containsTarget:p}=de(r,s,c,{matchWidth:!0}),g=e.computed(()=>{if(l.remote)return l.options;const S=b.value.trim().toLowerCase();return S?l.options.filter(E=>{var w;return E.label.toLowerCase().includes(S)||E.value.toLowerCase().includes(S)||(((w=E.description)==null?void 0:w.toLowerCase().includes(S))??!1)}):l.options});e.watch(g,S=>{S.length===0?o.value=-1:(o.value<0||o.value>=S.length)&&(o.value=0)});const k=(S,E)=>{const w=S.slice(0,E),N=[...l.triggers].filter(Boolean).sort((V,C)=>C.length-V.length);if(!N.length)return null;for(let V=w.length-1;V>=0;V--){const C=w[V];if(/\s/.test(C))return null;for(const P of N){const T=V-P.length+1;if(!(T<0)&&w.slice(T,V+1)===P){const I=T===0?"":w[T-1];if(T===0||/\s/.test(I))return{trigger:P,start:T,query:w.slice(V+1)}}}}return null},y=()=>{const S=d.value;if(!S||l.disabled){c.value=!1;return}const E=S.selectionStart??(l.modelValue??"").length,w=k(S.value,E);w?(m.value=w.trigger,f.value=w.start,b.value=w.query,c.value=!0,o.value=g.value.length?0:-1,n("search",{trigger:w.trigger,query:w.query})):(c.value=!1,m.value="",f.value=-1,b.value="")},h=S=>{const E=S.target;n("update:modelValue",E.value),y()},B=S=>{["ArrowUp","ArrowDown","Enter","Escape"].includes(S.key)||y()},$=S=>{const E=d.value,w=E?E.value:l.modelValue??"",N=(E==null?void 0:E.selectionStart)??w.length,V=f.value>=0?f.value:N,C=`${m.value}${S.value} `,P=w.slice(0,V)+C+w.slice(N),T=V+C.length;n("update:modelValue",P),n("select",S),c.value=!1,m.value="",f.value=-1,b.value="",e.nextTick(()=>{d.value&&(d.value.focus(),d.value.setSelectionRange(T,T))})},_=S=>{if(!c.value)return;const E=g.value.length;if(S.key==="Escape")S.preventDefault(),c.value=!1;else if(S.key==="ArrowDown")S.preventDefault(),E>0&&(o.value=(o.value+1)%E);else if(S.key==="ArrowUp")S.preventDefault(),E>0&&(o.value=(o.value-1+E)%E);else if(S.key==="Enter"&&E>0&&o.value>=0){S.preventDefault();const w=g.value[o.value];w&&$(w)}},D=S=>{p(S.target)||(c.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",D)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",D)),(S,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:i,class:e.normalizeClass(["mfs-mentions mfs-flex mfs-flex-col mfs-w-full",{"mfs-disabled":t.disabled}])},[e.createElementVNode("div",{ref_key:"triggerRef",ref:r,class:"mfs-mentions__box mfs-surface mfs-rounded mfs-shadow-inset mfs-w-full"},[e.createElementVNode("textarea",{ref_key:"textareaRef",ref:d,value:t.modelValue,placeholder:t.placeholder,rows:t.rows,disabled:t.disabled,role:"combobox","aria-autocomplete":"list","aria-expanded":c.value,class:"mfs-mentions__textarea mfs-w-full mfs-border-none mfs-text",onInput:h,onClick:y,onKeyup:B,onKeydown:_},null,40,eg)],512),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-mentions-pop"},{default:e.withCtx(()=>[c.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:s,style:e.normalizeStyle(e.unref(u)),role:"listbox",class:"mfs-mentions__dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading?(e.openBlock(),e.createElementBlock("div",tg,[...E[0]||(E[0]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1),e.createElementVNode("span",{class:"mfs-text-muted mfs-text-sm"},"Loading...",-1)])])):g.value.length?(e.openBlock(),e.createElementBlock("ul",lg,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(w,N)=>(e.openBlock(),e.createElementBlock("li",{key:`${w.value}-${N}`,role:"option","aria-selected":N===o.value,class:e.normalizeClass(["mfs-mentions__option mfs-flex mfs-flex-col mfs-rounded-sm mfs-cursor-pointer",{"mfs-mentions__option--active":N===o.value}]),onMousedown:e.withModifiers(V=>$(w),["prevent"]),onMouseenter:V=>o.value=N},[e.createElementVNode("span",og,e.toDisplayString(w.label),1),w.description?(e.openBlock(),e.createElementBlock("span",ag,e.toDisplayString(w.description),1)):e.createCommentVNode("",!0)],42,ng))),128))])):(e.openBlock(),e.createElementBlock("div",sg,[e.renderSlot(S.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)]))],4)):e.createCommentVNode("",!0)]),_:3})]))],2))}}),[["__scopeId","data-v-495bfd88"]]),rg={class:"mfs-signature__stage mfs-inset mfs-rounded-sm mfs-relative"},ig=["width","height"],dg={key:0,class:"mfs-signature__hint mfs-text-muted mfs-text-sm mfs-select-none"},cg={class:"mfs-signature__actions mfs-flex mfs-items-center mfs-justify-end mfs-gap-2"},Jl=F(e.defineComponent({__name:"SignaturePad",props:{modelValue:{default:null},width:{default:480},height:{default:180},penColor:{default:"currentColor"},lineWidth:{default:2.5},outputType:{default:"image/png"},fileName:{default:"signature.png"},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.ref(null),s=e.ref(!1),d=e.ref(!0),c=()=>{var h;return((h=r.value)==null?void 0:h.getContext("2d"))??null},o=h=>{if(n.penColor&&n.penColor!=="currentColor")return n.penColor;if(typeof window<"u"){const B=window.getComputedStyle(h).color;if(B)return B}return"#0f172a"},m=h=>{const B=r.value,$=B.getBoundingClientRect(),_=$.width>0?B.width/$.width:1,D=$.height>0?B.height/$.height:1;return{x:(h.clientX-$.left)*_,y:(h.clientY-$.top)*D}},f=h=>{var D;if(n.disabled)return;const B=r.value,$=c();if(!B||!$)return;(D=B.setPointerCapture)==null||D.call(B,h.pointerId);const _=m(h);$.strokeStyle=o(B),$.lineWidth=n.lineWidth,$.lineCap="round",$.lineJoin="round",$.beginPath(),$.moveTo(_.x,_.y),$.lineTo(_.x+.01,_.y+.01),$.stroke(),s.value=!0,d.value=!1},b=h=>{if(!s.value||n.disabled)return;const B=c();if(!B)return;const $=m(h);B.lineTo($.x,$.y),B.stroke()},u=h=>{var $;if(!s.value)return;const B=r.value;($=B==null?void 0:B.hasPointerCapture)!=null&&$.call(B,h.pointerId)&&B.releasePointerCapture(h.pointerId),s.value=!1},p=()=>d.value,g=()=>{const h=r.value,B=c();h&&B&&B.clearRect(0,0,h.width,h.height),s.value=!1,d.value=!0,i("update:modelValue",null),i("change",{blob:null,dataUrl:null,file:null})},k=()=>{const h=r.value;if(!h||d.value){const $={blob:null,dataUrl:null,file:null};return i("update:modelValue",null),i("change",$),Promise.resolve($)}const B=h.toDataURL(n.outputType);return new Promise($=>{h.toBlob(_=>{const D=_?new File([_],n.fileName,{type:n.outputType}):null,S={blob:_,dataUrl:B,file:D};i("update:modelValue",B),i("change",S),$(S)},n.outputType)})},y=h=>{const B=r.value,$=c();if(!B||!$)return;if($.clearRect(0,0,B.width,B.height),!h){d.value=!0;return}const _=new Image;_.onload=()=>{$.clearRect(0,0,B.width,B.height),$.drawImage(_,0,0,B.width,B.height),d.value=!1},_.src=h};return e.watch(()=>n.modelValue,h=>{if(h)r.value&&r.value.toDataURL(n.outputType)!==h&&y(h);else{const B=r.value,$=c();B&&$&&$.clearRect(0,0,B.width,B.height),d.value=!0}}),e.onMounted(()=>{n.modelValue&&y(n.modelValue)}),a({clear:g,isEmpty:p,exportSignature:k}),(h,B)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-signature mfs-surface mfs-rounded mfs-shadow-card mfs-flex mfs-flex-col mfs-gap-3",{"mfs-disabled":t.disabled}])},[e.createElementVNode("div",rg,[e.createElementVNode("canvas",{ref_key:"canvasRef",ref:r,width:t.width,height:t.height,class:"mfs-signature__canvas mfs-w-full",onPointerdown:f,onPointermove:b,onPointerup:u,onPointercancel:u,onPointerleave:u},null,40,ig),d.value?(e.openBlock(),e.createElementBlock("span",dg," Sign here ")):e.createCommentVNode("",!0)]),e.createElementVNode("div",cg,[e.createVNode($e,{variant:"surface",size:"sm",disabled:t.disabled||d.value,onClick:g},{default:e.withCtx(()=>[...B[0]||(B[0]=[e.createTextVNode(" Clear ",-1)])]),_:1},8,["disabled"]),e.createVNode($e,{variant:"primary",size:"sm",disabled:t.disabled||d.value,onClick:k},{default:e.withCtx(()=>[...B[1]||(B[1]=[e.createTextVNode(" Save ",-1)])]),_:1},8,["disabled"])])],2))}}),[["__scopeId","data-v-7b44dca2"]]),Ql=e.defineComponent({__name:"Form",props:{initialValues:{},errors:{},resolver:{},submitting:{type:Boolean,default:!1},validateOnSubmit:{type:Boolean,default:!0}},emits:["submit","reset"],setup(t,{expose:a,emit:l}){const n=t,i=l,r=e.reactive({...n.initialValues??{}}),s=e.reactive({}),d=g=>{for(const k of Object.keys(s))delete s[k];for(const[k,y]of Object.entries(g))(Array.isArray(y)?y.length>0:y)&&(s[k]=y)};e.watch(()=>n.errors,g=>{d(g??{})},{immediate:!0,deep:!0});const c=(g,k)=>{r[g]=k,g in s&&delete s[g]},o=(g,k)=>{(Array.isArray(k)?k.length>0:k)?s[g]=k:delete s[g]},m=g=>{if(g!==void 0){delete s[g];return}for(const k of Object.keys(s))delete s[k]},f=()=>{if(m(),!n.resolver)return!0;const g=n.resolver({...r});for(const[k,y]of Object.entries(g))y&&(s[k]=y);return Object.keys(s).length===0},b=()=>{const g=n.initialValues??{};for(const k of Object.keys(r))k in g||delete r[k];for(const[k,y]of Object.entries(g))r[k]=y;m(),i("reset")},u=()=>{const g={};for(const[k,y]of Object.entries(s)){const h=Array.isArray(y)?y[0]:y;h&&(g[k]=h)}return g},p=()=>{const g=n.validateOnSubmit?f():!0;i("submit",{values:{...r},valid:g,errors:u()})};return e.provide("mfsFormContext",{values:r,errors:s,submitting:e.computed(()=>n.submitting),setFieldValue:c,setFieldError:o,clearErrors:m,reset:b}),a({values:r,errors:s,validate:f,reset:b,setErrors:d}),(g,k)=>(e.openBlock(),e.createElementBlock("form",{class:"mfs-form mfs-flex mfs-flex-col mfs-gap-4",novalidate:"",onSubmit:e.withModifiers(p,["prevent"])},[e.renderSlot(g.$slots,"default",{values:r,errors:s,submitting:t.submitting,reset:b,validate:f})],32))}}),mg={class:"mfs-form-field mfs-flex mfs-flex-col mfs-gap-1-5"},fg=["for"],ug={key:0,class:"mfs-text-danger"},pg={key:1,class:"mfs-form-field__msg mfs-text-danger mfs-text-xs mfs-font-medium mfs-m-0"},kg={key:2,class:"mfs-form-field__msg mfs-caption mfs-m-0"},vl=e.defineComponent({__name:"FormField",props:{name:{},label:{},hint:{},error:{},required:{type:Boolean,default:!1}},setup(t){const a=t,l=e.inject("mfsFormContext",null),n=e.computed(()=>l==null?void 0:l.values[a.name]),i=e.computed(()=>{if(a.error)return a.error;const s=l==null?void 0:l.errors[a.name];return Array.isArray(s)?s[0]||void 0:s||void 0}),r=s=>{l==null||l.setFieldValue(a.name,s)};return(s,d)=>(e.openBlock(),e.createElementBlock("div",mg,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.name,class:"mfs-form-field__label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",ug,"*")):e.createCommentVNode("",!0)],8,fg)):e.createCommentVNode("",!0),e.renderSlot(s.$slots,"default",{value:n.value,error:i.value,setValue:r}),i.value?(e.openBlock(),e.createElementBlock("p",pg,e.toDisplayString(i.value),1)):t.hint?(e.openBlock(),e.createElementBlock("p",kg,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)]))}}),dt=[{id:"clay",name:"Claymorphism",description:"3D inflated soft surfaces, playful pastel aesthetics, and tactile curves.",icon:"Layers",previewBg:"linear-gradient(135deg, #e0e7ff 0%, #ede9fe 50%, #fce7f3 100%)"},{id:"glass",name:"Glassmorphism",description:"Frosted translucent glass, backdrop blurs, glow accents, and dark sleek UI.",icon:"Sparkles",previewBg:"radial-gradient(circle at 20% 20%, #1e1b4b 0%, #0f172a 60%, #020617 100%)"},{id:"neo",name:"Neumorphism",description:"Minimalist soft UI with extruded tactile elevations and dual directional lights.",icon:"Circle",previewBg:"linear-gradient(135deg, #e6ecf5 0%, #e2e8f0 100%)"},{id:"minimalism",name:"Minimalism",description:"Ultra-clean monochrome surfaces, hairline borders, and generous whitespace.",icon:"Minus",previewBg:"linear-gradient(135deg, #ffffff 0%, #f4f4f5 100%)"},{id:"brutalism",name:"Neubrutalism",description:"High-contrast bold borders, hard offset shadows, and vivid flat colors.",icon:"Square",previewBg:"linear-gradient(135deg, #fef08a 0%, #fde047 100%)"},{id:"bento",name:"Bento Grid",description:"Modular Apple-inspired rounded tiles with crisp spacing and subtle depth.",icon:"LayoutGrid",previewBg:"linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%)"},{id:"cyberpunk",name:"Cyberpunk",description:"Neon-lit dark HUD surfaces, sharp chamfered edges, and electric glows.",icon:"Zap",previewBg:"linear-gradient(135deg, #09090b 0%, #1e1b4b 60%, #3b0764 100%)"},{id:"retro",name:"Retro 90s",description:"Classic desktop bevels, pixel-sharp borders, and nostalgic system grays.",icon:"Monitor",previewBg:"linear-gradient(135deg, #d4d0c8 0%, #c0c0c0 100%)"},{id:"swiss",name:"Swiss Style",description:"Grid-disciplined typography, stark white planes, and bold red accents.",icon:"Grid",previewBg:"linear-gradient(135deg, #ffffff 0%, #f5f5f5 100%)"},{id:"skeuomorphism",name:"Skeuomorphism",description:"Rich physical textures, brushed gradients, and realistic specular highlights.",icon:"Box",previewBg:"linear-gradient(135deg, #e5e7eb 0%, #cbd5e1 100%)"},{id:"liquid-glass",name:"Liquid Glass",description:"Translucent refractive glass, specular rim highlights, and deep backdrop blur.",icon:"Droplets",previewBg:"radial-gradient(circle at 18% 20%, #1e3a8a 0%, #0b1020 58%, #881337 100%)"},{id:"material-you",name:"Material You",description:"Dynamic tonal pastel surfaces, expressive pill radii, and soft elevation.",icon:"Palette",previewBg:"linear-gradient(135deg, #f6f2fa 0%, #ede7f6 55%, #e8f0fe 100%)"},{id:"terminal",name:"Terminal",description:"Phosphor green CRT aesthetic, monospace typography, and crisp sharp edges.",icon:"Terminal",previewBg:"radial-gradient(circle at 50% 30%, #09170d 0%, #040805 100%)"},{id:"hand-drawn",name:"Hand-Drawn",description:"Warm sketchbook paper, charcoal ink strokes, and playful offset shadows.",icon:"PenTool",previewBg:"linear-gradient(180deg, #fdfbf7 0%, #f7f3e8 100%)"},{id:"y2k-chrome",name:"Y2K Chrome",description:"Early-2000s metallic silver, glossy bevels, electric cobalt, and cyber lime.",icon:"Disc",previewBg:"linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 50%, #dbeafe 100%)"},{id:"bauhaus",name:"Bauhaus",description:"Geometric modernism with primary red, blue, yellow, and stark black framing.",icon:"Shapes",previewBg:"linear-gradient(135deg, #f4f1ea 0%, #d92b2b 50%, #1d4ed8 100%)"},{id:"pixel-art",name:"Pixel Art",description:"8-bit and 16-bit arcade UI with stepped pixel borders and retro palette.",icon:"Gamepad2",previewBg:"linear-gradient(135deg, #1a1c2c 0%, #29366f 100%)"},{id:"aurora-gradient",name:"Aurora",description:"Northern lights dark glass with iridescent emerald, cyan, and violet glows.",icon:"Sunrise",previewBg:"radial-gradient(circle at 20% 20%, #10b981 0%, #070b19 60%, #8b5cf6 100%)"},{id:"vaporwave",name:"Vaporwave",description:"Retro-futuristic synth aesthetic with hot magenta, cyan neon, and sunset purple.",icon:"Radio",previewBg:"linear-gradient(155deg, #1a0b2e 0%, #431259 60%, #ff4ecd 100%)"},{id:"manga",name:"Manga",description:"High-contrast black and white ink panels with halftone depth and crimson accents.",icon:"BookOpen",previewBg:"linear-gradient(135deg, #ffffff 0%, #f3f4f6 70%, #dc2626 100%)"}],ct=dt.map(t=>t.id),en=ct.map(t=>`theme-${t}`),Xe=e.ref("clay");let tn=!1;const ln=t=>{if(typeof document>"u")return;const a=document.documentElement,l=document.body;a.classList.remove(...en),a.classList.add(`theme-${t}`),l==null||l.classList.remove(...en)};function nn(){const t=l=>{if(Xe.value=l,typeof document<"u"){const n=document.documentElement;n.getAttribute("data-theme")!==l&&n.setAttribute("data-theme",l),ln(l),localStorage.setItem("active-theme",l)}};return{currentTheme:Xe,themeOptions:dt,setTheme:t,initTheme:(l="clay")=>{if(typeof window<"u"){const n=localStorage.getItem("active-theme");n&&ct.includes(n)?t(n):t(l),!tn&&typeof MutationObserver<"u"&&(tn=!0,new MutationObserver(()=>{const r=document.documentElement.getAttribute("data-theme");r&&ct.includes(r)&&(Xe.value!==r&&(Xe.value=r),ln(r))}).observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}))}}}}let hg=1;function gg(t,a={}){const l=a.id??`mfs-style-${hg++}`,n=a.name,i=e.ref(!1);let r=null;function s(){if(typeof document>"u")return;const c=document.getElementById(l);if(c instanceof HTMLStyleElement){c.textContent=t,r=c,i.value=!0;return}const o=document.createElement("style");o.id=l,o.type="text/css",n&&o.setAttribute("data-mfs-style",n),o.textContent=t,document.head.appendChild(o),r=o,i.value=!0}function d(){if(typeof document>"u")return;const c=r??document.getElementById(l);c&&c.parentNode&&c.parentNode.removeChild(c),r=null,i.value=!1}return(a.immediate??!0)&&s(),e.getCurrentInstance()&&e.onUnmounted(d),{id:l,name:n,css:t,isLoaded:e.readonly(i),load:s,unload:d}}function on(t){return t===!1?{disabled:!0,color:"currentColor"}:typeof t=="object"&&t!==null?{disabled:!!t.disabled,color:t.color??"currentColor"}:{disabled:!1,color:"currentColor"}}const an={mounted(t,a){const l=on(a.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color;const n=getComputedStyle(t);n.position==="static"&&(t.style.position="relative"),n.overflow!=="hidden"&&(t.style.overflow="hidden");const i=r=>{if(t.__mfsRippleDisabled)return;const s=t.getBoundingClientRect(),d=Math.max(s.width,s.height)*2,c=r.clientX-s.left-d/2,o=r.clientY-s.top-d/2,m=document.createElement("span");m.style.position="absolute",m.style.width=`${d}px`,m.style.height=`${d}px`,m.style.left=`${c}px`,m.style.top=`${o}px`,m.style.borderRadius="50%",m.style.pointerEvents="none",m.style.backgroundColor=t.__mfsRippleColor??"currentColor",m.style.opacity="0.25",m.style.transform="scale(0)",t.appendChild(m);const f=m.animate([{transform:"scale(0)",opacity:.28},{transform:"scale(1)",opacity:0}],{duration:500,easing:"cubic-bezier(0.22, 1, 0.36, 1)"});f.onfinish=()=>m.remove()};t.__mfsRippleHandler=i,t.addEventListener("pointerdown",i)},updated(t,a){const l=on(a.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color},unmounted(t){t.__mfsRippleHandler&&(t.removeEventListener("pointerdown",t.__mfsRippleHandler),delete t.__mfsRippleHandler)}};function yg(t){return t.right?"right":t.bottom?"bottom":t.left?"left":"top"}function sn(t){const a=yg(t.modifiers),l=t.value;return typeof l=="string"?{text:l,disabled:!1,placement:a}:l&&typeof l=="object"?{text:l.value??"",disabled:!!l.disabled,placement:a,customClass:l.class}:{text:"",disabled:!0,placement:a}}function rn(t,a,l){const n=t.getBoundingClientRect(),i=a.getBoundingClientRect(),r=8;let s=0,d=0;switch(l){case"bottom":s=n.bottom+r,d=n.left+n.width/2-i.width/2;break;case"left":s=n.top+n.height/2-i.height/2,d=n.left-i.width-r;break;case"right":s=n.top+n.height/2-i.height/2,d=n.right+r;break;case"top":default:s=n.top-i.height-r,d=n.left+n.width/2-i.width/2;break}const c=Math.max(8,window.innerWidth-i.width-8),o=Math.max(8,window.innerHeight-i.height-8);a.style.top=`${Math.min(Math.max(8,s),o)}px`,a.style.left=`${Math.min(Math.max(8,d),c)}px`}function Ze(t){t.tipEl&&(t.tipEl.remove(),t.tipEl=void 0)}const mt={mounted(t,a){const n={...sn(a),show:()=>{if(n.disabled||!n.text)return;Ze(n);const i=document.createElement("div");i.setAttribute("role","tooltip"),i.textContent=n.text,n.customClass&&(i.className=n.customClass),Object.assign(i.style,{position:"fixed",zIndex:"10020",padding:"6px 10px",borderRadius:"var(--radius-sm, 8px)",backgroundColor:"var(--tooltip-bg, #0f172a)",color:"var(--tooltip-text, #f8fafc)",border:"1px solid var(--tooltip-border, rgba(255, 255, 255, 0.14))",fontSize:"0.78rem",fontWeight:"600",lineHeight:"1.35",maxWidth:"min(260px, 80vw)",pointerEvents:"none",boxShadow:"0 6px 18px rgba(0, 0, 0, 0.2)",whiteSpace:"nowrap"}),document.body.appendChild(i),rn(t,i,n.placement),n.tipEl=i},hide:()=>Ze(n)};t.__mfsTooltipState=n,t.addEventListener("mouseenter",n.show),t.addEventListener("mouseleave",n.hide),t.addEventListener("focusin",n.show),t.addEventListener("focusout",n.hide)},updated(t,a){const l=t.__mfsTooltipState;if(!l)return;const n=sn(a);l.text=n.text,l.disabled=n.disabled,l.placement=n.placement,l.customClass=n.customClass,l.disabled||!l.text?Ze(l):l.tipEl&&(l.tipEl.textContent=l.text,rn(t,l.tipEl,l.placement))},unmounted(t){const a=t.__mfsTooltipState;a&&(t.removeEventListener("mouseenter",a.show),t.removeEventListener("mouseleave",a.hide),t.removeEventListener("focusin",a.show),t.removeEventListener("focusout",a.hide),Ze(a),delete t.__mfsTooltipState)}},bg=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(",");function dn(t){return Array.from(t.querySelectorAll(bg)).filter(a=>a.offsetParent!==null||a===document.activeElement)}function cn(t){if(t.__mfsTrapActive)return;t.__mfsTrapActive=!0,t.__mfsPrevFocus=document.activeElement;const a=dn(t);a.length>0&&a[0].focus();const l=n=>{if(n.key!=="Tab")return;const i=dn(t);if(i.length===0){n.preventDefault();return}const r=i[0],s=i[i.length-1];n.shiftKey&&document.activeElement===r?(n.preventDefault(),s.focus()):!n.shiftKey&&document.activeElement===s&&(n.preventDefault(),r.focus())};t.__mfsFocusTrapHandler=l,t.addEventListener("keydown",l)}function mn(t){t.__mfsTrapActive&&(t.__mfsTrapActive=!1,t.__mfsFocusTrapHandler&&(t.removeEventListener("keydown",t.__mfsFocusTrapHandler),delete t.__mfsFocusTrapHandler),t.__mfsPrevFocus&&typeof t.__mfsPrevFocus.focus=="function"&&t.__mfsPrevFocus.focus(),t.__mfsPrevFocus=null)}const fn={mounted(t,a){a.value!==!1&&cn(t)},updated(t,a){a.value===!1?mn(t):cn(t)},unmounted(t){mn(t)}},Bg=new Set(["fade-up","fade-down","fade-left","fade-right","zoom-in"]),un="cubic-bezier(0.22, 1, 0.36, 1)";function wg(t){return typeof t=="string"&&Bg.has(t)}function pn(t,a){switch(t){case"fade-down":return`translate3d(0, -${a}px, 0)`;case"fade-left":return`translate3d(${a}px, 0, 0)`;case"fade-right":return`translate3d(-${a}px, 0, 0)`;case"zoom-in":return"scale(0.92)";case"fade-up":default:return`translate3d(0, ${a}px, 0)`}}function _g(t){return t==="zoom-in"?"scale(1)":"translate3d(0, 0, 0)"}const kn={mounted(t,a){var p;if(typeof IntersectionObserver>"u")return;const l=typeof a.value=="string"?wg(a.value)?{animation:a.value}:{enterClass:a.value}:a.value??{},n=l.enterClass===void 0,i=l.animation??"fade-up",r=l.duration??500,s=l.delay??0,d=l.distance??24,c=l.threshold??.1,o=l.once??!0,m=(l.enterClass??"").split(/\s+/).filter(Boolean),f=(l.leaveClass??"").split(/\s+/).filter(Boolean),b=typeof window<"u"&&((p=window.matchMedia)==null?void 0:p.call(window,"(prefers-reduced-motion: reduce)").matches);n&&!b&&(t.style.opacity="0",t.style.transform=pn(i,d),t.style.transition=`opacity ${r}ms ${un} ${s}ms, transform ${r}ms ${un} ${s}ms`);const u=new IntersectionObserver(g=>{for(const k of g)k.isIntersecting?(f.length&&t.classList.remove(...f),m.length&&t.classList.add(...m),n&&(t.style.opacity="1",t.style.transform=_g(i)),o&&u.unobserve(t)):o||(m.length&&t.classList.remove(...m),f.length&&t.classList.add(...f),n&&!b&&(t.style.opacity="0",t.style.transform=pn(i,d)))},{threshold:c});t.__mfsAosObserver=u,u.observe(t)},unmounted(t){t.__mfsAosObserver&&(t.__mfsAosObserver.disconnect(),delete t.__mfsAosObserver)}};function Eg(t,a){var l;if(!a||a==="@self")return t;if(a==="@next")return t.nextElementSibling;if(a==="@prev")return t.previousElementSibling;if(a==="@parent")return t.parentElement;if(a==="@grandparent")return((l=t.parentElement)==null?void 0:l.parentElement)??null;try{return document.querySelector(a)}catch{return null}}function hn(t){return typeof t=="string"?{toggleClass:t}:t}const gn={mounted(t,a){t.__mfsStyleClassOpts=hn(a.value);const l=()=>{const n=t.__mfsStyleClassOpts;if(!n)return;const i=Eg(t,n.selector);i&&(n.toggleClass?n.toggleClass.split(/\s+/).filter(Boolean).forEach(r=>i.classList.toggle(r)):(n.leaveClass&&n.leaveClass.split(/\s+/).filter(Boolean).forEach(r=>i.classList.remove(r)),n.enterClass&&n.enterClass.split(/\s+/).filter(Boolean).forEach(r=>i.classList.add(r))))};t.__mfsStyleClassHandler=l,t.addEventListener("click",l)},updated(t,a){t.__mfsStyleClassOpts=hn(a.value)},unmounted(t){t.__mfsStyleClassHandler&&(t.removeEventListener("click",t.__mfsStyleClassHandler),delete t.__mfsStyleClassHandler)}},yn={primary:{bg:"var(--primary, #3b82f6)",color:"var(--primary-text, #ffffff)"},secondary:{bg:"var(--secondary, #64748b)",color:"var(--secondary-text, #ffffff)"},success:{bg:"var(--success, #22c55e)",color:"var(--success-text, #ffffff)"},warning:{bg:"var(--warning, #f59e0b)",color:"var(--warning-text, #1e293b)"},danger:{bg:"var(--danger, #ef4444)",color:"var(--danger-text, #ffffff)"}};function $g(t){const a=t.value;return a==null||a===""?null:typeof a=="string"||typeof a=="number"?{text:String(a),severity:"primary"}:typeof a=="object"?a.value===null||a.value===void 0||a.value===""?null:{text:String(a.value),severity:a.severity??"primary"}:null}function Vg(t,a){if(typeof window>"u")return;getComputedStyle(t).position==="static"&&(a.hadStaticPosition=!0,a.previousPosition=t.style.position,t.style.position="relative")}function xg(){const t=document.createElement("span");return Object.assign(t.style,{position:"absolute",top:"0",right:"0",transform:"translate(40%, -40%)",zIndex:"1",pointerEvents:"none",display:"inline-flex",alignItems:"center",justifyContent:"center",minWidth:"18px",height:"18px",padding:"0 6px",borderRadius:"9999px",fontSize:"0.72rem",fontWeight:"700",lineHeight:"1",whiteSpace:"nowrap",userSelect:"none",boxShadow:"0 2px 6px rgba(0, 0, 0, 0.18)"}),t}function bn(t,a,l){const n=$g(a);if(!n){l.badgeEl&&(l.badgeEl.remove(),l.badgeEl=void 0);return}Vg(t,l),l.badgeEl||(l.badgeEl=xg(),t.appendChild(l.badgeEl));const i=yn[n.severity]??yn.primary;l.badgeEl.className=`mfs-badge mfs-pill mfs-bg-${n.severity}`,l.badgeEl.style.backgroundColor=i.bg,l.badgeEl.style.color=i.color,l.badgeEl.textContent=n.text}const ft={mounted(t,a){const l={hadStaticPosition:!1,previousPosition:""};t.__mfsBadgeState=l,bn(t,a,l)},updated(t,a){const l=t.__mfsBadgeState;l&&bn(t,a,l)},unmounted(t){const a=t.__mfsBadgeState;a&&(a.badgeEl&&(a.badgeEl.remove(),a.badgeEl=void 0),a.hadStaticPosition&&(t.style.position=a.previousPosition),delete t.__mfsBadgeState)}},Cg=ft,Bn={int:{charPattern:/^[\d-]$/,pastePattern:/^-?\d+$/},pint:{charPattern:/^\d$/,pastePattern:/^\d+$/},num:{charPattern:/^[\d.-]$/,pastePattern:/^-?\d*(\.\d*)?$/},pnum:{charPattern:/^[\d.]$/,pastePattern:/^\d*(\.\d*)?$/},money:{charPattern:/^[\d.,\s]$/,pastePattern:/^[\d.,\s]+$/},hex:{charPattern:/^[0-9a-fA-F]$/,pastePattern:/^[0-9a-fA-F]+$/},alpha:{charPattern:/^[a-zA-Z]$/,pastePattern:/^[a-zA-Z]+$/},alphanum:{charPattern:/^[a-zA-Z0-9]$/,pastePattern:/^[a-zA-Z0-9]+$/}};function ut(t,a){return(t.global||t.sticky)&&(t.lastIndex=0),t.test(a)}function Ng(t,a){if(!a)return!0;if(a instanceof RegExp)return ut(a,t);const l=Bn[a];return l?l.charPattern.test(t):!0}function Sg(t,a){if(!a||t==="")return!0;if(a instanceof RegExp)return a.source.startsWith("^")||a.source.endsWith("$")?ut(a,t):[...t].every(n=>ut(a,n));const l=Bn[a];return l?l.pastePattern.test(t):!0}const pt={mounted(t,a){const l={filter:a.value,onKeyPress(n){n.ctrlKey||n.metaKey||n.altKey||n.key.length!==1||Ng(n.key,l.filter)||n.preventDefault()},onPaste(n){var r;const i=((r=n.clipboardData)==null?void 0:r.getData("text"))??"";Sg(i,l.filter)||n.preventDefault()}};t.__mfsKeyFilterState=l,t.addEventListener("keypress",l.onKeyPress),t.addEventListener("paste",l.onPaste)},updated(t,a){t.__mfsKeyFilterState&&(t.__mfsKeyFilterState.filter=a.value)},unmounted(t){const a=t.__mfsKeyFilterState;a&&(t.removeEventListener("keypress",a.onKeyPress),t.removeEventListener("paste",a.onPaste),delete t.__mfsKeyFilterState)}},Mg=pt,Dg={Button:$e,ButtonGroup:kt,Card:ht,Input:Te,InputText:Te,Badge:ve,Switch:ge,ToggleSwitch:ge,InputSwitch:ge,Modal:ye,Dialog:ye,Textarea:gt,InputNumber:yt,Password:bt,Checkbox:fe,RadioButton:et,Select:Le,Dropdown:Le,MultiSelect:Bt,Slider:wt,Rating:_t,ColorPicker:Et,DatePicker:ze,Calendar:ze,Avatar:Ie,Chip:Ve,Tag:Ve,Divider:$t,Accordion:Vt,Timeline:xt,Carousel:Ct,Image:Nt,Toast:Dt,Alert:Re,Message:Re,Tooltip:Tt,Drawer:Pe,Sidebar:Pe,Popover:Ae,OverlayPanel:Ae,Skeleton:Lt,ProgressBar:zt,ProgressSpinner:It,ConfirmDialog:At,Navbar:je,Menubar:je,Tabs:Ke,TabView:Ke,Breadcrumb:Kt,Pagination:xe,Paginator:xe,Steps:Oe,Stepper:Oe,ContextMenu:Ot,ScrollTop:Ht,DataTable:Ut,Column:Wt,DataView:Gt,Tree:qt,AutoComplete:Yt,Cascader:He,CascadeSelect:He,TreeSelect:Xt,Knob:Zt,SelectButton:Jt,ToggleButton:Qt,InputOtp:vt,InputMask:el,InputGroup:tl,InputGroupAddon:ll,IconField:nl,InputIcon:ol,Listbox:al,FloatLabel:sl,IftaLabel:rl,Editor:il,CodeEditor:cl,SplitButton:ml,SpeedDial:fl,Panel:ul,Fieldset:pl,Splitter:kl,Toolbar:hl,ScrollPanel:gl,Fluid:yl,Deferred:We,DeferredContent:We,Menu:bl,TieredMenu:Bl,SlideMenu:wl,PanelMenu:_l,MegaMenu:El,Dock:$l,TabMenu:Vl,OrderList:xl,PickList:Cl,TreeTable:Nl,OrganizationChart:Sl,VirtualScroller:Ml,MeterGroup:Dl,Inplace:Tl,SortableList:qe,Draggable:qe,ConfirmPopup:Ll,InlineMessage:zl,BlockUI:Il,Galleria:Rl,FileUpload:Pl,Terminal:Al,Chart:Fl,ImageCropper:rt,AvatarGroup:jl,OverlayBadge:Kl,ImageCompare:Ol,Portal:Hl,Chips:Ye,InputChips:Ye,CheckboxGroup:Ul,RadioButtonGroup:Wl,DynamicDialog:ql,CommandPalette:Yl,InfiniteScroll:Xl,Mentions:Zl,SignaturePad:Jl,Form:Ql,FormField:vl},Tg={ripple:an,tooltip:mt,focustrap:fn,animateonscroll:kn,styleclass:gn,badge:ft,keyfilter:pt},Lg={install(t,a={}){for(const[l,n]of Object.entries(Dg))t.component(l,n);for(const[l,n]of Object.entries(Tg))t.directive(l,n);if(typeof window<"u"){const{initTheme:l}=nn();l(a.defaultTheme||"clay")}}};L.Accordion=Vt,L.Alert=Re,L.AutoComplete=Yt,L.Avatar=Ie,L.AvatarGroup=jl,L.Badge=ve,L.BadgeDirective=Cg,L.BlockUI=Il,L.Breadcrumb=Kt,L.Button=$e,L.ButtonGroup=kt,L.Calendar=ze,L.Card=ht,L.Carousel=Ct,L.CascadeSelect=He,L.Cascader=He,L.Chart=Fl,L.Checkbox=fe,L.CheckboxGroup=Ul,L.Chip=Ve,L.Chips=Ye,L.CodeEditor=cl,L.ColorPicker=Et,L.Column=Wt,L.CommandPalette=Yl,L.ConfirmDialog=At,L.ConfirmPopup=Ll,L.ContextMenu=Ot,L.DataTable=Ut,L.DataView=Gt,L.DatePicker=ze,L.Deferred=We,L.DeferredContent=We,L.Dialog=ye,L.Divider=$t,L.Dock=$l,L.Draggable=qe,L.Drawer=Pe,L.Dropdown=Le,L.DynamicDialog=ql,L.Editor=il,L.Fieldset=pl,L.FileUpload=Pl,L.FloatLabel=sl,L.Fluid=yl,L.Form=Ql,L.FormField=vl,L.Galleria=Rl,L.IconField=nl,L.IftaLabel=rl,L.Image=Nt,L.ImageCompare=Ol,L.ImageCropper=rt,L.InfiniteScroll=Xl,L.InlineMessage=zl,L.Inplace=Tl,L.Input=Te,L.InputChips=Ye,L.InputGroup=tl,L.InputGroupAddon=ll,L.InputIcon=ol,L.InputMask=el,L.InputNumber=yt,L.InputOtp=vt,L.InputSwitch=ge,L.InputText=Te,L.KeyFilter=Mg,L.Knob=Zt,L.Listbox=al,L.MegaMenu=El,L.Mentions=Zl,L.Menu=bl,L.Menubar=je,L.Message=Re,L.MeterGroup=Dl,L.Modal=ye,L.MultiSelect=Bt,L.Navbar=je,L.OrderList=xl,L.OrganizationChart=Sl,L.OverlayBadge=Kl,L.OverlayPanel=Ae,L.Pagination=xe,L.Paginator=xe,L.Panel=ul,L.PanelMenu=_l,L.Password=bt,L.PickList=Cl,L.Popover=Ae,L.Portal=Hl,L.ProgressBar=zt,L.ProgressSpinner=It,L.RadioButton=et,L.RadioButtonGroup=Wl,L.Rating=_t,L.ScrollPanel=gl,L.ScrollTop=Ht,L.Select=Le,L.SelectButton=Jt,L.Sidebar=Pe,L.SignaturePad=Jl,L.Skeleton=Lt,L.SlideMenu=wl,L.Slider=wt,L.SortableList=qe,L.SpeedDial=fl,L.SplitButton=ml,L.Splitter=kl,L.Stepper=Oe,L.Steps=Oe,L.Switch=ge,L.THEME_OPTIONS=dt,L.TabMenu=Vl,L.TabView=Ke,L.Tabs=Ke,L.Tag=Ve,L.Terminal=Al,L.Textarea=gt,L.TieredMenu=Bl,L.Timeline=xt,L.Toast=Dt,L.ToggleButton=Qt,L.ToggleSwitch=ge,L.Toolbar=hl,L.Tooltip=Tt,L.TooltipDirective=mt,L.Tree=qt,L.TreeSelect=Xt,L.TreeTable=Nl,L.VirtualScroller=Ml,L.default=Lg,L.useConfirm=Pt,L.useDialog=Gl,L.useDragDrop=Lu,L.useStyle=gg,L.useTheme=nn,L.useToast=Mt,L.vAnimateOnScroll=kn,L.vBadge=ft,L.vFocusTrap=fn,L.vKeyFilter=pt,L.vRipple=an,L.vStyleClass=gn,L.vTooltip=mt,Object.defineProperties(L,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
|