@mfs-atomic/ui 1.1.0 → 1.1.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.
@@ -1,33 +1,33 @@
1
- (function(x,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(x=typeof globalThis<"u"?globalThis:x||self,e(x.MfsTheme={},x.Vue))})(this,(function(x,e){"use strict";const so=["disabled","type"],ro={key:0,class:"btn__spinner"},io={key:1,class:"btn__icon btn__icon--prepend"},co={class:"btn__content"},mo={key:2,class:"btn__icon btn__icon--append"},fo=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:s}){const l=s,o=a=>{l("click",a)};return(a,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:o},[t.loading?(e.openBlock(),e.createElementBlock("span",ro)):e.createCommentVNode("",!0),a.$slots.prepend&&!t.loading?(e.openBlock(),e.createElementBlock("span",io,[e.renderSlot(a.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",co,[e.renderSlot(a.$slots,"default",{},void 0,!0)]),a.$slots.append&&!t.loading?(e.openBlock(),e.createElementBlock("span",mo,[e.renderSlot(a.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],10,so))}}),L=(t,s)=>{const l=t.__vccOpts||t;for(const[o,a]of s)l[o]=a;return l},ie=L(fo,[["__scopeId","data-v-76212e60"]]),po={},uo={class:"mfs-btn-group mfs-inline-flex mfs-items-center",role:"group"};function ko(t,s){return e.openBlock(),e.createElementBlock("div",uo,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const qe=L(po,[["render",ko],["__scopeId","data-v-3e6bbebb"]]),ho={key:0,class:"card__header"},go={key:0,class:"card__title mfs-title"},yo={key:1,class:"card__subtitle mfs-caption"},bo={class:"card__body"},Bo={key:1,class:"card__footer"},Ye=L(e.defineComponent({__name:"Card",props:{title:{},subtitle:{},hoverable:{type:Boolean,default:!1},bordered:{type:Boolean,default:!1}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["card","mfs-card",{"card--hoverable":t.hoverable,"card--bordered":t.bordered}])},[s.$slots.header||t.title?(e.openBlock(),e.createElementBlock("div",ho,[e.renderSlot(s.$slots,"header",{},()=>[e.createElementVNode("div",null,[t.title?(e.openBlock(),e.createElementBlock("h3",go,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),t.subtitle?(e.openBlock(),e.createElementBlock("p",yo,e.toDisplayString(t.subtitle),1)):e.createCommentVNode("",!0)])],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",bo,[e.renderSlot(s.$slots,"default",{},void 0,!0)]),s.$slots.footer?(e.openBlock(),e.createElementBlock("div",Bo,[e.renderSlot(s.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-38a6c076"]]),_o={key:0,class:"input-label mfs-text"},wo={key:0,class:"input-required"},Eo={key:0,class:"input-affix mfs-text-muted input-affix--prepend"},$o=["id","type","value","placeholder","disabled","readonly"],Vo={key:1,class:"input-affix mfs-text-muted input-affix--append"},Co={key:1,class:"input-msg input-msg--error mfs-text-danger"},xo={key:2,class:"input-msg mfs-caption"},ke=L(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:s}){const l=s,o=a=>{const r=a.target;l("update:modelValue",r.value)};return(a,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",_o,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",wo,"*")):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}])},[a.$slots.prepend?(e.openBlock(),e.createElementBlock("span",Eo,[e.renderSlot(a.$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:o,onFocus:r[0]||(r[0]=i=>a.$emit("focus",i)),onBlur:r[1]||(r[1]=i=>a.$emit("blur",i))},null,40,$o),a.$slots.append?(e.openBlock(),e.createElementBlock("span",Vo,[e.renderSlot(a.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],2),t.error?(e.openBlock(),e.createElementBlock("p",Co,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",xo,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-b6818f92"]]),Le=L(e.defineComponent({__name:"Badge",props:{variant:{default:"primary"},size:{default:"md"}},setup(t){return(s,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(s.$slots,"prepend",{},void 0,!0),e.renderSlot(s.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-649f6dac"]]),No=["checked","disabled"],So={key:0,class:"switch__label"},le=L(e.defineComponent({__name:"Switch",props:{modelValue:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=s,o=a=>{const r=a.target;l("update:modelValue",r.checked),l("change",r.checked)};return(a,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:o},null,40,No),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||a.$slots.default?(e.openBlock(),e.createElementBlock("span",So,[e.renderSlot(a.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-de02acdb"]]),Mo={key:0,class:"modal-header mfs-flex mfs-items-center mfs-justify-between"},Do={class:"modal-title mfs-title"},zo={class:"modal-body"},Lo={key:1,class:"modal-footer mfs-flex mfs-items-center mfs-justify-end mfs-gap-3"},oe=L(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:s}){const l=t,o=s,a=()=>{o("update:modelValue",!1),o("close")},r=()=>{l.closeOnBackdrop&&a()};let i="",c=!1;const d=n=>{if(!(typeof document>"u"))if(n){if(c)return;i=document.body.style.overflow,document.body.style.overflow="hidden",c=!0}else c&&(document.body.style.overflow=i,c=!1)};return e.onMounted(()=>{l.modelValue&&d(!0)}),e.watch(()=>l.modelValue,n=>d(n)),e.onBeforeUnmount(()=>{d(!1)}),(n,k)=>(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:k[0]||(k[0]=e.withModifiers(()=>{},["stop"]))},[t.title||n.$slots.header?(e.openBlock(),e.createElementBlock("div",Mo,[e.renderSlot(n.$slots,"header",{},()=>[e.createElementVNode("h3",Do,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:a,"aria-label":"Close modal"}," ✕ ")])):e.createCommentVNode("",!0),e.createElementVNode("div",zo,[e.renderSlot(n.$slots,"default",{},void 0,!0)]),n.$slots.footer?(e.openBlock(),e.createElementBlock("div",Lo,[e.renderSlot(n.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-3a4fa0a7"]]),To=["for"],Io={key:0,class:"mfs-text-danger"},Po=["id","value","placeholder","disabled","readonly","rows","maxlength","aria-invalid"],Ro={key:1,class:"textarea-footer mfs-flex mfs-items-center mfs-justify-between mfs-gap-2"},Fo={key:0,class:"textarea-msg textarea-msg--error mfs-text-danger"},Ao={key:1,class:"textarea-msg mfs-caption"},jo={key:2,class:"textarea-spacer mfs-flex-1"},Ko={key:3,class:"textarea-count mfs-caption"},Xe=L(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:s}){const l=t,o=s,a=e.useId(),r=e.computed(()=>l.id||`mfs-textarea-${a}`),i=e.ref(null),c=e.computed(()=>(l.modelValue??"").length),d=()=>{const k=i.value;!k||!l.autoResize||(k.style.height="auto",k.style.height=`${k.scrollHeight}px`)},n=k=>{const h=k.target;o("update:modelValue",h.value),e.nextTick(d)};return e.watch(()=>l.modelValue,()=>e.nextTick(d)),e.onMounted(d),(k,h)=>(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",Io,"*")):e.createCommentVNode("",!0)],8,To)):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:i,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:n,onFocus:h[0]||(h[0]=y=>k.$emit("focus",y)),onBlur:h[1]||(h[1]=y=>k.$emit("blur",y))},null,40,Po)],2),t.error||t.hint||t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("div",Ro,[t.error?(e.openBlock(),e.createElementBlock("p",Fo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Ao,e.toDisplayString(t.hint),1)):(e.openBlock(),e.createElementBlock("span",jo)),t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("span",Ko,[e.createTextVNode(e.toDisplayString(c.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-607879e7"]]),Oo=["for"],Uo={key:0,class:"num-required mfs-text-danger"},Ho={class:"num-box mfs-surface mfs-rounded mfs-shadow-inset mfs-flex mfs-items-center mfs-gap-1-5"},Wo=["disabled"],Go={class:"num-input-area mfs-flex-1 mfs-flex mfs-items-center mfs-gap-1 mfs-min-w-0 mfs-px-1"},qo={key:0,class:"num-prefix mfs-text-muted mfs-font-semibold mfs-select-none"},Yo=["id","value","placeholder","disabled","readonly","aria-invalid","aria-valuemin","aria-valuemax","aria-valuenow"],Xo=["disabled"],Zo={key:1,class:"num-msg num-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Jo={key:2,class:"num-msg mfs-caption mfs-m-0"},Ze=L(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:s}){const l=t,o=s,a=e.useId(),r=e.computed(()=>l.id||`mfs-num-${a}`),i=e.ref(!1),c=e.ref(""),d=u=>{let b=u;l.min!==void 0&&(b=Math.max(l.min,b)),l.max!==void 0&&(b=Math.min(l.max,b));const g=Math.pow(10,l.decimals);return Math.round(b*g)/g},n=e.computed(()=>l.min!==void 0&&l.modelValue!==null&&l.modelValue<=l.min),k=e.computed(()=>l.max!==void 0&&l.modelValue!==null&&l.modelValue>=l.max),h=e.computed(()=>i.value?c.value:l.modelValue===null||l.modelValue===void 0||Number.isNaN(l.modelValue)?"":l.decimals>0?l.modelValue.toFixed(l.decimals):String(l.modelValue)),y=()=>{i.value=!0,c.value=l.modelValue!==null&&l.modelValue!==void 0?String(l.modelValue):""},f=u=>{const b=u.target.value;if(c.value=b,b.trim()===""||b==="-"){b.trim()===""&&o("update:modelValue",null);return}const g=Number(b);Number.isNaN(g)||o("update:modelValue",g)},p=()=>{if(i.value=!1,c.value.trim()===""){o("update:modelValue",null),o("change",null);return}const u=Number(c.value);if(Number.isNaN(u)){o("update:modelValue",null),o("change",null);return}const b=d(u);o("update:modelValue",b),o("change",b)},m=u=>{if(l.disabled||l.readonly)return;const b=l.modelValue??(l.min!==void 0?l.min:0),g=d(b+u*l.step);o("update:modelValue",g),o("change",g)};return(u,b)=>(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",Uo,"*")):e.createCommentVNode("",!0)],8,Oo)):e.createCommentVNode("",!0),e.createElementVNode("div",Ho,[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||n.value,onClick:b[0]||(b[0]=g=>m(-1))},[...b[4]||(b[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,Wo),e.createElementVNode("div",Go,[t.prefix?(e.openBlock(),e.createElementBlock("span",qo,e.toDisplayString(t.prefix),1)):e.createCommentVNode("",!0),e.createElementVNode("input",{id:r.value,type:"text",inputmode:"decimal",value:h.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:y,onBlur:p,onInput:f,onKeydown:[b[1]||(b[1]=e.withKeys(e.withModifiers(g=>m(1),["prevent"]),["up"])),b[2]||(b[2]=e.withKeys(e.withModifiers(g=>m(-1),["prevent"]),["down"]))]},null,40,Yo)]),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||k.value,onClick:b[3]||(b[3]=g=>m(1))},[...b[5]||(b[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,Xo)]),t.error?(e.openBlock(),e.createElementBlock("p",Zo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Jo,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-94f092b6"]]),Qo=["for"],vo={key:0,class:"mfs-text-danger"},en={class:"pwd-box mfs-flex mfs-items-center mfs-surface mfs-rounded mfs-shadow-inset"},tn=["id","type","value","placeholder","disabled","readonly","aria-invalid"],ln=["aria-label","aria-pressed","disabled"],on={key:0,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},nn={key:1,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},an={key:1,class:"pwd-strength mfs-flex mfs-items-center mfs-gap-2","aria-live":"polite"},sn={class:"pwd-bars mfs-flex-1"},rn={key:2,class:"pwd-msg pwd-msg--error mfs-text-danger"},dn={key:3,class:"pwd-msg mfs-caption"},Je=L(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:s}){const l=t,o=s,a=e.useId(),r=e.computed(()=>l.id||`mfs-pwd-${a}`),i=e.ref(!1),c=n=>{o("update:modelValue",n.target.value)},d=e.computed(()=>{const n=l.modelValue||"";let k=0;return n.length>=6&&k++,n.length>=10&&k++,/[a-z]/.test(n)&&/[A-Z]/.test(n)&&k++,/\d/.test(n)&&/[^A-Za-z0-9]/.test(n)&&k++,k=Math.max(1,Math.min(4,k)),{score:k,...{1:{label:"Weak",color:"var(--danger, #f43f5e)"},2:{label:"Fair",color:"var(--warning, #f59e0b)"},3:{label:"Good",color:"var(--primary, #8b5cf6)"},4:{label:"Strong",color:"var(--success, #10b981)"}}[k]}});return(n,k)=>(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",vo,"*")):e.createCommentVNode("",!0)],8,Qo)):e.createCommentVNode("",!0),e.createElementVNode("div",en,[e.createElementVNode("input",{id:r.value,type:i.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:c,onFocus:k[0]||(k[0]=h=>n.$emit("focus",h)),onBlur:k[1]||(k[1]=h=>n.$emit("blur",h))},null,40,tn),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":i.value?"Hide password":"Show password","aria-pressed":i.value,disabled:t.disabled,onClick:k[2]||(k[2]=h=>i.value=!i.value)},[i.value?(e.openBlock(),e.createElementBlock("svg",on,[...k[3]||(k[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",nn,[...k[4]||(k[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,ln)]),t.showStrength&&t.modelValue?(e.openBlock(),e.createElementBlock("div",an,[e.createElementVNode("div",sn,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(4,h=>e.createElementVNode("span",{key:h,class:e.normalizeClass(["pwd-bar mfs-pill",{"pwd-bar--active":h<=d.value.score}]),style:e.normalizeStyle({backgroundColor:h<=d.value.score?d.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:d.value.color})},e.toDisplayString(d.value.label),5)])):e.createCommentVNode("",!0),t.error?(e.openBlock(),e.createElementBlock("p",rn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",dn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-e18398e6"]]),cn=["id","checked","disabled","aria-label","tabindex"],mn={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round",class:"checkbox__icon"},fn={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"},pn={key:0,class:"checkbox__label"},ne=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue.includes(l.value):!!l.modelValue);e.watchEffect(()=>{a.value&&(a.value.indeterminate=l.indeterminate)}),e.onMounted(()=>{a.value&&(a.value.indeterminate=l.indeterminate)});const i=c=>{const d=c.target.checked;let n;Array.isArray(l.modelValue)?n=d?[...l.modelValue,l.value]:l.modelValue.filter(k=>k!==l.value):n=d,o("update:modelValue",n),o("change",n)};return(c,d)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["checkbox mfs-text",{"checkbox--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{ref_key:"inputRef",ref:a,id:t.id,type:"checkbox",class:"checkbox__input",checked:r.value,disabled:t.disabled,"aria-label":t.ariaLabel,tabindex:t.tabindex,onChange:i},null,40,cn),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",mn,[...d[0]||(d[0]=[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"},null,-1)])])):r.value?(e.openBlock(),e.createElementBlock("svg",fn,[...d[1]||(d[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),t.label||c.$slots.default?(e.openBlock(),e.createElementBlock("span",pn,[e.renderSlot(c.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-c6f5af78"]]),un=["id","name","value","checked","disabled"],kn={key:0,class:"radio__label"},Te=L(e.defineComponent({__name:"RadioButton",props:{modelValue:{},value:{},name:{},label:{},disabled:{type:Boolean,default:!1},id:{}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.computed(()=>l.modelValue===l.value),r=()=>{l.disabled||(o("update:modelValue",l.value),o("change",l.value))};return(i,c)=>(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:a.value,disabled:t.disabled,onChange:r},null,40,un),e.createElementVNode("span",{class:e.normalizeClass(["radio__circle mfs-surface mfs-shadow",{"radio__circle--checked":a.value}])},[...c[0]||(c[0]=[e.createElementVNode("span",{class:"radio__dot"},null,-1)])],2),t.label||i.$slots.default?(e.openBlock(),e.createElementBlock("span",kn,[e.renderSlot(i.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-7cb79a2c"]]);function J(t,s,l,o){const a=(o==null?void 0:o.offset)??6,r=(o==null?void 0:o.matchWidth)??!1,i=(o==null?void 0:o.align)??"left",c=e.ref(0),d=e.ref(0),n=e.ref(void 0),k=()=>{var E;if(typeof window>"u"||!t.value)return;const p=t.value.getBoundingClientRect(),m=(E=s.value)==null?void 0:E.getBoundingClientRect(),u=Math.max((m==null?void 0:m.width)??0,r?p.width:0)||p.width,b=(m==null?void 0:m.height)??0;let g=p.left;i==="right"?g=p.right-u:i==="center"&&(g=p.left+(p.width-u)/2);const B=8,w=Math.max(B,window.innerWidth-u-B);g=Math.min(Math.max(B,g),w);const _=window.innerHeight-p.bottom,$=p.top;let V=p.bottom+a;b>0&&p.bottom+a+b>window.innerHeight-B&&$>_&&(V=Math.max(B,p.top-b-a)),c.value=V,d.value=g,n.value=r?p.width:void 0},h=e.computed(()=>{const p={position:"fixed",top:`${c.value}px`,left:`${d.value}px`,zIndex:10100};return r&&n.value!==void 0&&(p.minWidth=`${n.value}px`),p}),y=p=>{var m,u;return p instanceof Node?!!((m=t.value)!=null&&m.contains(p)||(u=s.value)!=null&&u.contains(p)):!1},f=()=>{l.value&&k()};return e.watch(l,p=>{p&&(k(),e.nextTick(k))}),e.watch(s,p=>{p&&l.value&&k()}),e.onMounted(()=>{typeof window>"u"||(window.addEventListener("scroll",f,!0),window.addEventListener("resize",f),l.value&&k())}),e.onBeforeUnmount(()=>{typeof window>"u"||(window.removeEventListener("scroll",f,!0),window.removeEventListener("resize",f))}),{overlayStyle:h,updatePosition:k,containsTarget:y}}const hn={key:0,class:"mfs-text-danger"},gn=["aria-expanded","aria-invalid","disabled"],yn={class:"select-actions mfs-inline-flex mfs-items-center mfs-text-muted"},bn={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Bn={key:0,class:"select-search-box"},_n={class:"select-options mfs-flex mfs-flex-col"},wn=["aria-selected","disabled","onClick","onMouseenter"],En={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"},$n={key:0,class:"select-empty mfs-empty-state"},Vn={key:1,class:"select-empty mfs-empty-state"},Cn={key:1,class:"select-msg select-msg--error mfs-text-danger"},xn={key:2,class:"select-msg mfs-caption"},he=L(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:s}){const l=t,o=s,a=e.useId(),r=`mfs-select-${a}`,i=`mfs-select-list-${a}`,c=e.ref(null),d=e.ref(null),n=e.ref(null),k=e.ref(null),h=e.ref(!1),y=e.ref(""),f=e.ref(-1),{overlayStyle:p,containsTarget:m}=J(d,n,h,{matchWidth:!0}),u=e.computed(()=>l.options.map(N=>typeof N=="string"?{label:N,value:N}:N)),b=e.computed(()=>{if(l.remote)return u.value;const N=y.value.trim().toLowerCase();return N?u.value.filter(F=>F.label.toLowerCase().includes(N)):u.value}),g=N=>{o("filter",{value:N.target.value})},B=e.computed(()=>u.value.find(N=>N.value===l.modelValue)),w=()=>{l.disabled||(h.value=!0,f.value=b.value.findIndex(N=>N.value===l.modelValue),l.searchable&&e.nextTick(()=>{var N;return(N=k.value)==null?void 0:N.focus()}))},_=()=>{h.value=!1,y.value=""},$=()=>{h.value?_():w()},V=N=>{N.disabled||(o("update:modelValue",N.value),o("change",N.value),_())},E=()=>{o("update:modelValue",null),o("change",null)},C=N=>{if(!h.value){(N.key==="ArrowDown"||N.key==="ArrowUp"||N.key==="Enter"||N.key===" ")&&(N.preventDefault(),w());return}const F=b.value;if(N.key==="Escape")N.preventDefault(),_();else if(N.key==="ArrowDown"){if(N.preventDefault(),!F.length)return;f.value=(f.value+1)%F.length}else if(N.key==="ArrowUp"){if(N.preventDefault(),!F.length)return;f.value=(f.value-1+F.length)%F.length}else if(N.key==="Enter"){N.preventDefault();const H=F[f.value];H&&!H.disabled&&V(H)}},S=N=>{m(N.target)||_()};return e.onMounted(()=>document.addEventListener("mousedown",S)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",S)),(N,F)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:c,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",hn,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:d,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":h.value,"aria-controls":i,"aria-invalid":!!t.error,disabled:t.disabled,onClick:$,onKeydown:C},[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",yn,[t.loading?(e.openBlock(),e.createElementBlock("span",bn)):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"])},[...F[1]||(F[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":h.value}])},[...F[2]||(F[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))])],40,gn),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"select-pop"},{default:e.withCtx(()=>[h.value?(e.openBlock(),e.createElementBlock("div",{key:0,id:i,ref_key:"overlayRef",ref:n,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",Bn,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:k,"onUpdate:modelValue":F[0]||(F[0]=H=>y.value=H),type:"text",class:"select-search mfs-w-full mfs-text-sm mfs-inset",placeholder:"Search...",onInput:g,onKeydown:C},null,544),[[e.vModelText,y.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",_n,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(H,z)=>(e.openBlock(),e.createElementBlock("button",{key:String(H.value)+z,type:"button",role:"option","aria-selected":H.value===t.modelValue,disabled:H.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":H.value===t.modelValue,"select-option--active":z===f.value}]),onClick:j=>V(H),onMouseenter:j=>f.value=z},[e.renderSlot(N.$slots,"option",{option:H,selected:H.value===t.modelValue},()=>[e.createElementVNode("span",null,e.toDisplayString(H.label),1),H.value===t.modelValue?(e.openBlock(),e.createElementBlock("svg",En,[...F[3]||(F[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],!0)],42,wn))),128)),t.loading&&b.value.length===0?(e.openBlock(),e.createElementBlock("div",$n,[...F[4]||(F[4]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):b.value.length===0?(e.openBlock(),e.createElementBlock("div",Vn,[e.renderSlot(N.$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",Cn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",xn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-96053d34"]]),Nn={key:0,class:"ms-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},Sn={key:0,class:"mfs-text-danger"},Mn=["aria-expanded","aria-invalid","onKeydown"],Dn={class:"ms-chips mfs-flex-1 mfs-flex mfs-flex-wrap mfs-items-center mfs-gap-1-5"},zn={class:"ms-chip-text"},Ln=["aria-label","onClick"],Tn={key:0,class:"ms-placeholder mfs-text-muted"},In={key:0,class:"mfs-spinner mfs-spinner--sm mfs-shrink-0","aria-hidden":"true"},Pn={key:0,class:"ms-search-box"},Rn={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},Fn={class:"ms-options mfs-flex mfs-flex-col mfs-overflow-y-auto"},An=["aria-selected","disabled","onClick"],jn={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},Kn={key:0,class:"ms-empty mfs-empty-state"},On={key:1,class:"ms-empty mfs-empty-state"},Un={key:1,class:"ms-msg ms-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Hn={key:2,class:"ms-msg mfs-caption mfs-m-0"},Qe=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(""),{overlayStyle:k,containsTarget:h}=J(r,i,d,{matchWidth:!0}),y=e.computed(()=>l.options.map(C=>typeof C=="string"?{label:C,value:C}:C)),f=e.computed(()=>{if(l.remote)return y.value;const C=n.value.trim().toLowerCase();return C?y.value.filter(S=>S.label.toLowerCase().includes(C)):y.value}),p=C=>{o("filter",{value:C.target.value})},m=e.computed(()=>y.value.filter(C=>!C.disabled)),u=e.computed(()=>y.value.filter(C=>l.modelValue.includes(C.value))),b=e.computed(()=>m.value.length>0&&m.value.every(C=>l.modelValue.includes(C.value))),g=C=>l.modelValue.includes(C),B=()=>{l.disabled||(d.value=!d.value,d.value&&l.searchable&&e.nextTick(()=>{var C;return(C=c.value)==null?void 0:C.focus()}))},w=()=>{d.value=!1,n.value=""},_=C=>{if(C.disabled)return;const S=g(C.value)?l.modelValue.filter(N=>N!==C.value):[...l.modelValue,C.value];o("update:modelValue",S),o("change",S)},$=C=>{const S=l.modelValue.filter(N=>N!==C);o("update:modelValue",S),o("change",S)},V=()=>{const C=b.value?[]:m.value.map(S=>S.value);o("update:modelValue",C),o("change",C)},E=C=>{h(C.target)||w()};return e.onMounted(()=>document.addEventListener("mousedown",E)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",E)),(C,S)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:a,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",Nn,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",Sn,"*")):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":d.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(w,["escape"]),e.withKeys(e.withModifiers(B,["prevent"]),["enter"])]},[e.createElementVNode("div",Dn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,N=>(e.openBlock(),e.createElementBlock("span",{key:String(N.value),class:"ms-chip mfs-inline-flex mfs-items-center mfs-gap-1 mfs-bg-primary mfs-font-semibold mfs-pill"},[e.createElementVNode("span",zn,e.toDisplayString(N.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 ${N.label}`,onClick:e.withModifiers(F=>$(N.value),["stop"])},[...S[1]||(S[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,Ln))]))),128)),u.value.length===0?(e.openBlock(),e.createElementBlock("span",Tn,e.toDisplayString(t.placeholder),1)):e.createCommentVNode("",!0)]),t.loading?(e.openBlock(),e.createElementBlock("span",In)):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":d.value}])},[...S[2]||(S[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],40,Mn),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ms-pop"},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:i,role:"listbox","aria-multiselectable":"true",style:e.normalizeStyle(e.unref(k)),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",Pn,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:c,"onUpdate:modelValue":S[0]||(S[0]=N=>n.value=N),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(w,["escape"])},null,544),[[e.vModelText,n.value]])])):e.createCommentVNode("",!0),t.selectAll&&m.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:V},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":b.value}])},[b.value?(e.openBlock(),e.createElementBlock("svg",Rn,[...S[3]||(S[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),S[4]||(S[4]=e.createElementVNode("span",null,"Select All",-1))])):e.createCommentVNode("",!0),e.createElementVNode("div",Fn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(N,F)=>(e.openBlock(),e.createElementBlock("button",{key:String(N.value)+F,type:"button",role:"option","aria-selected":g(N.value),disabled:N.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":g(N.value)}]),onClick:H=>_(N)},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":g(N.value)}])},[g(N.value)?(e.openBlock(),e.createElementBlock("svg",jn,[...S[5]||(S[5]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),e.createElementVNode("span",null,e.toDisplayString(N.label),1)],10,An))),128)),t.loading&&f.value.length===0?(e.openBlock(),e.createElementBlock("div",Kn,[...S[6]||(S[6]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):f.value.length===0?(e.openBlock(),e.createElementBlock("div",On,[e.renderSlot(C.$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",Un,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Hn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-196f1d68"]]),Wn={key:0,class:"mfs-flex mfs-justify-between mfs-items-center mfs-text-sm"},Gn={class:"mfs-font-semibold mfs-text"},qn={class:"slider-readout mfs-text-primary mfs-font-semibold"},Yn=["aria-valuemin","aria-valuemax","aria-valuenow"],Xn={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},Zn=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],Jn={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},ve=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.computed(()=>typeof l.modelValue=="number"?l.modelValue:l.min),c=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[0]:l.min),d=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[1]:l.max),n=B=>{const w=l.max-l.min;return w<=0?0:Math.max(0,Math.min(100,(B-l.min)/w*100))},k=e.computed(()=>{if(l.range){const B=n(c.value),w=n(d.value);return{left:`${B}%`,width:`${Math.max(0,w-B)}%`}}return{left:"0%",width:`${n(i.value)}%`}}),h=B=>{const w=Math.max(l.min,Math.min(l.max,B)),_=Math.round((w-l.min)/l.step)*l.step+l.min;return Math.max(l.min,Math.min(l.max,Number(_.toFixed(6))))},y=B=>{var $;const w=($=a.value)==null?void 0:$.getBoundingClientRect();if(!w||w.width===0)return l.min;const _=Math.max(0,Math.min(1,(B-w.left)/w.width));return h(l.min+_*(l.max-l.min))},f=(B,w)=>{if(l.range){const _=[c.value,d.value];B===0?_[0]=Math.min(w,_[1]):_[1]=Math.max(w,_[0]),o("update:modelValue",_)}else o("update:modelValue",w)},p=B=>{r.value!==null&&f(r.value,y(B.clientX))},m=()=>{r.value!==null&&(r.value=null,o("change",l.modelValue)),window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",m)},u=(B,w)=>{l.disabled||(w.preventDefault(),r.value=B,window.addEventListener("pointermove",p),window.addEventListener("pointerup",m))},b=B=>{if(l.disabled)return;const w=y(B.clientX);let _=0;l.range&&(_=Math.abs(w-c.value)<=Math.abs(w-d.value)?0:1),f(_,w),u(_,B)},g=(B,w)=>{if(l.disabled)return;const _=w.key==="ArrowRight"||w.key==="ArrowUp"?l.step:w.key==="ArrowLeft"||w.key==="ArrowDown"?-l.step:0;if(!_)return;w.preventDefault();const $=l.range?B===0?c.value:d.value:i.value;f(B,h($+_)),o("change",l.modelValue)};return e.onBeforeUnmount(m),(B,w)=>(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",Wn,[e.createElementVNode("span",Gn,e.toDisplayString(t.label),1),e.createElementVNode("span",qn,e.toDisplayString(t.range&&Array.isArray(t.modelValue)?`${t.modelValue[0]} – ${t.modelValue[1]}`:i.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"trackRef",ref:a,class:"slider-track mfs-relative mfs-surface mfs-pill mfs-shadow-inset mfs-cursor-pointer",onPointerdown:b},[e.createElementVNode("div",{class:"slider-fill mfs-absolute mfs-pill mfs-bg-primary",style:e.normalizeStyle(k.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:`${n(c.value)}%`}),"aria-valuemin":t.min,"aria-valuemax":d.value,"aria-valuenow":c.value,"aria-label":"Minimum value",onPointerdown:w[0]||(w[0]=e.withModifiers(_=>u(0,_),["stop"])),onKeydown:w[1]||(w[1]=_=>g(0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",Xn,e.toDisplayString(c.value),1)):e.createCommentVNode("",!0)],46,Yn)):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:`${n(t.range?d.value:i.value)}%`}),"aria-valuemin":t.range?c.value:t.min,"aria-valuemax":t.max,"aria-valuenow":t.range?d.value:i.value,"aria-label":t.range?"Maximum value":t.label||"Slider",onPointerdown:w[2]||(w[2]=e.withModifiers(_=>u(t.range?1:0,_),["stop"])),onKeydown:w[3]||(w[3]=_=>g(t.range?1:0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",Jn,e.toDisplayString(t.range?d.value:i.value),1)):e.createCommentVNode("",!0)],46,Zn)],544)],2))}}),[["__scopeId","data-v-755740d4"]]),Qn={key:0,class:"rating-label mfs-text"},vn=["aria-label","aria-valuemax","aria-valuenow"],ea=["disabled","aria-label","onMousemove","onClick"],ta={viewBox:"0 0 24 24",width:"24",height:"24",class:"rating-svg"},la=["id"],oa=["fill","stroke"],et=L(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:s}){const l=t,o=s,a=`mfs-star-${e.useId()}`,r=e.ref(null),i=e.computed(()=>r.value!==null?r.value:l.modelValue),c=(f,p)=>{if(!l.allowHalf)return f;const m=p.currentTarget.getBoundingClientRect();return p.clientX-m.left<m.width/2?f-.5:f},d=(f,p)=>{l.disabled||l.readonly||(r.value=c(f,p))},n=(f,p)=>{if(l.disabled||l.readonly)return;const m=c(f,p);o("update:modelValue",m),o("change",m)},k=f=>{if(l.disabled||l.readonly)return;const p=l.allowHalf?.5:1;if(f.key==="ArrowRight"||f.key==="ArrowUp"){f.preventDefault();const m=Math.min(l.stars,l.modelValue+p);o("update:modelValue",m),o("change",m)}else if(f.key==="ArrowLeft"||f.key==="ArrowDown"){f.preventDefault();const m=Math.max(0,l.modelValue-p);o("update:modelValue",m),o("change",m)}},h=f=>{const p=i.value;return p>=f?"var(--warning, #f59e0b)":l.allowHalf&&p>=f-.5?`url(#${a}-${f})`:"transparent"},y=f=>i.value>=f-.5?"var(--warning, #f59e0b)":"var(--text-muted, #94a3b8)";return(f,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",Qn,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]=m=>r.value=null),onKeydown:k},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.stars,m=>(e.openBlock(),e.createElementBlock("button",{key:m,type:"button",class:"rating-star",disabled:t.disabled,"aria-label":`Rate ${m} of ${t.stars}`,onMousemove:u=>d(m,u),onClick:u=>n(m,u)},[(e.openBlock(),e.createElementBlock("svg",ta,[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`${a}-${m}`,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,la)]),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:h(m),stroke:y(m),"stroke-width":"1.8","stroke-linejoin":"round"},null,8,oa)]))],40,ea))),128))],40,vn)],2))}}),[["__scopeId","data-v-2a8aa484"]]),na={key:0,class:"cp-label mfs-text mfs-text-sm mfs-font-semibold"},aa={class:"cp-container mfs-relative"},sa=["disabled","aria-expanded"],ra={class:"cp-hex mfs-font-mono"},ia={class:"cp-native-row mfs-flex mfs-items-center mfs-gap-2"},da=["value"],ca=["value"],ma={class:"cp-rgb mfs-grid mfs-grid-cols-3 mfs-gap-1-5"},fa={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},pa=["value"],ua={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},ka=["value"],ha={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},ga=["value"],ya={key:0,class:"cp-presets mfs-grid mfs-grid-cols-4 mfs-gap-2"},ba=["aria-label","onClick"],tt=L(e.defineComponent({__name:"ColorPicker",props:{modelValue:{default:"#8b5cf6"},presets:{default:()=>["#8b5cf6","#38bdf8","#10b981","#f59e0b","#f43f5e","#ec4899","#64748b","#0f172a"]},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=J(a,r,i,{offset:8}),n=e.computed(()=>/^#[0-9a-fA-F]{6}$/.test(l.modelValue)?l.modelValue:"#8b5cf6"),k=e.computed(()=>{const b=n.value.slice(1);return{r:parseInt(b.slice(0,2),16),g:parseInt(b.slice(2,4),16),b:parseInt(b.slice(4,6),16)}}),h=b=>{o("update:modelValue",b),o("change",b)},y=b=>{const g=b.startsWith("#")?b:`#${b}`;/^#[0-9a-fA-F]{6}$/.test(g)&&h(g.toLowerCase())},f=b=>Math.max(0,Math.min(255,b)).toString(16).padStart(2,"0"),p=(b,g)=>{const B=Number(g.target.value);if(Number.isNaN(B))return;const w={...k.value,[b]:B};h(`#${f(w.r)}${f(w.g)}${f(w.b)}`)},m=b=>{i.value&&!d(b.target)&&(i.value=!1)},u=b=>{b.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",m),document.addEventListener("keydown",u)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",m),document.removeEventListener("keydown",u)}),(b,g)=>(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",na,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",aa,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,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":i.value,"aria-label":"Pick a color",onClick:g[0]||(g[0]=B=>i.value=!i.value)},[e.createElementVNode("span",{class:"cp-swatch mfs-rounded-full",style:e.normalizeStyle({backgroundColor:t.modelValue})},null,4),e.createElementVNode("span",ra,e.toDisplayString(t.modelValue.toUpperCase()),1)],8,sa),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cp-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),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",ia,[e.createElementVNode("input",{type:"color",class:"cp-native mfs-p-0 mfs-border-none mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer",value:n.value,"aria-label":"Color palette",onInput:g[1]||(g[1]=B=>y(B.target.value))},null,40,da),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:g[2]||(g[2]=B=>y(B.target.value))},null,40,ca)]),e.createElementVNode("div",ma,[e.createElementVNode("label",fa,[g[6]||(g[6]=e.createElementVNode("span",null,"R",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:k.value.r,onInput:g[3]||(g[3]=B=>p("r",B))},null,40,pa)]),e.createElementVNode("label",ua,[g[7]||(g[7]=e.createElementVNode("span",null,"G",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:k.value.g,onInput:g[4]||(g[4]=B=>p("g",B))},null,40,ka)]),e.createElementVNode("label",ha,[g[8]||(g[8]=e.createElementVNode("span",null,"B",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:k.value.b,onInput:g[5]||(g[5]=B=>p("b",B))},null,40,ga)])]),t.presets.length?(e.openBlock(),e.createElementBlock("div",ya,[(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()===n.value.toLowerCase()}]),style:e.normalizeStyle({backgroundColor:B}),"aria-label":`Select color ${B}`,onClick:w=>h(B)},null,14,ba))),128))])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:1})]))])],2))}}),[["__scopeId","data-v-5c82328d"]]),Ba={key:0,class:"dp-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},_a={key:0,class:"dp-required mfs-text-danger"},wa={class:"dp-container mfs-relative"},Ea=["disabled","aria-expanded","aria-invalid"],$a={class:"dp-header mfs-flex mfs-items-center mfs-justify-between"},Va={class:"dp-month-year mfs-font-bold mfs-text"},Ca={class:"dp-weekdays"},xa=["disabled","onClick"],Na={key:1,class:"dp-msg dp-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Sa={key:2,class:"dp-msg mfs-caption mfs-m-0"},ge=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=J(a,r,i,{offset:8}),n=new Date,k=T=>{if(!T)return null;const K=T instanceof Date?new Date(T.getTime()):new Date(T);return Number.isNaN(K.getTime())?null:new Date(K.getFullYear(),K.getMonth(),K.getDate())},h=e.computed(()=>Array.isArray(l.modelValue)?k(l.modelValue[0])||n:k(l.modelValue)||n),y=e.ref(h.value.getFullYear()),f=e.ref(h.value.getMonth()),p=e.ref(null),m=["Su","Mo","Tu","We","Th","Fr","Sa"],u=["January","February","March","April","May","June","July","August","September","October","November","December"],b=e.computed(()=>u[f.value]),g=T=>{const K=new Date(y.value,f.value+T,1);y.value=K.getFullYear(),f.value=K.getMonth()},B=e.computed(()=>{const K=new Date(y.value,f.value,1).getDay(),P=[];for(let I=0;I<42;I++){const M=new Date(y.value,f.value,1-K+I);P.push({key:`${M.getFullYear()}-${M.getMonth()}-${M.getDate()}`,date:M,inMonth:M.getMonth()===f.value})}return P}),w=(T,K)=>!!(T&&K&&T.getFullYear()===K.getFullYear()&&T.getMonth()===K.getMonth()&&T.getDate()===K.getDate()),_=e.computed(()=>k(l.min)),$=e.computed(()=>k(l.max)),V=T=>!!(_.value&&T<_.value||$.value&&T>$.value),E=e.computed(()=>!l.range&&!Array.isArray(l.modelValue)?k(l.modelValue):null),C=e.computed(()=>l.range?p.value?[p.value,null]:Array.isArray(l.modelValue)?[k(l.modelValue[0]),k(l.modelValue[1])]:[null,null]:[null,null]),S=T=>{if(!l.range)return w(T,E.value);const[K,P]=C.value;return w(T,K)||w(T,P)},N=T=>{if(!l.range)return!1;const[K,P]=C.value;return!!(K&&P&&T>K&&T<P)},F=T=>T?`${T.getFullYear()}-${String(T.getMonth()+1).padStart(2,"0")}-${String(T.getDate()).padStart(2,"0")}`:"",H=e.computed(()=>{if(!l.range)return F(E.value);if(Array.isArray(l.modelValue)){const T=F(k(l.modelValue[0])),K=F(k(l.modelValue[1]));return T&&K?`${T} – ${K}`:T}return""}),z=T=>{if(!V(T)){if(!l.range){o("update:modelValue",T),o("change",T),i.value=!1;return}if(!p.value)p.value=T;else{const K=T<p.value?[T,p.value]:[p.value,T];p.value=null,o("update:modelValue",K),o("change",K),i.value=!1}}},j=T=>{d(T.target)||(i.value=!1)},W=T=>{T.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",j),document.addEventListener("keydown",W)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",j),document.removeEventListener("keydown",W)}),(T,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",Ba,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",_a,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",wa,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,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":i.value,"aria-invalid":!!t.error,onClick:K[0]||(K[0]=P=>i.value=!i.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-cbbd3b1e><rect x="3" y="4" width="18" height="18" rx="2" ry="2" data-v-cbbd3b1e></rect><line x1="16" y1="2" x2="16" y2="6" data-v-cbbd3b1e></line><line x1="8" y1="2" x2="8" y2="6" data-v-cbbd3b1e></line><line x1="3" y1="10" x2="21" y2="10" data-v-cbbd3b1e></line></svg>',1)),e.createElementVNode("span",{class:e.normalizeClass(["dp-value",{"dp-value--placeholder mfs-text-muted":!H.value}])},e.toDisplayString(H.value||t.placeholder),3)],8,Ea),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"dp-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),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",$a,[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]=P=>g(-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",Va,e.toDisplayString(b.value)+" "+e.toDisplayString(y.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]=P=>g(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",Ca,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(m,P=>e.createElementVNode("span",{key:P,class:"dp-weekday mfs-text-center mfs-text-xs mfs-font-semibold mfs-text-muted mfs-py-1"},e.toDisplayString(P),1)),64))]),e.createVNode(e.Transition,{name:"dp-fade",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("div",{key:`${y.value}-${f.value}`,class:"dp-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,P=>(e.openBlock(),e.createElementBlock("button",{key:P.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":!P.inMonth,"dp-day--selected":S(P.date),"dp-day--in-range":N(P.date),"dp-day--today":w(P.date,e.unref(n))}]),disabled:V(P.date),onClick:I=>z(P.date)},e.toDisplayString(P.date.getDate()),11,xa))),128))]))]),_:1})],4)):e.createCommentVNode("",!0)]),_:1})]))]),t.error?(e.openBlock(),e.createElementBlock("p",Na,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Sa,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-cbbd3b1e"]]),Ma=["role","aria-label"],Da=["src","alt"],za={key:1,class:"avatar__fallback"},La=["aria-label"],ye=L(e.defineComponent({__name:"Avatar",props:{src:{},alt:{},label:{},size:{default:"md"},shape:{default:"circle"},status:{}},setup(t){const s=t,l=e.ref(!1);e.watch(()=>s.src,()=>{l.value=!1});const o=e.computed(()=>s.src&&!l.value?s.src:""),a=()=>{l.value=!0},r=e.computed(()=>{const i=(s.label||s.alt||"").trim();if(!i)return"?";const c=i.split(/\s+/).filter(Boolean);return c.length===1?c[0].slice(0,2).toUpperCase():(c[0][0]+c[c.length-1][0]).toUpperCase()});return(i,c)=>(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:o.value?void 0:"img","aria-label":t.alt||t.label||"Avatar"},[o.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:o.value,alt:t.alt||t.label||"Avatar",class:"avatar__img",onError:a},null,40,Da)):(e.openBlock(),e.createElementBlock("span",za,[e.renderSlot(i.$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,La)):e.createCommentVNode("",!0)],10,Ma))}}),[["__scopeId","data-v-05a4906f"]]),Ta=["role","tabindex","aria-pressed","onKeydown"],Ia={key:0,class:"chip__prepend"},Pa={class:"chip__label"},de=L(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:s}){const l=t,o=s,a=r=>{l.clickable&&o("click",r)};return(r,i)=>(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:a,onKeydown:[e.withKeys(a,["enter"]),e.withKeys(e.withModifiers(a,["prevent"]),["space"])]},[r.$slots.prepend?(e.openBlock(),e.createElementBlock("span",Ia,[e.renderSlot(r.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",Pa,[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:i[0]||(i[0]=e.withModifiers(c=>o("remove"),["stop"]))},[...i[1]||(i[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,Ta))}}),[["__scopeId","data-v-1d8fa890"]]),Ra=["aria-orientation"],Fa={key:0,class:"divider__label mfs-caption"},lt=L(e.defineComponent({__name:"Divider",props:{orientation:{default:"horizontal"},align:{default:"center"},dashed:{type:Boolean,default:!1}},setup(t){const s=e.useSlots(),l=e.computed(()=>!!s.default);return(o,a)=>(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",Fa,[e.renderSlot(o.$slots,"default",{},void 0,!0)])):e.createCommentVNode("",!0)],10,Ra))}}),[["__scopeId","data-v-2cc4685f"]]),Aa={class:"accordion mfs-flex mfs-flex-col mfs-gap-3 mfs-w-full"},ja=["aria-expanded","aria-controls","disabled","onClick"],Ka={class:"accordion__title mfs-title"},Oa=["id"],Ua={class:"accordion__body mfs-overflow-hidden"},Ha={key:0,class:"accordion__text mfs-text-muted"},ot=L(e.defineComponent({__name:"Accordion",props:{items:{default:()=>[]},multiple:{type:Boolean,default:!1},modelValue:{default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=n=>n==null?[]:Array.isArray(n)?n:[n],r=e.ref(a(l.modelValue));e.watch(()=>l.modelValue,n=>{n!==void 0&&(r.value=a(n))});const i=e.computed(()=>l.modelValue!==void 0?a(l.modelValue):r.value),c=n=>i.value.includes(n),d=n=>{const k=c(n);let h;l.multiple?h=k?i.value.filter(f=>f!==n):[...i.value,n]:h=k?[]:[n],r.value=h;const y=l.multiple?h:h[0]??null;o("update:modelValue",y),o("change",y)};return(n,k)=>(e.openBlock(),e.createElementBlock("div",Aa,[t.items.length?e.createCommentVNode("",!0):e.renderSlot(n.$slots,"default",{},void 0,!0,0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,h=>(e.openBlock(),e.createElementBlock("div",{key:h.key,class:e.normalizeClass(["accordion__item","mfs-surface","mfs-rounded","mfs-shadow","mfs-overflow-hidden",{"is-open":c(h.key),"is-disabled mfs-disabled":h.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":c(h.key),"aria-controls":`acc-panel-${h.key}`,disabled:h.disabled,onClick:y=>d(h.key)},[e.createElementVNode("span",Ka,e.toDisplayString(h.title),1),k[0]||(k[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,ja),e.createElementVNode("div",{id:`acc-panel-${h.key}`,class:"accordion__panel",role:"region"},[e.createElementVNode("div",Ua,[e.renderSlot(n.$slots,"item",{item:h,open:c(h.key)},()=>[h.content?(e.openBlock(),e.createElementBlock("p",Ha,e.toDisplayString(h.content),1)):e.createCommentVNode("",!0)],!0)])],8,Oa)],2))),128))]))}}),[["__scopeId","data-v-91745f4e"]]),Wa=["aria-busy"],Ga={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},qa={key:1,class:"mfs-empty-state"},Ya={class:"timeline__rail mfs-flex mfs-flex-col mfs-items-center mfs-shrink-0","aria-hidden":"true"},Xa={key:0,class:"timeline__icon-text"},Za={key:0,class:"timeline__line mfs-flex-1 mfs-my-1"},Ja={class:"timeline__content mfs-surface mfs-rounded mfs-shadow-card mfs-flex-1 mfs-mb-4"},Qa={class:"timeline__header mfs-flex mfs-justify-between mfs-gap-2-5 mfs-flex-wrap"},va={class:"timeline__title mfs-title mfs-m-0 mfs-font-bold"},es={key:0,class:"timeline__time mfs-caption"},ts={key:0,class:"timeline__desc mfs-text-muted mfs-m-0"},nt=L(e.defineComponent({__name:"Timeline",props:{items:{default:()=>[]},layout:{default:"vertical"},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},setup(t){return(s,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",Ga,[e.renderSlot(s.$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",qa,[e.renderSlot(s.$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,(o,a)=>(e.openBlock(),e.createElementBlock("li",{key:a,class:"timeline__item mfs-flex mfs-gap-4"},[e.createElementVNode("div",Ya,[e.createElementVNode("span",{class:e.normalizeClass(["timeline__dot","mfs-shadow","mfs-rounded-full","mfs-flex","mfs-items-center","mfs-justify-center",o.status==="surface"?"mfs-surface-subtle":`mfs-bg-${o.status||"primary"}`,`timeline__dot--${o.status||"primary"}`])},[e.renderSlot(s.$slots,"icon",{item:o,index:a},()=>[o.icon?(e.openBlock(),e.createElementBlock("span",Xa,e.toDisplayString(o.icon),1)):e.createCommentVNode("",!0)],!0)],2),a<t.items.length-1?(e.openBlock(),e.createElementBlock("span",Za)):e.createCommentVNode("",!0)]),e.createElementVNode("div",Ja,[e.renderSlot(s.$slots,"item",{item:o,index:a},()=>[e.createElementVNode("div",Qa,[e.createElementVNode("h4",va,e.toDisplayString(o.title),1),o.timestamp?(e.openBlock(),e.createElementBlock("time",es,e.toDisplayString(o.timestamp),1)):e.createCommentVNode("",!0)]),o.description?(e.openBlock(),e.createElementBlock("p",ts,e.toDisplayString(o.description),1)):e.createCommentVNode("",!0)],!0)])]))),128))],2)):e.createCommentVNode("",!0)],10,Wa))}}),[["__scopeId","data-v-e4d2eafc"]]),ls=["aria-busy"],os={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ns={key:1,class:"mfs-empty-state"},as={key:2,class:"carousel__stage"},ss=["aria-hidden"],rs={class:"carousel__fallback mfs-text"},is=["disabled"],ds=["disabled"],cs={key:3,class:"carousel__indicators mfs-flex mfs-justify-center mfs-py-3"},ms={class:"carousel__dots mfs-surface-subtle mfs-pill mfs-blur",role:"tablist","aria-label":"Slide indicators"},fs=["aria-selected","aria-label","onClick"],at=L(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:s}){const l=t,o=s,a=e.ref(l.modelValue),r=e.ref(!1);let i=null,c=null;e.watch(()=>l.modelValue,u=>{u>=0&&u<l.items.length&&(a.value=u)});const d=u=>{const b=l.items.length;if(!b)return;let g=u;l.loop?g=(u+b)%b:g=Math.max(0,Math.min(b-1,u)),a.value=g,o("update:modelValue",g),o("change",g)},n=()=>d(a.value+1),k=()=>d(a.value-1),h=u=>{i=u.clientX},y=u=>{if(i===null)return;const b=u.clientX-i;i=null,Math.abs(b)>40&&(b<0?n():k())},f=()=>{i=null},p=()=>{c&&(clearInterval(c),c=null)},m=()=>{p(),l.autoplay&&l.items.length>1&&(c=setInterval(()=>{r.value||n()},l.interval))};return e.watch(()=>[l.autoplay,l.interval,l.items.length],m),e.onMounted(m),e.onBeforeUnmount(p),(u,b)=>(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:b[0]||(b[0]=g=>r.value=!0),onMouseleave:b[1]||(b[1]=g=>r.value=!1),onFocusin:b[2]||(b[2]=g=>r.value=!0),onFocusout:b[3]||(b[3]=g=>r.value=!1)},[t.loading?(e.openBlock(),e.createElementBlock("div",os,[e.renderSlot(u.$slots,"loading",{},()=>[b[4]||(b[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",ns,[e.renderSlot(u.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",as,[e.createElementVNode("div",{class:"carousel__viewport",onPointerdown:h,onPointerup:y,onPointercancel:f},[e.createElementVNode("div",{class:"carousel__track",style:e.normalizeStyle({transform:`translateX(-${a.value*100}%)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"carousel__slide","aria-hidden":B!==a.value},[e.renderSlot(u.$slots,"default",{item:g,index:B},()=>[e.createElementVNode("div",rs,e.toDisplayString(g),1)],!0)],8,ss))),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&&a.value===0,onClick:k},[...b[5]||(b[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,is),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&&a.value===t.items.length-1,onClick:n},[...b[6]||(b[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,ds)],64)):e.createCommentVNode("",!0)])),t.items.length>1?(e.openBlock(),e.createElementBlock("div",cs,[e.createElementVNode("div",ms,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>(e.openBlock(),e.createElementBlock("button",{key:B,type:"button",role:"tab","aria-selected":B===a.value,"aria-label":`Go to slide ${B+1}`,class:e.normalizeClass(["carousel__dot","mfs-focus-ring",{"is-active":B===a.value}]),onClick:w=>d(B)},null,10,fs))),128))])])):e.createCommentVNode("",!0)],42,ls))}}),[["__scopeId","data-v-a3ec7623"]]),ps={key:0,class:"mfs-image__placeholder","aria-hidden":"true"},us=["aria-label"],ks=["src","alt"],hs=["aria-label"],gs=["src","alt"],st=L(e.defineComponent({__name:"Image",props:{src:{},alt:{default:""},width:{},height:{},preview:{type:Boolean,default:!1},fit:{default:"cover"}},setup(t){const s=t,l=e.ref(!1),o=e.ref(!1),a=e.ref(!1),r=y=>y===void 0?void 0:typeof y=="number"?`${y}px`:y,i=e.computed(()=>({width:r(s.width),height:r(s.height)}));e.watch(()=>s.src,()=>{l.value=!1,o.value=!1});const c=()=>{l.value=!0,o.value=!1},d=()=>{l.value=!1,o.value=!0},n=y=>{y.key==="Escape"&&h()},k=()=>{s.preview&&l.value&&!o.value&&(a.value=!0,window.addEventListener("keydown",n))},h=()=>{a.value=!1,window.removeEventListener("keydown",n)};return e.onBeforeUnmount(()=>{window.removeEventListener("keydown",n)}),(y,f)=>(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&&!o.value}]),style:e.normalizeStyle(i.value),onClick:k},[!l.value&&!o.value?(e.openBlock(),e.createElementBlock("div",ps)):e.createCommentVNode("",!0),o.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"},[...f[1]||(f[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,us)):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:c,onError:d},null,46,ks),[[e.vShow,!o.value]]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"img-fade"},{default:e.withCtx(()=>[a.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:h},[e.createElementVNode("button",{type:"button",class:"mfs-image__close","aria-label":"Close preview",onClick:e.withModifiers(h,["stop"])},[...f[2]||(f[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:f[0]||(f[0]=e.withModifiers(()=>{},["stop"]))},null,8,gs)],8,hs)):e.createCommentVNode("",!0)]),_:1})]))],6))}}),[["__scopeId","data-v-66fca7b1"]]),v=e.ref([]),ee=new Map;let ys=0;function Ie(t){const s=ee.get(t);s!=null&&s.timerId&&(clearTimeout(s.timerId),s.timerId=null)}function bs(t,s){if(s<=0)return;Ie(t);const l=setTimeout(()=>{Pe(t)},s);ee.set(t,{timerId:l,remaining:s,startedAt:Date.now()})}function Pe(t){Ie(t),ee.delete(t),v.value=v.value.filter(s=>s.id!==t)}function Bs(t){const s=ee.get(t);!s||!s.timerId||(clearTimeout(s.timerId),s.timerId=null,s.remaining=Math.max(0,s.remaining-(Date.now()-s.startedAt)))}function _s(t){const s=ee.get(t);!s||s.timerId||s.remaining<=0||(s.startedAt=Date.now(),s.timerId=setTimeout(()=>{Pe(t)},s.remaining))}function rt(t){const s=t.id??`mfs-toast-${++ys}`,l=t.duration??4e3,o={id:s,title:t.title,message:t.message,severity:t.severity??"info",duration:l,closable:t.closable??!0},a=v.value.findIndex(r=>r.id===s);return a!==-1?v.value.splice(a,1,o):v.value.push(o),l>0&&bs(s,l),s}function ws(){for(const t of ee.keys())Ie(t);ee.clear(),v.value=[]}function it(){return{toasts:e.readonly(v),add:rt,show:rt,remove:Pe,clear:ws,pause:Bs,resume:_s}}const Es=["role","onMouseenter","onMouseleave","onFocusin","onFocusout"],$s={class:"mfs-toast__icon mfs-shrink-0","aria-hidden":"true"},Vs={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Cs={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},xs={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ns={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ss={class:"mfs-toast__body mfs-flex-1 mfs-min-w-0"},Ms={key:0,class:"mfs-toast__title mfs-title mfs-font-bold"},Ds={class:"mfs-toast__message mfs-text-muted mfs-text-sm"},zs=["onClick"],dt=L(e.defineComponent({__name:"Toast",props:{position:{default:"top-right"},max:{}},setup(t){const s=t,{toasts:l,remove:o,pause:a,resume:r}=it(),i=e.computed(()=>s.max&&s.max>0?l.value.slice(-s.max):l.value);return(c,d)=>(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(i.value,n=>(e.openBlock(),e.createElementBlock("div",{key:n.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--${n.severity}`]]),role:n.severity==="danger"||n.severity==="warning"?"alert":"status","aria-live":"polite",onMouseenter:k=>e.unref(a)(n.id),onMouseleave:k=>e.unref(r)(n.id),onFocusin:k=>e.unref(a)(n.id),onFocusout:k=>e.unref(r)(n.id)},[e.createElementVNode("span",$s,[n.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Vs,[...d[0]||(d[0]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):n.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",Cs,[...d[1]||(d[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)])])):n.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",xs,[...d[2]||(d[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",Ns,[...d[3]||(d[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",Ss,[n.title?(e.openBlock(),e.createElementBlock("div",Ms,e.toDisplayString(n.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Ds,e.toDisplayString(n.message),1)]),n.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:k=>e.unref(o)(n.id)},[...d[4]||(d[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,Es))),128))]),_:1})],2)]))}}),[["__scopeId","data-v-e95e4289"]]),Ls={class:"mfs-alert__icon","aria-hidden":"true"},Ts={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Is={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ps={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Rs={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Fs={class:"mfs-alert__content"},As={key:0,class:"mfs-alert__title mfs-title"},js={class:"mfs-alert__body mfs-text-muted"},be=L(e.defineComponent({__name:"Alert",props:{severity:{default:"info"},title:{},closable:{type:Boolean,default:!1}},emits:["close"],setup(t,{emit:s}){const l=s;return(o,a)=>(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",Ls,[e.renderSlot(o.$slots,"icon",{},()=>[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Ts,[...a[1]||(a[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",Is,[...a[2]||(a[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",Ps,[...a[3]||(a[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",Rs,[...a[4]||(a[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",Fs,[t.title?(e.openBlock(),e.createElementBlock("div",As,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",js,[e.renderSlot(o.$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:a[0]||(a[0]=r=>l("close"))},[...a[5]||(a[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-17471fb4"]]),Ks=["aria-describedby"],Os=["id"],ct=L(e.defineComponent({__name:"Tooltip",props:{content:{default:""},placement:{default:"top"},disabled:{type:Boolean,default:!1}},setup(t){const s=t,l=e.ref(!1),o=e.useId(),a=()=>{!s.disabled&&s.content&&(l.value=!0)},r=()=>{l.value=!1};return(i,c)=>(e.openBlock(),e.createElementBlock("span",{class:"mfs-relative mfs-inline-flex mfs-items-center",onMouseenter:a,onMouseleave:r,onFocusin:a,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(o):void 0},[e.renderSlot(i.$slots,"default",{},void 0,!0)],8,Ks),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(o),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),c[0]||(c[0]=e.createElementVNode("span",{class:"mfs-tooltip__arrow mfs-absolute","aria-hidden":"true"},null,-1))],10,Os)):e.createCommentVNode("",!0)]),_:1})],32))}}),[["__scopeId","data-v-41e6fd61"]]),Us=["aria-label"],Hs={key:0,class:"mfs-drawer__header mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},Ws={class:"mfs-drawer__title mfs-title mfs-m-0 mfs-font-bold"},Gs={class:"mfs-drawer__body mfs-flex-1 mfs-p-5 mfs-overflow-y-auto"},qs={key:1,class:"mfs-drawer__footer mfs-border-t mfs-flex mfs-justify-end mfs-gap-2-5"},Be=L(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:s}){const l=t,o=s,a=e.computed(()=>l.position==="left"||l.position==="right"),r=e.computed(()=>a.value?{width:l.size,maxWidth:"100vw",height:"100%"}:{height:l.size,maxHeight:"100vh",width:"100%"}),i=()=>{o("update:modelValue",!1),o("close")},c=()=>{l.closeOnBackdrop&&i()},d=y=>{y.key==="Escape"&&l.modelValue&&i()};let n="",k=!1;const h=y=>{if(!(typeof document>"u"))if(y){if(k)return;n=document.body.style.overflow,document.body.style.overflow="hidden",document.addEventListener("keydown",d),k=!0}else k&&(document.body.style.overflow=n,document.removeEventListener("keydown",d),k=!1)};return e.onMounted(()=>{l.modelValue&&h(!0)}),e.watch(()=>l.modelValue,y=>h(y)),e.onBeforeUnmount(()=>{h(!1)}),(y,f)=>(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:c},[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:f[0]||(f[0]=e.withModifiers(()=>{},["stop"]))},[t.title||y.$slots.header?(e.openBlock(),e.createElementBlock("div",Hs,[e.renderSlot(y.$slots,"header",{},()=>[e.createElementVNode("h3",Ws,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:i},[...f[1]||(f[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",Gs,[e.renderSlot(y.$slots,"default",{},void 0,!0)]),y.$slots.footer?(e.openBlock(),e.createElementBlock("div",qs,[e.renderSlot(y.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],14,Us)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-1d638027"]]),Ys={class:"mfs-popover-wrapper"},Xs=["aria-expanded"],_e=L(e.defineComponent({__name:"Popover",props:{modelValue:{type:Boolean,default:void 0},placement:{default:"bottom"}},emits:["update:modelValue"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),c=e.computed(()=>l.modelValue!==void 0),d=e.computed(()=>c.value?!!l.modelValue:i.value),{overlayStyle:n,containsTarget:k}=J(a,r,d,{offset:10,align:"center"}),h=b=>{c.value||(i.value=b),o("update:modelValue",b)},y=()=>h(!d.value),f=()=>h(!1),p=b=>{k(b.target)||f()},m=b=>{b.key==="Escape"&&f()},u=b=>{typeof document>"u"||(b?(document.addEventListener("pointerdown",p),document.addEventListener("keydown",m)):(document.removeEventListener("pointerdown",p),document.removeEventListener("keydown",m)))};return e.watch(d,b=>u(b),{immediate:!0}),e.onBeforeUnmount(()=>{u(!1)}),(b,g)=>(e.openBlock(),e.createElementBlock("div",Ys,[e.createElementVNode("div",{ref_key:"triggerRef",ref:a,class:"mfs-popover__trigger","aria-expanded":d.value,"aria-haspopup":"dialog",onClick:y},[e.renderSlot(b.$slots,"trigger",{open:d.value,toggle:y},void 0,!0)],8,Xs),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-popover"},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(n)),class:e.normalizeClass(["mfs-popover mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur",[`mfs-popover--${t.placement}`]]),role:"dialog"},[e.renderSlot(b.$slots,"default",{close:f},void 0,!0)],6)):e.createCommentVNode("",!0)]),_:3})]))]))}}),[["__scopeId","data-v-cd2807a7"]]),mt=L(e.defineComponent({__name:"Skeleton",props:{variant:{default:"text"},width:{},height:{},lines:{default:1},animated:{type:Boolean,default:!0}},setup(t){const s=t,l=e.computed(()=>s.variant!=="text"?1:Math.max(1,Math.floor(s.lines))),o=a=>{const r=s.variant==="text"&&l.value>1&&a===l.value,i=s.variant==="circle"?"48px":r?"72%":"100%",c=s.variant==="circle"?s.width??"48px":s.variant==="text"?"14px":"80px";return{width:r&&!s.width?"72%":s.width??i,height:s.height??c}};return(a,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,i=>(e.openBlock(),e.createElementBlock("div",{key:i,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(o(i))},null,6))),128))],2))}}),[["__scopeId","data-v-ac23abe4"]]),Zs={class:"mfs-progress"},Js=["aria-valuenow"],Qs={key:0,class:"mfs-progress__label mfs-caption"},ft=L(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 s=t,l=e.computed(()=>Math.min(100,Math.max(0,s.value)));return(o,a)=>(e.openBlock(),e.createElementBlock("div",Zs,[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,Js),t.showValue&&!t.indeterminate?(e.openBlock(),e.createElementBlock("span",Qs,e.toDisplayString(Math.round(l.value))+"% ",1)):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-9a84cdec"]]),vs={class:"mfs-spinner__svg",viewBox:"0 0 50 50"},er=["stroke-width"],tr=["stroke-width"],pt=L(e.defineComponent({__name:"ProgressSpinner",props:{size:{default:"md"},strokeWidth:{default:4},variant:{default:"primary"}},setup(t){const s=t,l={sm:"22px",md:"36px",lg:"52px"},o=e.computed(()=>typeof s.size=="number"?`${s.size}px`:l[s.size]);return(a,r)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["mfs-spinner mfs-text",[`mfs-spinner--${t.variant}`]]),style:e.normalizeStyle({width:o.value,height:o.value}),role:"status","aria-label":"Loading"},[(e.openBlock(),e.createElementBlock("svg",vs,[e.createElementVNode("circle",{class:"mfs-spinner__track",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth},null,8,er),e.createElementVNode("circle",{class:"mfs-spinner__ring",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,tr)]))],6))}}),[["__scopeId","data-v-fcb783c0"]]),we=e.ref({isOpen:!1,options:null});let ae=null;function ut(t){var o,a;const s=we.value.options,l=ae;ae=null,we.value={isOpen:!1,options:null},t?(o=s==null?void 0:s.onAccept)==null||o.call(s):(a=s==null?void 0:s.onReject)==null||a.call(s),l==null||l(t)}function lr(t){return ae&&(ae(!1),ae=null),we.value={isOpen:!0,options:{confirmLabel:"Confirm",cancelLabel:"Cancel",variant:"primary",...t}},new Promise(s=>{ae=s})}function kt(){return{state:e.readonly(we),confirm:lr,accept:()=>ut(!0),reject:()=>ut(!1)}}const or=["aria-labelledby","aria-describedby"],nr={class:"mfs-confirm__header"},ar=["id"],sr=["id"],rr={class:"mfs-flex mfs-justify-end mfs-gap-2-5 mfs-flex-wrap"},ht=L(e.defineComponent({__name:"ConfirmDialog",setup(t){const{state:s,accept:l,reject:o}=kt(),a=e.useId(),r=e.useId(),i=c=>{c.key==="Escape"&&s.value.isOpen&&o()};return e.watch(()=>s.value.isOpen,c=>{typeof document>"u"||(c?document.addEventListener("keydown",i):document.removeEventListener("keydown",i))},{immediate:!0}),e.onBeforeUnmount(()=>{typeof document<"u"&&document.removeEventListener("keydown",i)}),(c,d)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-fade"},{default:e.withCtx(()=>[e.unref(s).isOpen&&e.unref(s).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:d[3]||(d[3]=(...n)=>e.unref(o)&&e.unref(o)(...n))},[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(a),"aria-describedby":e.unref(r),onClick:d[2]||(d[2]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",nr,[e.createElementVNode("h3",{id:e.unref(a),class:"mfs-confirm__title mfs-title mfs-m-0"},e.toDisplayString(e.unref(s).options.title),9,ar)]),e.createElementVNode("p",{id:e.unref(r),class:"mfs-confirm__message mfs-text-muted"},e.toDisplayString(e.unref(s).options.message),9,sr),e.createElementVNode("div",rr,[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:d[0]||(d[0]=(...n)=>e.unref(o)&&e.unref(o)(...n))},e.toDisplayString(e.unref(s).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(s).options.variant??"primary"}`]]),onClick:d[1]||(d[1]=(...n)=>e.unref(l)&&e.unref(l)(...n))},e.toDisplayString(e.unref(s).options.confirmLabel??"Confirm"),3)])],8,or)])):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-cd6aa53d"]]),ir={class:"navbar__inner mfs-flex mfs-items-center mfs-justify-between mfs-gap-4"},dr={class:"navbar__brand mfs-flex mfs-items-center mfs-font-bold"},cr={class:"navbar__nav","aria-label":"Main navigation"},mr={class:"navbar__list mfs-flex mfs-items-center"},fr=["aria-current","onClick"],pr={class:"navbar__actions mfs-flex mfs-items-center"},ur=["aria-expanded"],kr={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"},hr={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"},gr={key:0,id:"navbar-mobile-drawer",class:"navbar__drawer",role:"region","aria-label":"Mobile navigation"},yr={class:"navbar__mobile-list mfs-flex mfs-flex-col"},br=["aria-current","onClick"],Ee=L(e.defineComponent({__name:"Navbar",props:{items:{default:()=>[]},sticky:{type:Boolean,default:!0},bordered:{type:Boolean,default:!0}},emits:["navigate"],setup(t,{emit:s}){const l=s,o=e.ref(!1),a=(c,d)=>{l("navigate",c,d)},r=(c,d)=>{o.value=!1,l("navigate",c,d)},i=c=>{c.key==="Escape"&&o.value&&(o.value=!1)};return e.onMounted(()=>{window.addEventListener("keydown",i)}),e.onUnmounted(()=>{window.removeEventListener("keydown",i)}),(c,d)=>(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",ir,[e.createElementVNode("div",dr,[e.renderSlot(c.$slots,"brand",{},void 0,!0)]),e.createElementVNode("nav",cr,[e.renderSlot(c.$slots,"links",{items:t.items,navigate:a},()=>[e.createElementVNode("ul",mr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,k)=>(e.openBlock(),e.createElementBlock("li",{key:k,class:"navbar__item"},[!n.to&&!n.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":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>a(n,h)},e.toDisplayString(n.label),11,fr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.to?"router-link":"a"),{key:1,to:n.to,href:n.href,class:e.normalizeClass(["navbar__link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-pill",{"navbar__link--active":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>a(n,h)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)]),e.createElementVNode("div",pr,[e.renderSlot(c.$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":o.value,"aria-controls":"navbar-mobile-drawer","aria-label":"Toggle navigation menu",onClick:d[0]||(d[0]=n=>o.value=!o.value)},[o.value?(e.openBlock(),e.createElementBlock("svg",hr,[...d[2]||(d[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",kr,[...d[1]||(d[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,ur)])]),e.createVNode(e.Transition,{name:"navbar-drawer"},{default:e.withCtx(()=>[o.value?(e.openBlock(),e.createElementBlock("div",gr,[e.renderSlot(c.$slots,"links",{items:t.items,navigate:r},()=>[e.createElementVNode("ul",yr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,k)=>(e.openBlock(),e.createElementBlock("li",{key:k},[!n.to&&!n.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":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>r(n,h)},e.toDisplayString(n.label),11,br)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.to?"router-link":"a"),{key:1,to:n.to,href:n.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":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>r(n,h)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)])):e.createCommentVNode("",!0)]),_:3})],2))}}),[["__scopeId","data-v-2b84fbe9"]]),Br={class:"tabs"},_r=["aria-selected","aria-disabled","disabled","tabindex","onClick"],wr={key:0,class:"tabs__panel",role:"tabpanel"},$e=L(e.defineComponent({__name:"Tabs",props:{items:{},modelValue:{},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=new Map,i=e.ref({left:0,width:0,ready:!1}),c=e.computed(()=>{var u;if(l.modelValue!==void 0)return l.modelValue;const m=l.items.find(b=>!b.disabled);return(m==null?void 0:m.key)??((u=l.items[0])==null?void 0:u.key)??""}),d=e.computed(()=>({transform:`translateX(${i.value.left}px)`,width:`${i.value.width}px`,opacity:i.value.ready&&i.value.width>0?1:0})),n=(m,u)=>{u?r.set(m,u):r.delete(m)},k=async(m=!1)=>{await e.nextTick();const u=r.get(c.value);if(!u){i.value={left:0,width:0,ready:!1};return}i.value={left:u.offsetLeft,width:u.offsetWidth,ready:!0},m&&l.scrollable&&u.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},h=(m,u)=>{m.disabled||m.key===c.value||(o("update:modelValue",m.key),o("change",m.key))},y=m=>{var B;const u=l.items.filter(w=>!w.disabled);if(!u.length)return;const b=u.findIndex(w=>w.key===c.value);let g=-1;if(m.key==="ArrowRight"?g=(b+1)%u.length:m.key==="ArrowLeft"?g=(b-1+u.length)%u.length:m.key==="Home"?g=0:m.key==="End"&&(g=u.length-1),g>=0){m.preventDefault();const w=u[g];h(w),(B=r.get(w.key))==null||B.focus()}};let f=null;e.watch(()=>[c.value,l.items],()=>k(!0),{deep:!0});const p=()=>k(!1);return e.onMounted(()=>{k(!1),typeof ResizeObserver<"u"&&a.value&&(f=new ResizeObserver(p),f.observe(a.value)),window.addEventListener("resize",p)}),e.onUnmounted(()=>{f==null||f.disconnect(),window.removeEventListener("resize",p)}),(m,u)=>(e.openBlock(),e.createElementBlock("div",Br,[e.createElementVNode("div",{ref_key:"listRef",ref:a,class:e.normalizeClass(["tabs__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tabs__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:y},[e.createElementVNode("span",{class:"tabs__indicator mfs-pill",style:e.normalizeStyle(d.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(b,g)=>(e.openBlock(),e.createElementBlock("button",{key:b.key,ref_for:!0,ref:B=>n(b.key,B),type:"button",role:"tab",class:e.normalizeClass(["tabs__tab mfs-pill mfs-bg-transparent",{"tabs__tab--active":b.key===c.value,"tabs__tab--disabled mfs-disabled":b.disabled}]),"aria-selected":b.key===c.value,"aria-disabled":b.disabled||void 0,disabled:b.disabled,tabindex:b.key===c.value?0:-1,onClick:B=>h(b)},[e.renderSlot(m.$slots,"tab",{item:b,active:b.key===c.value},()=>[e.createTextVNode(e.toDisplayString(b.label),1)],!0)],10,_r))),128))],34),m.$slots.default?(e.openBlock(),e.createElementBlock("div",wr,[e.renderSlot(m.$slots,"default",{activeKey:c.value},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-80912f0b"]]),Er={class:"breadcrumb mfs-surface mfs-pill mfs-inline-flex mfs-items-center","aria-label":"Breadcrumb"},$r={class:"breadcrumb__list mfs-flex mfs-flex-wrap mfs-items-center"},Vr={key:0,class:"breadcrumb__separator mfs-inline-flex mfs-items-center mfs-text-muted","aria-hidden":"true"},Cr={key:0},xr={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Nr=["aria-current"],Sr=["onClick"],gt=L(e.defineComponent({__name:"Breadcrumb",props:{items:{},separator:{default:"chevron"}},emits:["navigate"],setup(t,{emit:s}){const l=s;return(o,a)=>(e.openBlock(),e.createElementBlock("nav",Er,[e.createElementVNode("ol",$r,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(r,i)=>(e.openBlock(),e.createElementBlock("li",{key:i,class:"breadcrumb__item mfs-inline-flex mfs-items-center"},[i>0?(e.openBlock(),e.createElementBlock("span",Vr,[e.renderSlot(o.$slots,"separator",{},()=>[t.separator==="slash"?(e.openBlock(),e.createElementBlock("span",Cr,"/")):(e.openBlock(),e.createElementBlock("svg",xr,[...a[0]||(a[0]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])]))],!0)])):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"item",{item:r,isLast:i===t.items.length-1},()=>[i===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":i===t.items.length-1?"page":void 0},e.toDisplayString(r.label),11,Nr)):!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:c=>l("navigate",r,c)},e.toDisplayString(r.label),9,Sr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.to?"router-link":"a"),{key:2,to:r.to,href:r.href,class:"breadcrumb__link mfs-inline-flex mfs-items-center mfs-rounded-sm mfs-border-none mfs-font-medium mfs-text",onClick:c=>l("navigate",r,c)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.label),1)]),_:2},1032,["to","href","onClick"]))],!0)]))),128))])]))}}),[["__scopeId","data-v-79984457"]]),Mr=["aria-busy"],Dr={class:"pagination__controls"},zr=["disabled"],Lr=["disabled"],Tr={key:0,class:"pagination__ellipsis mfs-text-muted","aria-hidden":"true"},Ir=["disabled","aria-label","aria-current","onClick"],Pr=["disabled"],Rr=["disabled"],Fr={key:0,class:"pagination__extras"},Ar={key:0,class:"pagination__per-page"},jr=["value","disabled"],Kr=["value"],Or={class:"pagination__label mfs-text-muted"},Ur=["max","disabled"],ce=L(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:s}){const l=t,o=e.computed(()=>l.disabled||l.loading),a=s,r=e.ref(""),i=e.computed(()=>Math.max(1,Math.ceil(l.total/Math.max(1,l.perPage)))),c=e.computed(()=>Math.min(Math.max(1,l.modelValue),i.value)),d=e.computed(()=>{const y=i.value,f=c.value,p=l.siblingCount,m=p*2+5;if(y<=m)return Array.from({length:y},(_,$)=>$+1);const u=Math.max(f-p,1),b=Math.min(f+p,y),g=u>2,B=b<y-1,w=[1];if(g)w.push("ellipsis");else for(let _=2;_<u;_++)w.push(_);for(let _=Math.max(2,u);_<=Math.min(y-1,b);_++)w.push(_);if(B)w.push("ellipsis");else for(let _=b+1;_<y;_++)w.push(_);return y>1&&w.push(y),w}),n=y=>{if(o.value)return;const f=Math.min(Math.max(1,y),i.value);f!==c.value&&(a("update:modelValue",f),a("change",{page:f,perPage:l.perPage}))},k=y=>{if(o.value)return;const f=Number(y.target.value),p=Math.max(1,Math.ceil(l.total/Math.max(1,f))),m=Math.min(c.value,p);a("update:perPage",f),m!==c.value&&a("update:modelValue",m),a("change",{page:m,perPage:f})},h=()=>{if(o.value)return;const y=Number.parseInt(r.value,10);Number.isNaN(y)||n(y),r.value=""};return(y,f)=>(e.openBlock(),e.createElementBlock("nav",{class:"pagination mfs-row mfs-text","aria-label":"Pagination","aria-busy":t.loading||void 0},[e.createElementVNode("div",Dr,[e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value<=1,"aria-label":"First page",onClick:f[0]||(f[0]=p=>n(1))},[...f[5]||(f[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,zr),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value<=1,"aria-label":"Previous page",onClick:f[1]||(f[1]=p=>n(c.value-1))},[...f[6]||(f[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,Lr),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(p,m)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:m},[p==="ellipsis"?(e.openBlock(),e.createElementBlock("span",Tr," … ")):(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===c.value}]),disabled:o.value,"aria-label":`Page ${p}`,"aria-current":p===c.value?"page":void 0,onClick:u=>n(p)},e.toDisplayString(p),11,Ir))],64))),128)),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value>=i.value,"aria-label":"Next page",onClick:f[2]||(f[2]=p=>n(c.value+1))},[...f[7]||(f[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,Pr),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value>=i.value,"aria-label":"Last page",onClick:f[3]||(f[3]=p=>n(i.value))},[...f[8]||(f[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,Rr)]),t.perPageOptions.length||t.showJumpTo?(e.openBlock(),e.createElementBlock("div",Fr,[t.perPageOptions.length?(e.openBlock(),e.createElementBlock("label",Ar,[f[9]||(f[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:o.value,"aria-label":"Items per page",onChange:k},[(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,Kr))),128))],40,jr)])):e.createCommentVNode("",!0),t.showJumpTo?(e.openBlock(),e.createElementBlock("form",{key:1,class:"pagination__jump",onSubmit:e.withModifiers(h,["prevent"])},[e.createElementVNode("label",Or,[f[10]||(f[10]=e.createTextVNode(" Go ",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":f[4]||(f[4]=p=>r.value=p),type:"number",min:"1",max:i.value,disabled:o.value,class:"pagination__input mfs-surface mfs-rounded-md mfs-shadow-inset","aria-label":"Jump to page"},null,8,Ur),[[e.vModelText,r.value]])])],32)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],8,Mr))}}),[["__scopeId","data-v-81601b38"]]),Hr=["aria-current"],Wr=["onClick"],Gr={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},qr={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"},Yr={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"},Xr={key:2},Zr={class:"steps__content mfs-flex mfs-flex-col"},Jr={class:"steps__label mfs-font-semibold"},Qr={key:0,class:"steps__desc mfs-text-muted"},vr={key:1,class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md"},ei={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},ti={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"},li={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"},oi={key:2},ni={class:"steps__content mfs-flex mfs-flex-col"},ai={class:"steps__label mfs-font-semibold"},si={key:0,class:"steps__desc mfs-text-muted"},Ve=L(e.defineComponent({__name:"Steps",props:{items:{},modelValue:{default:0},clickable:{type:Boolean,default:!1},direction:{default:"responsive"}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=(i,c)=>i.status?i.status:c<l.modelValue?"completed":c===l.modelValue?"active":"upcoming",r=i=>{!l.clickable||i===l.modelValue||(o("update:modelValue",i),o("change",i))};return(i,c)=>(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,(d,n)=>(e.openBlock(),e.createElementBlock("li",{key:n,class:e.normalizeClass(["steps__item mfs-flex mfs-items-center mfs-gap-2",[`steps__item--${a(d,n)}`,{"steps__item--clickable":t.clickable}]]),"aria-current":a(d,n)==="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:k=>r(n)},[e.createElementVNode("span",Gr,[a(d,n)==="completed"?(e.openBlock(),e.createElementBlock("svg",qr,[...c[0]||(c[0]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):a(d,n)==="error"?(e.openBlock(),e.createElementBlock("svg",Yr,[...c[1]||(c[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",Xr,e.toDisplayString(n+1),1))]),e.createElementVNode("span",Zr,[e.createElementVNode("span",Jr,e.toDisplayString(d.label),1),d.description?(e.openBlock(),e.createElementBlock("span",Qr,e.toDisplayString(d.description),1)):e.createCommentVNode("",!0)])],8,Wr)):(e.openBlock(),e.createElementBlock("div",vr,[e.createElementVNode("span",ei,[a(d,n)==="completed"?(e.openBlock(),e.createElementBlock("svg",ti,[...c[2]||(c[2]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):a(d,n)==="error"?(e.openBlock(),e.createElementBlock("svg",li,[...c[3]||(c[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",oi,e.toDisplayString(n+1),1))]),e.createElementVNode("span",ni,[e.createElementVNode("span",ai,e.toDisplayString(d.label),1),d.description?(e.openBlock(),e.createElementBlock("span",si,e.toDisplayString(d.description),1)):e.createCommentVNode("",!0)])])),n<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":a(d,n)==="completed"}]),"aria-hidden":"true"},null,2)):e.createCommentVNode("",!0)],10,Hr))),128))],2))}}),[["__scopeId","data-v-b60b46b4"]]),ri={key:0,class:"ctx-menu__divider mfs-divider",role:"separator"},ii={key:1,role:"none"},di=["disabled","onClick"],ci={key:0,class:"ctx-menu__icon","aria-hidden":"true"},mi={class:"ctx-menu__label"},yt=L(e.defineComponent({__name:"ContextMenu",props:{items:{}},emits:["select","open","close"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.ref(!1),i=e.ref(null),c=e.ref({x:0,y:0}),d=new Map,n=(g,B)=>{B?d.set(g,B):d.delete(g)},k=()=>{r.value&&(r.value=!1,b(),a("close"))},h=async g=>{var w;r.value=!0,c.value={x:g.clientX,y:g.clientY},a("open"),await e.nextTick();const B=i.value;if(B){const _=B.getBoundingClientRect(),$=8,V=window.innerWidth-_.width-$,E=window.innerHeight-_.height-$;c.value={x:Math.max($,Math.min(g.clientX,V)),y:Math.max($,Math.min(g.clientY,E))};const C=o.items.findIndex(S=>!S.divider&&!S.disabled);C>=0&&((w=d.get(C))==null||w.focus())}u()},y=g=>{var B;g.disabled||((B=g.action)==null||B.call(g),a("select",g),k())},f=g=>{var $,V;const B=o.items.map((E,C)=>!E.divider&&!E.disabled?C:-1).filter(E=>E>=0);if(!B.length)return;const w=document.activeElement,_=B.findIndex(E=>d.get(E)===w);if(g.key==="ArrowDown"){g.preventDefault();const E=B[(_+1)%B.length];($=d.get(E))==null||$.focus()}else if(g.key==="ArrowUp"){g.preventDefault();const E=B[(_-1+B.length)%B.length];(V=d.get(E))==null||V.focus()}else g.key==="Escape"&&(g.preventDefault(),k())},p=g=>{i.value&&!i.value.contains(g.target)&&k()},m=g=>{g.key==="Escape"&&k()},u=()=>{window.addEventListener("pointerdown",p),window.addEventListener("keydown",m),window.addEventListener("resize",k)},b=()=>{window.removeEventListener("pointerdown",p),window.removeEventListener("keydown",m),window.removeEventListener("resize",k)};return e.onUnmounted(()=>{b()}),s({open:h,close:k}),(g,B)=>(e.openBlock(),e.createElementBlock("div",{class:"ctx-wrapper",onContextmenu:e.withModifiers(h,["prevent"])},[e.renderSlot(g.$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:i,class:"ctx-menu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${c.value.x}px`,top:`${c.value.y}px`}),onKeydown:f},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(w,_)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:_},[w.divider?(e.openBlock(),e.createElementBlock("li",ri)):(e.openBlock(),e.createElementBlock("li",ii,[e.createElementVNode("button",{ref_for:!0,ref:$=>n(_,$),type:"button",role:"menuitem",class:e.normalizeClass(["ctx-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"ctx-menu__item--disabled mfs-disabled":w.disabled,"ctx-menu__item--danger":w.danger}]),disabled:w.disabled,onClick:$=>y(w)},[e.renderSlot(g.$slots,"item",{item:w},()=>[w.icon?(e.openBlock(),e.createElementBlock("span",ci,e.toDisplayString(w.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",mi,e.toDisplayString(w.label),1)],!0)],10,di)]))],64))),128))],36)):e.createCommentVNode("",!0)]),_:3})]))],32))}}),[["__scopeId","data-v-abdbc3af"]]),bt=L(e.defineComponent({__name:"ScrollTop",props:{threshold:{default:200},behavior:{default:"smooth"},target:{default:null}},emits:["click"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1);let r=null;const i=()=>typeof l.target=="string"?document.querySelector(l.target)??window:l.target instanceof HTMLElement?l.target:window,c=()=>{if(!r)return;const n=r===window?window.scrollY:r.scrollTop;a.value=n>=l.threshold},d=n=>{i().scrollTo({top:0,behavior:l.behavior}),o("click",n)};return e.onMounted(()=>{r=i(),r.addEventListener("scroll",c,{passive:!0}),c()}),e.onUnmounted(()=>{r==null||r.removeEventListener("scroll",c)}),(n,k)=>(e.openBlock(),e.createBlock(e.Transition,{name:"scroll-top-pop"},{default:e.withCtx(()=>[a.value?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"scroll-top mfs-shadow mfs-interactive","aria-label":"Scroll to top",onClick:d},[e.renderSlot(n.$slots,"default",{},()=>[k[0]||(k[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-266880c8"]]),fi={key:0,class:"data-table__toolbar mfs-flex mfs-flex-wrap mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},pi={key:0,class:"data-table__search mfs-relative mfs-flex mfs-items-center"},ui=["value"],ki={class:"data-table__wrap mfs-w-full mfs-overflow-x-auto"},hi={class:"data-table__table mfs-w-full mfs-text-left"},gi={class:"data-table__head"},yi={key:0,class:"data-table__th data-table__th--select mfs-text-muted mfs-whitespace-nowrap"},bi=["aria-sort"],Bi=["onClick"],_i={class:"data-table__sort-icon mfs-shrink-0",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},wi=["fill"],Ei=["fill"],$i={key:0,class:"data-table__sort-badge"},Vi={key:1},Ci={class:"data-table__body"},xi={key:0,class:"data-table__empty-row"},Ni=["colspan"],Si={class:"data-table__empty-content mfs-inline-flex mfs-flex-col mfs-items-center mfs-gap-2"},Mi=["aria-selected","onClick"],Di=["checked","aria-label","onChange"],zi=["data-label"],Li={class:"data-table__cell-value"},Ti={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"},Ii={key:0,class:"data-table__per-page mfs-inline-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-text-muted"},Pi=["value","disabled"],Ri=["value"],Fi={key:2,class:"mfs-loading-overlay","aria-busy":"true"},Bt=L(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:{}},emits:["update:selection","update:searchQuery","update:page","update:rows","update:rowsPerPage","update:first","update:multiSortMeta","page","sort","filter","row-click"],setup(t,{emit:s}){const l=t,o=s,a=`dt-radio-${e.useId()}`,r=e.ref(l.searchQuery),i=e.ref(null),c=e.ref(null),d=e.ref(l.multiSortMeta?l.multiSortMeta.map(I=>({...I})):[]);e.watch(()=>l.multiSortMeta,I=>{d.value=I?I.map(M=>({...M})):[]},{deep:!0});const n=e.computed(()=>l.multiSortMeta??d.value),k=e.computed(()=>l.value??(Array.isArray(l.rows)?l.rows:[])),h=e.ref(typeof l.rows=="number"?l.rows:l.rowsPerPage??10);e.watch(()=>l.rows,I=>{typeof I=="number"&&(h.value=I)}),e.watch(()=>l.rowsPerPage,I=>{I!==void 0&&(h.value=I)});const y=e.computed(()=>Math.max(1,typeof l.rows=="number"?l.rows:l.rowsPerPage??h.value)),f=e.ref(l.page!==void 0?Math.max(1,l.page):l.first>0?Math.floor(l.first/y.value)+1:1);e.watch(()=>l.page,I=>{I!==void 0&&(f.value=Math.max(1,I))}),e.watch(()=>l.first,I=>{I!==void 0&&l.page===void 0&&(f.value=Math.floor(Math.max(0,I)/y.value)+1)}),e.watch(()=>l.searchQuery,I=>{r.value=I});const p=e.computed(()=>l.searchQuery!==""?l.searchQuery:r.value);e.watch(p,()=>{!l.lazy&&l.paginator&&S.value!==1&&(f.value=1,o("update:page",1),o("update:first",0))});const m=e.computed(()=>l.selectable===!0||l.selectable==="multiple"?"multiple":l.selectable==="single"?"single":null);function u(I,M){const R=I==null?void 0:I[l.rowKey];return typeof R=="string"||typeof R=="number"?R:M}function b(I){const M=I.target.value;r.value=M,o("update:searchQuery",M),o("filter",M)}function g(I){if(l.sortMode==="multiple"){const M=n.value.find(R=>R.key===I);return M?M.order:null}return i.value===I?c.value:null}function B(I){if(l.sortMode!=="multiple"||n.value.length===0)return null;const M=n.value.findIndex(R=>R.key===I);return M>=0?M+1:null}function w(I){if(l.sortMode==="multiple"){const M=n.value.map(O=>({...O})),R=M.findIndex(O=>O.key===I);let D="asc";R===-1?(M.push({key:I,order:"asc"}),D="asc"):M[R].order==="asc"?(M[R].order="desc",D="desc"):(M.splice(R,1),D=null),d.value=M,o("update:multiSortMeta",M),o("sort",{key:I,order:D,multiSortMeta:M});return}i.value!==I?(i.value=I,c.value="asc"):c.value==="asc"?c.value="desc":(i.value=null,c.value=null),o("sort",{key:I,order:c.value})}function _(I){if(!I.sortable)return;const M=g(I.key);return M?M==="asc"?"ascending":"descending":"none"}function $(I,M,R){return I==null&&M==null?0:I==null?-1*R:M==null?1*R:typeof I=="number"&&typeof M=="number"?(I-M)*R:String(I).localeCompare(String(M))*R}const V=e.computed(()=>{if(l.lazy)return k.value;const I=p.value.trim().toLowerCase();let M=k.value;if(I){const R=l.columns.map(D=>D.key);M=M.filter(D=>R.some(O=>String(D[O]??"").toLowerCase().includes(I)))}if(l.sortMode==="multiple"){if(n.value.length>0){const R=n.value;M=[...M].sort((D,O)=>{for(const Y of R){const Q=Y.order==="asc"?1:-1,ze=$(D[Y.key],O[Y.key],Q);if(ze!==0)return ze}return 0})}}else if(i.value&&c.value){const R=i.value,D=c.value==="asc"?1:-1;M=[...M].sort((O,Y)=>$(O[R],Y[R],D))}return M}),E=e.computed(()=>l.lazy?l.totalRecords??k.value.length:l.totalRecords??V.value.length),C=e.computed(()=>Math.max(1,Math.ceil(E.value/y.value))),S=e.computed(()=>{const I=l.page!==void 0?l.page:f.value;return Math.min(Math.max(1,I),C.value)}),N=e.computed(()=>{if(l.lazy||!l.paginator)return V.value;const I=(S.value-1)*y.value;return V.value.slice(I,I+y.value)});function F(I){const M=y.value,R=C.value,D=Math.min(Math.max(1,I),R),O=(D-1)*M;f.value=D,o("update:page",D),o("update:first",O),o("page",{page:D,first:O,rows:M,pageCount:R,rowsPerPage:M})}function H(I){if(l.loading)return;const M=Number(I.target.value);if(!Number.isFinite(M)||M<=0)return;h.value=M;const R=Math.max(1,Math.ceil(E.value/M)),D=Math.min(S.value,R),O=(D-1)*M;f.value=D,o("update:rows",M),o("update:rowsPerPage",M),o("update:page",D),o("update:first",O),o("page",{page:D,first:O,rows:M,pageCount:R,rowsPerPage:M})}function z(I,M){if(!m.value||!l.selection)return!1;const R=u(I,M);return m.value==="single"?Array.isArray(l.selection)?!1:u(l.selection,-1)===R:Array.isArray(l.selection)&&l.selection.some((D,O)=>u(D,O)===R)}const j=e.computed(()=>m.value!=="multiple"||N.value.length===0?!1:N.value.every((I,M)=>z(I,M))),W=e.computed(()=>{if(m.value!=="multiple"||N.value.length===0)return!1;const I=N.value.filter((M,R)=>z(M,R)).length;return I>0&&I<N.value.length});function T(I,M){if(!m.value)return;if(m.value==="single"){o("update:selection",I);return}const R=u(I,M),D=Array.isArray(l.selection)?[...l.selection]:[],O=D.findIndex((Y,Q)=>u(Y,Q)===R);O>=0?D.splice(O,1):D.push(I),o("update:selection",D)}function K(){m.value==="multiple"&&(j.value?o("update:selection",[]):o("update:selection",[...N.value]))}function P(I,M){o("row-click",I),m.value&&T(I,M)}return(I,M)=>(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||I.$slots.header?(e.openBlock(),e.createElementBlock("div",fi,[e.renderSlot(I.$slots,"header",{},void 0,!0),t.searchable?(e.openBlock(),e.createElementBlock("div",pi,[M[3]||(M[3]=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:b},null,40,ui)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",ki,[e.createElementVNode("table",hi,[e.createElementVNode("thead",gi,[e.createElementVNode("tr",null,[m.value?(e.openBlock(),e.createElementBlock("th",yi,[m.value==="multiple"?(e.openBlock(),e.createBlock(ne,{key:0,class:"data-table__checkbox","model-value":j.value,indeterminate:W.value,"aria-label":"Select all rows",onClick:M[0]||(M[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(t.columns,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":g(R.key)!==null}]),onClick:D=>w(R.key)},[e.createElementVNode("span",null,e.toDisplayString(R.label),1),(e.openBlock(),e.createElementBlock("svg",_i,[e.createElementVNode("path",{d:"M8 3L11 6.5H5L8 3Z",fill:g(R.key)==="asc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,wi),e.createElementVNode("path",{d:"M8 13L5 9.5H11L8 13Z",fill:g(R.key)==="desc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Ei)])),t.sortMode==="multiple"&&B(R.key)!==null?(e.openBlock(),e.createElementBlock("span",$i,e.toDisplayString(B(R.key)),1)):e.createCommentVNode("",!0)],10,Bi)):(e.openBlock(),e.createElementBlock("span",Vi,e.toDisplayString(R.label),1))],14,bi))),128))])]),e.createElementVNode("tbody",Ci,[N.value.length===0?(e.openBlock(),e.createElementBlock("tr",xi,[e.createElementVNode("td",{colspan:t.columns.length+(m.value?1:0),class:"data-table__empty mfs-text-muted mfs-text-center"},[e.renderSlot(I.$slots,"empty",{},()=>[e.createElementVNode("div",Si,[M[4]||(M[4]=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,Ni)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(N.value,(R,D)=>(e.openBlock(),e.createElementBlock("tr",{key:u(R,D),class:e.normalizeClass(["data-table__row",{"data-table__row--selected":z(R,D)}]),"aria-selected":m.value?z(R,D):void 0,onClick:O=>P(R,D)},[m.value?(e.openBlock(),e.createElementBlock("td",{key:0,class:"data-table__td data-table__td--select","data-label":"Select",onClick:M[2]||(M[2]=e.withModifiers(()=>{},["stop"]))},[m.value==="single"?(e.openBlock(),e.createElementBlock("input",{key:0,type:"radio",class:"data-table__checkbox mfs-cursor-pointer",name:a,checked:z(R,D),"aria-label":`Select row ${D+1}`,onChange:O=>T(R,D)},null,40,Di)):(e.openBlock(),e.createBlock(ne,{key:1,class:"data-table__checkbox","model-value":z(R,D),"aria-label":`Select row ${D+1}`,onClick:M[1]||(M[1]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":O=>T(R,D)},null,8,["model-value","aria-label","onUpdate:modelValue"]))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,O=>(e.openBlock(),e.createElementBlock("td",{key:O.key,class:e.normalizeClass(["data-table__td",O.align?`data-table__cell--${O.align}`:""]),"data-label":O.label},[e.renderSlot(I.$slots,`cell-${O.key}`,{row:R,value:R[O.key],column:O,index:D},()=>[e.createElementVNode("span",Li,e.toDisplayString(R[O.key]??""),1)],!0)],10,zi))),128))],10,Mi))),128))])])]),t.paginator?(e.openBlock(),e.createElementBlock("div",Ti,[t.rowsPerPageOptions.length?(e.openBlock(),e.createElementBlock("label",Ii,[M[5]||(M[5]=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:y.value,disabled:t.loading,"aria-label":"Rows per page",onChange:H},[(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,Ri))),128))],40,Pi),M[6]||(M[6]=e.createElementVNode("span",null,"per page",-1))])):e.createCommentVNode("",!0),e.createVNode(ce,{"model-value":S.value,total:E.value,"per-page":y.value,"per-page-options":[],loading:t.loading,"onUpdate:modelValue":F},null,8,["model-value","total","per-page","loading"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Fi,[e.renderSlot(I.$slots,"loading",{},()=>[M[7]||(M[7]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-df43973e"]]),_t=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(s,l)=>null}});function me(t,s,l="id"){if(t&&typeof t=="object"&&l in t){const o=t[l];if(typeof o=="string"||typeof o=="number")return o}return s}const Ai={class:"data-view mfs-relative"},ji={class:"data-view__header"},Ki={class:"data-view__header-left"},Oi={class:"data-view__toggle mfs-inset mfs-rounded-md",role:"group","aria-label":"View layout"},Ui=["aria-pressed"],Hi=["aria-pressed"],Wi={key:0,class:"data-view__empty mfs-card mfs-text-muted"},Gi={class:"data-view__empty-content"},qi={class:"data-view__fallback-card mfs-card"},Yi={key:2,class:"mfs-loading-overlay","aria-busy":"true"},wt=L(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:s}){const l=t,o=s,a=e.ref(l.layout);e.watch(()=>l.layout,d=>{a.value=d});const r=e.computed(()=>a.value),i=e.computed(()=>{if(!(r.value!=="grid"||!l.columns))return{gridTemplateColumns:`repeat(${l.columns}, minmax(0, 1fr))`}});function c(d){a.value!==d&&(a.value=d,o("update:layout",d))}return(d,n)=>(e.openBlock(),e.createElementBlock("div",Ai,[e.createElementVNode("div",ji,[e.createElementVNode("div",Ki,[e.renderSlot(d.$slots,"header",{},void 0,!0)]),e.createElementVNode("div",Oi,[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:n[0]||(n[0]=k=>c("grid"))},[...n[2]||(n[2]=[e.createStaticVNode('<svg viewBox="0 0 18 18" fill="none" aria-hidden="true" data-v-c1be6bfd><rect x="2" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect><rect x="10" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect><rect x="2" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect><rect x="10" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect></svg>',1)])],10,Ui),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:n[1]||(n[1]=k=>c("list"))},[...n[3]||(n[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,Hi)])]),t.items.length===0?(e.openBlock(),e.createElementBlock("div",Wi,[e.renderSlot(d.$slots,"empty",{},()=>[e.createElementVNode("div",Gi,[n[4]||(n[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(i.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(k,h)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(me)(k,h,t.itemKey),class:"data-view__item"},[r.value==="grid"&&d.$slots.grid?e.renderSlot(d.$slots,"grid",{item:k,index:h},void 0,!0,0):r.value==="list"&&d.$slots.list?e.renderSlot(d.$slots,"list",{item:k,index:h},void 0,!0,1):e.renderSlot(d.$slots,"default",{item:k,index:h,layout:r.value},()=>[e.createElementVNode("div",qi,e.toDisplayString(k),1)],!0,2)]))),128))],6)),t.loading?(e.openBlock(),e.createElementBlock("div",Yi,[e.renderSlot(d.$slots,"loading",{},()=>[n[5]||(n[5]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-c1be6bfd"]]),Xi=["role"],Zi={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ji={key:1,class:"mfs-empty-state"},Qi=["aria-expanded","aria-selected","aria-disabled"],vi=["onClick","onKeydown"],ed=["aria-label","onClick"],td={key:1,class:"tree__spacer","aria-hidden":"true"},ld={key:3,class:"tree__icon","aria-hidden":"true"},od={class:"tree__content"},nd={class:"tree__label"},Et=L(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:s}){const l=t,o=s;function a(f){return Array.isArray(f.children)&&f.children.length>0}function r(f){return a(f)||l.lazy&&!f.leaf}function i(f){return l.expandedKeys.includes(f)}function c(f){return l.selectedKeys.includes(f)}function d(f){var u;if(!r(f))return;const p=new Set(l.expandedKeys),m=!p.has(f.key);m?(p.add(f.key),l.lazy&&!((u=f.children)!=null&&u.length)&&o("lazy-load",f)):p.delete(f.key),o("update:expandedKeys",Array.from(p)),o("node-toggle",f,m)}function n(f){r(f)&&!i(f.key)&&d(f)}function k(f){r(f)&&i(f.key)&&d(f)}function h(f){if(f.disabled||l.selectionMode==="none")return;if(l.selectionMode==="single"){o("update:selectedKeys",c(f.key)?[]:[f.key]);return}const p=new Set(l.selectedKeys);p.has(f.key)?p.delete(f.key):p.add(f.key),o("update:selectedKeys",Array.from(p))}function y(f){f.disabled||(o("node-click",f),l.selectionMode!=="none"?h(f):r(f)&&d(f))}return(f,p)=>{const m=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",Zi,[e.renderSlot(f.$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",Ji,[e.renderSlot(f.$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,u=>(e.openBlock(),e.createElementBlock("li",{key:u.key,class:"tree__item",role:"treeitem","aria-expanded":r(u)?i(u.key):void 0,"aria-selected":t.selectionMode!=="none"?c(u.key):void 0,"aria-disabled":u.disabled||void 0},[e.createElementVNode("div",{class:e.normalizeClass(["tree__row mfs-rounded-sm mfs-focus-ring",{"tree__row--selected":c(u.key),"tree__row--disabled mfs-disabled":u.disabled}]),style:e.normalizeStyle({paddingLeft:`${t.level*20+8}px`}),tabindex:"0",onClick:b=>y(u),onKeydown:[e.withKeys(e.withModifiers(b=>y(u),["prevent"]),["enter"]),e.withKeys(e.withModifiers(b=>y(u),["prevent"]),["space"]),e.withKeys(e.withModifiers(b=>n(u),["prevent"]),["right"]),e.withKeys(e.withModifiers(b=>k(u),["prevent"]),["left"])]},[r(u)?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree__toggle mfs-text-muted",{"tree__toggle--expanded":i(u.key)}]),"aria-label":i(u.key)?`Collapse ${u.label}`:`Expand ${u.label}`,tabindex:"-1",onClick:e.withModifiers(b=>d(u),["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,ed)):(e.openBlock(),e.createElementBlock("span",td)),t.selectionMode==="checkbox"?(e.openBlock(),e.createBlock(ne,{key:2,class:"tree__checkbox","model-value":c(u.key),disabled:u.disabled,"aria-label":`Select ${u.label}`,tabindex:-1,onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":b=>h(u)},null,8,["model-value","disabled","aria-label","onUpdate:modelValue"])):e.createCommentVNode("",!0),u.icon?(e.openBlock(),e.createElementBlock("span",ld,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("div",od,[e.renderSlot(f.$slots,"node",{node:u,expanded:i(u.key),selected:c(u.key),level:t.level},()=>[e.createElementVNode("span",nd,e.toDisplayString(u.label),1)],!0)])],46,vi),a(u)&&i(u.key)?(e.openBlock(),e.createBlock(m,{key:0,nodes:u.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]=b=>f.$emit("update:expandedKeys",b)),"onUpdate:selectedKeys":p[2]||(p[2]=b=>f.$emit("update:selectedKeys",b)),onNodeClick:p[3]||(p[3]=b=>f.$emit("node-click",b)),onNodeToggle:p[4]||(p[4]=(b,g)=>f.$emit("node-toggle",b,g)),onLazyLoad:p[5]||(p[5]=b=>f.$emit("lazy-load",b))},e.createSlots({_:2},[f.$slots.node?{name:"node",fn:e.withCtx(b=>[e.renderSlot(f.$slots,"node",e.mergeProps({ref_for:!0},b),void 0,!0)]),key:"0"}:void 0]),1032,["nodes","expanded-keys","selection-mode","selected-keys","lazy","level"])):e.createCommentVNode("",!0)],8,Qi))),128))],10,Xi)}}}),[["__scopeId","data-v-0e17bf40"]]),ad={class:"ac-box mfs-surface mfs-rounded mfs-shadow-inset"},sd=["aria-expanded","value","placeholder","disabled"],rd={key:0,class:"ac-spinner","aria-hidden":"true"},id=["aria-selected","onMousedown","onMouseenter"],dd={key:0,class:"mfs-empty-state",role:"status"},$t=L(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:s}){const l=t,o=s,a=`mfs-ac-${e.useId()}`,r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(-1),{overlayStyle:k,containsTarget:h}=J(i,c,d,{matchWidth:!0}),y=e.computed(()=>{const B=l.suggestions.map(_=>typeof _=="string"?{label:_,value:_}:_);if(l.remote)return B;const w=(l.modelValue||"").toLowerCase();return B.filter(_=>!w||_.label.toLowerCase().includes(w))}),f=e.computed(()=>(l.modelValue||"").length>=l.minLength&&!l.loading&&y.value.length===0),p=B=>{const w=B.target.value;o("update:modelValue",w),w.length>=l.minLength?(o("complete",{query:w}),d.value=!0,n.value=-1):d.value=!1},m=()=>{(l.modelValue||"").length>=l.minLength&&(y.value.length||!l.loading)&&(d.value=!0)},u=B=>{o("update:modelValue",B.label),o("select",B),d.value=!1},b=B=>{if(d.value){if(B.key==="Escape")d.value=!1;else if(B.key==="ArrowDown")B.preventDefault(),y.value.length&&(n.value=(n.value+1)%y.value.length);else if(B.key==="ArrowUp")B.preventDefault(),y.value.length&&(n.value=(n.value-1+y.value.length)%y.value.length);else if(B.key==="Enter"&&n.value>=0){B.preventDefault();const w=y.value[n.value];w&&u(w)}}},g=B=>{h(B.target)||(d.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",g)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",g)),(B,w)=>(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:a,class:"ac-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:i,class:"ac-container"},[e.createElementVNode("div",ad,[e.createElementVNode("input",{id:a,type:"text",role:"combobox","aria-expanded":d.value,"aria-autocomplete":"list",value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,class:"ac-input mfs-text",onInput:p,onFocus:m,onKeydown:b},null,40,sd),t.loading?(e.openBlock(),e.createElementBlock("span",rd)):e.createCommentVNode("",!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ac-pop"},{default:e.withCtx(()=>[d.value&&(y.value.length||f.value)?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:c,role:"listbox",style:e.normalizeStyle(e.unref(k)),class:"ac-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(_,$)=>(e.openBlock(),e.createElementBlock("li",{key:_.label+$,role:"option","aria-selected":$===n.value,class:e.normalizeClass(["ac-option mfs-text",{"ac-option--active":$===n.value}]),onMousedown:e.withModifiers(V=>u(_),["prevent"]),onMouseenter:V=>n.value=$},e.toDisplayString(_.label),43,id))),128)),f.value?(e.openBlock(),e.createElementBlock("li",dd,[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-7c96b5c1"]]),cd={key:0,class:"cas-label mfs-text"},md={class:"cas-container"},fd=["disabled","aria-expanded"],pd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},ud={key:0,class:"cas-col"},kd={key:1,class:"cas-col"},hd={class:"mfs-empty-state"},gd=["disabled","onClick"],yd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},bd={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Bd={key:0,class:"cas-col"},Ce=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=J(a,r,i,{offset:6}),n=e.ref([...l.modelValue]);e.watch(()=>l.modelValue,m=>{n.value=[...m||[]]});const k=e.computed(()=>{const m=[];let u=l.options,b=0;for(;u&&u.length;){m.push(u);const g=n.value[b],B=u.find(w=>w.value===g);u=B==null?void 0:B.children,b++}return m}),h=e.computed(()=>{const m=[];let u=l.options;for(const b of l.modelValue||[]){const g=u==null?void 0:u.find(B=>B.value===b);if(!g)break;m.push(g.label),u=g.children}return m.join(l.separator)}),y=(m,u)=>{var g,B;if(u.disabled)return;const b=[...n.value.slice(0,m),u.value];if(n.value=b,l.lazy&&!u.isLeaf&&!((g=u.children)!=null&&g.length)){o("lazy-load",u);return}(B=u.children)!=null&&B.length||(o("update:modelValue",b),o("change",b),i.value=!1)},f=m=>{d(m.target)||(i.value=!1)},p=m=>{m.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",f),document.addEventListener("keydown",p)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",f),document.removeEventListener("keydown",p)}),(m,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cas-wrapper",{"cas-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",cd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",md,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,type:"button",class:"cas-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":i.value,onClick:u[0]||(u[0]=b=>i.value=!i.value)},[e.createElementVNode("span",{class:e.normalizeClass(["cas-value",{"mfs-text-muted":!h.value}])},e.toDisplayString(h.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",pd)):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":i.value}])},[...u[1]||(u[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,fd),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cas-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),class:"cas-panel mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading&&k.value.length===0?(e.openBlock(),e.createElementBlock("div",ud,[e.renderSlot(m.$slots,"loading",{},()=>[u[2]||(u[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):k.value.length===0?(e.openBlock(),e.createElementBlock("div",kd,[e.createElementVNode("div",hd,[e.renderSlot(m.$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(k.value,(b,g)=>(e.openBlock(),e.createElementBlock("div",{key:g,class:"cas-col"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b,B=>{var w;return e.openBlock(),e.createElementBlock("button",{key:String(B.value),type:"button",class:e.normalizeClass(["cas-item mfs-text",{"cas-item--active":n.value[g]===B.value}]),disabled:B.disabled,onClick:_=>y(g,B)},[e.createElementVNode("span",null,e.toDisplayString(B.label),1),B.loading?(e.openBlock(),e.createElementBlock("span",yd)):(w=B.children)!=null&&w.length||t.lazy&&!B.isLeaf?(e.openBlock(),e.createElementBlock("svg",bd,[...u[3]||(u[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,gd)}),128))]))),128)),t.loading?(e.openBlock(),e.createElementBlock("div",Bd,[e.renderSlot(m.$slots,"loading",{},()=>[u[4]||(u[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"]]),_d={key:0,class:"ts-label mfs-text"},wd={class:"ts-container"},Ed=["disabled","aria-expanded"],$d={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Vd={key:1,class:"mfs-empty-state"},Cd=["aria-selected"],xd=["aria-label","onClick"],Nd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Sd={key:1,class:"ts-expand-spacer"},Md=["disabled","onClick"],Dd={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"},Vt=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=J(a,r,i,{offset:6,matchWidth:!0}),n=e.reactive(new Set),k=g=>{var B;n.has(g.value)?n.delete(g.value):(n.add(g.value),l.lazy&&!g.isLeaf&&!((B=g.children)!=null&&B.length)&&o("lazy-load",g))},h=e.computed(()=>{const g=[],B=(w,_)=>{var $;for(const V of w)g.push({node:V,depth:_}),($=V.children)!=null&&$.length&&n.has(V.value)&&B(V.children,_+1)};return B(l.options,0),g}),y=e.computed(()=>{const g=new Map,B=w=>{var _;for(const $ of w)g.set($.value,$.label),(_=$.children)!=null&&_.length&&B($.children)};return B(l.options),g}),f=e.computed(()=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.map(g=>y.value.get(g)??String(g)).join(", "):l.modelValue===null||l.modelValue===void 0?"":y.value.get(l.modelValue)??String(l.modelValue)),p=g=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(g):l.modelValue===g,m=g=>{if(!g.disabled)if(l.multiple){const B=Array.isArray(l.modelValue)?l.modelValue:[],w=B.includes(g.value)?B.filter(_=>_!==g.value):[...B,g.value];o("update:modelValue",w),o("change",w)}else o("update:modelValue",g.value),o("change",g.value),i.value=!1},u=g=>{d(g.target)||(i.value=!1)},b=g=>{g.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",u),document.addEventListener("keydown",b)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",u),document.removeEventListener("keydown",b)}),(g,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",_d,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",wd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,type:"button",class:"ts-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":i.value,onClick:B[0]||(B[0]=w=>i.value=!i.value)},[e.createElementVNode("span",{class:e.normalizeClass(["ts-value",{"mfs-text-muted":!f.value}])},e.toDisplayString(f.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",$d)):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":i.value}])},[...B[1]||(B[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,Ed),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ts-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),class:"ts-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow",role:"tree"},[t.loading&&h.value.length===0?e.renderSlot(g.$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):h.value.length===0?(e.openBlock(),e.createElementBlock("div",Vd,[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(h.value,w=>{var _;return e.openBlock(),e.createElementBlock("div",{key:String(w.node.value),role:"treeitem","aria-selected":p(w.node.value),class:"ts-row",style:e.normalizeStyle({paddingLeft:`${8+w.depth*18}px`})},[(_=w.node.children)!=null&&_.length||t.lazy&&!w.node.isLeaf?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"ts-expand mfs-text-muted","aria-label":n.has(w.node.value)?"Collapse":"Expand",onClick:e.withModifiers($=>k(w.node),["stop"])},[w.node.loading?(e.openBlock(),e.createElementBlock("span",Nd)):(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:n.has(w.node.value)?"rotate(90deg)":""})},[...B[3]||(B[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])],4))],8,xd)):(e.openBlock(),e.createElementBlock("span",Sd)),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["ts-node mfs-text",{"ts-node--selected":p(w.node.value)}]),disabled:w.node.disabled,onClick:$=>m(w.node)},[e.createElementVNode("span",null,e.toDisplayString(w.node.label),1),p(w.node.value)?(e.openBlock(),e.createElementBlock("svg",Dd,[...B[4]||(B[4]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],10,Md)],12,Cd)}),128)),t.loading?e.renderSlot(g.$slots,"loading",{},void 0,!0,0):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-2741eadc"]]),zd=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],Ld=["viewBox","width","height"],Td=["d","stroke-width"],Id=["d","stroke-width"],Pd={class:"knob-value mfs-text mfs-font-mono"},Rd={key:0,class:"knob-label mfs-caption"},Ct=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(!1),i=e.computed(()=>l.size/2),c=e.computed(()=>l.size/2-l.strokeWidth-4),d=B=>{const w=(B-90)*Math.PI/180;return{x:i.value+c.value*Math.cos(w),y:i.value+c.value*Math.sin(w)}},n=(B,w)=>{const _=d(w),$=d(B),V=w-B<=180?"0":"1";return`M ${_.x} ${_.y} A ${c.value} ${c.value} 0 ${V} 0 ${$.x} ${$.y}`},k=e.computed(()=>{const B=l.max-l.min;return B<=0?0:Math.max(0,Math.min(1,(l.modelValue-l.min)/B))}),h=e.computed(()=>n(225,495)),y=e.computed(()=>{const B=225+k.value*270;return B<=225.1?"":n(225,B)}),f=e.computed(()=>l.valueTemplate.replace("{value}",String(l.modelValue))),p=(B,w)=>{var H;const _=(H=a.value)==null?void 0:H.getBoundingClientRect();if(!_)return;const $=_.left+_.width/2,V=_.top+_.height/2;let E=Math.atan2(w-V,B-$)*180/Math.PI+90;E<0&&(E+=360);let C=E>=225?E-225:E<=135?E+135:E<180?270:0;C=Math.max(0,Math.min(270,C));const S=l.min+C/270*(l.max-l.min),N=Math.round((S-l.min)/l.step)*l.step+l.min,F=Math.max(l.min,Math.min(l.max,Number(N.toFixed(6))));o("update:modelValue",F)},m=B=>{r.value&&p(B.clientX,B.clientY)},u=()=>{r.value&&(r.value=!1,o("change",l.modelValue)),window.removeEventListener("pointermove",m),window.removeEventListener("pointerup",u)},b=B=>{l.disabled||l.readonly||(B.preventDefault(),r.value=!0,p(B.clientX,B.clientY),window.addEventListener("pointermove",m),window.addEventListener("pointerup",u))},g=B=>{if(l.disabled||l.readonly)return;const w=B.key==="ArrowRight"||B.key==="ArrowUp"?l.step:B.key==="ArrowLeft"||B.key==="ArrowDown"?-l.step:0;if(!w)return;B.preventDefault();const _=Math.max(l.min,Math.min(l.max,l.modelValue+w));o("update:modelValue",_),o("change",_)};return e.onBeforeUnmount(u),(B,w)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["knob-wrapper",{"knob-wrapper--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("div",{ref_key:"svgBoxRef",ref:a,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:b,onKeydown:g},[(e.openBlock(),e.createElementBlock("svg",{viewBox:`0 0 ${t.size} ${t.size}`,width:t.size,height:t.size},[e.createElementVNode("path",{d:h.value,fill:"none",stroke:"var(--surface-subtle, rgba(148,163,184,0.28))","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,Td),e.createElementVNode("path",{d:y.value,fill:"none",stroke:"var(--primary, #8b5cf6)","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,Id)],8,Ld)),e.createElementVNode("span",Pd,e.toDisplayString(f.value),1)],44,zd),t.label?(e.openBlock(),e.createElementBlock("span",Rd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-5002b75d"]]),Fd=["disabled","aria-pressed","onClick"],xt=L(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:s}){const l=t,o=s,a=e.computed(()=>l.options.map(c=>typeof c=="string"?{label:c,value:c}:c)),r=c=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(c):l.modelValue===c,i=c=>{if(!(l.disabled||c.disabled))if(l.multiple){const d=Array.isArray(l.modelValue)?l.modelValue:[],n=d.includes(c.value)?d.filter(k=>k!==c.value):[...d,c.value];o("update:modelValue",n),o("change",n)}else o("update:modelValue",c.value),o("change",c.value)};return(c,d)=>(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(a.value,(n,k)=>(e.openBlock(),e.createElementBlock("button",{key:String(n.value)+k,type:"button",class:e.normalizeClass(["sb-btn mfs-text mfs-focus-ring",{"sb-btn--active mfs-shadow":r(n.value)}]),disabled:t.disabled||n.disabled,"aria-pressed":r(n.value),onClick:h=>i(n)},e.toDisplayString(n.label),11,Fd))),128))],2))}}),[["__scopeId","data-v-80282f25"]]),Ad=["aria-pressed","disabled"],Nt=L(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:s}){const l=t,o=s,a=()=>{if(l.disabled)return;const r=!l.modelValue;o("update:modelValue",r),o("change",r)};return(r,i)=>(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:a},[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.modelValue?t.onLabel:t.offLabel),1)],!0)],10,Ad))}}),[["__scopeId","data-v-84c00cdb"]]),jd=["type","inputmode","value","disabled","aria-label","onInput","onKeydown","onPaste"],St=L(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:s}){const l=t,o=s,a=e.ref([]),r=(h,y)=>{a.value[y]=h},i=e.computed(()=>Array.from({length:l.length},(h,y)=>l.modelValue[y]??"")),c=h=>{const y=h.join("").slice(0,l.length);o("update:modelValue",y),y.length===l.length&&!h.includes("")&&o("complete",y)},d=(h,y)=>{var u;const p=y.target.value.slice(-1);if(l.integerOnly&&p&&!/^\d$/.test(p)){y.target.value=i.value[h];return}const m=[...i.value];m[h]=p,c(m),p&&h<l.length-1&&((u=a.value[h+1])==null||u.focus())},n=(h,y)=>{var f,p,m;y.key==="Backspace"&&!i.value[h]&&h>0?(f=a.value[h-1])==null||f.focus():y.key==="ArrowLeft"&&h>0?(y.preventDefault(),(p=a.value[h-1])==null||p.focus()):y.key==="ArrowRight"&&h<l.length-1&&(y.preventDefault(),(m=a.value[h+1])==null||m.focus())},k=(h,y)=>{var b,g;y.preventDefault();const f=((b=y.clipboardData)==null?void 0:b.getData("text"))??"",p=l.integerOnly?f.replace(/\D/g,""):f;if(!p)return;const m=[...i.value];for(let B=0;B<p.length&&h+B<l.length;B++)m[h+B]=p[B];c(m);const u=Math.min(l.length-1,h+p.length);(g=a.value[u])==null||g.focus()};return(h,y)=>(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,f=>(e.openBlock(),e.createElementBlock("input",{key:f,ref_for:!0,ref:p=>r(p,f-1),type:t.mask?"password":"text",inputmode:t.integerOnly?"numeric":"text",maxlength:"1",value:i.value[f-1],disabled:t.disabled,"aria-label":`Digit ${f} of ${t.length}`,class:"otp-cell mfs-surface mfs-rounded mfs-shadow-inset mfs-text mfs-font-mono",onInput:p=>d(f-1,p),onKeydown:p=>n(f-1,p),onPaste:p=>k(f-1,p)},null,40,jd))),128))],2))}}),[["__scopeId","data-v-825a2351"]]),Kd={class:"mask-box mfs-surface mfs-rounded mfs-shadow-inset"},Od=["value","placeholder","disabled"],Mt=L(e.defineComponent({__name:"InputMask",props:{modelValue:{default:""},mask:{},label:{},placeholder:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:s}){const l=t,o=s,a=`mfs-mask-${e.useId()}`,r=(d,n)=>d==="9"?/^\d$/.test(n):d==="a"?/^[a-zA-Z]$/.test(n):d==="*"?/^[a-zA-Z0-9]$/.test(n):!1,i=d=>{const n=d.split("");let k="",h=0;for(let y=0;y<l.mask.length&&h<n.length;y++){const f=l.mask[y];if(f==="9"||f==="a"||f==="*"){for(;h<n.length&&!r(f,n[h]);)h++;h<n.length&&(k+=n[h],h++)}else k+=f,n[h]===f&&h++}return k},c=d=>{const n=d.target,k=i(n.value);n.value=k,o("update:modelValue",k)};return(d,n)=>(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:a,class:"mask-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Kd,[e.createElementVNode("input",{id:a,type:"text",value:t.modelValue,placeholder:t.placeholder||t.mask,disabled:t.disabled,class:"mask-input mfs-text mfs-font-mono",onInput:c},null,40,Od)])],2))}}),[["__scopeId","data-v-5d657e20"]]),Ud={},Hd={class:"ig-wrapper mfs-surface mfs-rounded mfs-shadow-inset"};function Wd(t,s){return e.openBlock(),e.createElementBlock("div",Hd,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const Dt=L(Ud,[["render",Wd],["__scopeId","data-v-9b55039f"]]),Gd={},qd={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 Yd(t,s){return e.openBlock(),e.createElementBlock("span",qd,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const zt=L(Gd,[["render",Yd],["__scopeId","data-v-06440459"]]),Xd={key:0,class:"icon-field__icon mfs-text-muted","aria-hidden":"true"},Lt=L(e.defineComponent({__name:"IconField",props:{iconPosition:{default:"left"},fluid:{type:Boolean,default:!1}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["icon-field",[`icon-field--${t.iconPosition}`,{"icon-field--fluid":t.fluid}]])},[s.$slots.icon?(e.openBlock(),e.createElementBlock("span",Xd,[e.renderSlot(s.$slots,"icon",{},void 0,!0)])):e.createCommentVNode("",!0),e.renderSlot(s.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-aafeb221"]]),Zd={},Jd={class:"input-icon mfs-inline-flex mfs-items-center mfs-justify-center mfs-text-muted","aria-hidden":"true"};function Qd(t,s){return e.openBlock(),e.createElementBlock("span",Jd,[e.renderSlot(t.$slots,"default")])}const Tt=L(Zd,[["render",Qd]]),vd={key:0,class:"lb-filter-box"},ec=["disabled"],tc=["aria-multiselectable"],lc=["aria-selected","onClick","onKeydown"],oc={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"},nc={key:0,class:"lb-empty mfs-text-muted"},It=L(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:s}){const l=t,o=s,a=e.ref(""),r=e.computed(()=>l.options.map(n=>typeof n=="string"?{label:n,value:n}:n)),i=e.computed(()=>{const n=a.value.trim().toLowerCase();return n?r.value.filter(k=>k.label.toLowerCase().includes(n)):r.value}),c=n=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(n):l.modelValue===n,d=n=>{if(!(l.disabled||n.disabled))if(l.multiple){const k=Array.isArray(l.modelValue)?l.modelValue:[],h=k.includes(n.value)?k.filter(y=>y!==n.value):[...k,n.value];o("update:modelValue",h),o("change",h)}else o("update:modelValue",n.value),o("change",n.value)};return(n,k)=>(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",vd,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":k[0]||(k[0]=h=>a.value=h),type:"text",class:"lb-filter mfs-inset mfs-text",placeholder:"Filter...",disabled:t.disabled},null,8,ec),[[e.vModelText,a.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(i.value,(h,y)=>(e.openBlock(),e.createElementBlock("li",{key:String(h.value)+y,role:"option","aria-selected":c(h.value),class:e.normalizeClass(["lb-item mfs-text mfs-focus-ring",{"lb-item--selected":c(h.value),"lb-item--disabled":h.disabled}]),tabindex:"0",onClick:f=>d(h),onKeydown:[e.withKeys(e.withModifiers(f=>d(h),["prevent"]),["enter"]),e.withKeys(e.withModifiers(f=>d(h),["prevent"]),["space"])]},[e.createElementVNode("span",null,e.toDisplayString(h.label),1),c(h.value)?(e.openBlock(),e.createElementBlock("svg",oc,[...k[1]||(k[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],42,lc))),128)),i.value.length===0?(e.openBlock(),e.createElementBlock("li",nc,"No options")):e.createCommentVNode("",!0)],8,tc)],2))}}),[["__scopeId","data-v-57e05a19"]]),ac=["for"],Pt=L(e.defineComponent({__name:"FloatLabel",props:{label:{},forId:{},active:{type:Boolean}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["fl-wrapper",{"fl-wrapper--active":t.active}])},[e.renderSlot(s.$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,ac)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-c37f1a9e"]]),sc={class:"ifta-wrapper mfs-surface mfs-rounded mfs-shadow-inset"},rc=["for"],ic={class:"ifta-control"},Rt=L(e.defineComponent({__name:"IftaLabel",props:{label:{},forId:{}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",sc,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"ifta-label mfs-text-muted"},e.toDisplayString(t.label),9,rc)):e.createCommentVNode("",!0),e.createElementVNode("div",ic,[e.renderSlot(s.$slots,"default",{},void 0,!0)])]))}}),[["__scopeId","data-v-289391b4"]]),dc={key:0,class:"ed-toolbar mfs-surface-subtle",role:"toolbar","aria-label":"Formatting"},cc=["contenteditable","data-placeholder"],Ft=L(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:s}){const l=t,o=s,a=e.ref(null),r=n=>{const k=new DOMParser().parseFromString(n||"","text/html");return k.body.querySelectorAll("script, iframe, object, embed").forEach(h=>h.remove()),k.body.querySelectorAll("*").forEach(h=>{for(const y of Array.from(h.attributes)){const f=y.name.toLowerCase(),p=y.value.trim().toLowerCase();(f.startsWith("on")||(f==="href"||f==="src")&&p.startsWith("javascript:"))&&h.removeAttribute(y.name)}}),Array.from(k.body.childNodes)},i=n=>{!a.value||a.value.innerHTML===n||a.value.replaceChildren(...r(n))};e.onMounted(()=>i(l.modelValue)),e.watch(()=>l.modelValue,n=>i(n));const c=()=>{a.value&&o("update:modelValue",a.value.innerHTML)},d=n=>{var k;l.disabled||l.readonly||((k=a.value)==null||k.focus(),document.execCommand(n,!1),c())};return(n,k)=>(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",dc,[e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bold","aria-label":"Bold",onMousedown:k[0]||(k[0]=e.withModifiers(h=>d("bold"),["prevent"]))},[...k[7]||(k[7]=[e.createElementVNode("strong",null,"B",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Italic","aria-label":"Italic",onMousedown:k[1]||(k[1]=e.withModifiers(h=>d("italic"),["prevent"]))},[...k[8]||(k[8]=[e.createElementVNode("em",null,"I",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Underline","aria-label":"Underline",onMousedown:k[2]||(k[2]=e.withModifiers(h=>d("underline"),["prevent"]))},[...k[9]||(k[9]=[e.createElementVNode("u",null,"U",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Strikethrough","aria-label":"Strikethrough",onMousedown:k[3]||(k[3]=e.withModifiers(h=>d("strikeThrough"),["prevent"]))},[...k[10]||(k[10]=[e.createElementVNode("s",null,"S",-1)])],32),k[11]||(k[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:k[4]||(k[4]=e.withModifiers(h=>d("insertUnorderedList"),["prevent"]))}," • List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Numbered List","aria-label":"Numbered List",onMousedown:k[5]||(k[5]=e.withModifiers(h=>d("insertOrderedList"),["prevent"]))}," 1. List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text-muted",title:"Clear Formatting","aria-label":"Clear Formatting",onMousedown:k[6]||(k[6]=e.withModifiers(h=>d("removeFormat"),["prevent"]))}," Clear ",32)])),e.createElementVNode("div",{ref_key:"editorRef",ref:a,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:c},null,44,cc)],2))}}),[["__scopeId","data-v-8aa9e8cf"]]);/**
1
+ (function(x,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(x=typeof globalThis<"u"?globalThis:x||self,e(x.MfsTheme={},x.Vue))})(this,(function(x,e){"use strict";const po=["disabled","type"],uo={key:0,class:"btn__spinner"},ko={key:1,class:"btn__icon btn__icon--prepend"},ho={class:"btn__content"},go={key:2,class:"btn__icon btn__icon--append"},yo=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:s}){const l=s,o=a=>{l("click",a)};return(a,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:o},[t.loading?(e.openBlock(),e.createElementBlock("span",uo)):e.createCommentVNode("",!0),a.$slots.prepend&&!t.loading?(e.openBlock(),e.createElementBlock("span",ko,[e.renderSlot(a.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",ho,[e.renderSlot(a.$slots,"default",{},void 0,!0)]),a.$slots.append&&!t.loading?(e.openBlock(),e.createElementBlock("span",go,[e.renderSlot(a.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],10,po))}}),D=(t,s)=>{const l=t.__vccOpts||t;for(const[o,a]of s)l[o]=a;return l},he=D(yo,[["__scopeId","data-v-76212e60"]]),bo={},Bo={class:"mfs-btn-group mfs-inline-flex mfs-items-center",role:"group"};function _o(t,s){return e.openBlock(),e.createElementBlock("div",Bo,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const et=D(bo,[["render",_o],["__scopeId","data-v-3e6bbebb"]]),wo={key:0,class:"card__header"},Eo={key:0,class:"card__title mfs-title"},$o={key:1,class:"card__subtitle mfs-caption"},Vo={class:"card__body"},Co={key:1,class:"card__footer"},tt=D(e.defineComponent({__name:"Card",props:{title:{},subtitle:{},hoverable:{type:Boolean,default:!1},bordered:{type:Boolean,default:!1}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["card","mfs-card",{"card--hoverable":t.hoverable,"card--bordered":t.bordered}])},[s.$slots.header||t.title?(e.openBlock(),e.createElementBlock("div",wo,[e.renderSlot(s.$slots,"header",{},()=>[e.createElementVNode("div",null,[t.title?(e.openBlock(),e.createElementBlock("h3",Eo,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),t.subtitle?(e.openBlock(),e.createElementBlock("p",$o,e.toDisplayString(t.subtitle),1)):e.createCommentVNode("",!0)])],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Vo,[e.renderSlot(s.$slots,"default",{},void 0,!0)]),s.$slots.footer?(e.openBlock(),e.createElementBlock("div",Co,[e.renderSlot(s.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-38a6c076"]]),xo={key:0,class:"input-label mfs-text"},No={key:0,class:"input-required"},So={key:0,class:"input-affix mfs-text-muted input-affix--prepend"},Mo=["id","type","value","placeholder","disabled","readonly"],Do={key:1,class:"input-affix mfs-text-muted input-affix--append"},zo={key:1,class:"input-msg input-msg--error mfs-text-danger"},To={key:2,class:"input-msg mfs-caption"},Ee=D(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:s}){const l=s,o=a=>{const r=a.target;l("update:modelValue",r.value)};return(a,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",xo,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",No,"*")):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}])},[a.$slots.prepend?(e.openBlock(),e.createElementBlock("span",So,[e.renderSlot(a.$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:o,onFocus:r[0]||(r[0]=i=>a.$emit("focus",i)),onBlur:r[1]||(r[1]=i=>a.$emit("blur",i))},null,40,Mo),a.$slots.append?(e.openBlock(),e.createElementBlock("span",Do,[e.renderSlot(a.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],2),t.error?(e.openBlock(),e.createElementBlock("p",zo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",To,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-b6818f92"]]),je=D(e.defineComponent({__name:"Badge",props:{variant:{default:"primary"},size:{default:"md"}},setup(t){return(s,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(s.$slots,"prepend",{},void 0,!0),e.renderSlot(s.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-649f6dac"]]),Lo=["checked","disabled"],Io={key:0,class:"switch__label"},ce=D(e.defineComponent({__name:"Switch",props:{modelValue:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=s,o=a=>{const r=a.target;l("update:modelValue",r.checked),l("change",r.checked)};return(a,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:o},null,40,Lo),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||a.$slots.default?(e.openBlock(),e.createElementBlock("span",Io,[e.renderSlot(a.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-de02acdb"]]),Ro={key:0,class:"modal-header mfs-flex mfs-items-center mfs-justify-between"},Po={class:"modal-title mfs-title"},Fo={class:"modal-body"},Ao={key:1,class:"modal-footer mfs-flex mfs-items-center mfs-justify-end mfs-gap-3"},me=D(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:s}){const l=t,o=s,a=()=>{o("update:modelValue",!1),o("close")},r=()=>{l.closeOnBackdrop&&a()};let i="",c=!1;const d=n=>{if(!(typeof document>"u"))if(n){if(c)return;i=document.body.style.overflow,document.body.style.overflow="hidden",c=!0}else c&&(document.body.style.overflow=i,c=!1)};return e.onMounted(()=>{l.modelValue&&d(!0)}),e.watch(()=>l.modelValue,n=>d(n)),e.onBeforeUnmount(()=>{d(!1)}),(n,k)=>(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:k[0]||(k[0]=e.withModifiers(()=>{},["stop"]))},[t.title||n.$slots.header?(e.openBlock(),e.createElementBlock("div",Ro,[e.renderSlot(n.$slots,"header",{},()=>[e.createElementVNode("h3",Po,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:a,"aria-label":"Close modal"}," ✕ ")])):e.createCommentVNode("",!0),e.createElementVNode("div",Fo,[e.renderSlot(n.$slots,"default",{},void 0,!0)]),n.$slots.footer?(e.openBlock(),e.createElementBlock("div",Ao,[e.renderSlot(n.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-3a4fa0a7"]]),jo=["for"],Ko={key:0,class:"mfs-text-danger"},Oo=["id","value","placeholder","disabled","readonly","rows","maxlength","aria-invalid"],Uo={key:1,class:"textarea-footer mfs-flex mfs-items-center mfs-justify-between mfs-gap-2"},Ho={key:0,class:"textarea-msg textarea-msg--error mfs-text-danger"},Wo={key:1,class:"textarea-msg mfs-caption"},Go={key:2,class:"textarea-spacer mfs-flex-1"},qo={key:3,class:"textarea-count mfs-caption"},lt=D(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:s}){const l=t,o=s,a=e.useId(),r=e.computed(()=>l.id||`mfs-textarea-${a}`),i=e.ref(null),c=e.computed(()=>(l.modelValue??"").length),d=()=>{const k=i.value;!k||!l.autoResize||(k.style.height="auto",k.style.height=`${k.scrollHeight}px`)},n=k=>{const h=k.target;o("update:modelValue",h.value),e.nextTick(d)};return e.watch(()=>l.modelValue,()=>e.nextTick(d)),e.onMounted(d),(k,h)=>(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",Ko,"*")):e.createCommentVNode("",!0)],8,jo)):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:i,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:n,onFocus:h[0]||(h[0]=y=>k.$emit("focus",y)),onBlur:h[1]||(h[1]=y=>k.$emit("blur",y))},null,40,Oo)],2),t.error||t.hint||t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("div",Uo,[t.error?(e.openBlock(),e.createElementBlock("p",Ho,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Wo,e.toDisplayString(t.hint),1)):(e.openBlock(),e.createElementBlock("span",Go)),t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("span",qo,[e.createTextVNode(e.toDisplayString(c.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-607879e7"]]),Yo=["for"],Xo={key:0,class:"num-required mfs-text-danger"},Zo={class:"num-box mfs-surface mfs-rounded mfs-shadow-inset mfs-flex mfs-items-center mfs-gap-1-5"},Jo=["disabled"],Qo={class:"num-input-area mfs-flex-1 mfs-flex mfs-items-center mfs-gap-1 mfs-min-w-0 mfs-px-1"},vo={key:0,class:"num-prefix mfs-text-muted mfs-font-semibold mfs-select-none"},en=["id","value","placeholder","disabled","readonly","aria-invalid","aria-valuemin","aria-valuemax","aria-valuenow"],tn=["disabled"],ln={key:1,class:"num-msg num-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},on={key:2,class:"num-msg mfs-caption mfs-m-0"},ot=D(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:s}){const l=t,o=s,a=e.useId(),r=e.computed(()=>l.id||`mfs-num-${a}`),i=e.ref(!1),c=e.ref(""),d=u=>{let b=u;l.min!==void 0&&(b=Math.max(l.min,b)),l.max!==void 0&&(b=Math.min(l.max,b));const g=Math.pow(10,l.decimals);return Math.round(b*g)/g},n=e.computed(()=>l.min!==void 0&&l.modelValue!==null&&l.modelValue<=l.min),k=e.computed(()=>l.max!==void 0&&l.modelValue!==null&&l.modelValue>=l.max),h=e.computed(()=>i.value?c.value:l.modelValue===null||l.modelValue===void 0||Number.isNaN(l.modelValue)?"":l.decimals>0?l.modelValue.toFixed(l.decimals):String(l.modelValue)),y=()=>{i.value=!0,c.value=l.modelValue!==null&&l.modelValue!==void 0?String(l.modelValue):""},f=u=>{const b=u.target.value;if(c.value=b,b.trim()===""||b==="-"){b.trim()===""&&o("update:modelValue",null);return}const g=Number(b);Number.isNaN(g)||o("update:modelValue",g)},p=()=>{if(i.value=!1,c.value.trim()===""){o("update:modelValue",null),o("change",null);return}const u=Number(c.value);if(Number.isNaN(u)){o("update:modelValue",null),o("change",null);return}const b=d(u);o("update:modelValue",b),o("change",b)},m=u=>{if(l.disabled||l.readonly)return;const b=l.modelValue??(l.min!==void 0?l.min:0),g=d(b+u*l.step);o("update:modelValue",g),o("change",g)};return(u,b)=>(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",Xo,"*")):e.createCommentVNode("",!0)],8,Yo)):e.createCommentVNode("",!0),e.createElementVNode("div",Zo,[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||n.value,onClick:b[0]||(b[0]=g=>m(-1))},[...b[4]||(b[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,Jo),e.createElementVNode("div",Qo,[t.prefix?(e.openBlock(),e.createElementBlock("span",vo,e.toDisplayString(t.prefix),1)):e.createCommentVNode("",!0),e.createElementVNode("input",{id:r.value,type:"text",inputmode:"decimal",value:h.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:y,onBlur:p,onInput:f,onKeydown:[b[1]||(b[1]=e.withKeys(e.withModifiers(g=>m(1),["prevent"]),["up"])),b[2]||(b[2]=e.withKeys(e.withModifiers(g=>m(-1),["prevent"]),["down"]))]},null,40,en)]),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||k.value,onClick:b[3]||(b[3]=g=>m(1))},[...b[5]||(b[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,tn)]),t.error?(e.openBlock(),e.createElementBlock("p",ln,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",on,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-94f092b6"]]),nn=["for"],an={key:0,class:"mfs-text-danger"},sn={class:"pwd-box mfs-flex mfs-items-center mfs-surface mfs-rounded mfs-shadow-inset"},rn=["id","type","value","placeholder","disabled","readonly","aria-invalid"],dn=["aria-label","aria-pressed","disabled"],cn={key:0,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},mn={key:1,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},fn={key:1,class:"pwd-strength mfs-flex mfs-items-center mfs-gap-2","aria-live":"polite"},pn={class:"pwd-bars mfs-flex-1"},un={key:2,class:"pwd-msg pwd-msg--error mfs-text-danger"},kn={key:3,class:"pwd-msg mfs-caption"},nt=D(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:s}){const l=t,o=s,a=e.useId(),r=e.computed(()=>l.id||`mfs-pwd-${a}`),i=e.ref(!1),c=n=>{o("update:modelValue",n.target.value)},d=e.computed(()=>{const n=l.modelValue||"";let k=0;return n.length>=6&&k++,n.length>=10&&k++,/[a-z]/.test(n)&&/[A-Z]/.test(n)&&k++,/\d/.test(n)&&/[^A-Za-z0-9]/.test(n)&&k++,k=Math.max(1,Math.min(4,k)),{score:k,...{1:{label:"Weak",color:"var(--danger, #f43f5e)"},2:{label:"Fair",color:"var(--warning, #f59e0b)"},3:{label:"Good",color:"var(--primary, #8b5cf6)"},4:{label:"Strong",color:"var(--success, #10b981)"}}[k]}});return(n,k)=>(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",an,"*")):e.createCommentVNode("",!0)],8,nn)):e.createCommentVNode("",!0),e.createElementVNode("div",sn,[e.createElementVNode("input",{id:r.value,type:i.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:c,onFocus:k[0]||(k[0]=h=>n.$emit("focus",h)),onBlur:k[1]||(k[1]=h=>n.$emit("blur",h))},null,40,rn),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":i.value?"Hide password":"Show password","aria-pressed":i.value,disabled:t.disabled,onClick:k[2]||(k[2]=h=>i.value=!i.value)},[i.value?(e.openBlock(),e.createElementBlock("svg",cn,[...k[3]||(k[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",mn,[...k[4]||(k[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,dn)]),t.showStrength&&t.modelValue?(e.openBlock(),e.createElementBlock("div",fn,[e.createElementVNode("div",pn,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(4,h=>e.createElementVNode("span",{key:h,class:e.normalizeClass(["pwd-bar mfs-pill",{"pwd-bar--active":h<=d.value.score}]),style:e.normalizeStyle({backgroundColor:h<=d.value.score?d.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:d.value.color})},e.toDisplayString(d.value.label),5)])):e.createCommentVNode("",!0),t.error?(e.openBlock(),e.createElementBlock("p",un,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",kn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-e18398e6"]]),hn=["id","checked","disabled","aria-label","tabindex"],gn={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round",class:"checkbox__icon"},yn={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"},bn={key:0,class:"checkbox__label"},fe=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue.includes(l.value):!!l.modelValue);e.watchEffect(()=>{a.value&&(a.value.indeterminate=l.indeterminate)}),e.onMounted(()=>{a.value&&(a.value.indeterminate=l.indeterminate)});const i=c=>{const d=c.target.checked;let n;Array.isArray(l.modelValue)?n=d?[...l.modelValue,l.value]:l.modelValue.filter(k=>k!==l.value):n=d,o("update:modelValue",n),o("change",n)};return(c,d)=>(e.openBlock(),e.createElementBlock("label",{class:e.normalizeClass(["checkbox mfs-text",{"checkbox--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("input",{ref_key:"inputRef",ref:a,id:t.id,type:"checkbox",class:"checkbox__input",checked:r.value,disabled:t.disabled,"aria-label":t.ariaLabel,tabindex:t.tabindex,onChange:i},null,40,hn),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",gn,[...d[0]||(d[0]=[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"},null,-1)])])):r.value?(e.openBlock(),e.createElementBlock("svg",yn,[...d[1]||(d[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),t.label||c.$slots.default?(e.openBlock(),e.createElementBlock("span",bn,[e.renderSlot(c.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-c6f5af78"]]),Bn=["id","name","value","checked","disabled"],_n={key:0,class:"radio__label"},Ke=D(e.defineComponent({__name:"RadioButton",props:{modelValue:{},value:{},name:{},label:{},disabled:{type:Boolean,default:!1},id:{}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.computed(()=>l.modelValue===l.value),r=()=>{l.disabled||(o("update:modelValue",l.value),o("change",l.value))};return(i,c)=>(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:a.value,disabled:t.disabled,onChange:r},null,40,Bn),e.createElementVNode("span",{class:e.normalizeClass(["radio__circle mfs-surface mfs-shadow",{"radio__circle--checked":a.value}])},[...c[0]||(c[0]=[e.createElementVNode("span",{class:"radio__dot"},null,-1)])],2),t.label||i.$slots.default?(e.openBlock(),e.createElementBlock("span",_n,[e.renderSlot(i.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-7cb79a2c"]]);function oe(t,s,l,o){const a=(o==null?void 0:o.offset)??6,r=(o==null?void 0:o.matchWidth)??!1,i=(o==null?void 0:o.align)??"left",c=e.ref(0),d=e.ref(0),n=e.ref(void 0),k=()=>{var E;if(typeof window>"u"||!t.value)return;const p=t.value.getBoundingClientRect(),m=(E=s.value)==null?void 0:E.getBoundingClientRect(),u=Math.max((m==null?void 0:m.width)??0,r?p.width:0)||p.width,b=(m==null?void 0:m.height)??0;let g=p.left;i==="right"?g=p.right-u:i==="center"&&(g=p.left+(p.width-u)/2);const B=8,w=Math.max(B,window.innerWidth-u-B);g=Math.min(Math.max(B,g),w);const _=window.innerHeight-p.bottom,$=p.top;let C=p.bottom+a;b>0&&p.bottom+a+b>window.innerHeight-B&&$>_&&(C=Math.max(B,p.top-b-a)),c.value=C,d.value=g,n.value=r?p.width:void 0},h=e.computed(()=>{const p={position:"fixed",top:`${c.value}px`,left:`${d.value}px`,zIndex:10100};return r&&n.value!==void 0&&(p.minWidth=`${n.value}px`),p}),y=p=>{var m,u;return p instanceof Node?!!((m=t.value)!=null&&m.contains(p)||(u=s.value)!=null&&u.contains(p)):!1},f=()=>{l.value&&k()};return e.watch(l,p=>{p&&(k(),e.nextTick(k))}),e.watch(s,p=>{p&&l.value&&k()}),e.onMounted(()=>{typeof window>"u"||(window.addEventListener("scroll",f,!0),window.addEventListener("resize",f),l.value&&k())}),e.onBeforeUnmount(()=>{typeof window>"u"||(window.removeEventListener("scroll",f,!0),window.removeEventListener("resize",f))}),{overlayStyle:h,updatePosition:k,containsTarget:y}}const wn={key:0,class:"mfs-text-danger"},En=["aria-expanded","aria-invalid","disabled"],$n={class:"select-actions mfs-inline-flex mfs-items-center mfs-text-muted"},Vn={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Cn={key:0,class:"select-search-box"},xn={class:"select-options mfs-flex mfs-flex-col"},Nn=["aria-selected","disabled","onClick","onMouseenter"],Sn={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"},Mn={key:0,class:"select-empty mfs-empty-state"},Dn={key:1,class:"select-empty mfs-empty-state"},zn={key:1,class:"select-msg select-msg--error mfs-text-danger"},Tn={key:2,class:"select-msg mfs-caption"},$e=D(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:s}){const l=t,o=s,a=e.useId(),r=`mfs-select-${a}`,i=`mfs-select-list-${a}`,c=e.ref(null),d=e.ref(null),n=e.ref(null),k=e.ref(null),h=e.ref(!1),y=e.ref(""),f=e.ref(-1),{overlayStyle:p,containsTarget:m}=oe(d,n,h,{matchWidth:!0}),u=e.computed(()=>l.options.map(N=>typeof N=="string"?{label:N,value:N}:N)),b=e.computed(()=>{if(l.remote)return u.value;const N=y.value.trim().toLowerCase();return N?u.value.filter(I=>I.label.toLowerCase().includes(N)):u.value}),g=N=>{o("filter",{value:N.target.value})},B=e.computed(()=>u.value.find(N=>N.value===l.modelValue)),w=()=>{l.disabled||(h.value=!0,f.value=b.value.findIndex(N=>N.value===l.modelValue),l.searchable&&e.nextTick(()=>{var N;return(N=k.value)==null?void 0:N.focus()}))},_=()=>{h.value=!1,y.value=""},$=()=>{h.value?_():w()},C=N=>{N.disabled||(o("update:modelValue",N.value),o("change",N.value),_())},E=()=>{o("update:modelValue",null),o("change",null)},V=N=>{if(!h.value){(N.key==="ArrowDown"||N.key==="ArrowUp"||N.key==="Enter"||N.key===" ")&&(N.preventDefault(),w());return}const I=b.value;if(N.key==="Escape")N.preventDefault(),_();else if(N.key==="ArrowDown"){if(N.preventDefault(),!I.length)return;f.value=(f.value+1)%I.length}else if(N.key==="ArrowUp"){if(N.preventDefault(),!I.length)return;f.value=(f.value-1+I.length)%I.length}else if(N.key==="Enter"){N.preventDefault();const H=I[f.value];H&&!H.disabled&&C(H)}},M=N=>{m(N.target)||_()};return e.onMounted(()=>document.addEventListener("mousedown",M)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",M)),(N,I)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:c,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",wn,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:d,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":h.value,"aria-controls":i,"aria-invalid":!!t.error,disabled:t.disabled,onClick:$,onKeydown:V},[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",$n,[t.loading?(e.openBlock(),e.createElementBlock("span",Vn)):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"])},[...I[1]||(I[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":h.value}])},[...I[2]||(I[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))])],40,En),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"select-pop"},{default:e.withCtx(()=>[h.value?(e.openBlock(),e.createElementBlock("div",{key:0,id:i,ref_key:"overlayRef",ref:n,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",Cn,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:k,"onUpdate:modelValue":I[0]||(I[0]=H=>y.value=H),type:"text",class:"select-search mfs-w-full mfs-text-sm mfs-inset",placeholder:"Search...",onInput:g,onKeydown:V},null,544),[[e.vModelText,y.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",xn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(H,G)=>(e.openBlock(),e.createElementBlock("button",{key:String(H.value)+G,type:"button",role:"option","aria-selected":H.value===t.modelValue,disabled:H.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":H.value===t.modelValue,"select-option--active":G===f.value}]),onClick:Q=>C(H),onMouseenter:Q=>f.value=G},[e.renderSlot(N.$slots,"option",{option:H,selected:H.value===t.modelValue},()=>[e.createElementVNode("span",null,e.toDisplayString(H.label),1),H.value===t.modelValue?(e.openBlock(),e.createElementBlock("svg",Sn,[...I[3]||(I[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],!0)],42,Nn))),128)),t.loading&&b.value.length===0?(e.openBlock(),e.createElementBlock("div",Mn,[...I[4]||(I[4]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):b.value.length===0?(e.openBlock(),e.createElementBlock("div",Dn,[e.renderSlot(N.$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",zn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Tn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-96053d34"]]),Ln={key:0,class:"ms-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},In={key:0,class:"mfs-text-danger"},Rn=["aria-expanded","aria-invalid","onKeydown"],Pn={class:"ms-chips mfs-flex-1 mfs-flex mfs-flex-wrap mfs-items-center mfs-gap-1-5"},Fn={class:"ms-chip-text"},An=["aria-label","onClick"],jn={key:0,class:"ms-placeholder mfs-text-muted"},Kn={key:0,class:"mfs-spinner mfs-spinner--sm mfs-shrink-0","aria-hidden":"true"},On={key:0,class:"ms-search-box"},Un={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},Hn={class:"ms-options mfs-flex mfs-flex-col mfs-overflow-y-auto"},Wn=["aria-selected","disabled","onClick"],Gn={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},qn={key:0,class:"ms-empty mfs-empty-state"},Yn={key:1,class:"ms-empty mfs-empty-state"},Xn={key:1,class:"ms-msg ms-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Zn={key:2,class:"ms-msg mfs-caption mfs-m-0"},at=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(""),{overlayStyle:k,containsTarget:h}=oe(r,i,d,{matchWidth:!0}),y=e.computed(()=>l.options.map(V=>typeof V=="string"?{label:V,value:V}:V)),f=e.computed(()=>{if(l.remote)return y.value;const V=n.value.trim().toLowerCase();return V?y.value.filter(M=>M.label.toLowerCase().includes(V)):y.value}),p=V=>{o("filter",{value:V.target.value})},m=e.computed(()=>y.value.filter(V=>!V.disabled)),u=e.computed(()=>y.value.filter(V=>l.modelValue.includes(V.value))),b=e.computed(()=>m.value.length>0&&m.value.every(V=>l.modelValue.includes(V.value))),g=V=>l.modelValue.includes(V),B=()=>{l.disabled||(d.value=!d.value,d.value&&l.searchable&&e.nextTick(()=>{var V;return(V=c.value)==null?void 0:V.focus()}))},w=()=>{d.value=!1,n.value=""},_=V=>{if(V.disabled)return;const M=g(V.value)?l.modelValue.filter(N=>N!==V.value):[...l.modelValue,V.value];o("update:modelValue",M),o("change",M)},$=V=>{const M=l.modelValue.filter(N=>N!==V);o("update:modelValue",M),o("change",M)},C=()=>{const V=b.value?[]:m.value.map(M=>M.value);o("update:modelValue",V),o("change",V)},E=V=>{h(V.target)||w()};return e.onMounted(()=>document.addEventListener("mousedown",E)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",E)),(V,M)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:a,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",Ln,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",In,"*")):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":d.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(w,["escape"]),e.withKeys(e.withModifiers(B,["prevent"]),["enter"])]},[e.createElementVNode("div",Pn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,N=>(e.openBlock(),e.createElementBlock("span",{key:String(N.value),class:"ms-chip mfs-inline-flex mfs-items-center mfs-gap-1 mfs-bg-primary mfs-font-semibold mfs-pill"},[e.createElementVNode("span",Fn,e.toDisplayString(N.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 ${N.label}`,onClick:e.withModifiers(I=>$(N.value),["stop"])},[...M[1]||(M[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,An))]))),128)),u.value.length===0?(e.openBlock(),e.createElementBlock("span",jn,e.toDisplayString(t.placeholder),1)):e.createCommentVNode("",!0)]),t.loading?(e.openBlock(),e.createElementBlock("span",Kn)):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":d.value}])},[...M[2]||(M[2]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],40,Rn),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ms-pop"},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:i,role:"listbox","aria-multiselectable":"true",style:e.normalizeStyle(e.unref(k)),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",On,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:c,"onUpdate:modelValue":M[0]||(M[0]=N=>n.value=N),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(w,["escape"])},null,544),[[e.vModelText,n.value]])])):e.createCommentVNode("",!0),t.selectAll&&m.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:C},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":b.value}])},[b.value?(e.openBlock(),e.createElementBlock("svg",Un,[...M[3]||(M[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),M[4]||(M[4]=e.createElementVNode("span",null,"Select All",-1))])):e.createCommentVNode("",!0),e.createElementVNode("div",Hn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(N,I)=>(e.openBlock(),e.createElementBlock("button",{key:String(N.value)+I,type:"button",role:"option","aria-selected":g(N.value),disabled:N.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":g(N.value)}]),onClick:H=>_(N)},[e.createElementVNode("span",{class:e.normalizeClass(["ms-check mfs-inline-flex mfs-items-center mfs-justify-center mfs-shrink-0",{"ms-check--on":g(N.value)}])},[g(N.value)?(e.openBlock(),e.createElementBlock("svg",Gn,[...M[5]||(M[5]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],2),e.createElementVNode("span",null,e.toDisplayString(N.label),1)],10,Wn))),128)),t.loading&&f.value.length===0?(e.openBlock(),e.createElementBlock("div",qn,[...M[6]||(M[6]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):f.value.length===0?(e.openBlock(),e.createElementBlock("div",Yn,[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",Xn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Zn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-196f1d68"]]),Jn={key:0,class:"mfs-flex mfs-justify-between mfs-items-center mfs-text-sm"},Qn={class:"mfs-font-semibold mfs-text"},vn={class:"slider-readout mfs-text-primary mfs-font-semibold"},ea=["aria-valuemin","aria-valuemax","aria-valuenow"],ta={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},la=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],oa={key:0,class:"slider-tooltip mfs-absolute mfs-surface mfs-rounded-sm mfs-shadow-card mfs-whitespace-nowrap mfs-font-semibold"},st=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.computed(()=>typeof l.modelValue=="number"?l.modelValue:l.min),c=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[0]:l.min),d=e.computed(()=>Array.isArray(l.modelValue)?l.modelValue[1]:l.max),n=B=>{const w=l.max-l.min;return w<=0?0:Math.max(0,Math.min(100,(B-l.min)/w*100))},k=e.computed(()=>{if(l.range){const B=n(c.value),w=n(d.value);return{left:`${B}%`,width:`${Math.max(0,w-B)}%`}}return{left:"0%",width:`${n(i.value)}%`}}),h=B=>{const w=Math.max(l.min,Math.min(l.max,B)),_=Math.round((w-l.min)/l.step)*l.step+l.min;return Math.max(l.min,Math.min(l.max,Number(_.toFixed(6))))},y=B=>{var $;const w=($=a.value)==null?void 0:$.getBoundingClientRect();if(!w||w.width===0)return l.min;const _=Math.max(0,Math.min(1,(B-w.left)/w.width));return h(l.min+_*(l.max-l.min))},f=(B,w)=>{if(l.range){const _=[c.value,d.value];B===0?_[0]=Math.min(w,_[1]):_[1]=Math.max(w,_[0]),o("update:modelValue",_)}else o("update:modelValue",w)},p=B=>{r.value!==null&&f(r.value,y(B.clientX))},m=()=>{r.value!==null&&(r.value=null,o("change",l.modelValue)),window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",m)},u=(B,w)=>{l.disabled||(w.preventDefault(),r.value=B,window.addEventListener("pointermove",p),window.addEventListener("pointerup",m))},b=B=>{if(l.disabled)return;const w=y(B.clientX);let _=0;l.range&&(_=Math.abs(w-c.value)<=Math.abs(w-d.value)?0:1),f(_,w),u(_,B)},g=(B,w)=>{if(l.disabled)return;const _=w.key==="ArrowRight"||w.key==="ArrowUp"?l.step:w.key==="ArrowLeft"||w.key==="ArrowDown"?-l.step:0;if(!_)return;w.preventDefault();const $=l.range?B===0?c.value:d.value:i.value;f(B,h($+_)),o("change",l.modelValue)};return e.onBeforeUnmount(m),(B,w)=>(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",Jn,[e.createElementVNode("span",Qn,e.toDisplayString(t.label),1),e.createElementVNode("span",vn,e.toDisplayString(t.range&&Array.isArray(t.modelValue)?`${t.modelValue[0]} – ${t.modelValue[1]}`:i.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"trackRef",ref:a,class:"slider-track mfs-relative mfs-surface mfs-pill mfs-shadow-inset mfs-cursor-pointer",onPointerdown:b},[e.createElementVNode("div",{class:"slider-fill mfs-absolute mfs-pill mfs-bg-primary",style:e.normalizeStyle(k.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:`${n(c.value)}%`}),"aria-valuemin":t.min,"aria-valuemax":d.value,"aria-valuenow":c.value,"aria-label":"Minimum value",onPointerdown:w[0]||(w[0]=e.withModifiers(_=>u(0,_),["stop"])),onKeydown:w[1]||(w[1]=_=>g(0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",ta,e.toDisplayString(c.value),1)):e.createCommentVNode("",!0)],46,ea)):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:`${n(t.range?d.value:i.value)}%`}),"aria-valuemin":t.range?c.value:t.min,"aria-valuemax":t.max,"aria-valuenow":t.range?d.value:i.value,"aria-label":t.range?"Maximum value":t.label||"Slider",onPointerdown:w[2]||(w[2]=e.withModifiers(_=>u(t.range?1:0,_),["stop"])),onKeydown:w[3]||(w[3]=_=>g(t.range?1:0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",oa,e.toDisplayString(t.range?d.value:i.value),1)):e.createCommentVNode("",!0)],46,la)],544)],2))}}),[["__scopeId","data-v-755740d4"]]),na={key:0,class:"rating-label mfs-text"},aa=["aria-label","aria-valuemax","aria-valuenow"],sa=["disabled","aria-label","onMousemove","onClick"],ra={viewBox:"0 0 24 24",width:"24",height:"24",class:"rating-svg"},ia=["id"],da=["fill","stroke"],rt=D(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:s}){const l=t,o=s,a=`mfs-star-${e.useId()}`,r=e.ref(null),i=e.computed(()=>r.value!==null?r.value:l.modelValue),c=(f,p)=>{if(!l.allowHalf)return f;const m=p.currentTarget.getBoundingClientRect();return p.clientX-m.left<m.width/2?f-.5:f},d=(f,p)=>{l.disabled||l.readonly||(r.value=c(f,p))},n=(f,p)=>{if(l.disabled||l.readonly)return;const m=c(f,p);o("update:modelValue",m),o("change",m)},k=f=>{if(l.disabled||l.readonly)return;const p=l.allowHalf?.5:1;if(f.key==="ArrowRight"||f.key==="ArrowUp"){f.preventDefault();const m=Math.min(l.stars,l.modelValue+p);o("update:modelValue",m),o("change",m)}else if(f.key==="ArrowLeft"||f.key==="ArrowDown"){f.preventDefault();const m=Math.max(0,l.modelValue-p);o("update:modelValue",m),o("change",m)}},h=f=>{const p=i.value;return p>=f?"var(--warning, #f59e0b)":l.allowHalf&&p>=f-.5?`url(#${a}-${f})`:"transparent"},y=f=>i.value>=f-.5?"var(--warning, #f59e0b)":"var(--text-muted, #94a3b8)";return(f,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",na,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]=m=>r.value=null),onKeydown:k},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.stars,m=>(e.openBlock(),e.createElementBlock("button",{key:m,type:"button",class:"rating-star",disabled:t.disabled,"aria-label":`Rate ${m} of ${t.stars}`,onMousemove:u=>d(m,u),onClick:u=>n(m,u)},[(e.openBlock(),e.createElementBlock("svg",ra,[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`${a}-${m}`,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,ia)]),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:h(m),stroke:y(m),"stroke-width":"1.8","stroke-linejoin":"round"},null,8,da)]))],40,sa))),128))],40,aa)],2))}}),[["__scopeId","data-v-2a8aa484"]]),ca={key:0,class:"cp-label mfs-text mfs-text-sm mfs-font-semibold"},ma={class:"cp-container mfs-relative"},fa=["disabled","aria-expanded"],pa={class:"cp-hex mfs-font-mono"},ua={class:"cp-native-row mfs-flex mfs-items-center mfs-gap-2"},ka=["value"],ha=["value"],ga={class:"cp-rgb mfs-grid mfs-grid-cols-3 mfs-gap-1-5"},ya={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},ba=["value"],Ba={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},_a=["value"],wa={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},Ea=["value"],$a={key:0,class:"cp-presets mfs-grid mfs-grid-cols-4 mfs-gap-2"},Va=["aria-label","onClick"],it=D(e.defineComponent({__name:"ColorPicker",props:{modelValue:{default:"#8b5cf6"},presets:{default:()=>["#8b5cf6","#38bdf8","#10b981","#f59e0b","#f43f5e","#ec4899","#64748b","#0f172a"]},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=oe(a,r,i,{offset:8}),n=e.computed(()=>/^#[0-9a-fA-F]{6}$/.test(l.modelValue)?l.modelValue:"#8b5cf6"),k=e.computed(()=>{const b=n.value.slice(1);return{r:parseInt(b.slice(0,2),16),g:parseInt(b.slice(2,4),16),b:parseInt(b.slice(4,6),16)}}),h=b=>{o("update:modelValue",b),o("change",b)},y=b=>{const g=b.startsWith("#")?b:`#${b}`;/^#[0-9a-fA-F]{6}$/.test(g)&&h(g.toLowerCase())},f=b=>Math.max(0,Math.min(255,b)).toString(16).padStart(2,"0"),p=(b,g)=>{const B=Number(g.target.value);if(Number.isNaN(B))return;const w={...k.value,[b]:B};h(`#${f(w.r)}${f(w.g)}${f(w.b)}`)},m=b=>{i.value&&!d(b.target)&&(i.value=!1)},u=b=>{b.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",m),document.addEventListener("keydown",u)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",m),document.removeEventListener("keydown",u)}),(b,g)=>(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",ca,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",ma,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,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":i.value,"aria-label":"Pick a color",onClick:g[0]||(g[0]=B=>i.value=!i.value)},[e.createElementVNode("span",{class:"cp-swatch mfs-rounded-full",style:e.normalizeStyle({backgroundColor:t.modelValue})},null,4),e.createElementVNode("span",pa,e.toDisplayString(t.modelValue.toUpperCase()),1)],8,fa),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cp-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),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",ua,[e.createElementVNode("input",{type:"color",class:"cp-native mfs-p-0 mfs-border-none mfs-rounded-sm mfs-bg-transparent mfs-cursor-pointer",value:n.value,"aria-label":"Color palette",onInput:g[1]||(g[1]=B=>y(B.target.value))},null,40,ka),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:g[2]||(g[2]=B=>y(B.target.value))},null,40,ha)]),e.createElementVNode("div",ga,[e.createElementVNode("label",ya,[g[6]||(g[6]=e.createElementVNode("span",null,"R",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:k.value.r,onInput:g[3]||(g[3]=B=>p("r",B))},null,40,ba)]),e.createElementVNode("label",Ba,[g[7]||(g[7]=e.createElementVNode("span",null,"G",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:k.value.g,onInput:g[4]||(g[4]=B=>p("g",B))},null,40,_a)]),e.createElementVNode("label",wa,[g[8]||(g[8]=e.createElementVNode("span",null,"B",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:k.value.b,onInput:g[5]||(g[5]=B=>p("b",B))},null,40,Ea)])]),t.presets.length?(e.openBlock(),e.createElementBlock("div",$a,[(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()===n.value.toLowerCase()}]),style:e.normalizeStyle({backgroundColor:B}),"aria-label":`Select color ${B}`,onClick:w=>h(B)},null,14,Va))),128))])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:1})]))])],2))}}),[["__scopeId","data-v-5c82328d"]]),Ca={key:0,class:"dp-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},xa={key:0,class:"dp-required mfs-text-danger"},Na={class:"dp-container mfs-relative"},Sa=["disabled","aria-expanded","aria-invalid"],Ma={class:"dp-header mfs-flex mfs-items-center mfs-justify-between"},Da={class:"dp-month-year mfs-font-bold mfs-text"},za={class:"dp-weekdays"},Ta=["disabled","onClick"],La={key:1,class:"dp-msg dp-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Ia={key:2,class:"dp-msg mfs-caption mfs-m-0"},Ve=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=oe(a,r,i,{offset:8}),n=new Date,k=K=>{if(!K)return null;const U=K instanceof Date?new Date(K.getTime()):new Date(K);return Number.isNaN(U.getTime())?null:new Date(U.getFullYear(),U.getMonth(),U.getDate())},h=e.computed(()=>Array.isArray(l.modelValue)?k(l.modelValue[0])||n:k(l.modelValue)||n),y=e.ref(h.value.getFullYear()),f=e.ref(h.value.getMonth()),p=e.ref(null),m=["Su","Mo","Tu","We","Th","Fr","Sa"],u=["January","February","March","April","May","June","July","August","September","October","November","December"],b=e.computed(()=>u[f.value]),g=K=>{const U=new Date(y.value,f.value+K,1);y.value=U.getFullYear(),f.value=U.getMonth()},B=e.computed(()=>{const U=new Date(y.value,f.value,1).getDay(),Y=[];for(let L=0;L<42;L++){const T=new Date(y.value,f.value,1-U+L);Y.push({key:`${T.getFullYear()}-${T.getMonth()}-${T.getDate()}`,date:T,inMonth:T.getMonth()===f.value})}return Y}),w=(K,U)=>!!(K&&U&&K.getFullYear()===U.getFullYear()&&K.getMonth()===U.getMonth()&&K.getDate()===U.getDate()),_=e.computed(()=>k(l.min)),$=e.computed(()=>k(l.max)),C=K=>!!(_.value&&K<_.value||$.value&&K>$.value),E=e.computed(()=>!l.range&&!Array.isArray(l.modelValue)?k(l.modelValue):null),V=e.computed(()=>l.range?p.value?[p.value,null]:Array.isArray(l.modelValue)?[k(l.modelValue[0]),k(l.modelValue[1])]:[null,null]:[null,null]),M=K=>{if(!l.range)return w(K,E.value);const[U,Y]=V.value;return w(K,U)||w(K,Y)},N=K=>{if(!l.range)return!1;const[U,Y]=V.value;return!!(U&&Y&&K>U&&K<Y)},I=K=>K?`${K.getFullYear()}-${String(K.getMonth()+1).padStart(2,"0")}-${String(K.getDate()).padStart(2,"0")}`:"",H=e.computed(()=>{if(!l.range)return I(E.value);if(Array.isArray(l.modelValue)){const K=I(k(l.modelValue[0])),U=I(k(l.modelValue[1]));return K&&U?`${K} – ${U}`:K}return""}),G=K=>{if(!C(K)){if(!l.range){o("update:modelValue",K),o("change",K),i.value=!1;return}if(!p.value)p.value=K;else{const U=K<p.value?[K,p.value]:[p.value,K];p.value=null,o("update:modelValue",U),o("change",U),i.value=!1}}},Q=K=>{d(K.target)||(i.value=!1)},ee=K=>{K.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",Q),document.addEventListener("keydown",ee)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",Q),document.removeEventListener("keydown",ee)}),(K,U)=>(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",Ca,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",xa,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Na,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,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":i.value,"aria-invalid":!!t.error,onClick:U[0]||(U[0]=Y=>i.value=!i.value)},[U[3]||(U[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-cbbd3b1e><rect x="3" y="4" width="18" height="18" rx="2" ry="2" data-v-cbbd3b1e></rect><line x1="16" y1="2" x2="16" y2="6" data-v-cbbd3b1e></line><line x1="8" y1="2" x2="8" y2="6" data-v-cbbd3b1e></line><line x1="3" y1="10" x2="21" y2="10" data-v-cbbd3b1e></line></svg>',1)),e.createElementVNode("span",{class:e.normalizeClass(["dp-value",{"dp-value--placeholder mfs-text-muted":!H.value}])},e.toDisplayString(H.value||t.placeholder),3)],8,Sa),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"dp-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),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",Ma,[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:U[1]||(U[1]=Y=>g(-1))},[...U[4]||(U[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",Da,e.toDisplayString(b.value)+" "+e.toDisplayString(y.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:U[2]||(U[2]=Y=>g(1))},[...U[5]||(U[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",za,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(m,Y=>e.createElementVNode("span",{key:Y,class:"dp-weekday mfs-text-center mfs-text-xs mfs-font-semibold mfs-text-muted mfs-py-1"},e.toDisplayString(Y),1)),64))]),e.createVNode(e.Transition,{name:"dp-fade",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("div",{key:`${y.value}-${f.value}`,class:"dp-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,Y=>(e.openBlock(),e.createElementBlock("button",{key:Y.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":!Y.inMonth,"dp-day--selected":M(Y.date),"dp-day--in-range":N(Y.date),"dp-day--today":w(Y.date,e.unref(n))}]),disabled:C(Y.date),onClick:L=>G(Y.date)},e.toDisplayString(Y.date.getDate()),11,Ta))),128))]))]),_:1})],4)):e.createCommentVNode("",!0)]),_:1})]))]),t.error?(e.openBlock(),e.createElementBlock("p",La,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-cbbd3b1e"]]),Ra=["role","aria-label"],Pa=["src","alt"],Fa={key:1,class:"avatar__fallback"},Aa=["aria-label"],Ce=D(e.defineComponent({__name:"Avatar",props:{src:{},alt:{},label:{},size:{default:"md"},shape:{default:"circle"},status:{}},setup(t){const s=t,l=e.ref(!1);e.watch(()=>s.src,()=>{l.value=!1});const o=e.computed(()=>s.src&&!l.value?s.src:""),a=()=>{l.value=!0},r=e.computed(()=>{const i=(s.label||s.alt||"").trim();if(!i)return"?";const c=i.split(/\s+/).filter(Boolean);return c.length===1?c[0].slice(0,2).toUpperCase():(c[0][0]+c[c.length-1][0]).toUpperCase()});return(i,c)=>(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:o.value?void 0:"img","aria-label":t.alt||t.label||"Avatar"},[o.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:o.value,alt:t.alt||t.label||"Avatar",class:"avatar__img",onError:a},null,40,Pa)):(e.openBlock(),e.createElementBlock("span",Fa,[e.renderSlot(i.$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,Aa)):e.createCommentVNode("",!0)],10,Ra))}}),[["__scopeId","data-v-05a4906f"]]),ja=["role","tabindex","aria-pressed","onKeydown"],Ka={key:0,class:"chip__prepend"},Oa={class:"chip__label"},ge=D(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:s}){const l=t,o=s,a=r=>{l.clickable&&o("click",r)};return(r,i)=>(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:a,onKeydown:[e.withKeys(a,["enter"]),e.withKeys(e.withModifiers(a,["prevent"]),["space"])]},[r.$slots.prepend?(e.openBlock(),e.createElementBlock("span",Ka,[e.renderSlot(r.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",Oa,[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:i[0]||(i[0]=e.withModifiers(c=>o("remove"),["stop"]))},[...i[1]||(i[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,ja))}}),[["__scopeId","data-v-1d8fa890"]]),Ua=["aria-orientation"],Ha={key:0,class:"divider__label mfs-caption"},dt=D(e.defineComponent({__name:"Divider",props:{orientation:{default:"horizontal"},align:{default:"center"},dashed:{type:Boolean,default:!1}},setup(t){const s=e.useSlots(),l=e.computed(()=>!!s.default);return(o,a)=>(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",Ha,[e.renderSlot(o.$slots,"default",{},void 0,!0)])):e.createCommentVNode("",!0)],10,Ua))}}),[["__scopeId","data-v-2cc4685f"]]),Wa={class:"accordion mfs-flex mfs-flex-col mfs-gap-3 mfs-w-full"},Ga=["aria-expanded","aria-controls","disabled","onClick"],qa={class:"accordion__title mfs-title"},Ya=["id"],Xa={class:"accordion__body mfs-overflow-hidden"},Za={key:0,class:"accordion__text mfs-text-muted"},ct=D(e.defineComponent({__name:"Accordion",props:{items:{default:()=>[]},multiple:{type:Boolean,default:!1},modelValue:{default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=n=>n==null?[]:Array.isArray(n)?n:[n],r=e.ref(a(l.modelValue));e.watch(()=>l.modelValue,n=>{n!==void 0&&(r.value=a(n))});const i=e.computed(()=>l.modelValue!==void 0?a(l.modelValue):r.value),c=n=>i.value.includes(n),d=n=>{const k=c(n);let h;l.multiple?h=k?i.value.filter(f=>f!==n):[...i.value,n]:h=k?[]:[n],r.value=h;const y=l.multiple?h:h[0]??null;o("update:modelValue",y),o("change",y)};return(n,k)=>(e.openBlock(),e.createElementBlock("div",Wa,[t.items.length?e.createCommentVNode("",!0):e.renderSlot(n.$slots,"default",{},void 0,!0,0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,h=>(e.openBlock(),e.createElementBlock("div",{key:h.key,class:e.normalizeClass(["accordion__item","mfs-surface","mfs-rounded","mfs-shadow","mfs-overflow-hidden",{"is-open":c(h.key),"is-disabled mfs-disabled":h.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":c(h.key),"aria-controls":`acc-panel-${h.key}`,disabled:h.disabled,onClick:y=>d(h.key)},[e.createElementVNode("span",qa,e.toDisplayString(h.title),1),k[0]||(k[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,Ga),e.createElementVNode("div",{id:`acc-panel-${h.key}`,class:"accordion__panel",role:"region"},[e.createElementVNode("div",Xa,[e.renderSlot(n.$slots,"item",{item:h,open:c(h.key)},()=>[h.content?(e.openBlock(),e.createElementBlock("p",Za,e.toDisplayString(h.content),1)):e.createCommentVNode("",!0)],!0)])],8,Ya)],2))),128))]))}}),[["__scopeId","data-v-91745f4e"]]),Ja=["aria-busy"],Qa={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},va={key:1,class:"mfs-empty-state"},es={class:"timeline__rail mfs-flex mfs-flex-col mfs-items-center mfs-shrink-0","aria-hidden":"true"},ts={key:0,class:"timeline__icon-text"},ls={key:0,class:"timeline__line mfs-flex-1 mfs-my-1"},os={class:"timeline__content mfs-surface mfs-rounded mfs-shadow-card mfs-flex-1 mfs-mb-4"},ns={class:"timeline__header mfs-flex mfs-justify-between mfs-gap-2-5 mfs-flex-wrap"},as={class:"timeline__title mfs-title mfs-m-0 mfs-font-bold"},ss={key:0,class:"timeline__time mfs-caption"},rs={key:0,class:"timeline__desc mfs-text-muted mfs-m-0"},mt=D(e.defineComponent({__name:"Timeline",props:{items:{default:()=>[]},layout:{default:"vertical"},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},setup(t){return(s,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",Qa,[e.renderSlot(s.$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",va,[e.renderSlot(s.$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,(o,a)=>(e.openBlock(),e.createElementBlock("li",{key:a,class:"timeline__item mfs-flex mfs-gap-4"},[e.createElementVNode("div",es,[e.createElementVNode("span",{class:e.normalizeClass(["timeline__dot","mfs-shadow","mfs-rounded-full","mfs-flex","mfs-items-center","mfs-justify-center",o.status==="surface"?"mfs-surface-subtle":`mfs-bg-${o.status||"primary"}`,`timeline__dot--${o.status||"primary"}`])},[e.renderSlot(s.$slots,"icon",{item:o,index:a},()=>[o.icon?(e.openBlock(),e.createElementBlock("span",ts,e.toDisplayString(o.icon),1)):e.createCommentVNode("",!0)],!0)],2),a<t.items.length-1?(e.openBlock(),e.createElementBlock("span",ls)):e.createCommentVNode("",!0)]),e.createElementVNode("div",os,[e.renderSlot(s.$slots,"item",{item:o,index:a},()=>[e.createElementVNode("div",ns,[e.createElementVNode("h4",as,e.toDisplayString(o.title),1),o.timestamp?(e.openBlock(),e.createElementBlock("time",ss,e.toDisplayString(o.timestamp),1)):e.createCommentVNode("",!0)]),o.description?(e.openBlock(),e.createElementBlock("p",rs,e.toDisplayString(o.description),1)):e.createCommentVNode("",!0)],!0)])]))),128))],2)):e.createCommentVNode("",!0)],10,Ja))}}),[["__scopeId","data-v-e4d2eafc"]]),is=["aria-busy"],ds={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},cs={key:1,class:"mfs-empty-state"},ms={key:2,class:"carousel__stage"},fs=["aria-hidden"],ps={class:"carousel__fallback mfs-text"},us=["disabled"],ks=["disabled"],hs={key:3,class:"carousel__indicators mfs-flex mfs-justify-center mfs-py-3"},gs={class:"carousel__dots mfs-surface-subtle mfs-pill mfs-blur",role:"tablist","aria-label":"Slide indicators"},ys=["aria-selected","aria-label","onClick"],ft=D(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:s}){const l=t,o=s,a=e.ref(l.modelValue),r=e.ref(!1);let i=null,c=null;e.watch(()=>l.modelValue,u=>{u>=0&&u<l.items.length&&(a.value=u)});const d=u=>{const b=l.items.length;if(!b)return;let g=u;l.loop?g=(u+b)%b:g=Math.max(0,Math.min(b-1,u)),a.value=g,o("update:modelValue",g),o("change",g)},n=()=>d(a.value+1),k=()=>d(a.value-1),h=u=>{i=u.clientX},y=u=>{if(i===null)return;const b=u.clientX-i;i=null,Math.abs(b)>40&&(b<0?n():k())},f=()=>{i=null},p=()=>{c&&(clearInterval(c),c=null)},m=()=>{p(),l.autoplay&&l.items.length>1&&(c=setInterval(()=>{r.value||n()},l.interval))};return e.watch(()=>[l.autoplay,l.interval,l.items.length],m),e.onMounted(m),e.onBeforeUnmount(p),(u,b)=>(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:b[0]||(b[0]=g=>r.value=!0),onMouseleave:b[1]||(b[1]=g=>r.value=!1),onFocusin:b[2]||(b[2]=g=>r.value=!0),onFocusout:b[3]||(b[3]=g=>r.value=!1)},[t.loading?(e.openBlock(),e.createElementBlock("div",ds,[e.renderSlot(u.$slots,"loading",{},()=>[b[4]||(b[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",cs,[e.renderSlot(u.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",ms,[e.createElementVNode("div",{class:"carousel__viewport",onPointerdown:h,onPointerup:y,onPointercancel:f},[e.createElementVNode("div",{class:"carousel__track",style:e.normalizeStyle({transform:`translateX(-${a.value*100}%)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"carousel__slide","aria-hidden":B!==a.value},[e.renderSlot(u.$slots,"default",{item:g,index:B},()=>[e.createElementVNode("div",ps,e.toDisplayString(g),1)],!0)],8,fs))),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&&a.value===0,onClick:k},[...b[5]||(b[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,us),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&&a.value===t.items.length-1,onClick:n},[...b[6]||(b[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,ks)],64)):e.createCommentVNode("",!0)])),t.items.length>1?(e.openBlock(),e.createElementBlock("div",hs,[e.createElementVNode("div",gs,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>(e.openBlock(),e.createElementBlock("button",{key:B,type:"button",role:"tab","aria-selected":B===a.value,"aria-label":`Go to slide ${B+1}`,class:e.normalizeClass(["carousel__dot","mfs-focus-ring",{"is-active":B===a.value}]),onClick:w=>d(B)},null,10,ys))),128))])])):e.createCommentVNode("",!0)],42,is))}}),[["__scopeId","data-v-a3ec7623"]]),bs={key:0,class:"mfs-image__placeholder","aria-hidden":"true"},Bs=["aria-label"],_s=["src","alt"],ws=["aria-label"],Es=["src","alt"],pt=D(e.defineComponent({__name:"Image",props:{src:{},alt:{default:""},width:{},height:{},preview:{type:Boolean,default:!1},fit:{default:"cover"}},setup(t){const s=t,l=e.ref(!1),o=e.ref(!1),a=e.ref(!1),r=y=>y===void 0?void 0:typeof y=="number"?`${y}px`:y,i=e.computed(()=>({width:r(s.width),height:r(s.height)}));e.watch(()=>s.src,()=>{l.value=!1,o.value=!1});const c=()=>{l.value=!0,o.value=!1},d=()=>{l.value=!1,o.value=!0},n=y=>{y.key==="Escape"&&h()},k=()=>{s.preview&&l.value&&!o.value&&(a.value=!0,window.addEventListener("keydown",n))},h=()=>{a.value=!1,window.removeEventListener("keydown",n)};return e.onBeforeUnmount(()=>{window.removeEventListener("keydown",n)}),(y,f)=>(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&&!o.value}]),style:e.normalizeStyle(i.value),onClick:k},[!l.value&&!o.value?(e.openBlock(),e.createElementBlock("div",bs)):e.createCommentVNode("",!0),o.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"},[...f[1]||(f[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,Bs)):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:c,onError:d},null,46,_s),[[e.vShow,!o.value]]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"img-fade"},{default:e.withCtx(()=>[a.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:h},[e.createElementVNode("button",{type:"button",class:"mfs-image__close","aria-label":"Close preview",onClick:e.withModifiers(h,["stop"])},[...f[2]||(f[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:f[0]||(f[0]=e.withModifiers(()=>{},["stop"]))},null,8,Es)],8,ws)):e.createCommentVNode("",!0)]),_:1})]))],6))}}),[["__scopeId","data-v-66fca7b1"]]),re=e.ref([]),ie=new Map;let $s=0;function Oe(t){const s=ie.get(t);s!=null&&s.timerId&&(clearTimeout(s.timerId),s.timerId=null)}function Vs(t,s){if(s<=0)return;Oe(t);const l=setTimeout(()=>{Ue(t)},s);ie.set(t,{timerId:l,remaining:s,startedAt:Date.now()})}function Ue(t){Oe(t),ie.delete(t),re.value=re.value.filter(s=>s.id!==t)}function Cs(t){const s=ie.get(t);!s||!s.timerId||(clearTimeout(s.timerId),s.timerId=null,s.remaining=Math.max(0,s.remaining-(Date.now()-s.startedAt)))}function xs(t){const s=ie.get(t);!s||s.timerId||s.remaining<=0||(s.startedAt=Date.now(),s.timerId=setTimeout(()=>{Ue(t)},s.remaining))}function ut(t){const s=t.id??`mfs-toast-${++$s}`,l=t.duration??4e3,o={id:s,title:t.title,message:t.message,severity:t.severity??"info",duration:l,closable:t.closable??!0},a=re.value.findIndex(r=>r.id===s);return a!==-1?re.value.splice(a,1,o):re.value.push(o),l>0&&Vs(s,l),s}function Ns(){for(const t of ie.keys())Oe(t);ie.clear(),re.value=[]}function kt(){return{toasts:e.readonly(re),add:ut,show:ut,remove:Ue,clear:Ns,pause:Cs,resume:xs}}const Ss=["role","onMouseenter","onMouseleave","onFocusin","onFocusout"],Ms={class:"mfs-toast__icon mfs-shrink-0","aria-hidden":"true"},Ds={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},zs={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ts={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ls={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Is={class:"mfs-toast__body mfs-flex-1 mfs-min-w-0"},Rs={key:0,class:"mfs-toast__title mfs-title mfs-font-bold"},Ps={class:"mfs-toast__message mfs-text-muted mfs-text-sm"},Fs=["onClick"],ht=D(e.defineComponent({__name:"Toast",props:{position:{default:"top-right"},max:{}},setup(t){const s=t,{toasts:l,remove:o,pause:a,resume:r}=kt(),i=e.computed(()=>s.max&&s.max>0?l.value.slice(-s.max):l.value);return(c,d)=>(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(i.value,n=>(e.openBlock(),e.createElementBlock("div",{key:n.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--${n.severity}`]]),role:n.severity==="danger"||n.severity==="warning"?"alert":"status","aria-live":"polite",onMouseenter:k=>e.unref(a)(n.id),onMouseleave:k=>e.unref(r)(n.id),onFocusin:k=>e.unref(a)(n.id),onFocusout:k=>e.unref(r)(n.id)},[e.createElementVNode("span",Ms,[n.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Ds,[...d[0]||(d[0]=[e.createElementVNode("circle",{cx:"12",cy:"12",r:"10"},null,-1),e.createElementVNode("path",{d:"m9 12 2 2 4-4"},null,-1)])])):n.severity==="warning"?(e.openBlock(),e.createElementBlock("svg",zs,[...d[1]||(d[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)])])):n.severity==="danger"?(e.openBlock(),e.createElementBlock("svg",Ts,[...d[2]||(d[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",Ls,[...d[3]||(d[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",Is,[n.title?(e.openBlock(),e.createElementBlock("div",Rs,e.toDisplayString(n.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Ps,e.toDisplayString(n.message),1)]),n.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:k=>e.unref(o)(n.id)},[...d[4]||(d[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,Fs)):e.createCommentVNode("",!0)],42,Ss))),128))]),_:1})],2)]))}}),[["__scopeId","data-v-e95e4289"]]),As={class:"mfs-alert__icon","aria-hidden":"true"},js={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ks={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Os={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Us={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Hs={class:"mfs-alert__content"},Ws={key:0,class:"mfs-alert__title mfs-title"},Gs={class:"mfs-alert__body mfs-text-muted"},xe=D(e.defineComponent({__name:"Alert",props:{severity:{default:"info"},title:{},closable:{type:Boolean,default:!1}},emits:["close"],setup(t,{emit:s}){const l=s;return(o,a)=>(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",As,[e.renderSlot(o.$slots,"icon",{},()=>[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",js,[...a[1]||(a[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",Ks,[...a[2]||(a[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",Os,[...a[3]||(a[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",Us,[...a[4]||(a[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",Hs,[t.title?(e.openBlock(),e.createElementBlock("div",Ws,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Gs,[e.renderSlot(o.$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:a[0]||(a[0]=r=>l("close"))},[...a[5]||(a[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-17471fb4"]]),qs=["aria-describedby"],Ys=["id"],gt=D(e.defineComponent({__name:"Tooltip",props:{content:{default:""},placement:{default:"top"},disabled:{type:Boolean,default:!1}},setup(t){const s=t,l=e.ref(!1),o=e.useId(),a=()=>{!s.disabled&&s.content&&(l.value=!0)},r=()=>{l.value=!1};return(i,c)=>(e.openBlock(),e.createElementBlock("span",{class:"mfs-relative mfs-inline-flex mfs-items-center",onMouseenter:a,onMouseleave:r,onFocusin:a,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(o):void 0},[e.renderSlot(i.$slots,"default",{},void 0,!0)],8,qs),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(o),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),c[0]||(c[0]=e.createElementVNode("span",{class:"mfs-tooltip__arrow mfs-absolute","aria-hidden":"true"},null,-1))],10,Ys)):e.createCommentVNode("",!0)]),_:1})],32))}}),[["__scopeId","data-v-41e6fd61"]]),Xs=["aria-label"],Zs={key:0,class:"mfs-drawer__header mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},Js={class:"mfs-drawer__title mfs-title mfs-m-0 mfs-font-bold"},Qs={class:"mfs-drawer__body mfs-flex-1 mfs-p-5 mfs-overflow-y-auto"},vs={key:1,class:"mfs-drawer__footer mfs-border-t mfs-flex mfs-justify-end mfs-gap-2-5"},Ne=D(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:s}){const l=t,o=s,a=e.computed(()=>l.position==="left"||l.position==="right"),r=e.computed(()=>a.value?{width:l.size,maxWidth:"100vw",height:"100%"}:{height:l.size,maxHeight:"100vh",width:"100%"}),i=()=>{o("update:modelValue",!1),o("close")},c=()=>{l.closeOnBackdrop&&i()},d=y=>{y.key==="Escape"&&l.modelValue&&i()};let n="",k=!1;const h=y=>{if(!(typeof document>"u"))if(y){if(k)return;n=document.body.style.overflow,document.body.style.overflow="hidden",document.addEventListener("keydown",d),k=!0}else k&&(document.body.style.overflow=n,document.removeEventListener("keydown",d),k=!1)};return e.onMounted(()=>{l.modelValue&&h(!0)}),e.watch(()=>l.modelValue,y=>h(y)),e.onBeforeUnmount(()=>{h(!1)}),(y,f)=>(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:c},[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:f[0]||(f[0]=e.withModifiers(()=>{},["stop"]))},[t.title||y.$slots.header?(e.openBlock(),e.createElementBlock("div",Zs,[e.renderSlot(y.$slots,"header",{},()=>[e.createElementVNode("h3",Js,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:i},[...f[1]||(f[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",Qs,[e.renderSlot(y.$slots,"default",{},void 0,!0)]),y.$slots.footer?(e.openBlock(),e.createElementBlock("div",vs,[e.renderSlot(y.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],14,Xs)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-1d638027"]]),er={class:"mfs-popover-wrapper"},tr=["aria-expanded"],Se=D(e.defineComponent({__name:"Popover",props:{modelValue:{type:Boolean,default:void 0},placement:{default:"bottom"}},emits:["update:modelValue"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),c=e.computed(()=>l.modelValue!==void 0),d=e.computed(()=>c.value?!!l.modelValue:i.value),{overlayStyle:n,containsTarget:k}=oe(a,r,d,{offset:10,align:"center"}),h=b=>{c.value||(i.value=b),o("update:modelValue",b)},y=()=>h(!d.value),f=()=>h(!1),p=b=>{k(b.target)||f()},m=b=>{b.key==="Escape"&&f()},u=b=>{typeof document>"u"||(b?(document.addEventListener("pointerdown",p),document.addEventListener("keydown",m)):(document.removeEventListener("pointerdown",p),document.removeEventListener("keydown",m)))};return e.watch(d,b=>u(b),{immediate:!0}),e.onBeforeUnmount(()=>{u(!1)}),(b,g)=>(e.openBlock(),e.createElementBlock("div",er,[e.createElementVNode("div",{ref_key:"triggerRef",ref:a,class:"mfs-popover__trigger","aria-expanded":d.value,"aria-haspopup":"dialog",onClick:y},[e.renderSlot(b.$slots,"trigger",{open:d.value,toggle:y},void 0,!0)],8,tr),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-popover"},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(n)),class:e.normalizeClass(["mfs-popover mfs-surface mfs-overlay mfs-rounded mfs-shadow-card mfs-blur",[`mfs-popover--${t.placement}`]]),role:"dialog"},[e.renderSlot(b.$slots,"default",{close:f},void 0,!0)],6)):e.createCommentVNode("",!0)]),_:3})]))]))}}),[["__scopeId","data-v-cd2807a7"]]),yt=D(e.defineComponent({__name:"Skeleton",props:{variant:{default:"text"},width:{},height:{},lines:{default:1},animated:{type:Boolean,default:!0}},setup(t){const s=t,l=e.computed(()=>s.variant!=="text"?1:Math.max(1,Math.floor(s.lines))),o=a=>{const r=s.variant==="text"&&l.value>1&&a===l.value,i=s.variant==="circle"?"48px":r?"72%":"100%",c=s.variant==="circle"?s.width??"48px":s.variant==="text"?"14px":"80px";return{width:r&&!s.width?"72%":s.width??i,height:s.height??c}};return(a,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,i=>(e.openBlock(),e.createElementBlock("div",{key:i,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(o(i))},null,6))),128))],2))}}),[["__scopeId","data-v-ac23abe4"]]),lr={class:"mfs-progress"},or=["aria-valuenow"],nr={key:0,class:"mfs-progress__label mfs-caption"},bt=D(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 s=t,l=e.computed(()=>Math.min(100,Math.max(0,s.value)));return(o,a)=>(e.openBlock(),e.createElementBlock("div",lr,[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,or),t.showValue&&!t.indeterminate?(e.openBlock(),e.createElementBlock("span",nr,e.toDisplayString(Math.round(l.value))+"% ",1)):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-9a84cdec"]]),ar={class:"mfs-spinner__svg",viewBox:"0 0 50 50"},sr=["stroke-width"],rr=["stroke-width"],Bt=D(e.defineComponent({__name:"ProgressSpinner",props:{size:{default:"md"},strokeWidth:{default:4},variant:{default:"primary"}},setup(t){const s=t,l={sm:"22px",md:"36px",lg:"52px"},o=e.computed(()=>typeof s.size=="number"?`${s.size}px`:l[s.size]);return(a,r)=>(e.openBlock(),e.createElementBlock("span",{class:e.normalizeClass(["mfs-spinner mfs-text",[`mfs-spinner--${t.variant}`]]),style:e.normalizeStyle({width:o.value,height:o.value}),role:"status","aria-label":"Loading"},[(e.openBlock(),e.createElementBlock("svg",ar,[e.createElementVNode("circle",{class:"mfs-spinner__track",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth},null,8,sr),e.createElementVNode("circle",{class:"mfs-spinner__ring",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,rr)]))],6))}}),[["__scopeId","data-v-fcb783c0"]]),Me=e.ref({isOpen:!1,options:null});let pe=null;function _t(t){var o,a;const s=Me.value.options,l=pe;pe=null,Me.value={isOpen:!1,options:null},t?(o=s==null?void 0:s.onAccept)==null||o.call(s):(a=s==null?void 0:s.onReject)==null||a.call(s),l==null||l(t)}function ir(t){return pe&&(pe(!1),pe=null),Me.value={isOpen:!0,options:{confirmLabel:"Confirm",cancelLabel:"Cancel",variant:"primary",...t}},new Promise(s=>{pe=s})}function wt(){return{state:e.readonly(Me),confirm:ir,accept:()=>_t(!0),reject:()=>_t(!1)}}const dr=["aria-labelledby","aria-describedby"],cr={class:"mfs-confirm__header"},mr=["id"],fr=["id"],pr={class:"mfs-flex mfs-justify-end mfs-gap-2-5 mfs-flex-wrap"},Et=D(e.defineComponent({__name:"ConfirmDialog",setup(t){const{state:s,accept:l,reject:o}=wt(),a=e.useId(),r=e.useId(),i=c=>{c.key==="Escape"&&s.value.isOpen&&o()};return e.watch(()=>s.value.isOpen,c=>{typeof document>"u"||(c?document.addEventListener("keydown",i):document.removeEventListener("keydown",i))},{immediate:!0}),e.onBeforeUnmount(()=>{typeof document<"u"&&document.removeEventListener("keydown",i)}),(c,d)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-fade"},{default:e.withCtx(()=>[e.unref(s).isOpen&&e.unref(s).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:d[3]||(d[3]=(...n)=>e.unref(o)&&e.unref(o)(...n))},[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(a),"aria-describedby":e.unref(r),onClick:d[2]||(d[2]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",cr,[e.createElementVNode("h3",{id:e.unref(a),class:"mfs-confirm__title mfs-title mfs-m-0"},e.toDisplayString(e.unref(s).options.title),9,mr)]),e.createElementVNode("p",{id:e.unref(r),class:"mfs-confirm__message mfs-text-muted"},e.toDisplayString(e.unref(s).options.message),9,fr),e.createElementVNode("div",pr,[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:d[0]||(d[0]=(...n)=>e.unref(o)&&e.unref(o)(...n))},e.toDisplayString(e.unref(s).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(s).options.variant??"primary"}`]]),onClick:d[1]||(d[1]=(...n)=>e.unref(l)&&e.unref(l)(...n))},e.toDisplayString(e.unref(s).options.confirmLabel??"Confirm"),3)])],8,dr)])):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-cd6aa53d"]]),ur={class:"navbar__inner mfs-flex mfs-items-center mfs-justify-between mfs-gap-4"},kr={class:"navbar__brand mfs-flex mfs-items-center mfs-font-bold"},hr={class:"navbar__nav","aria-label":"Main navigation"},gr={class:"navbar__list mfs-flex mfs-items-center"},yr=["aria-current","onClick"],br={class:"navbar__actions mfs-flex mfs-items-center"},Br=["aria-expanded"],_r={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"},wr={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"},Er={key:0,id:"navbar-mobile-drawer",class:"navbar__drawer",role:"region","aria-label":"Mobile navigation"},$r={class:"navbar__mobile-list mfs-flex mfs-flex-col"},Vr=["aria-current","onClick"],De=D(e.defineComponent({__name:"Navbar",props:{items:{default:()=>[]},sticky:{type:Boolean,default:!0},bordered:{type:Boolean,default:!0}},emits:["navigate"],setup(t,{emit:s}){const l=s,o=e.ref(!1),a=(c,d)=>{l("navigate",c,d)},r=(c,d)=>{o.value=!1,l("navigate",c,d)},i=c=>{c.key==="Escape"&&o.value&&(o.value=!1)};return e.onMounted(()=>{window.addEventListener("keydown",i)}),e.onUnmounted(()=>{window.removeEventListener("keydown",i)}),(c,d)=>(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",ur,[e.createElementVNode("div",kr,[e.renderSlot(c.$slots,"brand",{},void 0,!0)]),e.createElementVNode("nav",hr,[e.renderSlot(c.$slots,"links",{items:t.items,navigate:a},()=>[e.createElementVNode("ul",gr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,k)=>(e.openBlock(),e.createElementBlock("li",{key:k,class:"navbar__item"},[!n.to&&!n.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":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>a(n,h)},e.toDisplayString(n.label),11,yr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.to?"router-link":"a"),{key:1,to:n.to,href:n.href,class:e.normalizeClass(["navbar__link mfs-inline-flex mfs-items-center mfs-font-medium mfs-border-none mfs-pill",{"navbar__link--active":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>a(n,h)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)]),e.createElementVNode("div",br,[e.renderSlot(c.$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":o.value,"aria-controls":"navbar-mobile-drawer","aria-label":"Toggle navigation menu",onClick:d[0]||(d[0]=n=>o.value=!o.value)},[o.value?(e.openBlock(),e.createElementBlock("svg",wr,[...d[2]||(d[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",_r,[...d[1]||(d[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,Br)])]),e.createVNode(e.Transition,{name:"navbar-drawer"},{default:e.withCtx(()=>[o.value?(e.openBlock(),e.createElementBlock("div",Er,[e.renderSlot(c.$slots,"links",{items:t.items,navigate:r},()=>[e.createElementVNode("ul",$r,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,k)=>(e.openBlock(),e.createElementBlock("li",{key:k},[!n.to&&!n.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":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>r(n,h)},e.toDisplayString(n.label),11,Vr)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.to?"router-link":"a"),{key:1,to:n.to,href:n.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":n.active}]),"aria-current":n.active?"page":void 0,onClick:h=>r(n,h)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.label),1)]),_:2},1032,["to","href","class","aria-current","onClick"]))]))),128))])],!0)])):e.createCommentVNode("",!0)]),_:3})],2))}}),[["__scopeId","data-v-2b84fbe9"]]),Cr={class:"tabs"},xr=["aria-selected","aria-disabled","disabled","tabindex","onClick"],Nr={key:0,class:"tabs__panel",role:"tabpanel"},ze=D(e.defineComponent({__name:"Tabs",props:{items:{},modelValue:{},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=new Map,i=e.ref({left:0,width:0,ready:!1}),c=e.computed(()=>{var u;if(l.modelValue!==void 0)return l.modelValue;const m=l.items.find(b=>!b.disabled);return(m==null?void 0:m.key)??((u=l.items[0])==null?void 0:u.key)??""}),d=e.computed(()=>({transform:`translateX(${i.value.left}px)`,width:`${i.value.width}px`,opacity:i.value.ready&&i.value.width>0?1:0})),n=(m,u)=>{u?r.set(m,u):r.delete(m)},k=async(m=!1)=>{await e.nextTick();const u=r.get(c.value);if(!u){i.value={left:0,width:0,ready:!1};return}i.value={left:u.offsetLeft,width:u.offsetWidth,ready:!0},m&&l.scrollable&&u.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},h=(m,u)=>{m.disabled||m.key===c.value||(o("update:modelValue",m.key),o("change",m.key))},y=m=>{var B;const u=l.items.filter(w=>!w.disabled);if(!u.length)return;const b=u.findIndex(w=>w.key===c.value);let g=-1;if(m.key==="ArrowRight"?g=(b+1)%u.length:m.key==="ArrowLeft"?g=(b-1+u.length)%u.length:m.key==="Home"?g=0:m.key==="End"&&(g=u.length-1),g>=0){m.preventDefault();const w=u[g];h(w),(B=r.get(w.key))==null||B.focus()}};let f=null;e.watch(()=>[c.value,l.items],()=>k(!0),{deep:!0});const p=()=>k(!1);return e.onMounted(()=>{k(!1),typeof ResizeObserver<"u"&&a.value&&(f=new ResizeObserver(p),f.observe(a.value)),window.addEventListener("resize",p)}),e.onUnmounted(()=>{f==null||f.disconnect(),window.removeEventListener("resize",p)}),(m,u)=>(e.openBlock(),e.createElementBlock("div",Cr,[e.createElementVNode("div",{ref_key:"listRef",ref:a,class:e.normalizeClass(["tabs__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tabs__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:y},[e.createElementVNode("span",{class:"tabs__indicator mfs-pill",style:e.normalizeStyle(d.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(b,g)=>(e.openBlock(),e.createElementBlock("button",{key:b.key,ref_for:!0,ref:B=>n(b.key,B),type:"button",role:"tab",class:e.normalizeClass(["tabs__tab mfs-pill mfs-bg-transparent",{"tabs__tab--active":b.key===c.value,"tabs__tab--disabled mfs-disabled":b.disabled}]),"aria-selected":b.key===c.value,"aria-disabled":b.disabled||void 0,disabled:b.disabled,tabindex:b.key===c.value?0:-1,onClick:B=>h(b)},[e.renderSlot(m.$slots,"tab",{item:b,active:b.key===c.value},()=>[e.createTextVNode(e.toDisplayString(b.label),1)],!0)],10,xr))),128))],34),m.$slots.default?(e.openBlock(),e.createElementBlock("div",Nr,[e.renderSlot(m.$slots,"default",{activeKey:c.value},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-80912f0b"]]),Sr={class:"breadcrumb mfs-surface mfs-pill mfs-inline-flex mfs-items-center","aria-label":"Breadcrumb"},Mr={class:"breadcrumb__list mfs-flex mfs-flex-wrap mfs-items-center"},Dr={key:0,class:"breadcrumb__separator mfs-inline-flex mfs-items-center mfs-text-muted","aria-hidden":"true"},zr={key:0},Tr={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Lr=["aria-current"],Ir=["onClick"],$t=D(e.defineComponent({__name:"Breadcrumb",props:{items:{},separator:{default:"chevron"}},emits:["navigate"],setup(t,{emit:s}){const l=s;return(o,a)=>(e.openBlock(),e.createElementBlock("nav",Sr,[e.createElementVNode("ol",Mr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(r,i)=>(e.openBlock(),e.createElementBlock("li",{key:i,class:"breadcrumb__item mfs-inline-flex mfs-items-center"},[i>0?(e.openBlock(),e.createElementBlock("span",Dr,[e.renderSlot(o.$slots,"separator",{},()=>[t.separator==="slash"?(e.openBlock(),e.createElementBlock("span",zr,"/")):(e.openBlock(),e.createElementBlock("svg",Tr,[...a[0]||(a[0]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])]))],!0)])):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"item",{item:r,isLast:i===t.items.length-1},()=>[i===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":i===t.items.length-1?"page":void 0},e.toDisplayString(r.label),11,Lr)):!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:c=>l("navigate",r,c)},e.toDisplayString(r.label),9,Ir)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(r.to?"router-link":"a"),{key:2,to:r.to,href:r.href,class:"breadcrumb__link mfs-inline-flex mfs-items-center mfs-rounded-sm mfs-border-none mfs-font-medium mfs-text",onClick:c=>l("navigate",r,c)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.label),1)]),_:2},1032,["to","href","onClick"]))],!0)]))),128))])]))}}),[["__scopeId","data-v-79984457"]]),Rr=["aria-busy"],Pr={class:"pagination__controls"},Fr=["disabled"],Ar=["disabled"],jr={key:0,class:"pagination__ellipsis mfs-text-muted","aria-hidden":"true"},Kr=["disabled","aria-label","aria-current","onClick"],Or=["disabled"],Ur=["disabled"],Hr={key:0,class:"pagination__extras"},Wr={key:0,class:"pagination__per-page"},Gr=["value","disabled"],qr=["value"],Yr={class:"pagination__label mfs-text-muted"},Xr=["max","disabled"],ye=D(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:s}){const l=t,o=e.computed(()=>l.disabled||l.loading),a=s,r=e.ref(""),i=e.computed(()=>Math.max(1,Math.ceil(l.total/Math.max(1,l.perPage)))),c=e.computed(()=>Math.min(Math.max(1,l.modelValue),i.value)),d=e.computed(()=>{const y=i.value,f=c.value,p=l.siblingCount,m=p*2+5;if(y<=m)return Array.from({length:y},(_,$)=>$+1);const u=Math.max(f-p,1),b=Math.min(f+p,y),g=u>2,B=b<y-1,w=[1];if(g)w.push("ellipsis");else for(let _=2;_<u;_++)w.push(_);for(let _=Math.max(2,u);_<=Math.min(y-1,b);_++)w.push(_);if(B)w.push("ellipsis");else for(let _=b+1;_<y;_++)w.push(_);return y>1&&w.push(y),w}),n=y=>{if(o.value)return;const f=Math.min(Math.max(1,y),i.value);f!==c.value&&(a("update:modelValue",f),a("change",{page:f,perPage:l.perPage}))},k=y=>{if(o.value)return;const f=Number(y.target.value),p=Math.max(1,Math.ceil(l.total/Math.max(1,f))),m=Math.min(c.value,p);a("update:perPage",f),m!==c.value&&a("update:modelValue",m),a("change",{page:m,perPage:f})},h=()=>{if(o.value)return;const y=Number.parseInt(r.value,10);Number.isNaN(y)||n(y),r.value=""};return(y,f)=>(e.openBlock(),e.createElementBlock("nav",{class:"pagination mfs-row mfs-text","aria-label":"Pagination","aria-busy":t.loading||void 0},[e.createElementVNode("div",Pr,[e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value<=1,"aria-label":"First page",onClick:f[0]||(f[0]=p=>n(1))},[...f[5]||(f[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,Fr),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value<=1,"aria-label":"Previous page",onClick:f[1]||(f[1]=p=>n(c.value-1))},[...f[6]||(f[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,Ar),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(p,m)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:m},[p==="ellipsis"?(e.openBlock(),e.createElementBlock("span",jr," … ")):(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===c.value}]),disabled:o.value,"aria-label":`Page ${p}`,"aria-current":p===c.value?"page":void 0,onClick:u=>n(p)},e.toDisplayString(p),11,Kr))],64))),128)),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value>=i.value,"aria-label":"Next page",onClick:f[2]||(f[2]=p=>n(c.value+1))},[...f[7]||(f[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,Or),e.createElementVNode("button",{type:"button",class:"pagination__btn mfs-surface mfs-shadow mfs-rounded-md mfs-interactive",disabled:o.value||c.value>=i.value,"aria-label":"Last page",onClick:f[3]||(f[3]=p=>n(i.value))},[...f[8]||(f[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,Ur)]),t.perPageOptions.length||t.showJumpTo?(e.openBlock(),e.createElementBlock("div",Hr,[t.perPageOptions.length?(e.openBlock(),e.createElementBlock("label",Wr,[f[9]||(f[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:o.value,"aria-label":"Items per page",onChange:k},[(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,qr))),128))],40,Gr)])):e.createCommentVNode("",!0),t.showJumpTo?(e.openBlock(),e.createElementBlock("form",{key:1,class:"pagination__jump",onSubmit:e.withModifiers(h,["prevent"])},[e.createElementVNode("label",Yr,[f[10]||(f[10]=e.createTextVNode(" Go ",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":f[4]||(f[4]=p=>r.value=p),type:"number",min:"1",max:i.value,disabled:o.value,class:"pagination__input mfs-surface mfs-rounded-md mfs-shadow-inset","aria-label":"Jump to page"},null,8,Xr),[[e.vModelText,r.value]])])],32)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],8,Rr))}}),[["__scopeId","data-v-81601b38"]]),Zr=["aria-current"],Jr=["onClick"],Qr={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},vr={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"},ei={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"},ti={key:2},li={class:"steps__content mfs-flex mfs-flex-col"},oi={class:"steps__label mfs-font-semibold"},ni={key:0,class:"steps__desc mfs-text-muted"},ai={key:1,class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md"},si={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},ri={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"},ii={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"},di={key:2},ci={class:"steps__content mfs-flex mfs-flex-col"},mi={class:"steps__label mfs-font-semibold"},fi={key:0,class:"steps__desc mfs-text-muted"},Te=D(e.defineComponent({__name:"Steps",props:{items:{},modelValue:{default:0},clickable:{type:Boolean,default:!1},direction:{default:"responsive"}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=(i,c)=>i.status?i.status:c<l.modelValue?"completed":c===l.modelValue?"active":"upcoming",r=i=>{!l.clickable||i===l.modelValue||(o("update:modelValue",i),o("change",i))};return(i,c)=>(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,(d,n)=>(e.openBlock(),e.createElementBlock("li",{key:n,class:e.normalizeClass(["steps__item mfs-flex mfs-items-center mfs-gap-2",[`steps__item--${a(d,n)}`,{"steps__item--clickable":t.clickable}]]),"aria-current":a(d,n)==="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:k=>r(n)},[e.createElementVNode("span",Qr,[a(d,n)==="completed"?(e.openBlock(),e.createElementBlock("svg",vr,[...c[0]||(c[0]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):a(d,n)==="error"?(e.openBlock(),e.createElementBlock("svg",ei,[...c[1]||(c[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",ti,e.toDisplayString(n+1),1))]),e.createElementVNode("span",li,[e.createElementVNode("span",oi,e.toDisplayString(d.label),1),d.description?(e.openBlock(),e.createElementBlock("span",ni,e.toDisplayString(d.description),1)):e.createCommentVNode("",!0)])],8,Jr)):(e.openBlock(),e.createElementBlock("div",ai,[e.createElementVNode("span",si,[a(d,n)==="completed"?(e.openBlock(),e.createElementBlock("svg",ri,[...c[2]||(c[2]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):a(d,n)==="error"?(e.openBlock(),e.createElementBlock("svg",ii,[...c[3]||(c[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",di,e.toDisplayString(n+1),1))]),e.createElementVNode("span",ci,[e.createElementVNode("span",mi,e.toDisplayString(d.label),1),d.description?(e.openBlock(),e.createElementBlock("span",fi,e.toDisplayString(d.description),1)):e.createCommentVNode("",!0)])])),n<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":a(d,n)==="completed"}]),"aria-hidden":"true"},null,2)):e.createCommentVNode("",!0)],10,Zr))),128))],2))}}),[["__scopeId","data-v-b60b46b4"]]),pi={key:0,class:"ctx-menu__divider mfs-divider",role:"separator"},ui={key:1,role:"none"},ki=["disabled","onClick"],hi={key:0,class:"ctx-menu__icon","aria-hidden":"true"},gi={class:"ctx-menu__label"},Vt=D(e.defineComponent({__name:"ContextMenu",props:{items:{}},emits:["select","open","close"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.ref(!1),i=e.ref(null),c=e.ref({x:0,y:0}),d=new Map,n=(g,B)=>{B?d.set(g,B):d.delete(g)},k=()=>{r.value&&(r.value=!1,b(),a("close"))},h=async g=>{var w;r.value=!0,c.value={x:g.clientX,y:g.clientY},a("open"),await e.nextTick();const B=i.value;if(B){const _=B.getBoundingClientRect(),$=8,C=window.innerWidth-_.width-$,E=window.innerHeight-_.height-$;c.value={x:Math.max($,Math.min(g.clientX,C)),y:Math.max($,Math.min(g.clientY,E))};const V=o.items.findIndex(M=>!M.divider&&!M.disabled);V>=0&&((w=d.get(V))==null||w.focus())}u()},y=g=>{var B;g.disabled||((B=g.action)==null||B.call(g),a("select",g),k())},f=g=>{var $,C;const B=o.items.map((E,V)=>!E.divider&&!E.disabled?V:-1).filter(E=>E>=0);if(!B.length)return;const w=document.activeElement,_=B.findIndex(E=>d.get(E)===w);if(g.key==="ArrowDown"){g.preventDefault();const E=B[(_+1)%B.length];($=d.get(E))==null||$.focus()}else if(g.key==="ArrowUp"){g.preventDefault();const E=B[(_-1+B.length)%B.length];(C=d.get(E))==null||C.focus()}else g.key==="Escape"&&(g.preventDefault(),k())},p=g=>{i.value&&!i.value.contains(g.target)&&k()},m=g=>{g.key==="Escape"&&k()},u=()=>{window.addEventListener("pointerdown",p),window.addEventListener("keydown",m),window.addEventListener("resize",k)},b=()=>{window.removeEventListener("pointerdown",p),window.removeEventListener("keydown",m),window.removeEventListener("resize",k)};return e.onUnmounted(()=>{b()}),s({open:h,close:k}),(g,B)=>(e.openBlock(),e.createElementBlock("div",{class:"ctx-wrapper",onContextmenu:e.withModifiers(h,["prevent"])},[e.renderSlot(g.$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:i,class:"ctx-menu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${c.value.x}px`,top:`${c.value.y}px`}),onKeydown:f},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(w,_)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:_},[w.divider?(e.openBlock(),e.createElementBlock("li",pi)):(e.openBlock(),e.createElementBlock("li",ui,[e.createElementVNode("button",{ref_for:!0,ref:$=>n(_,$),type:"button",role:"menuitem",class:e.normalizeClass(["ctx-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"ctx-menu__item--disabled mfs-disabled":w.disabled,"ctx-menu__item--danger":w.danger}]),disabled:w.disabled,onClick:$=>y(w)},[e.renderSlot(g.$slots,"item",{item:w},()=>[w.icon?(e.openBlock(),e.createElementBlock("span",hi,e.toDisplayString(w.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",gi,e.toDisplayString(w.label),1)],!0)],10,ki)]))],64))),128))],36)):e.createCommentVNode("",!0)]),_:3})]))],32))}}),[["__scopeId","data-v-abdbc3af"]]),Ct=D(e.defineComponent({__name:"ScrollTop",props:{threshold:{default:200},behavior:{default:"smooth"},target:{default:null}},emits:["click"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1);let r=null;const i=()=>typeof l.target=="string"?document.querySelector(l.target)??window:l.target instanceof HTMLElement?l.target:window,c=()=>{if(!r)return;const n=r===window?window.scrollY:r.scrollTop;a.value=n>=l.threshold},d=n=>{i().scrollTo({top:0,behavior:l.behavior}),o("click",n)};return e.onMounted(()=>{r=i(),r.addEventListener("scroll",c,{passive:!0}),c()}),e.onUnmounted(()=>{r==null||r.removeEventListener("scroll",c)}),(n,k)=>(e.openBlock(),e.createBlock(e.Transition,{name:"scroll-top-pop"},{default:e.withCtx(()=>[a.value?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"scroll-top mfs-shadow mfs-interactive","aria-label":"Scroll to top",onClick:d},[e.renderSlot(n.$slots,"default",{},()=>[k[0]||(k[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-266880c8"]]),yi={key:0,class:"data-table__toolbar mfs-flex mfs-flex-wrap mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},bi={key:0,class:"data-table__search mfs-relative mfs-flex mfs-items-center"},Bi=["value"],_i={class:"data-table__wrap mfs-w-full mfs-overflow-x-auto"},wi={class:"data-table__table mfs-w-full mfs-text-left"},Ei={class:"data-table__head"},$i={key:0,class:"data-table__th data-table__th--select mfs-text-muted mfs-whitespace-nowrap"},Vi=["aria-sort"],Ci=["onClick"],xi={class:"data-table__sort-icon mfs-shrink-0",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},Ni=["fill"],Si=["fill"],Mi={key:0,class:"data-table__sort-badge"},Di={key:1},zi={class:"data-table__body"},Ti={key:0,class:"data-table__empty-row"},Li=["colspan"],Ii={class:"data-table__empty-content mfs-inline-flex mfs-flex-col mfs-items-center mfs-gap-2"},Ri=["aria-selected","onClick"],Pi=["checked","aria-label","onChange"],Fi=["data-label"],Ai={class:"data-table__cell-value"},ji={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"},Ki={key:0,class:"data-table__per-page mfs-inline-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-text-muted"},Oi=["value","disabled"],Ui=["value"],Hi={key:2,class:"mfs-loading-overlay","aria-busy":"true"},xt=D(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:{}},emits:["update:selection","update:searchQuery","update:page","update:rows","update:rowsPerPage","update:first","update:multiSortMeta","page","sort","filter","row-click"],setup(t,{emit:s}){const l=t,o=s,a=`dt-radio-${e.useId()}`,r=e.ref(l.searchQuery),i=e.ref(null),c=e.ref(null),d=e.ref(l.multiSortMeta?l.multiSortMeta.map(L=>({...L})):[]);e.watch(()=>l.multiSortMeta,L=>{d.value=L?L.map(T=>({...T})):[]},{deep:!0});const n=e.computed(()=>l.multiSortMeta??d.value),k=e.computed(()=>l.value??(Array.isArray(l.rows)?l.rows:[])),h=e.ref(typeof l.rows=="number"?l.rows:l.rowsPerPage??10);e.watch(()=>l.rows,L=>{typeof L=="number"&&(h.value=L)}),e.watch(()=>l.rowsPerPage,L=>{L!==void 0&&(h.value=L)});const y=e.computed(()=>Math.max(1,typeof l.rows=="number"?l.rows:l.rowsPerPage??h.value)),f=e.ref(l.page!==void 0?Math.max(1,l.page):l.first>0?Math.floor(l.first/y.value)+1:1);e.watch(()=>l.page,L=>{L!==void 0&&(f.value=Math.max(1,L))}),e.watch(()=>l.first,L=>{L!==void 0&&l.page===void 0&&(f.value=Math.floor(Math.max(0,L)/y.value)+1)}),e.watch(()=>l.searchQuery,L=>{r.value=L});const p=e.computed(()=>l.searchQuery!==""?l.searchQuery:r.value);e.watch(p,()=>{!l.lazy&&l.paginator&&M.value!==1&&(f.value=1,o("update:page",1),o("update:first",0))});const m=e.computed(()=>l.selectable===!0||l.selectable==="multiple"?"multiple":l.selectable==="single"?"single":null);function u(L,T){const R=L==null?void 0:L[l.rowKey];return typeof R=="string"||typeof R=="number"?R:T}function b(L){const T=L.target.value;r.value=T,o("update:searchQuery",T),o("filter",T)}function g(L){if(l.sortMode==="multiple"){const T=n.value.find(R=>R.key===L);return T?T.order:null}return i.value===L?c.value:null}function B(L){if(l.sortMode!=="multiple"||n.value.length===0)return null;const T=n.value.findIndex(R=>R.key===L);return T>=0?T+1:null}function w(L){if(l.sortMode==="multiple"){const T=n.value.map(z=>({...z})),R=T.findIndex(z=>z.key===L);let S="asc";R===-1?(T.push({key:L,order:"asc"}),S="asc"):T[R].order==="asc"?(T[R].order="desc",S="desc"):(T.splice(R,1),S=null),d.value=T,o("update:multiSortMeta",T),o("sort",{key:L,order:S,multiSortMeta:T});return}i.value!==L?(i.value=L,c.value="asc"):c.value==="asc"?c.value="desc":(i.value=null,c.value=null),o("sort",{key:L,order:c.value})}function _(L){if(!L.sortable)return;const T=g(L.key);return T?T==="asc"?"ascending":"descending":"none"}function $(L,T,R){return L==null&&T==null?0:L==null?-1*R:T==null?1*R:typeof L=="number"&&typeof T=="number"?(L-T)*R:String(L).localeCompare(String(T))*R}const C=e.computed(()=>{if(l.lazy)return k.value;const L=p.value.trim().toLowerCase();let T=k.value;if(L){const R=l.columns.map(S=>S.key);T=T.filter(S=>R.some(z=>String(S[z]??"").toLowerCase().includes(L)))}if(l.sortMode==="multiple"){if(n.value.length>0){const R=n.value;T=[...T].sort((S,z)=>{for(const W of R){const O=W.order==="asc"?1:-1,X=$(S[W.key],z[W.key],O);if(X!==0)return X}return 0})}}else if(i.value&&c.value){const R=i.value,S=c.value==="asc"?1:-1;T=[...T].sort((z,W)=>$(z[R],W[R],S))}return T}),E=e.computed(()=>l.lazy?l.totalRecords??k.value.length:l.totalRecords??C.value.length),V=e.computed(()=>Math.max(1,Math.ceil(E.value/y.value))),M=e.computed(()=>{const L=l.page!==void 0?l.page:f.value;return Math.min(Math.max(1,L),V.value)}),N=e.computed(()=>{if(l.lazy||!l.paginator)return C.value;const L=(M.value-1)*y.value;return C.value.slice(L,L+y.value)});function I(L){const T=y.value,R=V.value,S=Math.min(Math.max(1,L),R),z=(S-1)*T;f.value=S,o("update:page",S),o("update:first",z),o("page",{page:S,first:z,rows:T,pageCount:R,rowsPerPage:T})}function H(L){if(l.loading)return;const T=Number(L.target.value);if(!Number.isFinite(T)||T<=0)return;h.value=T;const R=Math.max(1,Math.ceil(E.value/T)),S=Math.min(M.value,R),z=(S-1)*T;f.value=S,o("update:rows",T),o("update:rowsPerPage",T),o("update:page",S),o("update:first",z),o("page",{page:S,first:z,rows:T,pageCount:R,rowsPerPage:T})}function G(L,T){if(!m.value||!l.selection)return!1;const R=u(L,T);return m.value==="single"?Array.isArray(l.selection)?!1:u(l.selection,-1)===R:Array.isArray(l.selection)&&l.selection.some((S,z)=>u(S,z)===R)}const Q=e.computed(()=>m.value!=="multiple"||N.value.length===0?!1:N.value.every((L,T)=>G(L,T))),ee=e.computed(()=>{if(m.value!=="multiple"||N.value.length===0)return!1;const L=N.value.filter((T,R)=>G(T,R)).length;return L>0&&L<N.value.length});function K(L,T){if(!m.value)return;if(m.value==="single"){o("update:selection",L);return}const R=u(L,T),S=Array.isArray(l.selection)?[...l.selection]:[],z=S.findIndex((W,O)=>u(W,O)===R);z>=0?S.splice(z,1):S.push(L),o("update:selection",S)}function U(){m.value==="multiple"&&(Q.value?o("update:selection",[]):o("update:selection",[...N.value]))}function Y(L,T){o("row-click",L),m.value&&K(L,T)}return(L,T)=>(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||L.$slots.header?(e.openBlock(),e.createElementBlock("div",yi,[e.renderSlot(L.$slots,"header",{},void 0,!0),t.searchable?(e.openBlock(),e.createElementBlock("div",bi,[T[3]||(T[3]=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:b},null,40,Bi)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",_i,[e.createElementVNode("table",wi,[e.createElementVNode("thead",Ei,[e.createElementVNode("tr",null,[m.value?(e.openBlock(),e.createElementBlock("th",$i,[m.value==="multiple"?(e.openBlock(),e.createBlock(fe,{key:0,class:"data-table__checkbox","model-value":Q.value,indeterminate:ee.value,"aria-label":"Select all rows",onClick:T[0]||(T[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":U},null,8,["model-value","indeterminate"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,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":g(R.key)!==null}]),onClick:S=>w(R.key)},[e.createElementVNode("span",null,e.toDisplayString(R.label),1),(e.openBlock(),e.createElementBlock("svg",xi,[e.createElementVNode("path",{d:"M8 3L11 6.5H5L8 3Z",fill:g(R.key)==="asc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Ni),e.createElementVNode("path",{d:"M8 13L5 9.5H11L8 13Z",fill:g(R.key)==="desc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,Si)])),t.sortMode==="multiple"&&B(R.key)!==null?(e.openBlock(),e.createElementBlock("span",Mi,e.toDisplayString(B(R.key)),1)):e.createCommentVNode("",!0)],10,Ci)):(e.openBlock(),e.createElementBlock("span",Di,e.toDisplayString(R.label),1))],14,Vi))),128))])]),e.createElementVNode("tbody",zi,[N.value.length===0?(e.openBlock(),e.createElementBlock("tr",Ti,[e.createElementVNode("td",{colspan:t.columns.length+(m.value?1:0),class:"data-table__empty mfs-text-muted mfs-text-center"},[e.renderSlot(L.$slots,"empty",{},()=>[e.createElementVNode("div",Ii,[T[4]||(T[4]=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,Li)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(N.value,(R,S)=>(e.openBlock(),e.createElementBlock("tr",{key:u(R,S),class:e.normalizeClass(["data-table__row",{"data-table__row--selected":G(R,S)}]),"aria-selected":m.value?G(R,S):void 0,onClick:z=>Y(R,S)},[m.value?(e.openBlock(),e.createElementBlock("td",{key:0,class:"data-table__td data-table__td--select","data-label":"Select",onClick:T[2]||(T[2]=e.withModifiers(()=>{},["stop"]))},[m.value==="single"?(e.openBlock(),e.createElementBlock("input",{key:0,type:"radio",class:"data-table__checkbox mfs-cursor-pointer",name:a,checked:G(R,S),"aria-label":`Select row ${S+1}`,onChange:z=>K(R,S)},null,40,Pi)):(e.openBlock(),e.createBlock(fe,{key:1,class:"data-table__checkbox","model-value":G(R,S),"aria-label":`Select row ${S+1}`,onClick:T[1]||(T[1]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":z=>K(R,S)},null,8,["model-value","aria-label","onUpdate:modelValue"]))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,z=>(e.openBlock(),e.createElementBlock("td",{key:z.key,class:e.normalizeClass(["data-table__td",z.align?`data-table__cell--${z.align}`:""]),"data-label":z.label},[e.renderSlot(L.$slots,`cell-${z.key}`,{row:R,value:R[z.key],column:z,index:S},()=>[e.createElementVNode("span",Ai,e.toDisplayString(R[z.key]??""),1)],!0)],10,Fi))),128))],10,Ri))),128))])])]),t.paginator?(e.openBlock(),e.createElementBlock("div",ji,[t.rowsPerPageOptions.length?(e.openBlock(),e.createElementBlock("label",Ki,[T[5]||(T[5]=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:y.value,disabled:t.loading,"aria-label":"Rows per page",onChange:H},[(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,Ui))),128))],40,Oi),T[6]||(T[6]=e.createElementVNode("span",null,"per page",-1))])):e.createCommentVNode("",!0),e.createVNode(ye,{"model-value":M.value,total:E.value,"per-page":y.value,"per-page-options":[],loading:t.loading,"onUpdate:modelValue":I},null,8,["model-value","total","per-page","loading"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Hi,[e.renderSlot(L.$slots,"loading",{},()=>[T[7]||(T[7]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-df43973e"]]),Nt=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(s,l)=>null}});function be(t,s,l="id"){if(t&&typeof t=="object"&&l in t){const o=t[l];if(typeof o=="string"||typeof o=="number")return o}return s}const Wi={class:"data-view mfs-relative"},Gi={class:"data-view__header"},qi={class:"data-view__header-left"},Yi={class:"data-view__toggle mfs-inset mfs-rounded-md",role:"group","aria-label":"View layout"},Xi=["aria-pressed"],Zi=["aria-pressed"],Ji={key:0,class:"data-view__empty mfs-card mfs-text-muted"},Qi={class:"data-view__empty-content"},vi={class:"data-view__fallback-card mfs-card"},ed={key:2,class:"mfs-loading-overlay","aria-busy":"true"},St=D(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:s}){const l=t,o=s,a=e.ref(l.layout);e.watch(()=>l.layout,d=>{a.value=d});const r=e.computed(()=>a.value),i=e.computed(()=>{if(!(r.value!=="grid"||!l.columns))return{gridTemplateColumns:`repeat(${l.columns}, minmax(0, 1fr))`}});function c(d){a.value!==d&&(a.value=d,o("update:layout",d))}return(d,n)=>(e.openBlock(),e.createElementBlock("div",Wi,[e.createElementVNode("div",Gi,[e.createElementVNode("div",qi,[e.renderSlot(d.$slots,"header",{},void 0,!0)]),e.createElementVNode("div",Yi,[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:n[0]||(n[0]=k=>c("grid"))},[...n[2]||(n[2]=[e.createStaticVNode('<svg viewBox="0 0 18 18" fill="none" aria-hidden="true" data-v-c1be6bfd><rect x="2" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect><rect x="10" y="2" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect><rect x="2" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect><rect x="10" y="10" width="6" height="6" rx="1.5" stroke="currentColor" stroke-width="1.6" data-v-c1be6bfd></rect></svg>',1)])],10,Xi),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:n[1]||(n[1]=k=>c("list"))},[...n[3]||(n[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,Zi)])]),t.items.length===0?(e.openBlock(),e.createElementBlock("div",Ji,[e.renderSlot(d.$slots,"empty",{},()=>[e.createElementVNode("div",Qi,[n[4]||(n[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(i.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(k,h)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(be)(k,h,t.itemKey),class:"data-view__item"},[r.value==="grid"&&d.$slots.grid?e.renderSlot(d.$slots,"grid",{item:k,index:h},void 0,!0,0):r.value==="list"&&d.$slots.list?e.renderSlot(d.$slots,"list",{item:k,index:h},void 0,!0,1):e.renderSlot(d.$slots,"default",{item:k,index:h,layout:r.value},()=>[e.createElementVNode("div",vi,e.toDisplayString(k),1)],!0,2)]))),128))],6)),t.loading?(e.openBlock(),e.createElementBlock("div",ed,[e.renderSlot(d.$slots,"loading",{},()=>[n[5]||(n[5]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-c1be6bfd"]]),td=["role"],ld={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},od={key:1,class:"mfs-empty-state"},nd=["aria-expanded","aria-selected","aria-disabled"],ad=["onClick","onKeydown"],sd=["aria-label","onClick"],rd={key:1,class:"tree__spacer","aria-hidden":"true"},id={key:3,class:"tree__icon","aria-hidden":"true"},dd={class:"tree__content"},cd={class:"tree__label"},Mt=D(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:s}){const l=t,o=s;function a(f){return Array.isArray(f.children)&&f.children.length>0}function r(f){return a(f)||l.lazy&&!f.leaf}function i(f){return l.expandedKeys.includes(f)}function c(f){return l.selectedKeys.includes(f)}function d(f){var u;if(!r(f))return;const p=new Set(l.expandedKeys),m=!p.has(f.key);m?(p.add(f.key),l.lazy&&!((u=f.children)!=null&&u.length)&&o("lazy-load",f)):p.delete(f.key),o("update:expandedKeys",Array.from(p)),o("node-toggle",f,m)}function n(f){r(f)&&!i(f.key)&&d(f)}function k(f){r(f)&&i(f.key)&&d(f)}function h(f){if(f.disabled||l.selectionMode==="none")return;if(l.selectionMode==="single"){o("update:selectedKeys",c(f.key)?[]:[f.key]);return}const p=new Set(l.selectedKeys);p.has(f.key)?p.delete(f.key):p.add(f.key),o("update:selectedKeys",Array.from(p))}function y(f){f.disabled||(o("node-click",f),l.selectionMode!=="none"?h(f):r(f)&&d(f))}return(f,p)=>{const m=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",ld,[e.renderSlot(f.$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",od,[e.renderSlot(f.$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,u=>(e.openBlock(),e.createElementBlock("li",{key:u.key,class:"tree__item",role:"treeitem","aria-expanded":r(u)?i(u.key):void 0,"aria-selected":t.selectionMode!=="none"?c(u.key):void 0,"aria-disabled":u.disabled||void 0},[e.createElementVNode("div",{class:e.normalizeClass(["tree__row mfs-rounded-sm mfs-focus-ring",{"tree__row--selected":c(u.key),"tree__row--disabled mfs-disabled":u.disabled}]),style:e.normalizeStyle({paddingLeft:`${t.level*20+8}px`}),tabindex:"0",onClick:b=>y(u),onKeydown:[e.withKeys(e.withModifiers(b=>y(u),["prevent"]),["enter"]),e.withKeys(e.withModifiers(b=>y(u),["prevent"]),["space"]),e.withKeys(e.withModifiers(b=>n(u),["prevent"]),["right"]),e.withKeys(e.withModifiers(b=>k(u),["prevent"]),["left"])]},[r(u)?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree__toggle mfs-text-muted",{"tree__toggle--expanded":i(u.key)}]),"aria-label":i(u.key)?`Collapse ${u.label}`:`Expand ${u.label}`,tabindex:"-1",onClick:e.withModifiers(b=>d(u),["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,sd)):(e.openBlock(),e.createElementBlock("span",rd)),t.selectionMode==="checkbox"?(e.openBlock(),e.createBlock(fe,{key:2,class:"tree__checkbox","model-value":c(u.key),disabled:u.disabled,"aria-label":`Select ${u.label}`,tabindex:-1,onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":b=>h(u)},null,8,["model-value","disabled","aria-label","onUpdate:modelValue"])):e.createCommentVNode("",!0),u.icon?(e.openBlock(),e.createElementBlock("span",id,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("div",dd,[e.renderSlot(f.$slots,"node",{node:u,expanded:i(u.key),selected:c(u.key),level:t.level},()=>[e.createElementVNode("span",cd,e.toDisplayString(u.label),1)],!0)])],46,ad),a(u)&&i(u.key)?(e.openBlock(),e.createBlock(m,{key:0,nodes:u.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]=b=>f.$emit("update:expandedKeys",b)),"onUpdate:selectedKeys":p[2]||(p[2]=b=>f.$emit("update:selectedKeys",b)),onNodeClick:p[3]||(p[3]=b=>f.$emit("node-click",b)),onNodeToggle:p[4]||(p[4]=(b,g)=>f.$emit("node-toggle",b,g)),onLazyLoad:p[5]||(p[5]=b=>f.$emit("lazy-load",b))},e.createSlots({_:2},[f.$slots.node?{name:"node",fn:e.withCtx(b=>[e.renderSlot(f.$slots,"node",e.mergeProps({ref_for:!0},b),void 0,!0)]),key:"0"}:void 0]),1032,["nodes","expanded-keys","selection-mode","selected-keys","lazy","level"])):e.createCommentVNode("",!0)],8,nd))),128))],10,td)}}}),[["__scopeId","data-v-0e17bf40"]]),md={class:"ac-box mfs-surface mfs-rounded mfs-shadow-inset"},fd=["aria-expanded","value","placeholder","disabled"],pd={key:0,class:"ac-spinner","aria-hidden":"true"},ud=["aria-selected","onMousedown","onMouseenter"],kd={key:0,class:"mfs-empty-state",role:"status"},Dt=D(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:s}){const l=t,o=s,a=`mfs-ac-${e.useId()}`,r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(-1),{overlayStyle:k,containsTarget:h}=oe(i,c,d,{matchWidth:!0}),y=e.computed(()=>{const B=l.suggestions.map(_=>typeof _=="string"?{label:_,value:_}:_);if(l.remote)return B;const w=(l.modelValue||"").toLowerCase();return B.filter(_=>!w||_.label.toLowerCase().includes(w))}),f=e.computed(()=>(l.modelValue||"").length>=l.minLength&&!l.loading&&y.value.length===0),p=B=>{const w=B.target.value;o("update:modelValue",w),w.length>=l.minLength?(o("complete",{query:w}),d.value=!0,n.value=-1):d.value=!1},m=()=>{(l.modelValue||"").length>=l.minLength&&(y.value.length||!l.loading)&&(d.value=!0)},u=B=>{o("update:modelValue",B.label),o("select",B),d.value=!1},b=B=>{if(d.value){if(B.key==="Escape")d.value=!1;else if(B.key==="ArrowDown")B.preventDefault(),y.value.length&&(n.value=(n.value+1)%y.value.length);else if(B.key==="ArrowUp")B.preventDefault(),y.value.length&&(n.value=(n.value-1+y.value.length)%y.value.length);else if(B.key==="Enter"&&n.value>=0){B.preventDefault();const w=y.value[n.value];w&&u(w)}}},g=B=>{h(B.target)||(d.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",g)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",g)),(B,w)=>(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:a,class:"ac-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:i,class:"ac-container"},[e.createElementVNode("div",md,[e.createElementVNode("input",{id:a,type:"text",role:"combobox","aria-expanded":d.value,"aria-autocomplete":"list",value:t.modelValue,placeholder:t.placeholder,disabled:t.disabled,class:"ac-input mfs-text",onInput:p,onFocus:m,onKeydown:b},null,40,fd),t.loading?(e.openBlock(),e.createElementBlock("span",pd)):e.createCommentVNode("",!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ac-pop"},{default:e.withCtx(()=>[d.value&&(y.value.length||f.value)?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:c,role:"listbox",style:e.normalizeStyle(e.unref(k)),class:"ac-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(_,$)=>(e.openBlock(),e.createElementBlock("li",{key:_.label+$,role:"option","aria-selected":$===n.value,class:e.normalizeClass(["ac-option mfs-text",{"ac-option--active":$===n.value}]),onMousedown:e.withModifiers(C=>u(_),["prevent"]),onMouseenter:C=>n.value=$},e.toDisplayString(_.label),43,ud))),128)),f.value?(e.openBlock(),e.createElementBlock("li",kd,[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-7c96b5c1"]]),hd={key:0,class:"cas-label mfs-text"},gd={class:"cas-container"},yd=["disabled","aria-expanded"],bd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Bd={key:0,class:"cas-col"},_d={key:1,class:"cas-col"},wd={class:"mfs-empty-state"},Ed=["disabled","onClick"],$d={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Vd={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Cd={key:0,class:"cas-col"},Le=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=oe(a,r,i,{offset:6}),n=e.ref([...l.modelValue]);e.watch(()=>l.modelValue,m=>{n.value=[...m||[]]});const k=e.computed(()=>{const m=[];let u=l.options,b=0;for(;u&&u.length;){m.push(u);const g=n.value[b],B=u.find(w=>w.value===g);u=B==null?void 0:B.children,b++}return m}),h=e.computed(()=>{const m=[];let u=l.options;for(const b of l.modelValue||[]){const g=u==null?void 0:u.find(B=>B.value===b);if(!g)break;m.push(g.label),u=g.children}return m.join(l.separator)}),y=(m,u)=>{var g,B;if(u.disabled)return;const b=[...n.value.slice(0,m),u.value];if(n.value=b,l.lazy&&!u.isLeaf&&!((g=u.children)!=null&&g.length)){o("lazy-load",u);return}(B=u.children)!=null&&B.length||(o("update:modelValue",b),o("change",b),i.value=!1)},f=m=>{d(m.target)||(i.value=!1)},p=m=>{m.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",f),document.addEventListener("keydown",p)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",f),document.removeEventListener("keydown",p)}),(m,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cas-wrapper",{"cas-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",hd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",gd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,type:"button",class:"cas-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":i.value,onClick:u[0]||(u[0]=b=>i.value=!i.value)},[e.createElementVNode("span",{class:e.normalizeClass(["cas-value",{"mfs-text-muted":!h.value}])},e.toDisplayString(h.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",bd)):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":i.value}])},[...u[1]||(u[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,yd),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cas-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),class:"cas-panel mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading&&k.value.length===0?(e.openBlock(),e.createElementBlock("div",Bd,[e.renderSlot(m.$slots,"loading",{},()=>[u[2]||(u[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):k.value.length===0?(e.openBlock(),e.createElementBlock("div",_d,[e.createElementVNode("div",wd,[e.renderSlot(m.$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(k.value,(b,g)=>(e.openBlock(),e.createElementBlock("div",{key:g,class:"cas-col"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b,B=>{var w;return e.openBlock(),e.createElementBlock("button",{key:String(B.value),type:"button",class:e.normalizeClass(["cas-item mfs-text",{"cas-item--active":n.value[g]===B.value}]),disabled:B.disabled,onClick:_=>y(g,B)},[e.createElementVNode("span",null,e.toDisplayString(B.label),1),B.loading?(e.openBlock(),e.createElementBlock("span",$d)):(w=B.children)!=null&&w.length||t.lazy&&!B.isLeaf?(e.openBlock(),e.createElementBlock("svg",Vd,[...u[3]||(u[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Ed)}),128))]))),128)),t.loading?(e.openBlock(),e.createElementBlock("div",Cd,[e.renderSlot(m.$slots,"loading",{},()=>[u[4]||(u[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"]]),xd={key:0,class:"ts-label mfs-text"},Nd={class:"ts-container"},Sd=["disabled","aria-expanded"],Md={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Dd={key:1,class:"mfs-empty-state"},zd=["aria-selected"],Td=["aria-label","onClick"],Ld={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},Id={key:1,class:"ts-expand-spacer"},Rd=["disabled","onClick"],Pd={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"},zt=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=oe(a,r,i,{offset:6,matchWidth:!0}),n=e.reactive(new Set),k=g=>{var B;n.has(g.value)?n.delete(g.value):(n.add(g.value),l.lazy&&!g.isLeaf&&!((B=g.children)!=null&&B.length)&&o("lazy-load",g))},h=e.computed(()=>{const g=[],B=(w,_)=>{var $;for(const C of w)g.push({node:C,depth:_}),($=C.children)!=null&&$.length&&n.has(C.value)&&B(C.children,_+1)};return B(l.options,0),g}),y=e.computed(()=>{const g=new Map,B=w=>{var _;for(const $ of w)g.set($.value,$.label),(_=$.children)!=null&&_.length&&B($.children)};return B(l.options),g}),f=e.computed(()=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.map(g=>y.value.get(g)??String(g)).join(", "):l.modelValue===null||l.modelValue===void 0?"":y.value.get(l.modelValue)??String(l.modelValue)),p=g=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(g):l.modelValue===g,m=g=>{if(!g.disabled)if(l.multiple){const B=Array.isArray(l.modelValue)?l.modelValue:[],w=B.includes(g.value)?B.filter(_=>_!==g.value):[...B,g.value];o("update:modelValue",w),o("change",w)}else o("update:modelValue",g.value),o("change",g.value),i.value=!1},u=g=>{d(g.target)||(i.value=!1)},b=g=>{g.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",u),document.addEventListener("keydown",b)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",u),document.removeEventListener("keydown",b)}),(g,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",xd,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Nd,[e.createElementVNode("button",{ref_key:"triggerRef",ref:a,type:"button",class:"ts-trigger mfs-surface mfs-rounded mfs-shadow-inset mfs-focus-ring",disabled:t.disabled,"aria-expanded":i.value,onClick:B[0]||(B[0]=w=>i.value=!i.value)},[e.createElementVNode("span",{class:e.normalizeClass(["ts-value",{"mfs-text-muted":!f.value}])},e.toDisplayString(f.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",Md)):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":i.value}])},[...B[1]||(B[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,Sd),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ts-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(c)),class:"ts-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow",role:"tree"},[t.loading&&h.value.length===0?e.renderSlot(g.$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):h.value.length===0?(e.openBlock(),e.createElementBlock("div",Dd,[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(h.value,w=>{var _;return e.openBlock(),e.createElementBlock("div",{key:String(w.node.value),role:"treeitem","aria-selected":p(w.node.value),class:"ts-row",style:e.normalizeStyle({paddingLeft:`${8+w.depth*18}px`})},[(_=w.node.children)!=null&&_.length||t.lazy&&!w.node.isLeaf?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"ts-expand mfs-text-muted","aria-label":n.has(w.node.value)?"Collapse":"Expand",onClick:e.withModifiers($=>k(w.node),["stop"])},[w.node.loading?(e.openBlock(),e.createElementBlock("span",Ld)):(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:n.has(w.node.value)?"rotate(90deg)":""})},[...B[3]||(B[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])],4))],8,Td)):(e.openBlock(),e.createElementBlock("span",Id)),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["ts-node mfs-text",{"ts-node--selected":p(w.node.value)}]),disabled:w.node.disabled,onClick:$=>m(w.node)},[e.createElementVNode("span",null,e.toDisplayString(w.node.label),1),p(w.node.value)?(e.openBlock(),e.createElementBlock("svg",Pd,[...B[4]||(B[4]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],10,Rd)],12,zd)}),128)),t.loading?e.renderSlot(g.$slots,"loading",{},void 0,!0,0):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-2741eadc"]]),Fd=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],Ad=["viewBox","width","height"],jd=["d","stroke-width"],Kd=["d","stroke-width"],Od={class:"knob-value mfs-text mfs-font-mono"},Ud={key:0,class:"knob-label mfs-caption"},Tt=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(!1),i=e.computed(()=>l.size/2),c=e.computed(()=>l.size/2-l.strokeWidth-4),d=B=>{const w=(B-90)*Math.PI/180;return{x:i.value+c.value*Math.cos(w),y:i.value+c.value*Math.sin(w)}},n=(B,w)=>{const _=d(w),$=d(B),C=w-B<=180?"0":"1";return`M ${_.x} ${_.y} A ${c.value} ${c.value} 0 ${C} 0 ${$.x} ${$.y}`},k=e.computed(()=>{const B=l.max-l.min;return B<=0?0:Math.max(0,Math.min(1,(l.modelValue-l.min)/B))}),h=e.computed(()=>n(225,495)),y=e.computed(()=>{const B=225+k.value*270;return B<=225.1?"":n(225,B)}),f=e.computed(()=>l.valueTemplate.replace("{value}",String(l.modelValue))),p=(B,w)=>{var H;const _=(H=a.value)==null?void 0:H.getBoundingClientRect();if(!_)return;const $=_.left+_.width/2,C=_.top+_.height/2;let E=Math.atan2(w-C,B-$)*180/Math.PI+90;E<0&&(E+=360);let V=E>=225?E-225:E<=135?E+135:E<180?270:0;V=Math.max(0,Math.min(270,V));const M=l.min+V/270*(l.max-l.min),N=Math.round((M-l.min)/l.step)*l.step+l.min,I=Math.max(l.min,Math.min(l.max,Number(N.toFixed(6))));o("update:modelValue",I)},m=B=>{r.value&&p(B.clientX,B.clientY)},u=()=>{r.value&&(r.value=!1,o("change",l.modelValue)),window.removeEventListener("pointermove",m),window.removeEventListener("pointerup",u)},b=B=>{l.disabled||l.readonly||(B.preventDefault(),r.value=!0,p(B.clientX,B.clientY),window.addEventListener("pointermove",m),window.addEventListener("pointerup",u))},g=B=>{if(l.disabled||l.readonly)return;const w=B.key==="ArrowRight"||B.key==="ArrowUp"?l.step:B.key==="ArrowLeft"||B.key==="ArrowDown"?-l.step:0;if(!w)return;B.preventDefault();const _=Math.max(l.min,Math.min(l.max,l.modelValue+w));o("update:modelValue",_),o("change",_)};return e.onBeforeUnmount(u),(B,w)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["knob-wrapper",{"knob-wrapper--disabled mfs-disabled":t.disabled}])},[e.createElementVNode("div",{ref_key:"svgBoxRef",ref:a,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:b,onKeydown:g},[(e.openBlock(),e.createElementBlock("svg",{viewBox:`0 0 ${t.size} ${t.size}`,width:t.size,height:t.size},[e.createElementVNode("path",{d:h.value,fill:"none",stroke:"var(--surface-subtle, rgba(148,163,184,0.28))","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,jd),e.createElementVNode("path",{d:y.value,fill:"none",stroke:"var(--primary, #8b5cf6)","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,Kd)],8,Ad)),e.createElementVNode("span",Od,e.toDisplayString(f.value),1)],44,Fd),t.label?(e.openBlock(),e.createElementBlock("span",Ud,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-5002b75d"]]),Hd=["disabled","aria-pressed","onClick"],Lt=D(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:s}){const l=t,o=s,a=e.computed(()=>l.options.map(c=>typeof c=="string"?{label:c,value:c}:c)),r=c=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(c):l.modelValue===c,i=c=>{if(!(l.disabled||c.disabled))if(l.multiple){const d=Array.isArray(l.modelValue)?l.modelValue:[],n=d.includes(c.value)?d.filter(k=>k!==c.value):[...d,c.value];o("update:modelValue",n),o("change",n)}else o("update:modelValue",c.value),o("change",c.value)};return(c,d)=>(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(a.value,(n,k)=>(e.openBlock(),e.createElementBlock("button",{key:String(n.value)+k,type:"button",class:e.normalizeClass(["sb-btn mfs-text mfs-focus-ring",{"sb-btn--active mfs-shadow":r(n.value)}]),disabled:t.disabled||n.disabled,"aria-pressed":r(n.value),onClick:h=>i(n)},e.toDisplayString(n.label),11,Hd))),128))],2))}}),[["__scopeId","data-v-80282f25"]]),Wd=["aria-pressed","disabled"],It=D(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:s}){const l=t,o=s,a=()=>{if(l.disabled)return;const r=!l.modelValue;o("update:modelValue",r),o("change",r)};return(r,i)=>(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:a},[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.modelValue?t.onLabel:t.offLabel),1)],!0)],10,Wd))}}),[["__scopeId","data-v-84c00cdb"]]),Gd=["type","inputmode","value","disabled","aria-label","onInput","onKeydown","onPaste"],Rt=D(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:s}){const l=t,o=s,a=e.ref([]),r=(h,y)=>{a.value[y]=h},i=e.computed(()=>Array.from({length:l.length},(h,y)=>l.modelValue[y]??"")),c=h=>{const y=h.join("").slice(0,l.length);o("update:modelValue",y),y.length===l.length&&!h.includes("")&&o("complete",y)},d=(h,y)=>{var u;const p=y.target.value.slice(-1);if(l.integerOnly&&p&&!/^\d$/.test(p)){y.target.value=i.value[h];return}const m=[...i.value];m[h]=p,c(m),p&&h<l.length-1&&((u=a.value[h+1])==null||u.focus())},n=(h,y)=>{var f,p,m;y.key==="Backspace"&&!i.value[h]&&h>0?(f=a.value[h-1])==null||f.focus():y.key==="ArrowLeft"&&h>0?(y.preventDefault(),(p=a.value[h-1])==null||p.focus()):y.key==="ArrowRight"&&h<l.length-1&&(y.preventDefault(),(m=a.value[h+1])==null||m.focus())},k=(h,y)=>{var b,g;y.preventDefault();const f=((b=y.clipboardData)==null?void 0:b.getData("text"))??"",p=l.integerOnly?f.replace(/\D/g,""):f;if(!p)return;const m=[...i.value];for(let B=0;B<p.length&&h+B<l.length;B++)m[h+B]=p[B];c(m);const u=Math.min(l.length-1,h+p.length);(g=a.value[u])==null||g.focus()};return(h,y)=>(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,f=>(e.openBlock(),e.createElementBlock("input",{key:f,ref_for:!0,ref:p=>r(p,f-1),type:t.mask?"password":"text",inputmode:t.integerOnly?"numeric":"text",maxlength:"1",value:i.value[f-1],disabled:t.disabled,"aria-label":`Digit ${f} of ${t.length}`,class:"otp-cell mfs-surface mfs-rounded mfs-shadow-inset mfs-text mfs-font-mono",onInput:p=>d(f-1,p),onKeydown:p=>n(f-1,p),onPaste:p=>k(f-1,p)},null,40,Gd))),128))],2))}}),[["__scopeId","data-v-825a2351"]]),qd={class:"mask-box mfs-surface mfs-rounded mfs-shadow-inset"},Yd=["value","placeholder","disabled"],Pt=D(e.defineComponent({__name:"InputMask",props:{modelValue:{default:""},mask:{},label:{},placeholder:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:s}){const l=t,o=s,a=`mfs-mask-${e.useId()}`,r=(d,n)=>d==="9"?/^\d$/.test(n):d==="a"?/^[a-zA-Z]$/.test(n):d==="*"?/^[a-zA-Z0-9]$/.test(n):!1,i=d=>{const n=d.split("");let k="",h=0;for(let y=0;y<l.mask.length&&h<n.length;y++){const f=l.mask[y];if(f==="9"||f==="a"||f==="*"){for(;h<n.length&&!r(f,n[h]);)h++;h<n.length&&(k+=n[h],h++)}else k+=f,n[h]===f&&h++}return k},c=d=>{const n=d.target,k=i(n.value);n.value=k,o("update:modelValue",k)};return(d,n)=>(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:a,class:"mask-label mfs-text"},e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",qd,[e.createElementVNode("input",{id:a,type:"text",value:t.modelValue,placeholder:t.placeholder||t.mask,disabled:t.disabled,class:"mask-input mfs-text mfs-font-mono",onInput:c},null,40,Yd)])],2))}}),[["__scopeId","data-v-5d657e20"]]),Xd={},Zd={class:"ig-wrapper mfs-surface mfs-rounded mfs-shadow-inset"};function Jd(t,s){return e.openBlock(),e.createElementBlock("div",Zd,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const Ft=D(Xd,[["render",Jd],["__scopeId","data-v-9b55039f"]]),Qd={},vd={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 ec(t,s){return e.openBlock(),e.createElementBlock("span",vd,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const At=D(Qd,[["render",ec],["__scopeId","data-v-06440459"]]),tc={key:0,class:"icon-field__icon mfs-text-muted","aria-hidden":"true"},jt=D(e.defineComponent({__name:"IconField",props:{iconPosition:{default:"left"},fluid:{type:Boolean,default:!1}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["icon-field",[`icon-field--${t.iconPosition}`,{"icon-field--fluid":t.fluid}]])},[s.$slots.icon?(e.openBlock(),e.createElementBlock("span",tc,[e.renderSlot(s.$slots,"icon",{},void 0,!0)])):e.createCommentVNode("",!0),e.renderSlot(s.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-aafeb221"]]),lc={},oc={class:"input-icon mfs-inline-flex mfs-items-center mfs-justify-center mfs-text-muted","aria-hidden":"true"};function nc(t,s){return e.openBlock(),e.createElementBlock("span",oc,[e.renderSlot(t.$slots,"default")])}const Kt=D(lc,[["render",nc]]),ac={key:0,class:"lb-filter-box"},sc=["disabled"],rc=["aria-multiselectable"],ic=["aria-selected","onClick","onKeydown"],dc={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"},cc={key:0,class:"lb-empty mfs-text-muted"},Ot=D(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:s}){const l=t,o=s,a=e.ref(""),r=e.computed(()=>l.options.map(n=>typeof n=="string"?{label:n,value:n}:n)),i=e.computed(()=>{const n=a.value.trim().toLowerCase();return n?r.value.filter(k=>k.label.toLowerCase().includes(n)):r.value}),c=n=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(n):l.modelValue===n,d=n=>{if(!(l.disabled||n.disabled))if(l.multiple){const k=Array.isArray(l.modelValue)?l.modelValue:[],h=k.includes(n.value)?k.filter(y=>y!==n.value):[...k,n.value];o("update:modelValue",h),o("change",h)}else o("update:modelValue",n.value),o("change",n.value)};return(n,k)=>(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",ac,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":k[0]||(k[0]=h=>a.value=h),type:"text",class:"lb-filter mfs-inset mfs-text",placeholder:"Filter...",disabled:t.disabled},null,8,sc),[[e.vModelText,a.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(i.value,(h,y)=>(e.openBlock(),e.createElementBlock("li",{key:String(h.value)+y,role:"option","aria-selected":c(h.value),class:e.normalizeClass(["lb-item mfs-text mfs-focus-ring",{"lb-item--selected":c(h.value),"lb-item--disabled":h.disabled}]),tabindex:"0",onClick:f=>d(h),onKeydown:[e.withKeys(e.withModifiers(f=>d(h),["prevent"]),["enter"]),e.withKeys(e.withModifiers(f=>d(h),["prevent"]),["space"])]},[e.createElementVNode("span",null,e.toDisplayString(h.label),1),c(h.value)?(e.openBlock(),e.createElementBlock("svg",dc,[...k[1]||(k[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],42,ic))),128)),i.value.length===0?(e.openBlock(),e.createElementBlock("li",cc,"No options")):e.createCommentVNode("",!0)],8,rc)],2))}}),[["__scopeId","data-v-57e05a19"]]),mc=["for"],Ut=D(e.defineComponent({__name:"FloatLabel",props:{label:{},forId:{},active:{type:Boolean}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["fl-wrapper",{"fl-wrapper--active":t.active}])},[e.renderSlot(s.$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,mc)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-c37f1a9e"]]),fc={class:"ifta-wrapper mfs-surface mfs-rounded mfs-shadow-inset"},pc=["for"],uc={class:"ifta-control"},Ht=D(e.defineComponent({__name:"IftaLabel",props:{label:{},forId:{}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",fc,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"ifta-label mfs-text-muted"},e.toDisplayString(t.label),9,pc)):e.createCommentVNode("",!0),e.createElementVNode("div",uc,[e.renderSlot(s.$slots,"default",{},void 0,!0)])]))}}),[["__scopeId","data-v-289391b4"]]),kc={key:0,class:"ed-toolbar mfs-surface-subtle",role:"toolbar","aria-label":"Formatting"},hc=["contenteditable","data-placeholder"],Wt=D(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:s}){const l=t,o=s,a=e.ref(null),r=n=>{const k=new DOMParser().parseFromString(n||"","text/html");return k.body.querySelectorAll("script, iframe, object, embed").forEach(h=>h.remove()),k.body.querySelectorAll("*").forEach(h=>{for(const y of Array.from(h.attributes)){const f=y.name.toLowerCase(),p=y.value.trim().toLowerCase();(f.startsWith("on")||(f==="href"||f==="src")&&p.startsWith("javascript:"))&&h.removeAttribute(y.name)}}),Array.from(k.body.childNodes)},i=n=>{!a.value||a.value.innerHTML===n||a.value.replaceChildren(...r(n))};e.onMounted(()=>i(l.modelValue)),e.watch(()=>l.modelValue,n=>i(n));const c=()=>{a.value&&o("update:modelValue",a.value.innerHTML)},d=n=>{var k;l.disabled||l.readonly||((k=a.value)==null||k.focus(),document.execCommand(n,!1),c())};return(n,k)=>(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",kc,[e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bold","aria-label":"Bold",onMousedown:k[0]||(k[0]=e.withModifiers(h=>d("bold"),["prevent"]))},[...k[7]||(k[7]=[e.createElementVNode("strong",null,"B",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Italic","aria-label":"Italic",onMousedown:k[1]||(k[1]=e.withModifiers(h=>d("italic"),["prevent"]))},[...k[8]||(k[8]=[e.createElementVNode("em",null,"I",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Underline","aria-label":"Underline",onMousedown:k[2]||(k[2]=e.withModifiers(h=>d("underline"),["prevent"]))},[...k[9]||(k[9]=[e.createElementVNode("u",null,"U",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Strikethrough","aria-label":"Strikethrough",onMousedown:k[3]||(k[3]=e.withModifiers(h=>d("strikeThrough"),["prevent"]))},[...k[10]||(k[10]=[e.createElementVNode("s",null,"S",-1)])],32),k[11]||(k[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:k[4]||(k[4]=e.withModifiers(h=>d("insertUnorderedList"),["prevent"]))}," • List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Numbered List","aria-label":"Numbered List",onMousedown:k[5]||(k[5]=e.withModifiers(h=>d("insertOrderedList"),["prevent"]))}," 1. List ",32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text-muted",title:"Clear Formatting","aria-label":"Clear Formatting",onMousedown:k[6]||(k[6]=e.withModifiers(h=>d("removeFormat"),["prevent"]))}," Clear ",32)])),e.createElementVNode("div",{ref_key:"editorRef",ref:a,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:c},null,44,hc)],2))}}),[["__scopeId","data-v-8aa9e8cf"]]);/**
2
2
  * @license lucide-vue-next v0.460.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
5
5
  * See the LICENSE file in the root directory of this source tree.
6
- */const mc=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
6
+ */const gc=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();/**
7
7
  * @license lucide-vue-next v0.460.0 - ISC
8
8
  *
9
9
  * This source code is licensed under the ISC license.
10
10
  * See the LICENSE file in the root directory of this source tree.
11
- */var xe={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"};/**
11
+ */var Ie={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":2,"stroke-linecap":"round","stroke-linejoin":"round"};/**
12
12
  * @license lucide-vue-next v0.460.0 - ISC
13
13
  *
14
14
  * This source code is licensed under the ISC license.
15
15
  * See the LICENSE file in the root directory of this source tree.
16
- */const fc=({size:t,strokeWidth:s=2,absoluteStrokeWidth:l,color:o,iconNode:a,name:r,class:i,...c},{slots:d})=>e.h("svg",{...xe,width:t||xe.width,height:t||xe.height,stroke:o||xe.stroke,"stroke-width":l?Number(s)*24/Number(t):s,class:["lucide",`lucide-${mc(r??"icon")}`],...c},[...a.map(n=>e.h(...n)),...d.default?[d.default()]:[]]);/**
16
+ */const yc=({size:t,strokeWidth:s=2,absoluteStrokeWidth:l,color:o,iconNode:a,name:r,class:i,...c},{slots:d})=>e.h("svg",{...Ie,width:t||Ie.width,height:t||Ie.height,stroke:o||Ie.stroke,"stroke-width":l?Number(s)*24/Number(t):s,class:["lucide",`lucide-${gc(r??"icon")}`],...c},[...a.map(n=>e.h(...n)),...d.default?[d.default()]:[]]);/**
17
17
  * @license lucide-vue-next v0.460.0 - ISC
18
18
  *
19
19
  * This source code is licensed under the ISC license.
20
20
  * See the LICENSE file in the root directory of this source tree.
21
- */const At=(t,s)=>(l,{slots:o})=>e.h(fc,{...l,iconNode:s,name:t},o);/**
21
+ */const Gt=(t,s)=>(l,{slots:o})=>e.h(yc,{...l,iconNode:s,name:t},o);/**
22
22
  * @license lucide-vue-next v0.460.0 - ISC
23
23
  *
24
24
  * This source code is licensed under the ISC license.
25
25
  * See the LICENSE file in the root directory of this source tree.
26
- */const pc=At("CheckIcon",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
26
+ */const bc=Gt("CheckIcon",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
27
27
  * @license lucide-vue-next v0.460.0 - ISC
28
28
  *
29
29
  * This source code is licensed under the ISC license.
30
30
  * See the LICENSE file in the root directory of this source tree.
31
- */const uc=At("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"},hc={class:"mfs-code-editor__title"},gc={key:0,class:"mfs-code-editor__filename mfs-font-mono"},yc={class:"mfs-code-editor__lang-pill mfs-font-mono"},bc=["aria-label","title"],Bc={key:0,class:"mfs-code-editor__gutter mfs-font-mono","aria-hidden":"true"},_c={class:"mfs-code-editor__stage"},wc=["aria-hidden"],Ec={class:"mfs-code-editor__code"},$c=["value","disabled","placeholder","maxlength","aria-invalid","onKeydown"],Vc={class:"mfs-code-editor__footer mfs-font-mono"},Cc={class:"mfs-code-editor__status-group"},xc={class:"mfs-code-editor__status-group"},Nc={class:"mfs-code-editor__mode-badge"},jt=L(e.defineComponent({__name:"CodeEditor",props:{modelValue:{default:""},language:{default:"vue"},filename:{},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","change","focus","blur","copy"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),c=e.ref(!1);let d=null;const n=e.computed(()=>l.modelValue??""),k=e.computed(()=>n.value.split(`
32
- `)),h=e.computed(()=>Math.max(1,k.value.length)),y=e.computed(()=>n.value.length),f=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"]),p=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"]),m=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"]),u=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"]),b=new Set(["true","false","null"]);function g(z,j,W){if(!W)return;const T=z[z.length-1];T&&T.type===j?T.text+=W:z.push({type:j,text:W})}function B(z){return/[A-Za-z_$]/.test(z)}function w(z){return/[A-Za-z0-9_$-]/.test(z)}function _(z){return z>="0"&&z<="9"}function $(z,j,W){if(!z)return[];if(j==="text")return[{type:"plain",text:z}];const T=[],K=z.length;let P=0,I=!1;for(;P<K;){if(W.inHtmlComment){const D=z.indexOf("-->",P);D===-1?(g(T,"comment",z.slice(P)),P=K):(g(T,"comment",z.slice(P,D+3)),P=D+3,W.inHtmlComment=!1);continue}if(W.inBlockComment){const D=z.indexOf("*/",P);D===-1?(g(T,"comment",z.slice(P)),P=K):(g(T,"comment",z.slice(P,D+2)),P=D+2,W.inBlockComment=!1);continue}const M=z[P],R=z[P+1]??"";if(M===" "||M===" "||M==="\r"){let D=P+1;for(;D<K&&(z[D]===" "||z[D]===" "||z[D]==="\r");)D++;g(T,"plain",z.slice(P,D)),P=D;continue}if((j==="vue"||j==="html")&&z.startsWith("<!--",P)){const D=z.indexOf("-->",P+4);D===-1?(g(T,"comment",z.slice(P)),W.inHtmlComment=!0,P=K):(g(T,"comment",z.slice(P,D+3)),P=D+3);continue}if((j==="js"||j==="ts"||j==="vue"||j==="css"||j==="sql")&&M==="/"&&R==="*"){const D=z.indexOf("*/",P+2);D===-1?(g(T,"comment",z.slice(P)),W.inBlockComment=!0,P=K):(g(T,"comment",z.slice(P,D+2)),P=D+2);continue}if((j==="js"||j==="ts"||j==="vue"||j==="css")&&M==="/"&&R==="/"){g(T,"comment",z.slice(P)),P=K;continue}if(j==="bash"&&M==="#"){g(T,"comment",z.slice(P)),P=K;continue}if(j==="sql"&&M==="-"&&R==="-"){g(T,"comment",z.slice(P)),P=K;continue}if(M==='"'||M==="'"||M==="`"&&j!=="sql"){const D=M;let O=P+1;for(;O<K;){if(z[O]==="\\"&&O+1<K){O+=2;continue}if(z[O]===D){O++;break}O++}g(T,"string",z.slice(P,O)),P=O;continue}if((j==="vue"||j==="html")&&M==="<"){const D=R==="/";let O=P+(D?2:1);if(O<K&&/[A-Za-z]/.test(z[O])){for(;O<K&&/[A-Za-z0-9_:-]/.test(z[O]);)O++;g(T,"operator",z.slice(P,P+(D?2:1))),g(T,"tag",z.slice(P+(D?2:1),O)),I=!D,P=O;continue}}if((j==="vue"||j==="html")&&I){if(M==="/"&&R===">"){g(T,"operator","/>"),I=!1,P+=2;continue}if(M===">"){g(T,"operator",">"),I=!1,P++;continue}if(/[A-Za-z:@#]/.test(M)){let D=P+1;for(;D<K&&/[A-Za-z0-9_.:-]/.test(z[D]);)D++;g(T,"attr",z.slice(P,D)),P=D;continue}}if(j==="css"&&M==="#"&&/[0-9A-Fa-f]/.test(R)){let D=P+1;for(;D<K&&/[0-9A-Fa-f]/.test(z[D]);)D++;g(T,"number",z.slice(P,D)),P=D;continue}if(_(M)||M==="."&&_(R)){let D=P+1;for(;D<K&&/[0-9._xXa-fA-F]/.test(z[D]);)D++;g(T,"number",z.slice(P,D)),P=D;continue}if(B(M)){let D=P+1;for(;D<K&&w(z[D]);)D++;const O=z.slice(P,D);let Y=!1;j==="js"||j==="ts"||j==="vue"?Y=f.has(O):j==="sql"?Y=p.has(O.toUpperCase()):j==="bash"?Y=m.has(O):j==="css"?Y=u.has(O):j==="json"&&(Y=b.has(O)),j==="json"&&z[D]===void 0?g(T,Y?"keyword":"plain",O):j==="css"&&z.slice(D).trimStart().startsWith(":")?g(T,"attr",O):g(T,Y?"keyword":"plain",O),P=D;continue}if(/[+\-*/%=<>!&|^~?:]/.test(M)){let D=P+1;for(;D<K&&/[+\-*/%=<>!&|^~?:]/.test(z[D]);)D++;g(T,"operator",z.slice(P,D)),P=D;continue}g(T,"plain",M),P++}return T}const V=e.computed(()=>{const z={inBlockComment:!1,inHtmlComment:!1};return k.value.map(j=>$(j,l.language,z))}),E=()=>{var z;!l.readonly&&!l.disabled&&((z=r.value)==null||z.focus())},C=z=>{const W=z.target.value;o("update:modelValue",W),o("change",W)},S=async z=>{if(l.readonly||l.disabled)return;const j=z.target,W=j.selectionStart??0,T=j.selectionEnd??0,K=" ".repeat(Math.max(1,l.tabSize)),P=n.value,I=P.slice(0,W)+K+P.slice(T);l.maxLength!==void 0&&I.length>l.maxLength||(o("update:modelValue",I),o("change",I),await e.nextTick(),r.value&&(r.value.selectionStart=W+K.length,r.value.selectionEnd=W+K.length))},N=z=>{i.value=!0,o("focus",z)},F=z=>{i.value=!1,o("blur",z)},H=async()=>{var W;const z=n.value;let j=!1;if(typeof navigator<"u"&&((W=navigator.clipboard)!=null&&W.writeText))try{await navigator.clipboard.writeText(z),j=!0}catch{j=!1}if(!j&&typeof document<"u"){const T=document.createElement("textarea");T.value=z,T.setAttribute("readonly",""),T.style.position="fixed",T.style.opacity="0",document.body.appendChild(T),T.select();try{j=document.execCommand("copy")}catch{j=!1}document.body.removeChild(T)}j&&(c.value=!0,o("copy",z),d&&clearTimeout(d),d=setTimeout(()=>{c.value=!1},1800))};return(z,j)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-code-editor mfs-rounded mfs-shadow-card",{"mfs-code-editor--readonly":t.readonly,"mfs-code-editor--disabled mfs-disabled":t.disabled,"mfs-code-editor--invalid":t.invalid,"mfs-code-editor--focused":i.value}])},[e.createElementVNode("div",kc,[j[0]||(j[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)),e.createElementVNode("div",hc,[t.filename?(e.openBlock(),e.createElementBlock("span",gc,e.toDisplayString(t.filename),1)):e.createCommentVNode("",!0),e.createElementVNode("span",yc,e.toDisplayString(t.language.toUpperCase()),1)]),t.copyable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"mfs-code-editor__copy-btn","aria-label":c.value?"Copied":"Copy code",title:c.value?"Copied!":"Copy code",onClick:H},[c.value?(e.openBlock(),e.createBlock(e.unref(pc),{key:0,size:14})):(e.openBlock(),e.createBlock(e.unref(uc),{key:1,size:14})),e.createElementVNode("span",null,e.toDisplayString(c.value?"Copied":"Copy"),1)],8,bc)):e.createCommentVNode("",!0)]),e.createElementVNode("div",{ref_key:"bodyRef",ref:a,class:"mfs-code-editor__body",style:e.normalizeStyle({minHeight:t.minHeight,maxHeight:t.maxHeight}),onClick:E},[t.lineNumbers?(e.openBlock(),e.createElementBlock("div",Bc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,W=>(e.openBlock(),e.createElementBlock("div",{key:W,class:"mfs-code-editor__line-no"},e.toDisplayString(W),1))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",_c,[e.createElementVNode("pre",{class:"mfs-code-editor__highlight mfs-font-mono","aria-hidden":!t.readonly,style:e.normalizeStyle({tabSize:String(t.tabSize)})},[e.createElementVNode("code",Ec,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V.value,(W,T)=>(e.openBlock(),e.createElementBlock("span",{key:T,class:"mfs-code-editor__line"},[W.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(W,(K,P)=>(e.openBlock(),e.createElementBlock("span",{key:P,class:e.normalizeClass(`mfs-tok--${K.type}`)},e.toDisplayString(K.text),3))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString("​"))],64)),j[1]||(j[1]=e.createTextVNode(e.toDisplayString(`
33
- `),-1))]))),128))])],12,wc),t.readonly?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("textarea",{key:0,ref_key:"textareaRef",ref:r,class:"mfs-code-editor__textarea mfs-font-mono",value:n.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:C,onKeydown:e.withKeys(e.withModifiers(S,["prevent"]),["tab"]),onFocus:N,onBlur:F},null,44,$c))])],4),e.createElementVNode("div",Vc,[e.createElementVNode("div",Cc,[e.createElementVNode("span",null,"Lines: "+e.toDisplayString(h.value),1),e.createElementVNode("span",null,[e.createTextVNode(" Chars: "+e.toDisplayString(y.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",xc,[e.createElementVNode("span",null,e.toDisplayString(t.language.toUpperCase()),1),e.createElementVNode("span",Nc,e.toDisplayString(t.readonly?"Readonly":"Editable"),1)])])],2))}}),[["__scopeId","data-v-1dbdfc6c"]]),Sc={class:"split-btn"},Mc=["disabled"],Dc=["disabled","aria-expanded"],zc=["disabled","onClick"],Lc={key:0,class:"split-btn__icon"},Kt=L(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:s}){const l=s,o=e.ref(!1),a=e.ref(null),r=e.ref(null),{overlayStyle:i,containsTarget:c}=J(a,r,o,{offset:8,align:"right"}),d=h=>{h.disabled||(o.value=!1,l("select",h))},n=h=>{o.value&&!c(h.target)&&(o.value=!1)},k=h=>{h.key==="Escape"&&o.value&&(o.value=!1)};return e.onMounted(()=>{document.addEventListener("click",n),document.addEventListener("keydown",k)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",n),document.removeEventListener("keydown",k)}),(h,y)=>(e.openBlock(),e.createElementBlock("div",Sc,[e.createElementVNode("div",{ref_key:"triggerRef",ref:a,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:y[0]||(y[0]=f=>l("click",f))},[e.renderSlot(h.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)],10,Mc),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":o.value,"aria-label":"More actions",onClick:y[1]||(y[1]=f=>o.value=!o.value)},[...y[2]||(y[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,Dc)],2),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"split-fade"},{default:e.withCtx(()=>[o.value&&t.items.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(i)),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,(f,p)=>(e.openBlock(),e.createElementBlock("li",{key:p,role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:"split-btn__item mfs-text",disabled:f.disabled,onClick:m=>d(f)},[f.icon?(e.openBlock(),e.createElementBlock("span",Lc,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(f.label),1)],8,zc)]))),128))],4)):e.createCommentVNode("",!0)]),_:1})]))]))}}),[["__scopeId","data-v-54cf96eb"]]),Tc=["aria-expanded"],Ic={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"},Pc=["title","aria-label","disabled","onClick"],Ot=L(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:s}){const l=t,o=s,a=e.ref(!1);e.watch(()=>l.modelValue,n=>{n!==void 0&&(a.value=n)});const r=e.computed(()=>l.modelValue!==void 0?l.modelValue:a.value),i=()=>{const n=!r.value;a.value=n,o("update:modelValue",n)},c=n=>{var k;n.disabled||((k=n.action)==null||k.call(n),o("select",n),a.value=!1,o("update:modelValue",!1))},d=n=>{if(l.type!=="radial"||!l.items.length)return;const k=l.items.length,h=l.direction==="up"?-90:l.direction==="down"?90:l.direction==="left"?180:0,y=120,f=k>1?y/(k-1):0,m=(h-y/2+n*f)*Math.PI/180,u=Math.round(Math.cos(m)*l.radius),b=Math.round(Math.sin(m)*l.radius);return{position:"absolute",transform:`translate(${u}px, ${b}px)`}};return(n,k)=>(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:i},[(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"},[...k[0]||(k[0]=[e.createElementVNode("path",{d:"M12 5v14M5 12h14",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round"},null,-1)])],2))],8,Tc),r.value?(e.openBlock(),e.createElementBlock("ul",Ic,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,y)=>(e.openBlock(),e.createElementBlock("li",{key:y,class:"speed-dial__entry",style:e.normalizeStyle(d(y)),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":h.disabled}]),title:h.label,"aria-label":h.label,disabled:h.disabled,onClick:f=>c(h)},[e.renderSlot(n.$slots,"item",{item:h,index:y},()=>[e.createElementVNode("span",null,e.toDisplayString(h.icon||h.label.slice(0,2)),1)],!0)],10,Pc)],4))),128))])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-63f8f8f0"]]),Rc={key:0,class:"panel__header"},Fc={class:"panel__title mfs-title"},Ac={class:"panel__actions"},jc=["aria-expanded"],Kc={class:"panel__collapse"},Oc={class:"panel__inner"},Uc={class:"panel__body"},Hc={key:0,class:"panel__footer mfs-surface-subtle mfs-caption"},Ut=L(e.defineComponent({__name:"Panel",props:{header:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1);e.watch(()=>l.collapsed,c=>{c!==void 0&&(a.value=c)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:a.value),i=()=>{const c=!r.value;a.value=c,o("update:collapsed",c),o("toggle",c)};return(c,d)=>(e.openBlock(),e.createElementBlock("section",{class:e.normalizeClass(["panel","mfs-surface","mfs-rounded","mfs-shadow-card",{"is-collapsed":r.value}])},[t.header||c.$slots.header||t.toggleable?(e.openBlock(),e.createElementBlock("header",Rc,[e.createElementVNode("div",Fc,[e.renderSlot(c.$slots,"header",{},()=>[e.createTextVNode(e.toDisplayString(t.header),1)],!0)]),e.createElementVNode("div",Ac,[e.renderSlot(c.$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:i},[(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"},[...d[0]||(d[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,jc)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",Kc,[e.createElementVNode("div",Oc,[e.createElementVNode("div",Uc,[e.renderSlot(c.$slots,"default",{},void 0,!0)]),c.$slots.footer?(e.openBlock(),e.createElementBlock("footer",Hc,[e.renderSlot(c.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)])])],2))}}),[["__scopeId","data-v-0ea71fae"]]),Wc={key:0,class:"fieldset__legend mfs-surface-subtle mfs-pill mfs-shadow mfs-title mfs-text-sm mfs-font-bold"},Gc=["aria-expanded"],qc={key:1,class:"mfs-text"},Yc={class:"fieldset__collapse"},Xc={class:"mfs-overflow-hidden"},Zc={class:"mfs-pt-2"},Ht=L(e.defineComponent({__name:"Fieldset",props:{legend:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1);e.watch(()=>l.collapsed,c=>{c!==void 0&&(a.value=c)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:a.value),i=()=>{const c=!r.value;a.value=c,o("update:collapsed",c),o("toggle",c)};return(c,d)=>(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||c.$slots.legend?(e.openBlock(),e.createElementBlock("legend",Wc,[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:i},[(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"},[...d[0]||(d[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(c.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)],8,Gc)):(e.openBlock(),e.createElementBlock("span",qc,[e.renderSlot(c.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)]))])):e.createCommentVNode("",!0),e.createElementVNode("div",Yc,[e.createElementVNode("div",Xc,[e.createElementVNode("div",Zc,[e.renderSlot(c.$slots,"default",{},void 0,!0)])])])],2))}}),[["__scopeId","data-v-86bfdaad"]]),Jc=["aria-orientation","aria-valuenow","aria-valuemin","aria-valuemax"],Qc={class:"splitter__pane splitter__pane--second"},Wt=L(e.defineComponent({__name:"Splitter",props:{layout:{default:"horizontal"},initialSize:{default:50},minSize:{default:15}},emits:["resize"],setup(t,{emit:s}){const l=t,o=s,a=p=>Math.max(l.minSize,Math.min(100-l.minSize,p)),r=e.ref(a(l.initialSize)),i=e.ref(!1),c=e.ref(null),d=e.computed(()=>({flexBasis:`${r.value}%`})),n=p=>{if(!c.value)return;const m=c.value.getBoundingClientRect(),u=l.layout==="horizontal"?(p.clientX-m.left)/m.width*100:(p.clientY-m.top)/m.height*100;r.value=a(u),o("resize",r.value)},k=p=>{i.value=!0,p.currentTarget.setPointerCapture(p.pointerId),n(p)},h=p=>{i.value&&n(p)},y=p=>{i.value&&(i.value=!1,p.currentTarget.hasPointerCapture(p.pointerId)&&p.currentTarget.releasePointerCapture(p.pointerId))},f=p=>{const u=l.layout==="horizontal"?"ArrowLeft":"ArrowUp",b=l.layout==="horizontal"?"ArrowRight":"ArrowDown";p.key===u?(p.preventDefault(),r.value=a(r.value-5),o("resize",r.value)):p.key===b&&(p.preventDefault(),r.value=a(r.value+5),o("resize",r.value))};return(p,m)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:c,class:e.normalizeClass(["splitter",`splitter--${t.layout}`,"mfs-surface","mfs-rounded","mfs-shadow-card"])},[e.createElementVNode("div",{class:"splitter__pane",style:e.normalizeStyle(d.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:k,onPointermove:h,onPointerup:y,onPointercancel:y,onKeydown:f},[...m[0]||(m[0]=[e.createElementVNode("span",{class:"splitter__handle mfs-pill"},null,-1)])],40,Jc),e.createElementVNode("div",Qc,[e.renderSlot(p.$slots,"second",{},void 0,!0)])],2))}}),[["__scopeId","data-v-6fd2ec7c"]]),vc={class:"toolbar mfs-surface mfs-rounded mfs-shadow-card",role:"toolbar"},em={key:0,class:"toolbar__group toolbar__group--start"},tm={key:1,class:"toolbar__group toolbar__group--center"},lm={key:2,class:"toolbar__group toolbar__group--end"},Gt=L(e.defineComponent({__name:"Toolbar",setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",vc,[s.$slots.start||s.$slots.default?(e.openBlock(),e.createElementBlock("div",em,[e.renderSlot(s.$slots,"start",{},()=>[e.renderSlot(s.$slots,"default",{},void 0,!0)],!0)])):e.createCommentVNode("",!0),s.$slots.center?(e.openBlock(),e.createElementBlock("div",tm,[e.renderSlot(s.$slots,"center",{},void 0,!0)])):e.createCommentVNode("",!0),s.$slots.end?(e.openBlock(),e.createElementBlock("div",lm,[e.renderSlot(s.$slots,"end",{},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cf5eff51"]]),om={class:"scroll-panel__content"},qt=L(e.defineComponent({__name:"ScrollPanel",props:{maxHeight:{default:"300px"},width:{}},setup(t){const s=t,l=a=>a===void 0?void 0:typeof a=="number"?`${a}px`:a,o=e.computed(()=>({maxHeight:l(s.maxHeight),width:l(s.width)}));return(a,r)=>(e.openBlock(),e.createElementBlock("div",{class:"scroll-panel mfs-surface mfs-rounded mfs-shadow-card mfs-focus-ring",style:e.normalizeStyle(o.value),tabindex:"0"},[e.createElementVNode("div",om,[e.renderSlot(a.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-78b33875"]]),Yt=L(e.defineComponent({__name:"Fluid",props:{tag:{default:"div"},padded:{type:Boolean,default:!1}},setup(t){return(s,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(s.$slots,"default",{},void 0,!0)]),_:3},8,["class"]))}}),[["__scopeId","data-v-94565fea"]]),Ne=e.defineComponent({__name:"Deferred",props:{rootMargin:{default:"0px"},threshold:{default:0},once:{type:Boolean,default:!0}},emits:["load"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1),r=e.ref(null);let i=null;return e.onMounted(()=>{if(typeof IntersectionObserver>"u"||!r.value){a.value=!0,o("load");return}i=new IntersectionObserver(c=>{const d=c[0];d!=null&&d.isIntersecting&&(a.value=!0,o("load"),l.once&&(i==null||i.disconnect(),i=null))},{rootMargin:l.rootMargin,threshold:l.threshold}),i.observe(r.value)}),e.onBeforeUnmount(()=>{i==null||i.disconnect(),i=null}),(c,d)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"targetRef",ref:r,class:"mfs-w-full"},[a.value?e.renderSlot(c.$slots,"default",{},void 0,void 0,0):e.renderSlot(c.$slots,"placeholder",{},()=>[d[0]||(d[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))}}),nm={class:"menu__list"},am={key:0,class:"menu__separator mfs-divider",role:"separator"},sm={key:1,class:"menu__group",role:"presentation"},rm={key:0,class:"menu__group-label mfs-text-muted"},im={class:"menu__sublist"},dm=["disabled","onClick"],cm={key:0,class:"menu__icon","aria-hidden":"true"},mm={class:"menu__label"},fm={key:0,class:"menu__icon","aria-hidden":"true"},pm={class:"menu__label"},um={key:2,role:"none"},km=["disabled","onClick"],hm={key:0,class:"menu__icon","aria-hidden":"true"},gm={class:"menu__label"},ym={key:0,class:"menu__icon","aria-hidden":"true"},bm={class:"menu__label"},Bm={class:"menu__list"},_m={key:0,class:"menu__separator mfs-divider",role:"separator"},wm={key:1,class:"menu__group",role:"presentation"},Em={key:0,class:"menu__group-label mfs-text-muted"},$m={class:"menu__sublist"},Vm=["disabled","onClick"],Cm={key:0,class:"menu__icon","aria-hidden":"true"},xm={class:"menu__label"},Nm={key:0,class:"menu__icon","aria-hidden":"true"},Sm={class:"menu__label"},Mm={key:2,role:"none"},Dm=["disabled","onClick"],zm={key:0,class:"menu__icon","aria-hidden":"true"},Lm={class:"menu__label"},Tm={key:0,class:"menu__icon","aria-hidden":"true"},Im={class:"menu__label"},Xt=L(e.defineComponent({__name:"Menu",props:{items:{},popup:{type:Boolean,default:!1}},emits:["select"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.ref(!1),i=e.ref(null),c=e.ref({x:0,y:0}),d=()=>{r.value=!1,m()},n=async u=>{if(!o.popup)return;r.value=!0;const b=u.currentTarget,g=b==null?void 0:b.getBoundingClientRect();if(c.value=g?{x:g.left,y:g.bottom+6}:{x:u.clientX,y:u.clientY},await e.nextTick(),i.value){const B=i.value.getBoundingClientRect(),w=8;c.value={x:Math.max(w,Math.min(c.value.x,window.innerWidth-B.width-w)),y:Math.max(w,Math.min(c.value.y,window.innerHeight-B.height-w))}}p()},k=u=>{r.value?d():n(u)},h=u=>{var b;u.disabled||((b=u.command)==null||b.call(u),a("select",u),o.popup&&d())},y=u=>{u.key==="Escape"&&o.popup&&d()},f=u=>{i.value&&!i.value.contains(u.target)&&d()},p=()=>{window.addEventListener("pointerdown",f),window.addEventListener("resize",d)},m=()=>{window.removeEventListener("pointerdown",f),window.removeEventListener("resize",d)};return e.onUnmounted(m),s({open:n,close:d,toggle:k}),(u,b)=>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:i,class:"menu menu--popup mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${c.value.x}px`,top:`${c.value.y}px`}),onKeydown:y},[e.createElementVNode("ul",nm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>{var w;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[g.separator?(e.openBlock(),e.createElementBlock("li",am)):(w=g.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("li",sm,[g.label?(e.openBlock(),e.createElementBlock("div",rm,e.toDisplayString(g.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",im,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.items,(_,$)=>(e.openBlock(),e.createElementBlock("li",{key:$,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:V=>h(_)},[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",cm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",mm,e.toDisplayString(_.label),1)],!0)],10,dm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:_.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:V=>h(_)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",fm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",pm,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",um,[!g.to&&!g.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":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",hm,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",gm,e.toDisplayString(g.label),1)],!0)],10,km)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g.to?"router-link":"a"),{key:1,to:g.to,href:g.href,role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",ym,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",bm,e.toDisplayString(g.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:y},[e.createElementVNode("ul",Bm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>{var w;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[g.separator?(e.openBlock(),e.createElementBlock("li",_m)):(w=g.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("li",wm,[g.label?(e.openBlock(),e.createElementBlock("div",Em,e.toDisplayString(g.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",$m,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.items,(_,$)=>(e.openBlock(),e.createElementBlock("li",{key:$,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:V=>h(_)},[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Cm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",xm,e.toDisplayString(_.label),1)],!0)],10,Vm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:_.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:V=>h(_)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Nm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Sm,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",Mm,[!g.to&&!g.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":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",zm,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Lm,e.toDisplayString(g.label),1)],!0)],10,Dm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g.to?"router-link":"a"),{key:1,to:g.to,href:g.href,role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",Tm,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Im,e.toDisplayString(g.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],32))}}),[["__scopeId","data-v-b6f0d9c8"]]),Pm={class:"tiered-menu mfs-surface mfs-rounded-md mfs-blur","aria-label":"Tiered menu"},Rm={class:"tiered-menu__list",role:"menubar"},Fm={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},Am=["onMouseenter"],jm=["aria-haspopup","aria-expanded","disabled","onClick"],Km={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Om={class:"tiered-menu__label"},Um={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"},Hm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Wm={class:"tiered-menu__label"},Gm={key:2,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu"},qm={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},Ym=["onMouseenter"],Xm=["aria-haspopup","aria-expanded","disabled","onClick"],Zm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Jm={class:"tiered-menu__label"},Qm={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"},vm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},ef={class:"tiered-menu__label"},tf={key:2,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu"},lf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},of={key:1,role:"none"},nf=["disabled","onClick"],af={key:0,class:"tiered-menu__icon","aria-hidden":"true"},sf={class:"tiered-menu__label"},rf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},df={class:"tiered-menu__label"},Zt=L(e.defineComponent({__name:"TieredMenu",props:{items:{}},emits:["select"],setup(t,{emit:s}){const l=s,o=e.ref(null),a=e.ref(null),r=(i,c,d)=>{var n,k;if(!i.disabled){if((n=i.items)!=null&&n.length){c===1?(o.value=o.value===d?null:d,a.value=null):c===2&&(a.value=a.value===d?null:d);return}(k=i.command)==null||k.call(i),l("select",i),o.value=null,a.value=null}};return(i,c)=>(e.openBlock(),e.createElementBlock("nav",Pm,[e.createElementVNode("ul",Rm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(d,n)=>{var k,h,y,f,p;return e.openBlock(),e.createElementBlock(e.Fragment,{key:n},[d.separator?(e.openBlock(),e.createElementBlock("li",Fm)):(e.openBlock(),e.createElementBlock("li",{key:1,class:"tiered-menu__node",role:"none",onMouseenter:m=>o.value=n,onMouseleave:c[1]||(c[1]=m=>{o.value=null,a.value=null})},[(k=d.items)!=null&&k.length||!d.to&&!d.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===n,"tiered-menu__item--disabled mfs-disabled":d.disabled}]),"aria-haspopup":(h=d.items)!=null&&h.length?"true":void 0,"aria-expanded":(y=d.items)!=null&&y.length?o.value===n:void 0,disabled:d.disabled,onClick:m=>r(d,1,n)},[d.icon?(e.openBlock(),e.createElementBlock("span",Km,e.toDisplayString(d.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Om,e.toDisplayString(d.label),1),(f=d.items)!=null&&f.length?(e.openBlock(),e.createElementBlock("svg",Um,[...c[2]||(c[2]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,jm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d.to?"router-link":"a"),{key:1,to:d.to,href:d.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":o.value===n,"tiered-menu__item--disabled mfs-disabled":d.disabled}]),disabled:d.disabled,onClick:m=>r(d,1,n)},{default:e.withCtx(()=>[d.icon?(e.openBlock(),e.createElementBlock("span",Hm,e.toDisplayString(d.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Wm,e.toDisplayString(d.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),(p=d.items)!=null&&p.length&&o.value===n?(e.openBlock(),e.createElementBlock("ul",Gm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.items,(m,u)=>{var b,g,B,w,_;return e.openBlock(),e.createElementBlock(e.Fragment,{key:u},[m.separator?(e.openBlock(),e.createElementBlock("li",qm)):(e.openBlock(),e.createElementBlock("li",{key:1,class:"tiered-menu__node",role:"none",onMouseenter:$=>a.value=u,onMouseleave:c[0]||(c[0]=$=>a.value=null)},[(b=m.items)!=null&&b.length||!m.to&&!m.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":a.value===u,"tiered-menu__item--disabled mfs-disabled":m.disabled}]),"aria-haspopup":(g=m.items)!=null&&g.length?"true":void 0,"aria-expanded":(B=m.items)!=null&&B.length?a.value===u:void 0,disabled:m.disabled,onClick:$=>r(m,2,u)},[m.icon?(e.openBlock(),e.createElementBlock("span",Zm,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Jm,e.toDisplayString(m.label),1),(w=m.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("svg",Qm,[...c[3]||(c[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Xm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.to?"router-link":"a"),{key:1,to:m.to,href:m.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":a.value===u,"tiered-menu__item--disabled mfs-disabled":m.disabled}]),disabled:m.disabled,onClick:$=>r(m,2,u)},{default:e.withCtx(()=>[m.icon?(e.openBlock(),e.createElementBlock("span",vm,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",ef,e.toDisplayString(m.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),(_=m.items)!=null&&_.length&&a.value===u?(e.openBlock(),e.createElementBlock("ul",tf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.items,($,V)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:V},[$.separator?(e.openBlock(),e.createElementBlock("li",lf)):(e.openBlock(),e.createElementBlock("li",of,[!$.to&&!$.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":$.disabled}]),disabled:$.disabled,onClick:E=>r($,3,V)},[$.icon?(e.openBlock(),e.createElementBlock("span",af,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",sf,e.toDisplayString($.label),1)],10,nf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent($.to?"router-link":"a"),{key:1,to:$.to,href:$.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--disabled mfs-disabled":$.disabled}]),disabled:$.disabled,onClick:E=>r($,3,V)},{default:e.withCtx(()=>[$.icon?(e.openBlock(),e.createElementBlock("span",rf,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",df,e.toDisplayString($.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64))),128))])):e.createCommentVNode("",!0)],40,Ym))],64)}),128))])):e.createCommentVNode("",!0)],40,Am))],64)}),128))])]))}}),[["__scopeId","data-v-b9d2bab9"]]),cf={key:0,class:"slide-menu__header"},mf={class:"slide-menu__title mfs-title"},ff={class:"slide-menu__viewport"},pf=["disabled","onClick"],uf={key:0,class:"slide-menu__icon","aria-hidden":"true"},kf={class:"slide-menu__label"},hf={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"},gf={key:0,class:"slide-menu__icon","aria-hidden":"true"},yf={class:"slide-menu__label"},Jt=L(e.defineComponent({__name:"SlideMenu",props:{items:{},backLabel:{default:"Back"},menuWidth:{default:"260px"}},emits:["select"],setup(t,{emit:s}){const l=t,o=s,a=e.ref([]),r=e.ref("forward"),i=e.computed(()=>a.value.length?a.value[a.value.length-1].items:l.items),c=e.computed(()=>a.value.length?a.value[a.value.length-1].title:""),d=k=>{var h,y;if(!k.disabled){if((h=k.items)!=null&&h.length){r.value="forward",a.value.push({title:k.label,items:k.items});return}(y=k.command)==null||y.call(k),o("select",k)}},n=()=>{a.value.length&&(r.value="back",a.value.pop())};return(k,h)=>(e.openBlock(),e.createElementBlock("div",{class:"slide-menu mfs-surface mfs-overlay mfs-rounded-md mfs-blur",style:e.normalizeStyle({width:t.menuWidth})},[a.value.length>0?(e.openBlock(),e.createElementBlock("div",cf,[e.createElementVNode("button",{type:"button",class:"slide-menu__back mfs-surface-subtle mfs-rounded-sm mfs-interactive mfs-text",onClick:n},[h[0]||(h[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",mf,e.toDisplayString(c.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",ff,[e.createVNode(e.Transition,{name:r.value==="forward"?"slide-fwd":"slide-bck",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("ul",{key:a.value.length,class:"slide-menu__list",role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(y,f)=>{var p,m;return e.openBlock(),e.createElementBlock("li",{key:f,role:"none"},[(p=y.items)!=null&&p.length||!y.to&&!y.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":y.disabled}]),disabled:y.disabled,onClick:u=>d(y)},[y.icon?(e.openBlock(),e.createElementBlock("span",uf,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",kf,e.toDisplayString(y.label),1),(m=y.items)!=null&&m.length?(e.openBlock(),e.createElementBlock("svg",hf,[...h[1]||(h[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,pf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(y.to?"router-link":"a"),{key:1,to:y.to,href:y.href,role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:u=>d(y)},{default:e.withCtx(()=>[y.icon?(e.openBlock(),e.createElementBlock("span",gf,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",yf,e.toDisplayString(y.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))])}),128))]))]),_:1},8,["name"])])],4))}}),[["__scopeId","data-v-0c085066"]]),bf={class:"panel-menu","aria-label":"Panel navigation"},Bf=["aria-expanded","disabled","onClick"],_f={key:0,class:"panel-menu__icon","aria-hidden":"true"},wf={class:"panel-menu__label"},Ef={key:0,class:"panel-menu__icon","aria-hidden":"true"},$f={class:"panel-menu__label"},Vf={key:0,class:"panel-menu__list"},Cf=["disabled","onClick"],xf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Nf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Qt=L(e.defineComponent({__name:"PanelMenu",props:{items:{},multiple:{type:Boolean,default:!0},expandedKeys:{}},emits:["update:expandedKeys","select"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(l.expandedKeys??[]);e.watch(()=>l.expandedKeys,n=>{n!==void 0&&(a.value=[...n])});const r=(n,k)=>n.key??`${k}-${n.label}`,i=n=>a.value.includes(n),c=(n,k)=>{var h,y;if(!n.disabled){if((h=n.items)!=null&&h.length){const f=r(n,k);let p;i(f)?p=a.value.filter(m=>m!==f):p=l.multiple?[...a.value,f]:[f],a.value=p,o("update:expandedKeys",p);return}(y=n.command)==null||y.call(n),o("select",n)}},d=n=>{var k;n.disabled||((k=n.command)==null||k.call(n),o("select",n))};return(n,k)=>(e.openBlock(),e.createElementBlock("nav",bf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,y)=>{var f,p,m;return e.openBlock(),e.createElementBlock("div",{key:r(h,y),class:"panel-menu__panel mfs-surface mfs-rounded-md mfs-blur"},[(f=h.items)!=null&&f.length||!h.to&&!h.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":h.disabled}]),"aria-expanded":(p=h.items)!=null&&p.length?i(r(h,y)):void 0,disabled:h.disabled,onClick:u=>c(h,y)},[h.icon?(e.openBlock(),e.createElementBlock("span",_f,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",wf,e.toDisplayString(h.label),1),(m=h.items)!=null&&m.length?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(["panel-menu__chevron",{"panel-menu__chevron--open":i(r(h,y))}]),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"},[...k[0]||(k[0]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2)):e.createCommentVNode("",!0)],10,Bf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.to?"router-link":"a"),{key:1,to:h.to,href:h.href,class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:u=>c(h,y)},{default:e.withCtx(()=>[h.icon?(e.openBlock(),e.createElementBlock("span",Ef,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",$f,e.toDisplayString(h.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"panel-collapse"},{default:e.withCtx(()=>{var u;return[(u=h.items)!=null&&u.length&&i(r(h,y))?(e.openBlock(),e.createElementBlock("ul",Vf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(b,g)=>(e.openBlock(),e.createElementBlock("li",{key:g},[!b.to&&!b.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":b.disabled}]),disabled:b.disabled,onClick:B=>d(b)},[b.icon?(e.openBlock(),e.createElementBlock("span",xf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(b.label),1)],10,Cf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.to?"router-link":"a"),{key:1,to:b.to,href:b.href,class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:B=>d(b)},{default:e.withCtx(()=>[b.icon?(e.openBlock(),e.createElementBlock("span",Nf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(b.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])):e.createCommentVNode("",!0)]}),_:2},1024)])}),128))]))}}),[["__scopeId","data-v-80eb0ae4"]]),Sf={class:"mega-menu__bar mfs-flex mfs-flex-col mfs-gap-2"},Mf=["aria-expanded"],Df={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"},zf={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"},Lf=["onMouseenter"],Tf=["aria-haspopup","aria-expanded","disabled","onClick"],If={key:0,"aria-hidden":"true"},Pf={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"},Rf={key:0,"aria-hidden":"true"},Ff={key:0,class:"mega-menu__panel mfs-card mfs-overlay mfs-blur mfs-p-4",role:"menu"},Af={class:"mega-menu__columns"},jf={key:0,class:"mega-menu__col-title mfs-text-muted mfs-font-bold mfs-mb-2 mfs-px-2"},Kf={class:"mega-menu__col-list mfs-flex mfs-flex-col mfs-gap-1"},Of=["onClick"],Uf={class:"mega-menu__link-label mfs-font-semibold"},Hf={key:0,class:"mega-menu__link-desc mfs-text-muted"},Wf={class:"mega-menu__link-label mfs-font-semibold"},Gf={key:0,class:"mega-menu__link-desc mfs-text-muted"},vt=L(e.defineComponent({__name:"MegaMenu",props:{items:{},orientation:{default:"horizontal"}},emits:["select"],setup(t,{emit:s}){const l=s,o=e.ref(null),a=e.ref(null),r=e.ref(!1),i=()=>typeof window<"u"&&window.innerWidth<768,c=f=>{i()||(a.value=f)},d=()=>{i()||(a.value=null)},n=(f,p)=>{var m,u;if(!f.disabled){if((m=f.columns)!=null&&m.length){a.value=a.value===p?null:p;return}(u=f.command)==null||u.call(f),l("select",f),a.value=null,r.value=!1}},k=f=>{var p;(p=f.command)==null||p.call(f),l("select",f),a.value=null,r.value=!1},h=f=>{o.value&&!o.value.contains(f.target)&&(a.value=null)},y=f=>{f.key==="Escape"&&(a.value=null,r.value=!1)};return e.onMounted(()=>{window.addEventListener("pointerdown",h),window.addEventListener("keydown",y)}),e.onUnmounted(()=>{window.removeEventListener("pointerdown",h),window.removeEventListener("keydown",y)}),(f,p)=>(e.openBlock(),e.createElementBlock("nav",{ref_key:"rootRef",ref:o,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",Sf,[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":r.value,"aria-label":"Toggle mega menu",onClick:p[0]||(p[0]=m=>r.value=!r.value)},[r.value?(e.openBlock(),e.createElementBlock("svg",zf,[...p[2]||(p[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",Df,[...p[1]||(p[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)])])),p[3]||(p[3]=e.createElementVNode("span",null,"Menu",-1))],8,Mf),e.createElementVNode("ul",{class:e.normalizeClass(["mega-menu__list mfs-flex-col mfs-gap-1-5",{"mega-menu__list--open":r.value}]),role:"menubar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(m,u)=>{var b,g,B,w;return e.openBlock(),e.createElementBlock("li",{key:u,class:"mega-menu__root mfs-relative",role:"none",onMouseenter:_=>c(u),onMouseleave:d},[(b=m.columns)!=null&&b.length||!m.to&&!m.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":a.value===u,"mega-menu__trigger--disabled mfs-disabled":m.disabled}]),"aria-haspopup":(g=m.columns)!=null&&g.length?"true":void 0,"aria-expanded":(B=m.columns)!=null&&B.length?a.value===u:void 0,disabled:m.disabled,onClick:_=>n(m,u)},[m.icon?(e.openBlock(),e.createElementBlock("span",If,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(m.label),1),(w=m.columns)!=null&&w.length?(e.openBlock(),e.createElementBlock("svg",Pf,[...p[4]||(p[4]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])])):e.createCommentVNode("",!0)],10,Tf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.to?"router-link":"a"),{key:1,to:m.to,href:m.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":a.value===u,"mega-menu__trigger--disabled mfs-disabled":m.disabled}]),disabled:m.disabled,onClick:_=>n(m,u)},{default:e.withCtx(()=>[m.icon?(e.openBlock(),e.createElementBlock("span",Rf,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(m.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"mega-fade"},{default:e.withCtx(()=>{var _;return[(_=m.columns)!=null&&_.length&&a.value===u?(e.openBlock(),e.createElementBlock("div",Ff,[e.createElementVNode("div",Af,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.columns,($,V)=>(e.openBlock(),e.createElementBlock("div",{key:V,class:"mega-menu__col"},[$.title?(e.openBlock(),e.createElementBlock("div",jf,e.toDisplayString($.title),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Kf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.items,(E,C)=>(e.openBlock(),e.createElementBlock("li",{key:C,role:"none"},[!E.to&&!E.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:S=>k(E)},[e.createElementVNode("span",Uf,e.toDisplayString(E.label),1),E.description?(e.openBlock(),e.createElementBlock("span",Hf,e.toDisplayString(E.description),1)):e.createCommentVNode("",!0)],8,Of)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(E.to?"router-link":"a"),{key:1,to:E.to,href:E.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:S=>k(E)},{default:e.withCtx(()=>[e.createElementVNode("span",Wf,e.toDisplayString(E.label),1),E.description?(e.openBlock(),e.createElementBlock("span",Gf,e.toDisplayString(E.description),1)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","onClick"]))]))),128))])]))),128))])])):e.createCommentVNode("",!0)]}),_:2},1024)],40,Lf)}),128))],2)])],2))}}),[["__scopeId","data-v-c1804bd7"]]),qf={class:"dock__list mfs-surface mfs-shadow-card mfs-pill mfs-blur",role:"menubar"},Yf=["onMouseenter"],Xf=["aria-label","disabled","onClick"],Zf={class:"dock__glyph mfs-text"},Jf={key:0,class:"dock__dot","aria-hidden":"true"},Qf={class:"dock__glyph mfs-text"},vf={key:0,class:"dock__dot","aria-hidden":"true"},ep={class:"dock__tooltip mfs-surface mfs-shadow mfs-rounded-sm mfs-text",role:"tooltip"},el=L(e.defineComponent({__name:"Dock",props:{items:{},position:{default:"bottom"},magnification:{type:Boolean,default:!0}},emits:["select"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=c=>{if(!l.magnification||a.value===null)return{};const d=Math.abs(a.value-c);return d===0?{transform:"scale(1.32)"}:d===1?{transform:"scale(1.14)"}:{}},i=(c,d)=>{var n;c.disabled||((n=c.command)==null||n.call(c),o("select",c,d))};return(c,d)=>(e.openBlock(),e.createElementBlock("nav",{class:e.normalizeClass(["dock",[`dock--${t.position}`]]),"aria-label":"Dock navigation",onMouseleave:d[0]||(d[0]=n=>a.value=null)},[e.createElementVNode("ul",qf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,k)=>(e.openBlock(),e.createElementBlock("li",{key:k,class:"dock__item-wrap",role:"none",onMouseenter:h=>a.value=k},[!n.to&&!n.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":n.active,"dock__item--disabled mfs-disabled":n.disabled}]),style:e.normalizeStyle(r(k)),"aria-label":n.label,disabled:n.disabled,onClick:h=>i(n,k)},[e.renderSlot(c.$slots,"item",{item:n,index:k,active:!!n.active},()=>[e.createElementVNode("span",Zf,e.toDisplayString(n.icon??n.label.slice(0,2).toUpperCase()),1)],!0),n.active?(e.openBlock(),e.createElementBlock("span",Jf)):e.createCommentVNode("",!0)],14,Xf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.to?"router-link":"a"),{key:1,to:n.to,href:n.href,role:"menuitem",class:e.normalizeClass(["dock__item mfs-rounded-sm mfs-text",{"dock__item--active":n.active,"dock__item--disabled mfs-disabled":n.disabled}]),style:e.normalizeStyle(r(k)),"aria-label":n.label,disabled:n.disabled,onClick:h=>i(n,k)},{default:e.withCtx(()=>[e.renderSlot(c.$slots,"item",{item:n,index:k,active:!!n.active},()=>[e.createElementVNode("span",Qf,e.toDisplayString(n.icon??n.label.slice(0,2).toUpperCase()),1)],!0),n.active?(e.openBlock(),e.createElementBlock("span",vf)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","class","style","aria-label","disabled","onClick"])),e.createElementVNode("span",ep,e.toDisplayString(n.label),1)],40,Yf))),128))])],34))}}),[["__scopeId","data-v-f3aec655"]]),tp={class:"tab-menu","aria-label":"Tab navigation"},lp=["aria-selected","aria-disabled","tabindex","onClick"],op={key:0,class:"tab-menu__icon","aria-hidden":"true"},np={key:0,class:"tab-menu__icon","aria-hidden":"true"},tl=L(e.defineComponent({__name:"TabMenu",props:{items:{},modelValue:{default:0},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=new Map,i=e.ref({left:0,width:0,ready:!1}),c=(p,m)=>{const u=(m==null?void 0:m.$el)??m;u instanceof HTMLElement?r.set(p,u):r.delete(p)},d=e.computed(()=>({transform:`translateX(${i.value.left}px)`,width:`${i.value.width}px`,opacity:i.value.ready&&i.value.width>0?1:0})),n=async(p=!1)=>{await e.nextTick();const m=r.get(l.modelValue);if(!m){i.value={left:0,width:0,ready:!1};return}i.value={left:m.offsetLeft,width:m.offsetWidth,ready:!0},p&&l.scrollable&&m.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},k=(p,m,u)=>{var b;if(p.disabled){u.preventDefault();return}(b=p.command)==null||b.call(p),m!==l.modelValue&&(o("update:modelValue",m),o("change",{index:m,item:p}))},h=p=>{var g;const m=l.items.map((B,w)=>B.disabled?-1:w).filter(B=>B>=0);if(!m.length)return;const u=m.indexOf(l.modelValue);let b=-1;if(p.key==="ArrowRight"?b=m[(u+1)%m.length]:p.key==="ArrowLeft"?b=m[(u-1+m.length)%m.length]:p.key==="Home"?b=m[0]:p.key==="End"&&(b=m[m.length-1]),b>=0){p.preventDefault();const B=l.items[b];o("update:modelValue",b),o("change",{index:b,item:B}),(g=r.get(b))==null||g.focus()}},y=()=>n(!1);let f=null;return e.watch(()=>[l.modelValue,l.items],()=>n(!0),{deep:!0}),e.onMounted(()=>{n(!1),typeof ResizeObserver<"u"&&a.value&&(f=new ResizeObserver(y),f.observe(a.value)),window.addEventListener("resize",y)}),e.onUnmounted(()=>{f==null||f.disconnect(),window.removeEventListener("resize",y)}),(p,m)=>(e.openBlock(),e.createElementBlock("nav",tp,[e.createElementVNode("div",{ref_key:"listRef",ref:a,class:e.normalizeClass(["tab-menu__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tab-menu__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:h},[e.createElementVNode("span",{class:"tab-menu__indicator mfs-rounded-sm",style:e.normalizeStyle(d.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(u,b)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:u.key??b},[!u.to&&!u.href?(e.openBlock(),e.createElementBlock("button",{key:0,ref_for:!0,ref:g=>c(b,g),type:"button",role:"tab",class:e.normalizeClass(["tab-menu__item mfs-rounded-sm mfs-text",{"tab-menu__item--active":b===t.modelValue,"tab-menu__item--disabled mfs-disabled":u.disabled}]),"aria-selected":b===t.modelValue,"aria-disabled":u.disabled||void 0,tabindex:b===t.modelValue?0:-1,onClick:g=>k(u,b,g)},[u.icon?(e.openBlock(),e.createElementBlock("span",op,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.label),1)],10,lp)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.to?"router-link":"a"),{key:1,ref_for:!0,ref:g=>c(b,g),to:u.to,href:u.href,role:"tab",class:e.normalizeClass(["tab-menu__item mfs-rounded-sm mfs-text",{"tab-menu__item--active":b===t.modelValue,"tab-menu__item--disabled mfs-disabled":u.disabled}]),"aria-selected":b===t.modelValue,"aria-disabled":u.disabled||void 0,tabindex:b===t.modelValue?0:-1,onClick:g=>k(u,b,g)},{default:e.withCtx(()=>[u.icon?(e.openBlock(),e.createElementBlock("span",np,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.label),1)]),_:2},1032,["to","href","class","aria-selected","aria-disabled","tabindex","onClick"]))],64))),128))],34)]))}}),[["__scopeId","data-v-8e6dcb53"]]),ap={class:"order-list mfs-surface mfs-rounded mfs-shadow-card"},sp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},rp={key:1,class:"order-list__header"},ip={class:"order-list__title mfs-title"},dp={class:"order-list__body"},cp={class:"order-list__controls",role:"group","aria-label":"Reorder controls"},mp=["disabled"],fp=["disabled"],pp=["disabled"],up=["disabled"],kp={class:"order-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Orderable items"},hp={key:0,class:"mfs-empty-state"},gp=["aria-selected","onClick","onKeydown"],yp={class:"mfs-text"},ll=L(e.defineComponent({__name:"OrderList",props:{modelValue:{},itemKey:{default:"id"},header:{default:""},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},emits:["update:modelValue","reorder"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.computed(()=>a.value!==null&&a.value>0),i=e.computed(()=>a.value!==null&&a.value<l.modelValue.length-1);function c(y,f){a.value=f,o("update:modelValue",y),o("reorder",y)}function d(){if(!r.value||a.value===null)return;const y=a.value,f=[...l.modelValue];[f[y-1],f[y]]=[f[y],f[y-1]],c(f,y-1)}function n(){if(!i.value||a.value===null)return;const y=a.value,f=[...l.modelValue];[f[y+1],f[y]]=[f[y],f[y+1]],c(f,y+1)}function k(){if(!r.value||a.value===null)return;const y=a.value,f=[...l.modelValue],[p]=f.splice(y,1);f.unshift(p),c(f,0)}function h(){if(!i.value||a.value===null)return;const y=a.value,f=[...l.modelValue],[p]=f.splice(y,1);f.push(p),c(f,f.length-1)}return(y,f)=>(e.openBlock(),e.createElementBlock("div",ap,[t.loading?(e.openBlock(),e.createElementBlock("div",sp,[e.renderSlot(y.$slots,"loading",{},()=>[f[0]||(f[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.header||y.$slots.header?(e.openBlock(),e.createElementBlock("div",rp,[e.renderSlot(y.$slots,"header",{},()=>[e.createElementVNode("span",ip,e.toDisplayString(t.header),1)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",dp,[e.createElementVNode("div",cp,[e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!r.value,"aria-label":"Move to top",onClick:k},[...f[1]||(f[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,mp),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!r.value,"aria-label":"Move up",onClick:d},[...f[2]||(f[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,fp),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!i.value,"aria-label":"Move down",onClick:n},[...f[3]||(f[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,pp),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!i.value,"aria-label":"Move to bottom",onClick:h},[...f[4]||(f[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,up)]),e.createElementVNode("ul",kp,[!t.loading&&t.modelValue.length===0?(e.openBlock(),e.createElementBlock("li",hp,[e.renderSlot(y.$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,(p,m)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(me)(p,m,t.itemKey),class:e.normalizeClass(["order-list__item mfs-rounded-sm",{"order-list__item--selected":a.value===m}]),role:"option","aria-selected":a.value===m,tabindex:"0",onClick:u=>a.value=m,onKeydown:[e.withKeys(e.withModifiers(u=>a.value=m,["prevent"]),["enter"]),e.withKeys(e.withModifiers(u=>a.value=m,["prevent"]),["space"])]},[e.renderSlot(y.$slots,"item",{item:p,index:m,selected:a.value===m},()=>[e.createElementVNode("span",yp,e.toDisplayString(p),1)],!0)],42,gp))),128))])])]))}}),[["__scopeId","data-v-8ff7425c"]]),bp={class:"pick-list"},Bp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},_p={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},wp={key:0,class:"pick-list__header mfs-text"},Ep={class:"pick-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Source items"},$p={key:0,class:"mfs-empty-state"},Vp=["aria-selected","onClick","onKeydown"],Cp={class:"mfs-text"},xp={class:"pick-list__controls",role:"group","aria-label":"Transfer controls"},Np=["disabled"],Sp=["disabled"],Mp=["disabled"],Dp=["disabled"],zp={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},Lp={key:0,class:"pick-list__header mfs-text"},Tp={class:"pick-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Target items"},Ip={key:0,class:"mfs-empty-state"},Pp=["aria-selected","onClick","onKeydown"],Rp={class:"mfs-text"},ol=L(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"}},emits:["update:source","update:target","transfer"],setup(t,{emit:s}){const l=t,o=s,a=e.ref([]),r=e.ref([]);function i(f,p){return(f==="source"?a.value:r.value).includes(p)}function c(f,p){const m=f==="source"?a:r,u=m.value.indexOf(p);u>=0?m.value.splice(u,1):m.value.push(p)}function d(f,p){a.value=[],r.value=[],o("update:source",f),o("update:target",p),o("transfer",{source:f,target:p})}function n(){const f=new Set(a.value),p=l.source.filter((u,b)=>f.has(b)),m=l.source.filter((u,b)=>!f.has(b));d(m,[...l.target,...p])}function k(){d([],[...l.target,...l.source])}function h(){const f=new Set(r.value),p=l.target.filter((u,b)=>f.has(b)),m=l.target.filter((u,b)=>!f.has(b));d([...l.source,...p],m)}function y(){d([...l.source,...l.target],[])}return(f,p)=>(e.openBlock(),e.createElementBlock("div",bp,[t.loading?(e.openBlock(),e.createElementBlock("div",Bp,[e.renderSlot(f.$slots,"loading",{},()=>[p[0]||(p[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",_p,[t.sourceHeader?(e.openBlock(),e.createElementBlock("div",wp,e.toDisplayString(t.sourceHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Ep,[!t.loading&&t.source.length===0?(e.openBlock(),e.createElementBlock("li",$p,[e.renderSlot(f.$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,(m,u)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(me)(m,u,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":i("source",u)}]),role:"option","aria-selected":i("source",u),tabindex:"0",onClick:b=>c("source",u),onKeydown:[e.withKeys(e.withModifiers(b=>c("source",u),["prevent"]),["enter"]),e.withKeys(e.withModifiers(b=>c("source",u),["prevent"]),["space"])]},[e.renderSlot(f.$slots,"item",{item:m,index:u,list:"source"},()=>[e.createElementVNode("span",Cp,e.toDisplayString(m),1)],!0)],42,Vp))),128))])]),e.createElementVNode("div",xp,[e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:a.value.length===0,"aria-label":"Move selected to target",onClick:n},[...p[1]||(p[1]=[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:k},[...p[2]||(p[2]=[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,Sp),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:r.value.length===0,"aria-label":"Move selected to source",onClick:h},[...p[3]||(p[3]=[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,Mp),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[4]||(p[4]=[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,Dp)]),e.createElementVNode("div",zp,[t.targetHeader?(e.openBlock(),e.createElementBlock("div",Lp,e.toDisplayString(t.targetHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Tp,[!t.loading&&t.target.length===0?(e.openBlock(),e.createElementBlock("li",Ip,[e.renderSlot(f.$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,(m,u)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(me)(m,u,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":i("target",u)}]),role:"option","aria-selected":i("target",u),tabindex:"0",onClick:b=>c("target",u),onKeydown:[e.withKeys(e.withModifiers(b=>c("target",u),["prevent"]),["enter"]),e.withKeys(e.withModifiers(b=>c("target",u),["prevent"]),["space"])]},[e.renderSlot(f.$slots,"item",{item:m,index:u,list:"target"},()=>[e.createElementVNode("span",Rp,e.toDisplayString(m),1)],!0)],42,Pp))),128))])])]))}}),[["__scopeId","data-v-a25b1467"]]),Fp={class:"tree-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card"},Ap={class:"tree-table__wrap"},jp={class:"tree-table__table"},Kp={key:0},Op=["colspan"],Up=["aria-expanded","aria-label","onClick"],Hp={key:1,class:"tree-table__spacer","aria-hidden":"true"},Wp={key:0,class:"mfs-loading-overlay","aria-busy":"true"},nl=L(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:s}){const l=t,o=s,a=e.ref([...l.expandedKeys]);e.watch(()=>l.expandedKeys,c=>{a.value=[...c]});const r=e.computed(()=>{const c=[],d=new Set(a.value);function n(k,h){for(const y of k){const f=Array.isArray(y.children)&&y.children.length>0||l.lazy&&y.leaf!==!0,p=f&&d.has(y.key);c.push({node:y,depth:h,hasChildren:f,expanded:p}),p&&y.children&&n(y.children,h+1)}}return n(l.nodes,0),c});function i(c){const d=new Set(a.value),n=!d.has(c.key);n?d.add(c.key):d.delete(c.key);const k=Array.from(d);a.value=k,o("update:expandedKeys",k),o("node-toggle",c,n),n&&l.lazy&&(!c.children||c.children.length===0)&&o("lazy-load",c)}return(c,d)=>(e.openBlock(),e.createElementBlock("div",Fp,[e.createElementVNode("div",Ap,[e.createElementVNode("table",jp,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,n=>(e.openBlock(),e.createElementBlock("th",{key:n.key,class:e.normalizeClass(["tree-table__th mfs-text-muted",n.align?`tree-table__cell--${n.align}`:""]),style:e.normalizeStyle(n.width?{width:n.width}:void 0)},e.toDisplayString(n.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(c.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)],8,Op)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.value,n=>(e.openBlock(),e.createElementBlock("tr",{key:n.node.key,class:"tree-table__row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,(k,h)=>(e.openBlock(),e.createElementBlock("td",{key:k.key,class:e.normalizeClass(["tree-table__td mfs-text",k.align?`tree-table__cell--${k.align}`:""])},[h===0?(e.openBlock(),e.createElementBlock("div",{key:0,class:"tree-table__first-cell",style:e.normalizeStyle({paddingLeft:`${n.depth*20}px`})},[n.hasChildren?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree-table__toggle mfs-text-muted",{"tree-table__toggle--expanded":n.expanded}]),"aria-expanded":n.expanded,"aria-label":n.expanded?"Collapse row":"Expand row",onClick:y=>i(n.node)},[...d[0]||(d[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,Up)):(e.openBlock(),e.createElementBlock("span",Hp)),e.renderSlot(c.$slots,`cell-${k.key}`,{node:n.node,value:n.node.data[k.key],depth:n.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(n.node.data[k.key]??""),1)],!0)],4)):e.renderSlot(c.$slots,`cell-${k.key}`,{node:n.node,value:n.node.data[k.key],depth:n.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(n.node.data[k.key]??""),1)],!0,1)],2))),128))]))),128))])])]),t.loading?(e.openBlock(),e.createElementBlock("div",Wp,[e.renderSlot(c.$slots,"loading",{},()=>[d[1]||(d[1]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7d4f20c5"]]),Gp=["aria-busy"],qp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Yp={key:1,class:"mfs-empty-state"},Xp={class:"org-chart__node-wrap"},Zp={class:"org-chart__label mfs-title"},Jp={key:0,class:"org-chart__title mfs-caption"},Qp=["aria-expanded","aria-label"],vp={key:0,class:"org-chart__children"},al=L(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:s}){const l=t,o=s,a=e.ref(!0),r=e.computed(()=>{var d;return Array.isArray((d=l.value)==null?void 0:d.children)&&l.value.children.length>0}),i=e.computed(()=>l.value?l.expandedKeys?l.expandedKeys.includes(l.value.key):a.value:!1);e.watch(()=>l.expandedKeys,()=>{l.expandedKeys&&l.value&&(a.value=l.expandedKeys.includes(l.value.key))});function c(){if(!(!l.value||!r.value))if(l.expandedKeys){const d=new Set(l.expandedKeys);d.has(l.value.key)?d.delete(l.value.key):d.add(l.value.key),o("update:expandedKeys",Array.from(d))}else a.value=!a.value}return(d,n)=>{const k=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",qp,[e.renderSlot(d.$slots,"loading",{},()=>[n[4]||(n[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",Yp,[e.renderSlot(d.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):t.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("div",Xp,[e.createElementVNode("div",{class:"org-chart__node mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-focus-ring",tabindex:"0",onClick:n[0]||(n[0]=h=>d.$emit("node-click",t.value)),onKeydown:n[1]||(n[1]=e.withKeys(e.withModifiers(h=>d.$emit("node-click",t.value),["prevent"]),["enter"]))},[e.renderSlot(d.$slots,"node",{node:t.value,expanded:i.value},()=>[e.createElementVNode("div",Zp,e.toDisplayString(t.value.label),1),t.value.title?(e.openBlock(),e.createElementBlock("div",Jp,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":i.value,"aria-label":i.value?`Collapse ${t.value.label}`:`Expand ${t.value.label}`,onClick:e.withModifiers(c,["stop"])},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass({"org-chart__chevron--collapsed":!i.value}),viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[...n[5]||(n[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,Qp)):e.createCommentVNode("",!0)]),r.value&&i.value?(e.openBlock(),e.createElementBlock("div",vp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value.children,h=>(e.openBlock(),e.createElementBlock("div",{key:h.key,class:"org-chart__branch"},[e.createVNode(k,{value:h,collapsible:t.collapsible,"expanded-keys":t.expandedKeys,level:t.level+1,"onUpdate:expandedKeys":n[2]||(n[2]=y=>d.$emit("update:expandedKeys",y)),onNodeClick:n[3]||(n[3]=y=>d.$emit("node-click",y))},e.createSlots({_:2},[d.$slots.node?{name:"node",fn:e.withCtx(y=>[e.renderSlot(d.$slots,"node",e.mergeProps({ref_for:!0},y),void 0,!0)]),key:"0"}:void 0]),1032,["value","collapsible","expanded-keys","level"])]))),128))])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],10,Gp)}}}),[["__scopeId","data-v-426d2664"]]),eu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},tu={key:1,class:"mfs-empty-state"},lu={class:"mfs-text"},sl=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(0),i=e.ref(300);e.onMounted(()=>{a.value&&(i.value=a.value.clientHeight||300)});function c(){a.value&&(r.value=a.value.scrollTop,i.value=a.value.clientHeight||i.value,l.lazy&&o("lazy-load",{first:n.value,last:k.value}))}const d=e.computed(()=>l.items.length*l.itemSize),n=e.computed(()=>{const f=Math.floor(r.value/l.itemSize)-l.buffer;return Math.max(0,f)}),k=e.computed(()=>{const f=Math.ceil(i.value/l.itemSize),p=Math.floor(r.value/l.itemSize)+f+l.buffer;return Math.min(l.items.length,p)}),h=e.computed(()=>n.value*l.itemSize),y=e.computed(()=>l.items.slice(n.value,k.value).map((f,p)=>({item:f,index:n.value+p})));return(f,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:a,class:"virtual-scroller mfs-surface mfs-rounded mfs-shadow-card",style:e.normalizeStyle({height:t.height}),onScroll:c},[t.loading?(e.openBlock(),e.createElementBlock("div",eu,[e.renderSlot(f.$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",tu,[e.renderSlot(f.$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:`${d.value}px`})},[e.createElementVNode("div",{class:"virtual-scroller__content",style:e.normalizeStyle({transform:`translateY(${h.value}px)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,m=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(me)(m.item,m.index,t.itemKey),class:"virtual-scroller__item",style:e.normalizeStyle({height:`${t.itemSize}px`})},[e.renderSlot(f.$slots,"item",{item:m.item,index:m.index},()=>[e.createElementVNode("span",lu,e.toDisplayString(m.item),1)],!0)],4))),128))],4)],4))],36))}}),[["__scopeId","data-v-5a8d047c"]]),ou={class:"meter-group mfs-card"},nu=["aria-valuenow","aria-valuemax"],au=["title"],su={key:0,class:"meter-group__legend"},ru={class:"meter-group__label mfs-text"},iu={class:"meter-group__value mfs-text-muted"},rl=L(e.defineComponent({__name:"MeterGroup",props:{values:{},max:{default:100},showLegend:{type:Boolean,default:!0}},setup(t){const s=t,l=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)"],o=e.computed(()=>s.values.reduce((i,c)=>i+Math.max(0,c.value),0));function a(i){const c=s.max>0?s.max:100;return Math.min(100,Math.max(0,i/c*100))}function r(i){return l[i%l.length]}return(i,c)=>(e.openBlock(),e.createElementBlock("div",ou,[e.createElementVNode("div",{class:"meter-group__track mfs-inset mfs-pill",role:"progressbar","aria-valuenow":o.value,"aria-valuemin":"0","aria-valuemax":t.max},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(d,n)=>(e.openBlock(),e.createElementBlock("div",{key:d.label,class:"meter-group__segment",style:e.normalizeStyle({width:`${a(d.value)}%`,backgroundColor:d.color||r(n)}),title:`${d.label}: ${d.value}`},null,12,au))),128))],8,nu),t.showLegend?(e.openBlock(),e.createElementBlock("ol",su,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(d,n)=>(e.openBlock(),e.createElementBlock("li",{key:d.label,class:"meter-group__legend-item"},[e.createElementVNode("span",{class:"meter-group__dot mfs-pill",style:e.normalizeStyle({backgroundColor:d.color||r(n)}),"aria-hidden":"true"},null,4),e.createElementVNode("span",ru,e.toDisplayString(d.label),1),e.createElementVNode("span",iu,e.toDisplayString(d.value)+" ("+e.toDisplayString(Math.round(a(d.value)))+"%)",1)]))),128))])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7ff895f3"]]),du={class:"inplace"},cu=["tabindex","aria-disabled","onKeydown"],mu={class:"inplace__inner"},il=L(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:s}){const l=t,o=s,a=e.ref(l.active);e.watch(()=>l.active,d=>{a.value=d});const r=e.computed(()=>a.value);function i(){l.disabled||r.value||(a.value=!0,o("update:active",!0),o("open"))}function c(){r.value&&(a.value=!1,o("update:active",!1),o("close"))}return(d,n)=>(e.openBlock(),e.createElementBlock("div",du,[r.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"inplace__content mfs-surface mfs-rounded-md mfs-shadow",onKeydown:e.withKeys(c,["esc"])},[e.createElementVNode("div",mu,[e.renderSlot(d.$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:c},[...n[1]||(n[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:i,onKeydown:[e.withKeys(e.withModifiers(i,["prevent"]),["enter"]),e.withKeys(e.withModifiers(i,["prevent"]),["space"])]},[e.renderSlot(d.$slots,"display",{},()=>[n[0]||(n[0]=e.createElementVNode("span",{class:"mfs-text-muted"},"Click to edit",-1))],!0)],42,cu))]))}}),[["__scopeId","data-v-befa9d74"]]),fu={class:"mfs-flex mfs-items-start mfs-gap-2-5 mfs-mb-3"},pu={class:"mfs-confirm-popup__message mfs-text mfs-m-0"},uu={class:"mfs-flex mfs-justify-end mfs-gap-2"},dl=L(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:s,emit:l}){const o=t,a=l,r=e.ref(null),i=e.ref(!1),c=e.ref(null),d=e.ref({}),n=e.ref({top:0,left:0}),k=e.computed(()=>o.modelValue!==void 0),h=e.computed(()=>k.value?!!o.modelValue:i.value),y=e.computed(()=>d.value.message??o.message),f=e.computed(()=>d.value.acceptLabel??o.acceptLabel),p=e.computed(()=>d.value.rejectLabel??o.rejectLabel),m=e.computed(()=>d.value.variant??o.variant),u=e.computed(()=>({top:`${n.value.top}px`,left:`${n.value.left}px`}));function b(S){return S?S instanceof HTMLElement?S:S.currentTarget??S.target:null}async function g(){var j;await e.nextTick();const S=c.value??b(o.target);if(!S||typeof window>"u")return;const N=S.getBoundingClientRect(),F=((j=r.value)==null?void 0:j.offsetWidth)??260,H=Math.min(Math.max(12,N.left+N.width/2-F/2),window.innerWidth-F-12),z=N.bottom+10;n.value={top:z,left:H}}function B(S){k.value||(i.value=S),a("update:modelValue",S)}function w(S,N={}){c.value=b(S),d.value=N,B(!0),g()}function _(){B(!1)}function $(){var S,N;(N=(S=d.value).onAccept)==null||N.call(S),a("accept"),_()}function V(){var S,N;(N=(S=d.value).onReject)==null||N.call(S),a("reject"),_()}const E=S=>{var H;const N=S.target,F=c.value??b(o.target);(H=r.value)!=null&&H.contains(N)||F!=null&&F.contains(N)||_()},C=S=>{S.key==="Escape"&&_()};return e.watch(h,S=>{typeof document>"u"||(S?(g(),document.addEventListener("pointerdown",E),document.addEventListener("keydown",C)):(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",C)))}),e.onBeforeUnmount(()=>{typeof document<"u"&&(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",C))}),s({show:w,hide:_}),(S,N)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-popup"},{default:e.withCtx(()=>[h.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(u.value),role:"alertdialog","aria-modal":"false"},[e.createElementVNode("div",fu,[e.createElementVNode("span",{class:e.normalizeClass(["mfs-confirm-popup__icon mfs-shrink-0",[`mfs-text-${m.value}`]]),"aria-hidden":"true"},[...N[0]||(N[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",pu,e.toDisplayString(y.value),1)]),e.createElementVNode("div",uu,[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:V},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-${m.value}`]]),onClick:$},e.toDisplayString(f.value),3)])],4)):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-57b1abca"]]),ku={class:"mfs-inline-msg__icon","aria-hidden":"true"},hu={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},gu={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},yu={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},bu={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Bu={class:"mfs-inline-msg__text"},cl=L(e.defineComponent({__name:"InlineMessage",props:{severity:{default:"info"},text:{default:""}},setup(t){return(s,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",ku,[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",hu,[...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",gu,[...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",yu,[...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",bu,[...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",Bu,[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.text),1)],!0)])],2))}}),[["__scopeId","data-v-40ba4b5c"]]),_u=["aria-busy"],wu=["aria-label"],Eu={class:"mfs-blockui__content mfs-surface mfs-rounded mfs-shadow"},$u={key:0,class:"mfs-blockui__label mfs-text"},ml=L(e.defineComponent({__name:"BlockUI",props:{blocked:{type:Boolean,default:!1},fullScreen:{type:Boolean,default:!1},label:{default:""}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-blockui","aria-busy":t.blocked},[e.renderSlot(s.$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(s.$slots,"overlay",{},()=>[e.createElementVNode("div",Eu,[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",$u,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)])],!0)],10,wu)):e.createCommentVNode("",!0)]),_:3})],8,["disabled"]))],8,_u))}}),[["__scopeId","data-v-59ef354e"]]),Vu=["aria-busy","onKeydown"],Cu={class:"mfs-galleria__stage"},xu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Nu={key:1,class:"mfs-empty-state"},Su=["src","alt"],Mu=["aria-label"],Du={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},zu={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Lu={key:4,class:"mfs-galleria__caption"},Tu={key:0,class:"mfs-galleria__thumbs"},Iu=["aria-label","onClick"],Pu=["src","alt"],fl=L(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:s}){const l=t,o=s,a=e.ref(l.activeIndex),r=e.ref(l.fullscreen);e.watch(()=>l.activeIndex,k=>{a.value=k});const i=e.computed(()=>l.images[a.value]??null),c=k=>{if(l.images.length===0)return;const h=(k+l.images.length)%l.images.length;a.value=h,o("update:activeIndex",h)},d=()=>c(a.value-1),n=()=>c(a.value+1);return(k,h)=>{var y;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(d,["prevent"]),["left"]),e.withKeys(e.withModifiers(n,["prevent"]),["right"]),h[1]||(h[1]=e.withKeys(f=>r.value=!1,["escape"]))]},[e.createElementVNode("div",Cu,[t.loading?(e.openBlock(),e.createElementBlock("div",xu,[e.renderSlot(k.$slots,"loading",{},()=>[h[2]||(h[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",Nu,[e.renderSlot(k.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[i.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:i.value.src,alt:i.value.alt||i.value.title||"Gallery image",class:"mfs-galleria__image"},null,8,Su)):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:d},[...h[3]||(h[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:n},[...h[4]||(h[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:h[0]||(h[0]=f=>r.value=!r.value)},[r.value?(e.openBlock(),e.createElementBlock("svg",zu,[...h[6]||(h[6]=[e.createElementVNode("path",{d:"M4 14h6v6M20 10h-6V4M14 10l7-7M3 21l7-7"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",Du,[...h[5]||(h[5]=[e.createElementVNode("path",{d:"M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"},null,-1)])]))],8,Mu)):e.createCommentVNode("",!0),(y=i.value)!=null&&y.title?(e.openBlock(),e.createElementBlock("div",Lu,e.toDisplayString(i.value.title),1)):e.createCommentVNode("",!0)],64))]),t.showThumbnails&&t.images.length>1?(e.openBlock(),e.createElementBlock("div",Tu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(f,p)=>(e.openBlock(),e.createElementBlock("button",{key:p,type:"button",class:e.normalizeClass(["mfs-galleria__thumb mfs-rounded-sm",{"mfs-galleria__thumb--active":p===a.value}]),"aria-label":`View image ${p+1}`,onClick:m=>c(p)},[e.createElementVNode("img",{src:f.thumbnail||f.src,alt:f.alt||`Thumbnail ${p+1}`},null,8,Pu)],10,Iu))),128))])):e.createCommentVNode("",!0)],42,Vu)}}}),[["__scopeId","data-v-cfe349fe"]]),Ru=["disabled"],Fu=["onKeydown"],Au=["src"],ju={key:2,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},Ku={key:3,class:"mfs-cropper__controls mfs-flex mfs-flex-col mfs-gap-3"},Ou={class:"mfs-row mfs-justify-between"},Uu={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-1 mfs-min-w-0"},Hu=["disabled"],Wu=["disabled"],Gu=["disabled"],qu={class:"mfs-flex mfs-items-center mfs-gap-1-5 mfs-shrink-0"},Yu=["disabled"],Xu=["disabled"],Zu=["disabled"],Ju={class:"mfs-row mfs-justify-between mfs-flex-wrap mfs-gap-2"},Qu={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-wrap"},vu=["disabled"],ek={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"],ok={class:"mfs-flex mfs-items-center mfs-gap-2"},nk=["disabled"],ak=["disabled"],Re=L(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:s,emit:l}){const o=t,a=l,r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(null),n=e.ref(null),k=e.ref(!1),h=e.ref(null),y=e.ref(!1),f=e.ref(!1),p=e.ref(0),m=e.ref(0),u=e.ref(320),b=e.ref(260),g=e.ref(1),B=e.ref(0),w=e.ref(0),_=e.ref(0),$=e.ref(!1);let V=0,E=0,C=0,S=0,N=null;const F=e.ref(o.shape);e.watch(()=>o.shape,U=>{F.value=U});function H(U){o.disabled||F.value===U||(F.value=U,a("update:shape",U))}const z=e.computed(()=>n.value?n.value:o.src?o.src:typeof o.modelValue=="string"&&o.modelValue?o.modelValue:d.value?d.value:null),j=e.computed(()=>F.value==="circle"?1:o.aspectRatio>0?o.aspectRatio:1),W=e.computed(()=>{const U=Math.max(80,u.value*.82),A=Math.max(80,b.value*.82),G=j.value;let q=U,Z=q/G;return Z>A&&(Z=A,q=Z*G),{width:q,height:Z}}),T=e.computed(()=>Math.abs(B.value%180)===90),K=e.computed(()=>{if(!p.value||!m.value)return 1;const U=T.value?m.value:p.value,A=T.value?p.value:m.value;return Math.max(W.value.width/U,W.value.height/A)}),P=e.computed(()=>K.value*g.value);function I(U,A,G){return Math.min(G,Math.max(A,U))}function M(){if(!p.value||!m.value)return;const U=T.value?m.value:p.value,A=T.value?p.value:m.value,G=U*P.value,q=A*P.value,Z=Math.max(0,(G-W.value.width)/2),X=Math.max(0,(q-W.value.height)/2);w.value=I(w.value,-Z,Z),_.value=I(_.value,-X,X)}const R=e.computed(()=>({width:`${p.value}px`,height:`${m.value}px`,marginLeft:`${-p.value/2}px`,marginTop:`${-m.value/2}px`,transform:`translate(${w.value}px, ${_.value}px) rotate(${B.value}deg) scale(${P.value})`})),D=e.computed(()=>({width:`${W.value.width}px`,height:`${W.value.height}px`}));function O(){d.value&&(URL.revokeObjectURL(d.value),d.value=null)}function Y(U){if(!(U.type.startsWith("image/")||/\.(png|jpe?g|webp|gif|bmp|svg|avif)$/i.test(U.name))){const q=`Unsupported file type: ${U.name}`;h.value=q,a("error",q);return}O(),h.value=null,k.value=!1;const G=URL.createObjectURL(U);d.value=G,n.value=G,ue()}function Q(){var U;o.disabled||(U=r.value)==null||U.click()}function ze(U){var q;const A=U.target,G=(q=A.files)==null?void 0:q[0];G&&Y(G),A.value=""}function og(U){var G,q;if(y.value=!1,o.disabled)return;const A=(q=(G=U.dataTransfer)==null?void 0:G.files)==null?void 0:q[0];A&&Y(A)}function ng(){const U=c.value;U&&(p.value=U.naturalWidth,m.value=U.naturalHeight,k.value=!0,h.value=null,M())}function ag(){k.value=!1;const U="Failed to load image";h.value=U,a("error",U)}function sg(U){if(o.disabled||!k.value)return;const A=i.value;A&&($.value=!0,V=U.clientX,E=U.clientY,C=w.value,S=_.value,A.setPointerCapture(U.pointerId))}function rg(U){$.value&&(w.value=C+(U.clientX-V),_.value=S+(U.clientY-E),M())}function Zl(U){var A;$.value&&($.value=!1,(A=i.value)==null||A.releasePointerCapture(U.pointerId))}function ig(U){if(o.disabled||!k.value)return;const A=U.deltaY<0?.1:-.1;We(A)}function We(U){g.value=Number(I(g.value+U,1,3).toFixed(2))}function Jl(U){B.value=(B.value+U)%360,M()}function ue(){g.value=1,B.value=0,w.value=0,_.value=0,M()}async function Ql(){const U=c.value;if(!U||!k.value||f.value)return null;f.value=!0,h.value=null;try{const A=j.value,G=A>=1?o.outputSize:Math.round(o.outputSize*A),q=A>=1?Math.round(o.outputSize/A):o.outputSize,Z=document.createElement("canvas");Z.width=G,Z.height=q;const X=Z.getContext("2d");if(!X)throw new Error("Canvas 2D context is unavailable");o.outputType==="image/jpeg"&&(X.fillStyle="#ffffff",X.fillRect(0,0,G,q)),F.value==="circle"&&(X.beginPath(),X.arc(G/2,q/2,Math.min(G,q)/2,0,Math.PI*2),X.clip());const Ge=G/W.value.width;X.save(),X.translate(G/2+w.value*Ge,q/2+_.value*Ge),X.rotate(B.value*Math.PI/180);const to=P.value*Ge;X.scale(to,to),X.drawImage(U,-p.value/2,-m.value/2,p.value,m.value),X.restore();const lo=await new Promise((cg,mg)=>{Z.toBlob(ao=>ao?cg(ao):mg(new Error("Failed to export cropped image")),o.outputType,o.quality)}),dg=Z.toDataURL(o.outputType,o.quality),oo=new File([lo],o.fileName,{type:o.outputType}),no={blob:lo,dataUrl:dg,file:oo};return a("update:modelValue",oo),a("crop",no),no}catch(A){const G=A instanceof Error?A.message:"Failed to crop image";return h.value=G,a("error",G),null}finally{f.value=!1}}function vl(){const U=i.value;if(!U)return;const A=U.getBoundingClientRect();A.width>0&&A.height>0&&(u.value=A.width,b.value=A.height,M())}function eo(){N==null||N.disconnect(),!(!i.value||typeof ResizeObserver>"u")&&(N=new ResizeObserver(vl),N.observe(i.value),vl())}return e.watch(()=>o.modelValue,U=>{n.value=null,O(),k.value=!1,U instanceof File&&(d.value=URL.createObjectURL(U)),ue()},{immediate:!0}),e.watch(()=>o.src,()=>{n.value=null,k.value=!1,ue()}),e.watch([g,j],()=>{M()}),e.watch(i,U=>{U&&eo()}),e.onMounted(()=>{eo()}),e.onBeforeUnmount(()=>{N==null||N.disconnect(),O()}),s({crop:Ql,reset:ue}),(U,A)=>(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:ze},null,40,Ru),z.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"stageRef",ref:i,class:e.normalizeClass(["mfs-cropper__stage mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none",$.value?"mfs-cropper__stage--grabbing":"mfs-cropper__stage--grab"]),onPointerdown:sg,onPointermove:rg,onPointerup:Zl,onPointercancel:Zl,onWheel:e.withModifiers(ig,["prevent"])},[e.createElementVNode("img",{ref_key:"imgRef",ref:c,src:z.value,alt:"Crop source",draggable:"false",class:"mfs-cropper__img",style:e.normalizeStyle(R.value),onLoad:ng,onError:ag},null,44,Au),k.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__viewport mfs-absolute",{"mfs-cropper__viewport--circle":F.value==="circle"}]),style:e.normalizeStyle(D.value),"aria-hidden":"true"},[...A[11]||(A[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":y.value}]),role:"button",tabindex:"0","aria-label":"Select an image to crop",onClick:Q,onKeydown:[e.withKeys(e.withModifiers(Q,["prevent"]),["enter"]),e.withKeys(e.withModifiers(Q,["prevent"]),["space"])],onDragover:A[0]||(A[0]=e.withModifiers(G=>y.value=!0,["prevent"])),onDragleave:A[1]||(A[1]=e.withModifiers(G=>y.value=!1,["prevent"])),onDrop:e.withModifiers(og,["prevent"])},[...A[10]||(A[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,Fu)),h.value?(e.openBlock(),e.createElementBlock("div",ju,e.toDisplayString(h.value),1)):e.createCommentVNode("",!0),t.showControls&&z.value?(e.openBlock(),e.createElementBlock("div",Ku,[e.createElementVNode("div",Ou,[e.createElementVNode("div",Uu,[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||g.value<=1,onClick:A[2]||(A[2]=G=>We(-.15))},[...A[12]||(A[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,Hu),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":A[3]||(A[3]=G=>g.value=G),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,Wu),[[e.vModelText,g.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||g.value>=3,onClick:A[4]||(A[4]=G=>We(.15))},[...A[13]||(A[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,Gu)]),e.createElementVNode("div",qu,[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:A[5]||(A[5]=G=>Jl(-90))},[...A[14]||(A[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,Yu),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:A[6]||(A[6]=G=>Jl(90))},[...A[15]||(A[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,Xu),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:ue}," Reset ",8,Zu)])]),e.createElementVNode("div",Ju,[e.createElementVNode("div",Qu,[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:Q}," Change Image ",8,vu),t.allowShapeToggle?(e.openBlock(),e.createElementBlock("div",ek,[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",F.value==="rect"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":F.value==="rect",disabled:t.disabled,onClick:A[7]||(A[7]=G=>H("rect"))},[...A[16]||(A[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",F.value==="circle"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":F.value==="circle",disabled:t.disabled,onClick:A[8]||(A[8]=G=>H("circle"))},[...A[17]||(A[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",ok,[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:A[9]||(A[9]=G=>a("cancel"))}," Cancel ",8,nk),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||!k.value||f.value,onClick:Ql},e.toDisplayString(f.value?"Cropping...":"Crop"),9,ak)])])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4a71ca25"]]),sk=["aria-busy"],rk={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ik=["onKeydown"],dk=["accept","multiple","disabled"],ck={key:0,class:"mfs-upload__hint mfs-caption mfs-m-0"},mk={key:0},fk={key:1},pk={key:2},uk={key:1,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},kk={key:2,class:"mfs-upload__progress-wrap mfs-flex mfs-items-center mfs-gap-2-5"},hk={class:"mfs-upload__progress-track mfs-pill mfs-shadow-inset mfs-flex-1 mfs-overflow-hidden"},gk={class:"mfs-upload__progress-text mfs-text-muted mfs-font-bold"},yk={key:3,class:"mfs-upload__list mfs-m-0 mfs-p-0 mfs-flex mfs-flex-col mfs-gap-2"},bk={class:"mfs-upload__file-info mfs-flex mfs-flex-col mfs-min-w-0"},Bk={class:"mfs-upload__file-name mfs-text mfs-font-semibold mfs-truncate"},_k={class:"mfs-upload__file-size mfs-caption"},wk=["onClick"],pl=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(l.modelValue?[...l.modelValue]:[]),i=e.ref([]),c=e.ref(!1),d=e.ref(null),n=e.computed(()=>l.error||d.value),k=e.computed(()=>i.value[0]??null),h=e.computed(()=>k.value!==null),y=e.computed(()=>{const V=k.value;return V?`${V.name.replace(/\.[^.]+$/,"")||"cropped-image"}.png`:"cropped-image.png"});e.watch(()=>l.modelValue,V=>{V&&(r.value=[...V])});function f(V){return V<1024?`${V} B`:V<1024*1024?`${(V/1024).toFixed(1)} KB`:`${(V/(1024*1024)).toFixed(1)} MB`}function p(V,E){if(!E)return!0;const C=E.split(",").map(F=>F.trim().toLowerCase()).filter(Boolean);if(C.length===0)return!0;const S=V.name.toLowerCase(),N=V.type.toLowerCase();return C.some(F=>F.startsWith(".")?S.endsWith(F):F.endsWith("/*")?N.startsWith(F.slice(0,-1)):N===F)}function m(V){if(!V||l.disabled||l.loading)return;d.value=null;const E=[];for(const C of Array.from(V)){if(!p(C,l.accept)){const S=`Invalid file type: ${C.name}`;d.value=S,o("error",S);continue}if(l.maxFileSize&&C.size>l.maxFileSize){const S=`File too large: ${C.name} (max ${f(l.maxFileSize)})`;d.value=S,o("error",S);continue}E.push(C)}if(E.length!==0){if(l.crop){const C=l.multiple?E:[E[0]],S=C.filter(F=>F.type.startsWith("image/")),N=C.filter(F=>!F.type.startsWith("image/"));N.length>0&&(r.value=l.multiple?[...r.value,...N]:[N[0]],o("update:modelValue",r.value),o("select",r.value)),S.length>0&&(i.value=l.multiple?[...i.value,...S]:[S[0]]);return}r.value=l.multiple?[...r.value,...E]:[E[0]],o("update:modelValue",r.value),o("select",r.value)}}function u(V){r.value=l.multiple?[...r.value,V.file]:[V.file],o("update:modelValue",r.value),o("select",r.value),i.value.shift()}function b(){i.value.shift()}const g=()=>{var V;!l.disabled&&!l.loading&&((V=a.value)==null||V.click())},B=V=>{const E=V.target;m(E.files),E.value=""},w=()=>{!l.disabled&&!l.loading&&(c.value=!0)},_=V=>{var E;c.value=!1,m(((E=V.dataTransfer)==null?void 0:E.files)??null)},$=V=>{const[E]=r.value.splice(V,1);o("update:modelValue",r.value),E&&o("remove",E),r.value.length===0&&o("clear")};return(V,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",rk,[...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":c.value,"mfs-upload__dropzone--disabled mfs-disabled":t.disabled||t.loading}]),role:"button",tabindex:"0","aria-label":"Upload files",onClick:g,onKeydown:[e.withKeys(e.withModifiers(g,["prevent"]),["enter"]),e.withKeys(e.withModifiers(g,["prevent"]),["space"])],onDragover:e.withModifiers(w,["prevent"]),onDragleave:E[0]||(E[0]=e.withModifiers(C=>c.value=!1,["prevent"])),onDrop:e.withModifiers(_,["prevent"])},[e.createElementVNode("input",{ref_key:"inputRef",ref:a,type:"file",class:"mfs-upload__input",accept:t.accept,multiple:t.multiple,disabled:t.disabled||t.loading,onChange:B},null,40,dk),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-56400c6e><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-v-56400c6e><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" data-v-56400c6e></path><polyline points="17 8 12 3 7 8" data-v-56400c6e></polyline><line x1="12" x2="12" y1="3" y2="15" data-v-56400c6e></line></svg></span><p class="mfs-upload__title mfs-title mfs-m-0 mfs-font-semibold" data-v-56400c6e> Drag &amp; drop files here or <span class="mfs-upload__link mfs-text-primary" data-v-56400c6e>browse</span></p>',2)),t.accept||t.maxFileSize?(e.openBlock(),e.createElementBlock("p",ck,[t.accept?(e.openBlock(),e.createElementBlock("span",mk,"Accepted: "+e.toDisplayString(t.accept),1)):e.createCommentVNode("",!0),t.accept&&t.maxFileSize?(e.openBlock(),e.createElementBlock("span",fk," · ")):e.createCommentVNode("",!0),t.maxFileSize?(e.openBlock(),e.createElementBlock("span",pk,"Max: "+e.toDisplayString(f(t.maxFileSize)),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],42,ik),n.value?(e.openBlock(),e.createElementBlock("div",uk,e.toDisplayString(n.value),1)):e.createCommentVNode("",!0),typeof t.progress=="number"&&t.progress>0?(e.openBlock(),e.createElementBlock("div",kk,[e.createElementVNode("div",hk,[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",gk,e.toDisplayString(Math.round(t.progress))+"%",1)])):e.createCommentVNode("",!0),r.value.length>0?(e.openBlock(),e.createElementBlock("ul",yk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(C,S)=>(e.openBlock(),e.createElementBlock("li",{key:`${C.name}-${C.size}-${S}`,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",bk,[e.createElementVNode("span",Bk,e.toDisplayString(C.name),1),e.createElementVNode("span",_k,e.toDisplayString(f(C.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:N=>$(S)},[...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,wk)]))),128))])):e.createCommentVNode("",!0),e.createVNode(oe,{"model-value":h.value,title:"Crop Image",size:"md","close-on-backdrop":!1,onClose:b},{default:e.withCtx(()=>[k.value?(e.openBlock(),e.createBlock(Re,{key:0,"model-value":k.value,shape:t.cropShape,"aspect-ratio":t.cropAspectRatio,"file-name":y.value,onCrop:u,onCancel:b},null,8,["model-value","shape","aspect-ratio","file-name"])):e.createCommentVNode("",!0)]),_:1},8,["model-value"])],8,sk))}}),[["__scopeId","data-v-56400c6e"]]),Ek={key:0,class:"mfs-terminal__welcome mfs-text-muted"},$k={class:"mfs-flex mfs-gap-2"},Vk={class:"mfs-text-primary mfs-font-bold mfs-select-none"},Ck={class:"mfs-terminal__cmd"},xk={key:0,class:"mfs-terminal__response"},Nk={class:"mfs-text-primary mfs-font-bold mfs-select-none"},Sk=["onKeydown"],ul=L(e.defineComponent({__name:"Terminal",props:{welcomeMessage:{default:""},prompt:{default:"$"},commands:{}},emits:["command"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.ref([]),i=e.ref([]),c=e.ref(-1),d=e.ref(""),n=e.ref(null),k=e.ref(null),h=()=>{var u;(u=n.value)==null||u.focus()},y=async()=>{await e.nextTick(),k.value&&(k.value.scrollTop=k.value.scrollHeight)},f=async()=>{const u=d.value.trim();if(!u)return;d.value="",i.value.push(u),c.value=i.value.length;const[b,...g]=u.split(/\s+/);if(b==="clear"){r.value=[];return}const B={command:u};r.value.push(B);const w=r.value.length-1,_=$=>{r.value[w].response=$,y()};if(o.commands&&b in o.commands){const $=await o.commands[b](g);_($)}else a("command",{command:b,args:g,raw:u,respond:_});y()},p=()=>{i.value.length!==0&&(c.value=Math.max(0,c.value-1),d.value=i.value[c.value]??"")},m=()=>{i.value.length!==0&&(c.value=Math.min(i.value.length,c.value+1),d.value=i.value[c.value]??"")};return s({clear:()=>{r.value=[]}}),(u,b)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-terminal mfs-surface mfs-font-mono mfs-rounded mfs-shadow-card mfs-blur mfs-p-4",onClick:h},[t.welcomeMessage?(e.openBlock(),e.createElementBlock("div",Ek,e.toDisplayString(t.welcomeMessage),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"logRef",ref:k,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,(g,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"mfs-terminal__entry"},[e.createElementVNode("div",$k,[e.createElementVNode("span",Vk,e.toDisplayString(t.prompt),1),e.createElementVNode("span",Ck,e.toDisplayString(g.command),1)]),g.response?(e.openBlock(),e.createElementBlock("div",xk,e.toDisplayString(g.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(f,["prevent"])},[e.createElementVNode("span",Nk,e.toDisplayString(t.prompt),1),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:n,"onUpdate:modelValue":b[0]||(b[0]=g=>d.value=g),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(m,["prevent"]),["down"])]},null,40,Sk),[[e.vModelText,d.value]])],32)]))}}),[["__scopeId","data-v-7db4de65"]]),Mk=["aria-busy"],Dk={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},zk=["viewBox","aria-label"],Lk=["x2","y1","y2"],Tk=["x","y"],Ik=["x","y","width","height","fill","onMouseenter"],Pk=["x","y","width","height","fill"],Rk=["stroke","points"],Fk=["cx","cy","fill","onMouseenter"],Ak=["cx","cy"],jk=["transform"],Kk=["d","fill","onMouseenter"],Ok=["d","fill"],Uk={key:0,class:"mfs-chart__legend mfs-flex mfs-flex-wrap mfs-gap-3 mfs-justify-center"},se=480,fe=24,Fe=24,re=20,pe=30,kl=L(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 s=t,l=e.computed(()=>{var $;return(($=s.data)==null?void 0:$.labels)??[]}),o=e.computed(()=>{var $;return(($=s.data)==null?void 0:$.datasets)??[]}),a=e.computed(()=>o.value.length===0?!0:o.value.every($=>!$.data||$.data.length===0)),r=e.computed(()=>s.height),i=Math.random().toString(36).slice(2,8),c=`mfs-chart-clay-${i}`,d=`mfs-chart-clay-pt-${i}`,n=`mfs-chart-clay-gloss-${i}`,k={"--mfs-clay-filter":`url(#${c})`,"--mfs-clay-point-filter":`url(#${d})`},h=["#8b5cf6","#06b6d4","#10b981","#f59e0b","#f43f5e","#38bdf8"],y=e.ref(null),f=e.computed(()=>{const $=o.value.flatMap(V=>V.data);return Math.max(1,...$)}),p=$=>{const V=Math.max(1,l.value.length),E=se-fe-Fe;return V===1?fe+E/2:fe+E*($+.5)/V},m=$=>{const V=r.value-re-pe;return re+V-$/f.value*V},u=e.computed(()=>{const $=Math.max(1,l.value.length),V=Math.max(1,o.value.length),E=(se-fe-Fe)/$;return Math.max(6,Math.min(34,E*.68/V))}),b=($,V)=>{const E=Math.max(1,o.value.length),C=E*u.value+(E-1)*4;return p($)-C/2+V*(u.value+4)},g=$=>$.map((V,E)=>`${p(E)},${m(V)}`).join(" "),B=e.computed(()=>{const $=o.value[0];if(!$)return[];const V=$.data.reduce((N,F)=>N+Math.max(0,F),0)||1,E=Math.min(se,r.value)*.4,C=s.type==="doughnut"?E*.55:0;let S=-Math.PI/2;return $.data.map((N,F)=>{const H=Math.max(0,N)/V*Math.PI*2,z=S+H,j=H>Math.PI?1:0,W=Math.cos(S)*E,T=Math.sin(S)*E,K=Math.cos(z)*E,P=Math.sin(z)*E;let I="";if(C>0){const M=Math.cos(z)*C,R=Math.sin(z)*C,D=Math.cos(S)*C,O=Math.sin(S)*C;I=`M ${W} ${T} A ${E} ${E} 0 ${j} 1 ${K} ${P} L ${M} ${R} A ${C} ${C} 0 ${j} 0 ${D} ${O} Z`}else I=`M 0 0 L ${W} ${T} A ${E} ${E} 0 ${j} 1 ${K} ${P} Z`;return S=z,{d:I,value:N,label:l.value[F]??`Item ${F+1}`,color:h[F%h.length]}})}),w=e.computed(()=>s.type==="pie"||s.type==="doughnut"?l.value.map(($,V)=>({label:$,color:h[V%h.length]})):o.value.map(($,V)=>({label:$.label??`Series ${V+1}`,color:$.color??h[V%h.length]}))),_=($,V)=>{const E=$.currentTarget.closest(".mfs-chart__canvas");if(!E)return;const C=E.getBoundingClientRect();y.value={x:$.clientX-C.left+10,y:$.clientY-C.top-28,text:V}};return($,V)=>(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:k,"aria-busy":t.loading||void 0},[e.createElementVNode("div",{class:"mfs-chart__canvas mfs-relative mfs-w-full",style:e.normalizeStyle(t.loading&&a.value?{minHeight:`${t.height}px`}:void 0)},[t.loading?(e.openBlock(),e.createElementBlock("div",Dk,[e.renderSlot($.$slots,"loading",{},()=>[V[3]||(V[3]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&a.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"mfs-empty-state",style:e.normalizeStyle({minHeight:`${t.height}px`})},[e.renderSlot($.$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 ${se} ${r.value}`,role:"img","aria-label":`${t.type} chart`},[e.createElementVNode("defs",null,[e.createElementVNode("filter",{id:c,x:"-25%",y:"-25%",width:"150%",height:"150%"},[...V[4]||(V[4]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="3.5" result="dropBlur" data-v-20ce0a30></feGaussianBlur><feOffset dx="2" dy="5" in="dropBlur" result="dropOffset" data-v-20ce0a30></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.24" result="dropColor" data-v-20ce0a30></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-20ce0a30></feComposite><feOffset dx="2" dy="2.5" in="SourceAlpha" result="hlOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="2" in="hlOffset" result="hlBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.72" result="hlColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-20ce0a30></feComposite><feOffset dx="-2" dy="-2.5" in="SourceAlpha" result="shOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="2.2" in="shOffset" result="shBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.28" result="shColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-20ce0a30></feComposite><feMerge data-v-20ce0a30><feMergeNode in="dropShadow" data-v-20ce0a30></feMergeNode><feMergeNode in="SourceGraphic" data-v-20ce0a30></feMergeNode><feMergeNode in="innerShade" data-v-20ce0a30></feMergeNode><feMergeNode in="innerHighlight" data-v-20ce0a30></feMergeNode></feMerge>',15)])]),e.createElementVNode("filter",{id:d,x:"-40%",y:"-40%",width:"180%",height:"180%"},[...V[5]||(V[5]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="2" result="dropBlur" data-v-20ce0a30></feGaussianBlur><feOffset dx="1.5" dy="2.5" in="dropBlur" result="dropOffset" data-v-20ce0a30></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.26" result="dropColor" data-v-20ce0a30></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-20ce0a30></feComposite><feOffset dx="1.2" dy="1.4" in="SourceAlpha" result="hlOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="1.1" in="hlOffset" result="hlBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.8" result="hlColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-20ce0a30></feComposite><feOffset dx="-1.2" dy="-1.4" in="SourceAlpha" result="shOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="1.2" in="shOffset" result="shBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.3" result="shColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-20ce0a30></feComposite><feMerge data-v-20ce0a30><feMergeNode in="dropShadow" data-v-20ce0a30></feMergeNode><feMergeNode in="SourceGraphic" data-v-20ce0a30></feMergeNode><feMergeNode in="innerShade" data-v-20ce0a30></feMergeNode><feMergeNode in="innerHighlight" data-v-20ce0a30></feMergeNode></feMerge>',15)])]),e.createElementVNode("linearGradient",{id:n,x1:"0%",y1:"0%",x2:"0%",y2:"100%"},[...V[6]||(V[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:fe,x2:se-Fe,y1:re+(r.value-re-pe)*(E-1)/3,y2:re+(r.value-re-pe)*(E-1)/3,class:"mfs-chart__grid"},null,8,Lk)),64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(E,C)=>(e.openBlock(),e.createElementBlock("text",{key:C,x:p(C),y:r.value-8,"text-anchor":"middle",class:"mfs-chart__label"},e.toDisplayString(E),9,Tk))),128))],64)):e.createCommentVNode("",!0),t.type==="bar"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(o.value,(E,C)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:C},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(S,N)=>(e.openBlock(),e.createElementBlock("g",{key:N},[e.createElementVNode("rect",{x:b(N,C),y:m(S),width:u.value,height:Math.max(2,r.value-pe-m(S)),fill:E.color||h[C%h.length],rx:"4",class:"mfs-chart__bar",onMouseenter:F=>_(F,`${l.value[N]??N}: ${S}`),onMouseleave:V[0]||(V[0]=F=>y.value=null)},null,40,Ik),e.createElementVNode("rect",{x:b(N,C)+2,y:m(S)+2,width:Math.max(0,u.value-4),height:Math.max(0,Math.min(14,(r.value-pe-m(S))*.45)),fill:`url(#${n})`,rx:"4",class:"mfs-chart__clay-gloss"},null,8,Pk)]))),128))],64))),128)):t.type==="line"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(o.value,(E,C)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:C},[e.createElementVNode("polyline",{fill:"none",stroke:E.color||h[C%h.length],"stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round",points:g(E.data),class:"mfs-chart__line"},null,8,Rk),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(S,N)=>(e.openBlock(),e.createElementBlock("g",{key:N},[e.createElementVNode("circle",{cx:p(N),cy:m(S),r:"5",fill:E.color||h[C%h.length],class:"mfs-chart__point",onMouseenter:F=>_(F,`${l.value[N]??N}: ${S}`),onMouseleave:V[1]||(V[1]=F=>y.value=null)},null,40,Fk),e.createElementVNode("circle",{cx:p(N)-1.5,cy:m(S)-1.5,r:"1.6",fill:"var(--bevel-light, currentColor)","fill-opacity":"0.7",class:"mfs-chart__clay-gloss"},null,8,Ak)]))),128))],64))),128)):(e.openBlock(),e.createElementBlock("g",{key:3,transform:`translate(${se/2}, ${r.value/2})`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,C)=>(e.openBlock(),e.createElementBlock("path",{key:C,d:E.d,fill:E.color,class:"mfs-chart__slice",onMouseenter:S=>_(S,`${E.label}: ${E.value}`),onMouseleave:V[2]||(V[2]=S=>y.value=null)},null,40,Kk))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,C)=>(e.openBlock(),e.createElementBlock("path",{key:`gloss-${C}`,d:E.d,fill:`url(#${n})`,class:"mfs-chart__clay-gloss"},null,8,Ok))),128))],8,jk))],8,zk)),y.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:`${y.value.x}px`,top:`${y.value.y}px`})},e.toDisplayString(y.value.text),5)):e.createCommentVNode("",!0)],4),!a.value&&w.value.length>0?(e.openBlock(),e.createElementBlock("div",Uk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(E,C)=>(e.openBlock(),e.createElementBlock("span",{key:C,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,Mk))}}),[["__scopeId","data-v-20ce0a30"]]),hl=L(e.defineComponent({__name:"AvatarGroup",props:{max:{},size:{default:"md"},items:{}},setup(t){const s=t,l=e.computed(()=>s.items?s.max!==void 0&&s.max>=0&&s.items.length>s.max?s.items.slice(0,s.max):s.items:[]),o=e.computed(()=>!s.items||s.max===void 0||s.max<0?0:Math.max(0,s.items.length-s.max));return(a,r)=>{var i;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"},[(i=t.items)!=null&&i.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(c,d)=>(e.openBlock(),e.createBlock(ye,{key:d,src:c.src,label:c.label,size:t.size},null,8,["src","label","size"]))),128)),o.value>0?(e.openBlock(),e.createBlock(ye,{key:0,size:t.size,label:`+${o.value} more`,class:"mfs-avatar-group__overflow"},{default:e.withCtx(()=>[e.createTextVNode(" +"+e.toDisplayString(o.value),1)]),_:1},8,["size","label"])):e.createCommentVNode("",!0)],64)):e.renderSlot(a.$slots,"default",{},void 0,!0,1)],2)}}}),[["__scopeId","data-v-865c01f7"]]),Hk={class:"mfs-overlay-badge mfs-relative mfs-inline-flex"},gl=L(e.defineComponent({__name:"OverlayBadge",props:{value:{},variant:{default:"primary"},size:{default:"sm"}},setup(t){const s=t,l=e.computed(()=>s.value!==void 0&&s.value!=="");return(o,a)=>(e.openBlock(),e.createElementBlock("span",Hk,[e.renderSlot(o.$slots,"default",{},void 0,!0),l.value?(e.openBlock(),e.createBlock(Le,{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"]]),Wk=["src","alt"],Gk=["src","alt"],qk=["value"],yl=L(e.defineComponent({__name:"ImageCompare",props:{leftSrc:{},rightSrc:{},leftAlt:{default:"Before image"},rightAlt:{default:"After image"},modelValue:{default:50}},emits:["update:modelValue"],setup(t,{emit:s}){const l=t,o=s,a=p=>Math.min(100,Math.max(0,p)),r=e.ref(null),i=e.ref(a(l.modelValue)),c=e.ref(!1);e.watch(()=>l.modelValue,p=>{i.value=a(p)});const d=p=>{const m=Math.round(a(p)*10)/10;i.value=m,o("update:modelValue",m)},n=p=>{const m=r.value;if(!m)return;const u=m.getBoundingClientRect();if(u.width<=0)return;const b=(p-u.left)/u.width*100;d(b)},k=p=>{var m,u;c.value=!0,(u=(m=p.currentTarget)==null?void 0:m.setPointerCapture)==null||u.call(m,p.pointerId),n(p.clientX)},h=p=>{c.value&&n(p.clientX)},y=p=>{var m,u;c.value&&(c.value=!1,(u=(m=p.currentTarget)==null?void 0:m.releasePointerCapture)==null||u.call(m,p.pointerId))},f=p=>{const m=p.target;d(Number(m.value))};return(p,m)=>(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:k,onPointermove:h,onPointerup:y,onPointercancel:y},[e.createElementVNode("img",{src:t.rightSrc,alt:t.rightAlt,class:"mfs-image-compare__img mfs-w-full mfs-h-full",draggable:"false"},null,8,Wk),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-i.value}% 0 0)`}),draggable:"false"},null,12,Gk),e.createElementVNode("div",{class:"mfs-image-compare__divider mfs-absolute",style:e.normalizeStyle({left:`${i.value}%`}),"aria-hidden":"true"},[...m[0]||(m[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:i.value,class:"mfs-image-compare__range mfs-sr-only","aria-label":"Image comparison slider",onInput:f},null,40,qk)],544))}}),[["__scopeId","data-v-0e55644e"]]),bl=e.defineComponent({__name:"Portal",props:{appendTo:{default:"body"},disabled:{type:Boolean,default:!1}},setup(t){return(s,l)=>(e.openBlock(),e.createBlock(e.Teleport,{to:t.appendTo,disabled:t.disabled},[e.renderSlot(s.$slots,"default")],8,["to","disabled"]))}}),Yk=["for"],Xk=["id","placeholder","disabled","aria-invalid"],Zk={key:1,class:"mfs-chips-msg mfs-text-danger"},Jk={key:2,class:"mfs-chips-msg mfs-caption"},Se=L(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:s}){const l=t,o=s,a=e.useId(),r=e.ref(null),i=e.ref(""),c=e.computed(()=>l.max!==void 0&&l.modelValue.length>=l.max),d=()=>{var p;l.disabled||(p=r.value)==null||p.focus()},n=p=>{if(l.disabled)return;const m=l.separator?p.split(l.separator):[p],u=[...l.modelValue],b=[];for(const g of m){const B=g.trim();if(B){if(l.max!==void 0&&u.length>=l.max)break;!l.allowDuplicate&&u.includes(B)||(u.push(B),b.push(B))}}if(b.length>0){o("update:modelValue",u);for(const g of b)o("add",g)}i.value=""},k=p=>{if(l.disabled)return;const m=l.modelValue[p];if(m===void 0)return;const u=l.modelValue.filter((b,g)=>g!==p);o("update:modelValue",u),o("remove",m)},h=p=>{if(!l.disabled){if(p.key==="Enter"||l.separator&&p.key===l.separator){p.preventDefault(),i.value.trim()&&n(i.value);return}p.key==="Backspace"&&i.value===""&&l.modelValue.length>0&&(p.preventDefault(),k(l.modelValue.length-1))}},y=()=>{l.separator&&i.value.includes(l.separator)&&n(i.value)},f=()=>{i.value.trim()&&n(i.value)};return(p,m)=>(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(a),class:"mfs-chips-label mfs-text"},e.toDisplayString(t.label),9,Yk)):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:d},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(u,b)=>(e.openBlock(),e.createBlock(de,{key:`${u}-${b}`,label:u,removable:!t.disabled,onRemove:g=>k(b)},null,8,["label","removable","onRemove"]))),128)),e.withDirectives(e.createElementVNode("input",{id:e.unref(a),ref_key:"inputRef",ref:r,"onUpdate:modelValue":m[0]||(m[0]=u=>i.value=u),type:"text",class:"mfs-chips-input mfs-text",placeholder:c.value?"":t.placeholder,disabled:t.disabled||c.value,"aria-invalid":t.invalid||!!t.error||void 0,onKeydown:h,onInput:y,onBlur:f},null,40,Xk),[[e.vModelText,i.value]])],2),t.error?(e.openBlock(),e.createElementBlock("p",Zk,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Jk,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-0e7176f9"]]),Qk=["aria-invalid"],vk=Symbol("CheckboxGroup"),Bl=L(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:s}){const l=t,o=s,a=i=>{if(l.disabled)return;const d=l.modelValue.includes(i)?l.modelValue.filter(n=>n!==i):[...l.modelValue,i];o("update:modelValue",d),o("change",d)},r=i=>{l.disabled||!Array.isArray(i)||(o("update:modelValue",i),o("change",i))};return e.provide(vk,{modelValue:e.computed(()=>l.modelValue),name:e.computed(()=>l.name),disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),toggleValue:a}),(i,c)=>(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(i.$slots,t.name,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,toggleValue:a},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(d,n)=>(e.openBlock(),e.createBlock(ne,{key:n,"model-value":t.modelValue,value:d.value,label:d.label,disabled:t.disabled||d.disabled,"onUpdate:modelValue":r},null,8,["model-value","value","label","disabled"]))),128))],!0)],10,Qk))}}),[["__scopeId","data-v-bde4c6e4"]]),eh=["aria-invalid"],th=Symbol("RadioButtonGroup"),_l=L(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:s}){const l=t,o=s,a=`mfs-radio-group-${e.useId()}`,r=e.computed(()=>l.name||a),i=c=>{l.disabled||(o("update:modelValue",c),o("change",c))};return e.provide(th,{modelValue:e.computed(()=>l.modelValue),name:r,disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),selectValue:i}),(c,d)=>(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(c.$slots,r.value,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,selectValue:i},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(n,k)=>(e.openBlock(),e.createBlock(Te,{key:k,"model-value":t.modelValue,value:n.value,name:r.value,label:n.label,disabled:t.disabled||n.disabled,"onUpdate:modelValue":i},null,8,["model-value","value","name","label","disabled"]))),128))],!0)],10,eh))}}),[["__scopeId","data-v-2e9ea155"]]),te=e.ref([]);let lh=1;function oh(t,s={}){const l=`mfs-dialog-${lh++}`;return te.value=[...te.value,{id:l,component:e.markRaw(t),options:s}],l}function nh(t,s){var a,r;const l=te.value.findIndex(i=>i.id===t);if(l===-1)return;const o=te.value[l];te.value=te.value.filter(i=>i.id!==t),(r=(a=o.options).onClose)==null||r.call(a,s)}function wl(){return{dialogs:e.readonly(te),open:oh,close:nh}}const El=e.defineComponent({__name:"DynamicDialog",setup(t){const{dialogs:s,close:l}=wl(),o=e.defineComponent({name:"MfsDynamicDialogContent",props:{component:{type:Object,required:!0},componentProps:{type:Object,default:()=>({})},onClose:{type:Function,required:!0}},setup(a){const r={close:i=>a.onClose(i)};return e.provide("dialogRef",r),()=>e.h(a.component,a.componentProps)}});return(a,r)=>(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(s),i=>(e.openBlock(),e.createBlock(oe,{key:i.id,"model-value":!0,title:i.options.header,"onUpdate:modelValue":c=>!c&&e.unref(l)(i.id)},{default:e.withCtx(()=>[e.createElementVNode("div",{style:e.normalizeStyle(i.options.width?{width:i.options.width,maxWidth:"100%"}:void 0)},[e.createVNode(e.unref(o),{component:i.component,"component-props":i.options.props,"on-close":c=>e.unref(l)(i.id,c)},null,8,["component","component-props","on-close"])],4)]),_:2},1032,["title","onUpdate:modelValue"]))),128))}}),ah={class:"cmd-header mfs-flex mfs-items-center mfs-gap-2 mfs-border-b"},sh=["placeholder"],rh={key:0,class:"mfs-spinner mfs-spinner--sm",role:"status","aria-label":"Loading"},ih={key:1,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},dh={key:0,class:"mfs-empty-state"},ch={key:1,class:"mfs-empty-state"},mh={key:0,class:"cmd-group-label mfs-text-muted"},fh=["aria-selected","aria-disabled","disabled","onMouseenter","onClick"],ph={class:"cmd-item-main mfs-flex mfs-flex-col"},uh={class:"cmd-item-label"},kh={key:0,class:"cmd-item-desc mfs-text-muted"},hh={key:0,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},$l=L(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:s}){const l=t,o=s,a=e.ref(""),r=e.ref(-1),i=e.ref(null),c=e.ref(null),d=new Map,n=(_,$)=>{$?d.set(_,$):d.delete(_)},k=e.computed(()=>{if(l.remote)return l.items;const _=a.value.trim().toLowerCase();return _?l.items.filter($=>$.label.toLowerCase().includes(_)||$.description&&$.description.toLowerCase().includes(_)||$.group&&$.group.toLowerCase().includes(_)):l.items}),h=e.computed(()=>{const _=new Map;let $=0;for(const V of k.value){const E=V.group??"";_.has(E)||_.set(E,[]),_.get(E).push({item:V,flatIndex:$++})}return Array.from(_.entries()).map(([V,E])=>({group:V,entries:E}))}),y=e.computed(()=>h.value.flatMap(_=>_.entries.map($=>$.item))),f=_=>_.findIndex($=>!$.disabled);e.watch(y,_=>{d.clear(),r.value=f(_)},{immediate:!0});const p=()=>{o("update:modelValue",!1)},m=()=>{o("search",a.value)},u=(_,$)=>{$.disabled||(r.value=_)},b=_=>{_.disabled||(o("select",_),p())},g=_=>{var C;const $=y.value,V=$.length;if(V===0)return;let E=r.value;for(let S=0;S<V;S++)if(E=(E+_+V)%V,!((C=$[E])!=null&&C.disabled)){r.value=E,e.nextTick(()=>{var N;(N=d.get(E))==null||N.scrollIntoView({block:"nearest"})});return}},B=_=>{if(_.key==="ArrowDown")_.preventDefault(),g(1);else if(_.key==="ArrowUp")_.preventDefault(),g(-1);else if(_.key==="Enter"){const $=y.value[r.value];$&&!$.disabled&&(_.preventDefault(),b($))}else _.key==="Escape"&&(_.preventDefault(),p())},w=_=>{l.shortcut&&(_.metaKey||_.ctrlKey)&&_.key.toLowerCase()==="k"&&(_.preventDefault(),o("update:modelValue",!l.modelValue))};return e.watch(()=>l.modelValue,async _=>{var $;_&&(a.value="",r.value=f(y.value),await e.nextTick(),($=i.value)==null||$.focus())}),e.onMounted(()=>{typeof window<"u"&&window.addEventListener("keydown",w)}),e.onBeforeUnmount(()=>{typeof window<"u"&&window.removeEventListener("keydown",w)}),(_,$)=>(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:$[1]||($[1]=e.withModifiers(()=>{},["stop"])),onKeydown:B},[e.createElementVNode("div",ah,[$[2]||($[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:i,"onUpdate:modelValue":$[0]||($[0]=V=>a.value=V),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:m},null,40,sh),[[e.vModelText,a.value]]),t.loading?(e.openBlock(),e.createElementBlock("span",rh)):(e.openBlock(),e.createElementBlock("kbd",ih,"ESC"))]),e.createElementVNode("div",{ref_key:"listRef",ref:c,class:"cmd-list",role:"listbox"},[t.loading&&y.value.length===0?(e.openBlock(),e.createElementBlock("div",dh,[...$[3]||($[3]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-label":"Loading"},null,-1)])])):y.value.length===0?(e.openBlock(),e.createElementBlock("div",ch,[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(h.value,V=>(e.openBlock(),e.createElementBlock("div",{key:V.group,class:"cmd-group",role:"group"},[V.group?(e.openBlock(),e.createElementBlock("div",mh,e.toDisplayString(V.group),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V.entries,E=>(e.openBlock(),e.createElementBlock("button",{key:E.item.id,ref_for:!0,ref:C=>n(E.flatIndex,C),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:C=>u(E.flatIndex,E.item),onClick:C=>b(E.item)},[e.createElementVNode("div",ph,[e.createElementVNode("span",uh,e.toDisplayString(E.item.label),1),E.item.description?(e.openBlock(),e.createElementBlock("span",kh,e.toDisplayString(E.item.description),1)):e.createCommentVNode("",!0)]),E.item.shortcut?(e.openBlock(),e.createElementBlock("kbd",hh,e.toDisplayString(E.item.shortcut),1)):e.createCommentVNode("",!0)],42,fh))),128))]))),128))],512)],32)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-a0f21f67"]]),gh={class:"infinite-scroll mfs-flex mfs-flex-col"},yh={key:0,class:"mfs-empty-state"},bh={key:1,class:"infinite-scroll__status mfs-flex mfs-items-center mfs-justify-center mfs-p-4",role:"status","aria-live":"polite"},Bh={key:2,class:"mfs-soft-danger mfs-rounded mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-p-3",role:"alert"},_h={class:"mfs-text-sm mfs-font-medium"},wh={key:3,class:"mfs-text-sm mfs-text-muted mfs-text-center mfs-p-4"},Vl=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:s}){const l=t,o=s,a=e.ref(null);let r=null;const i=()=>{o("load")},c=()=>l.hasMore&&!l.loading&&!l.error,d=()=>{r==null||r.disconnect(),r=null,!(typeof IntersectionObserver>"u"||!a.value)&&(r=new IntersectionObserver(n=>{n.some(k=>k.isIntersecting)&&c()&&i()},{rootMargin:l.rootMargin}),r.observe(a.value))};return e.watch(()=>l.rootMargin,d),e.onMounted(()=>{d()}),e.onBeforeUnmount(()=>{r==null||r.disconnect(),r=null}),(n,k)=>(e.openBlock(),e.createElementBlock("div",gh,[e.renderSlot(n.$slots,"default"),t.isEmpty&&!t.loading&&!t.error?(e.openBlock(),e.createElementBlock("div",yh,[e.renderSlot(n.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",bh,[e.renderSlot(n.$slots,"loading",{},()=>[k[0]||(k[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))])])):t.error?(e.openBlock(),e.createElementBlock("div",Bh,[e.renderSlot(n.$slots,"error",{error:t.error,retry:i},()=>[e.createElementVNode("span",_h,e.toDisplayString(t.error),1),e.createVNode(ie,{size:"sm",variant:"danger",onClick:i},{default:e.withCtx(()=>[...k[1]||(k[1]=[e.createTextVNode("Retry",-1)])]),_:1})])])):!t.hasMore&&!t.isEmpty?(e.openBlock(),e.createElementBlock("div",wh,[e.renderSlot(n.$slots,"finished",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.finishedText),1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"sentinelRef",ref:a,class:"mfs-w-full mfs-h-px mfs-pointer-events-none","aria-hidden":"true"},null,512)]))}}),Eh=["value","placeholder","rows","disabled","aria-expanded"],$h={key:0,class:"mfs-mentions__loading mfs-flex mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-3"},Vh={key:1,class:"mfs-mentions__list"},Ch=["aria-selected","onMousedown","onMouseenter"],xh={class:"mfs-mentions__label mfs-text mfs-text-sm mfs-font-medium"},Nh={key:0,class:"mfs-mentions__desc mfs-text-muted mfs-text-xs"},Sh={key:2,class:"mfs-empty-state",role:"status"},Cl=L(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(0),k=e.ref(""),h=e.ref(-1),y=e.ref(""),{overlayStyle:f,containsTarget:p}=J(r,i,d,{matchWidth:!0}),m=e.computed(()=>{if(l.remote)return l.options;const V=y.value.trim().toLowerCase();return V?l.options.filter(E=>{var C;return E.label.toLowerCase().includes(V)||E.value.toLowerCase().includes(V)||(((C=E.description)==null?void 0:C.toLowerCase().includes(V))??!1)}):l.options});e.watch(m,V=>{V.length===0?n.value=-1:(n.value<0||n.value>=V.length)&&(n.value=0)});const u=(V,E)=>{const C=V.slice(0,E),S=[...l.triggers].filter(Boolean).sort((N,F)=>F.length-N.length);if(!S.length)return null;for(let N=C.length-1;N>=0;N--){const F=C[N];if(/\s/.test(F))return null;for(const H of S){const z=N-H.length+1;if(!(z<0)&&C.slice(z,N+1)===H){const j=z===0?"":C[z-1];if(z===0||/\s/.test(j))return{trigger:H,start:z,query:C.slice(N+1)}}}}return null},b=()=>{const V=c.value;if(!V||l.disabled){d.value=!1;return}const E=V.selectionStart??(l.modelValue??"").length,C=u(V.value,E);C?(k.value=C.trigger,h.value=C.start,y.value=C.query,d.value=!0,n.value=m.value.length?0:-1,o("search",{trigger:C.trigger,query:C.query})):(d.value=!1,k.value="",h.value=-1,y.value="")},g=V=>{const E=V.target;o("update:modelValue",E.value),b()},B=V=>{["ArrowUp","ArrowDown","Enter","Escape"].includes(V.key)||b()},w=V=>{const E=c.value,C=E?E.value:l.modelValue??"",S=(E==null?void 0:E.selectionStart)??C.length,N=h.value>=0?h.value:S,F=`${k.value}${V.value} `,H=C.slice(0,N)+F+C.slice(S),z=N+F.length;o("update:modelValue",H),o("select",V),d.value=!1,k.value="",h.value=-1,y.value="",e.nextTick(()=>{c.value&&(c.value.focus(),c.value.setSelectionRange(z,z))})},_=V=>{if(!d.value)return;const E=m.value.length;if(V.key==="Escape")V.preventDefault(),d.value=!1;else if(V.key==="ArrowDown")V.preventDefault(),E>0&&(n.value=(n.value+1)%E);else if(V.key==="ArrowUp")V.preventDefault(),E>0&&(n.value=(n.value-1+E)%E);else if(V.key==="Enter"&&E>0&&n.value>=0){V.preventDefault();const C=m.value[n.value];C&&w(C)}},$=V=>{p(V.target)||(d.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",$)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",$)),(V,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:a,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:c,value:t.modelValue,placeholder:t.placeholder,rows:t.rows,disabled:t.disabled,role:"combobox","aria-autocomplete":"list","aria-expanded":d.value,class:"mfs-mentions__textarea mfs-w-full mfs-border-none mfs-text",onInput:g,onClick:b,onKeyup:B,onKeydown:_},null,40,Eh)],512),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-mentions-pop"},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:i,style:e.normalizeStyle(e.unref(f)),role:"listbox",class:"mfs-mentions__dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading?(e.openBlock(),e.createElementBlock("div",$h,[...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)])])):m.value.length?(e.openBlock(),e.createElementBlock("ul",Vh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(C,S)=>(e.openBlock(),e.createElementBlock("li",{key:`${C.value}-${S}`,role:"option","aria-selected":S===n.value,class:e.normalizeClass(["mfs-mentions__option mfs-flex mfs-flex-col mfs-rounded-sm mfs-cursor-pointer",{"mfs-mentions__option--active":S===n.value}]),onMousedown:e.withModifiers(N=>w(C),["prevent"]),onMouseenter:N=>n.value=S},[e.createElementVNode("span",xh,e.toDisplayString(C.label),1),C.description?(e.openBlock(),e.createElementBlock("span",Nh,e.toDisplayString(C.description),1)):e.createCommentVNode("",!0)],42,Ch))),128))])):(e.openBlock(),e.createElementBlock("div",Sh,[e.renderSlot(V.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)]))],4)):e.createCommentVNode("",!0)]),_:3})]))],2))}}),[["__scopeId","data-v-b46fcff1"]]),Mh={class:"mfs-signature__stage mfs-inset mfs-rounded-sm mfs-relative"},Dh=["width","height"],zh={key:0,class:"mfs-signature__hint mfs-text-muted mfs-text-sm mfs-select-none"},Lh={class:"mfs-signature__actions mfs-flex mfs-items-center mfs-justify-end mfs-gap-2"},xl=L(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:s,emit:l}){const o=t,a=l,r=e.ref(null),i=e.ref(!1),c=e.ref(!0),d=()=>{var g;return((g=r.value)==null?void 0:g.getContext("2d"))??null},n=g=>{if(o.penColor&&o.penColor!=="currentColor")return o.penColor;if(typeof window<"u"){const B=window.getComputedStyle(g).color;if(B)return B}return"#0f172a"},k=g=>{const B=r.value,w=B.getBoundingClientRect(),_=w.width>0?B.width/w.width:1,$=w.height>0?B.height/w.height:1;return{x:(g.clientX-w.left)*_,y:(g.clientY-w.top)*$}},h=g=>{var $;if(o.disabled)return;const B=r.value,w=d();if(!B||!w)return;($=B.setPointerCapture)==null||$.call(B,g.pointerId);const _=k(g);w.strokeStyle=n(B),w.lineWidth=o.lineWidth,w.lineCap="round",w.lineJoin="round",w.beginPath(),w.moveTo(_.x,_.y),w.lineTo(_.x+.01,_.y+.01),w.stroke(),i.value=!0,c.value=!1},y=g=>{if(!i.value||o.disabled)return;const B=d();if(!B)return;const w=k(g);B.lineTo(w.x,w.y),B.stroke()},f=g=>{var w;if(!i.value)return;const B=r.value;(w=B==null?void 0:B.hasPointerCapture)!=null&&w.call(B,g.pointerId)&&B.releasePointerCapture(g.pointerId),i.value=!1},p=()=>c.value,m=()=>{const g=r.value,B=d();g&&B&&B.clearRect(0,0,g.width,g.height),i.value=!1,c.value=!0,a("update:modelValue",null),a("change",{blob:null,dataUrl:null,file:null})},u=()=>{const g=r.value;if(!g||c.value){const w={blob:null,dataUrl:null,file:null};return a("update:modelValue",null),a("change",w),Promise.resolve(w)}const B=g.toDataURL(o.outputType);return new Promise(w=>{g.toBlob(_=>{const $=_?new File([_],o.fileName,{type:o.outputType}):null,V={blob:_,dataUrl:B,file:$};a("update:modelValue",B),a("change",V),w(V)},o.outputType)})},b=g=>{const B=r.value,w=d();if(!B||!w)return;if(w.clearRect(0,0,B.width,B.height),!g){c.value=!0;return}const _=new Image;_.onload=()=>{w.clearRect(0,0,B.width,B.height),w.drawImage(_,0,0,B.width,B.height),c.value=!1},_.src=g};return e.watch(()=>o.modelValue,g=>{if(g)r.value&&r.value.toDataURL(o.outputType)!==g&&b(g);else{const B=r.value,w=d();B&&w&&w.clearRect(0,0,B.width,B.height),c.value=!0}}),e.onMounted(()=>{o.modelValue&&b(o.modelValue)}),s({clear:m,isEmpty:p,exportSignature:u}),(g,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",Mh,[e.createElementVNode("canvas",{ref_key:"canvasRef",ref:r,width:t.width,height:t.height,class:"mfs-signature__canvas mfs-w-full",onPointerdown:h,onPointermove:y,onPointerup:f,onPointercancel:f,onPointerleave:f},null,40,Dh),c.value?(e.openBlock(),e.createElementBlock("span",zh," Sign here ")):e.createCommentVNode("",!0)]),e.createElementVNode("div",Lh,[e.createVNode(ie,{variant:"surface",size:"sm",disabled:t.disabled||c.value,onClick:m},{default:e.withCtx(()=>[...B[0]||(B[0]=[e.createTextVNode(" Clear ",-1)])]),_:1},8,["disabled"]),e.createVNode(ie,{variant:"primary",size:"sm",disabled:t.disabled||c.value,onClick:u},{default:e.withCtx(()=>[...B[1]||(B[1]=[e.createTextVNode(" Save ",-1)])]),_:1},8,["disabled"])])],2))}}),[["__scopeId","data-v-7b44dca2"]]),Nl=e.defineComponent({__name:"Form",props:{initialValues:{},errors:{},resolver:{},submitting:{type:Boolean,default:!1},validateOnSubmit:{type:Boolean,default:!0}},emits:["submit","reset"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.reactive({...o.initialValues??{}}),i=e.reactive({}),c=m=>{for(const u of Object.keys(i))delete i[u];for(const[u,b]of Object.entries(m))(Array.isArray(b)?b.length>0:b)&&(i[u]=b)};e.watch(()=>o.errors,m=>{c(m??{})},{immediate:!0,deep:!0});const d=(m,u)=>{r[m]=u,m in i&&delete i[m]},n=(m,u)=>{(Array.isArray(u)?u.length>0:u)?i[m]=u:delete i[m]},k=m=>{if(m!==void 0){delete i[m];return}for(const u of Object.keys(i))delete i[u]},h=()=>{if(k(),!o.resolver)return!0;const m=o.resolver({...r});for(const[u,b]of Object.entries(m))b&&(i[u]=b);return Object.keys(i).length===0},y=()=>{const m=o.initialValues??{};for(const u of Object.keys(r))u in m||delete r[u];for(const[u,b]of Object.entries(m))r[u]=b;k(),a("reset")},f=()=>{const m={};for(const[u,b]of Object.entries(i)){const g=Array.isArray(b)?b[0]:b;g&&(m[u]=g)}return m},p=()=>{const m=o.validateOnSubmit?h():!0;a("submit",{values:{...r},valid:m,errors:f()})};return e.provide("mfsFormContext",{values:r,errors:i,submitting:e.computed(()=>o.submitting),setFieldValue:d,setFieldError:n,clearErrors:k,reset:y}),s({values:r,errors:i,validate:h,reset:y,setErrors:c}),(m,u)=>(e.openBlock(),e.createElementBlock("form",{class:"mfs-form mfs-flex mfs-flex-col mfs-gap-4",novalidate:"",onSubmit:e.withModifiers(p,["prevent"])},[e.renderSlot(m.$slots,"default",{values:r,errors:i,submitting:t.submitting,reset:y,validate:h})],32))}}),Th={class:"mfs-form-field mfs-flex mfs-flex-col mfs-gap-1-5"},Ih=["for"],Ph={key:0,class:"mfs-text-danger"},Rh={key:1,class:"mfs-form-field__msg mfs-text-danger mfs-text-xs mfs-font-medium mfs-m-0"},Fh={key:2,class:"mfs-form-field__msg mfs-caption mfs-m-0"},Sl=e.defineComponent({__name:"FormField",props:{name:{},label:{},hint:{},error:{},required:{type:Boolean,default:!1}},setup(t){const s=t,l=e.inject("mfsFormContext",null),o=e.computed(()=>l==null?void 0:l.values[s.name]),a=e.computed(()=>{if(s.error)return s.error;const i=l==null?void 0:l.errors[s.name];return Array.isArray(i)?i[0]||void 0:i||void 0}),r=i=>{l==null||l.setFieldValue(s.name,i)};return(i,c)=>(e.openBlock(),e.createElementBlock("div",Th,[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",Ph,"*")):e.createCommentVNode("",!0)],8,Ih)):e.createCommentVNode("",!0),e.renderSlot(i.$slots,"default",{value:o.value,error:a.value,setValue:r}),a.value?(e.openBlock(),e.createElementBlock("p",Rh,e.toDisplayString(a.value),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Fh,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)]))}}),Ae=[{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%)"}],je=Ae.map(t=>t.id),Ml=je.map(t=>`theme-${t}`),Me=e.ref("clay");let Dl=!1;const zl=t=>{if(typeof document>"u")return;const s=document.documentElement,l=document.body;s.classList.remove(...Ml),s.classList.add(`theme-${t}`),l==null||l.classList.remove(...Ml)};function Ll(){const t=l=>{if(Me.value=l,typeof document<"u"){const o=document.documentElement;o.getAttribute("data-theme")!==l&&o.setAttribute("data-theme",l),zl(l),localStorage.setItem("active-theme",l)}};return{currentTheme:Me,themeOptions:Ae,setTheme:t,initTheme:(l="clay")=>{if(typeof window<"u"){const o=localStorage.getItem("active-theme");o&&je.includes(o)?t(o):t(l),!Dl&&typeof MutationObserver<"u"&&(Dl=!0,new MutationObserver(()=>{const r=document.documentElement.getAttribute("data-theme");r&&je.includes(r)&&(Me.value!==r&&(Me.value=r),zl(r))}).observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}))}}}}let Ah=1;function jh(t,s={}){const l=s.id??`mfs-style-${Ah++}`,o=s.name,a=e.ref(!1);let r=null;function i(){if(typeof document>"u")return;const d=document.getElementById(l);if(d instanceof HTMLStyleElement){d.textContent=t,r=d,a.value=!0;return}const n=document.createElement("style");n.id=l,n.type="text/css",o&&n.setAttribute("data-mfs-style",o),n.textContent=t,document.head.appendChild(n),r=n,a.value=!0}function c(){if(typeof document>"u")return;const d=r??document.getElementById(l);d&&d.parentNode&&d.parentNode.removeChild(d),r=null,a.value=!1}return(s.immediate??!0)&&i(),e.getCurrentInstance()&&e.onUnmounted(c),{id:l,name:o,css:t,isLoaded:e.readonly(a),load:i,unload:c}}function Tl(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 Il={mounted(t,s){const l=Tl(s.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color;const o=getComputedStyle(t);o.position==="static"&&(t.style.position="relative"),o.overflow!=="hidden"&&(t.style.overflow="hidden");const a=r=>{if(t.__mfsRippleDisabled)return;const i=t.getBoundingClientRect(),c=Math.max(i.width,i.height)*2,d=r.clientX-i.left-c/2,n=r.clientY-i.top-c/2,k=document.createElement("span");k.style.position="absolute",k.style.width=`${c}px`,k.style.height=`${c}px`,k.style.left=`${d}px`,k.style.top=`${n}px`,k.style.borderRadius="50%",k.style.pointerEvents="none",k.style.backgroundColor=t.__mfsRippleColor??"currentColor",k.style.opacity="0.25",k.style.transform="scale(0)",t.appendChild(k);const h=k.animate([{transform:"scale(0)",opacity:.28},{transform:"scale(1)",opacity:0}],{duration:500,easing:"cubic-bezier(0.22, 1, 0.36, 1)"});h.onfinish=()=>k.remove()};t.__mfsRippleHandler=a,t.addEventListener("pointerdown",a)},updated(t,s){const l=Tl(s.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color},unmounted(t){t.__mfsRippleHandler&&(t.removeEventListener("pointerdown",t.__mfsRippleHandler),delete t.__mfsRippleHandler)}};function Kh(t){return t.right?"right":t.bottom?"bottom":t.left?"left":"top"}function Pl(t){const s=Kh(t.modifiers),l=t.value;return typeof l=="string"?{text:l,disabled:!1,placement:s}:l&&typeof l=="object"?{text:l.value??"",disabled:!!l.disabled,placement:s,customClass:l.class}:{text:"",disabled:!0,placement:s}}function Rl(t,s,l){const o=t.getBoundingClientRect(),a=s.getBoundingClientRect(),r=8;let i=0,c=0;switch(l){case"bottom":i=o.bottom+r,c=o.left+o.width/2-a.width/2;break;case"left":i=o.top+o.height/2-a.height/2,c=o.left-a.width-r;break;case"right":i=o.top+o.height/2-a.height/2,c=o.right+r;break;case"top":default:i=o.top-a.height-r,c=o.left+o.width/2-a.width/2;break}const d=Math.max(8,window.innerWidth-a.width-8),n=Math.max(8,window.innerHeight-a.height-8);s.style.top=`${Math.min(Math.max(8,i),n)}px`,s.style.left=`${Math.min(Math.max(8,c),d)}px`}function De(t){t.tipEl&&(t.tipEl.remove(),t.tipEl=void 0)}const Ke={mounted(t,s){const o={...Pl(s),show:()=>{if(o.disabled||!o.text)return;De(o);const a=document.createElement("div");a.setAttribute("role","tooltip"),a.textContent=o.text,o.customClass&&(a.className=o.customClass),Object.assign(a.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(a),Rl(t,a,o.placement),o.tipEl=a},hide:()=>De(o)};t.__mfsTooltipState=o,t.addEventListener("mouseenter",o.show),t.addEventListener("mouseleave",o.hide),t.addEventListener("focusin",o.show),t.addEventListener("focusout",o.hide)},updated(t,s){const l=t.__mfsTooltipState;if(!l)return;const o=Pl(s);l.text=o.text,l.disabled=o.disabled,l.placement=o.placement,l.customClass=o.customClass,l.disabled||!l.text?De(l):l.tipEl&&(l.tipEl.textContent=l.text,Rl(t,l.tipEl,l.placement))},unmounted(t){const s=t.__mfsTooltipState;s&&(t.removeEventListener("mouseenter",s.show),t.removeEventListener("mouseleave",s.hide),t.removeEventListener("focusin",s.show),t.removeEventListener("focusout",s.hide),De(s),delete t.__mfsTooltipState)}},Oh=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(",");function Fl(t){return Array.from(t.querySelectorAll(Oh)).filter(s=>s.offsetParent!==null||s===document.activeElement)}function Al(t){if(t.__mfsTrapActive)return;t.__mfsTrapActive=!0,t.__mfsPrevFocus=document.activeElement;const s=Fl(t);s.length>0&&s[0].focus();const l=o=>{if(o.key!=="Tab")return;const a=Fl(t);if(a.length===0){o.preventDefault();return}const r=a[0],i=a[a.length-1];o.shiftKey&&document.activeElement===r?(o.preventDefault(),i.focus()):!o.shiftKey&&document.activeElement===i&&(o.preventDefault(),r.focus())};t.__mfsFocusTrapHandler=l,t.addEventListener("keydown",l)}function jl(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 Kl={mounted(t,s){s.value!==!1&&Al(t)},updated(t,s){s.value===!1?jl(t):Al(t)},unmounted(t){jl(t)}},Uh=new Set(["fade-up","fade-down","fade-left","fade-right","zoom-in"]),Ol="cubic-bezier(0.22, 1, 0.36, 1)";function Hh(t){return typeof t=="string"&&Uh.has(t)}function Ul(t,s){switch(t){case"fade-down":return`translate3d(0, -${s}px, 0)`;case"fade-left":return`translate3d(${s}px, 0, 0)`;case"fade-right":return`translate3d(-${s}px, 0, 0)`;case"zoom-in":return"scale(0.92)";case"fade-up":default:return`translate3d(0, ${s}px, 0)`}}function Wh(t){return t==="zoom-in"?"scale(1)":"translate3d(0, 0, 0)"}const Hl={mounted(t,s){var p;if(typeof IntersectionObserver>"u")return;const l=typeof s.value=="string"?Hh(s.value)?{animation:s.value}:{enterClass:s.value}:s.value??{},o=l.enterClass===void 0,a=l.animation??"fade-up",r=l.duration??500,i=l.delay??0,c=l.distance??24,d=l.threshold??.1,n=l.once??!0,k=l.enterClass??"",h=l.leaveClass??"",y=typeof window<"u"&&((p=window.matchMedia)==null?void 0:p.call(window,"(prefers-reduced-motion: reduce)").matches);o&&!y&&(t.style.opacity="0",t.style.transform=Ul(a,c),t.style.transition=`opacity ${r}ms ${Ol} ${i}ms, transform ${r}ms ${Ol} ${i}ms`);const f=new IntersectionObserver(m=>{for(const u of m)u.isIntersecting?(h&&t.classList.remove(h),k&&t.classList.add(k),o&&(t.style.opacity="1",t.style.transform=Wh(a)),n&&f.unobserve(t)):n||(k&&t.classList.remove(k),h&&t.classList.add(h),o&&!y&&(t.style.opacity="0",t.style.transform=Ul(a,c)))},{threshold:d});t.__mfsAosObserver=f,f.observe(t)},unmounted(t){t.__mfsAosObserver&&(t.__mfsAosObserver.disconnect(),delete t.__mfsAosObserver)}};function Gh(t,s){var l;return!s||s==="@self"?t:s==="@next"?t.nextElementSibling:s==="@prev"?t.previousElementSibling:s==="@parent"?t.parentElement:s==="@grandparent"?((l=t.parentElement)==null?void 0:l.parentElement)??null:document.querySelector(s)}function Wl(t){return typeof t=="string"?{toggleClass:t}:t}const Gl={mounted(t,s){t.__mfsStyleClassOpts=Wl(s.value);const l=()=>{const o=t.__mfsStyleClassOpts;if(!o)return;const a=Gh(t,o.selector);a&&(o.toggleClass?o.toggleClass.split(/\s+/).filter(Boolean).forEach(r=>a.classList.toggle(r)):(o.leaveClass&&o.leaveClass.split(/\s+/).filter(Boolean).forEach(r=>a.classList.remove(r)),o.enterClass&&o.enterClass.split(/\s+/).filter(Boolean).forEach(r=>a.classList.add(r))))};t.__mfsStyleClassHandler=l,t.addEventListener("click",l)},updated(t,s){t.__mfsStyleClassOpts=Wl(s.value)},unmounted(t){t.__mfsStyleClassHandler&&(t.removeEventListener("click",t.__mfsStyleClassHandler),delete t.__mfsStyleClassHandler)}},ql={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 qh(t){const s=t.value;return s==null||s===""?null:typeof s=="string"||typeof s=="number"?{text:String(s),severity:"primary"}:typeof s=="object"?s.value===null||s.value===void 0||s.value===""?null:{text:String(s.value),severity:s.severity??"primary"}:null}function Yh(t,s){if(typeof window>"u")return;getComputedStyle(t).position==="static"&&(s.hadStaticPosition=!0,s.previousPosition=t.style.position,t.style.position="relative")}function Xh(){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 Yl(t,s,l){const o=qh(s);if(!o){l.badgeEl&&(l.badgeEl.remove(),l.badgeEl=void 0);return}Yh(t,l),l.badgeEl||(l.badgeEl=Xh(),t.appendChild(l.badgeEl));const a=ql[o.severity]??ql.primary;l.badgeEl.className=`mfs-badge mfs-pill mfs-bg-${o.severity}`,l.badgeEl.style.backgroundColor=a.bg,l.badgeEl.style.color=a.color,l.badgeEl.textContent=o.text}const Oe={mounted(t,s){const l={hadStaticPosition:!1,previousPosition:""};t.__mfsBadgeState=l,Yl(t,s,l)},updated(t,s){const l=t.__mfsBadgeState;l&&Yl(t,s,l)},unmounted(t){const s=t.__mfsBadgeState;s&&(s.badgeEl&&(s.badgeEl.remove(),s.badgeEl=void 0),s.hadStaticPosition&&(t.style.position=s.previousPosition),delete t.__mfsBadgeState)}},Zh=Oe,Xl={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 Ue(t,s){return(t.global||t.sticky)&&(t.lastIndex=0),t.test(s)}function Jh(t,s){if(!s)return!0;if(s instanceof RegExp)return Ue(s,t);const l=Xl[s];return l?l.charPattern.test(t):!0}function Qh(t,s){if(!s||t==="")return!0;if(s instanceof RegExp)return s.source.startsWith("^")||s.source.endsWith("$")?Ue(s,t):[...t].every(o=>Ue(s,o));const l=Xl[s];return l?l.pastePattern.test(t):!0}const He={mounted(t,s){const l={filter:s.value,onKeyPress(o){o.ctrlKey||o.metaKey||o.altKey||o.key.length!==1||Jh(o.key,l.filter)||o.preventDefault()},onPaste(o){var r;const a=((r=o.clipboardData)==null?void 0:r.getData("text"))??"";Qh(a,l.filter)||o.preventDefault()}};t.__mfsKeyFilterState=l,t.addEventListener("keypress",l.onKeyPress),t.addEventListener("paste",l.onPaste)},updated(t,s){t.__mfsKeyFilterState&&(t.__mfsKeyFilterState.filter=s.value)},unmounted(t){const s=t.__mfsKeyFilterState;s&&(t.removeEventListener("keypress",s.onKeyPress),t.removeEventListener("paste",s.onPaste),delete t.__mfsKeyFilterState)}},vh=He,eg={Button:ie,ButtonGroup:qe,Card:Ye,Input:ke,InputText:ke,Badge:Le,Switch:le,ToggleSwitch:le,InputSwitch:le,Modal:oe,Dialog:oe,Textarea:Xe,InputNumber:Ze,Password:Je,Checkbox:ne,RadioButton:Te,Select:he,Dropdown:he,MultiSelect:Qe,Slider:ve,Rating:et,ColorPicker:tt,DatePicker:ge,Calendar:ge,Avatar:ye,Chip:de,Tag:de,Divider:lt,Accordion:ot,Timeline:nt,Carousel:at,Image:st,Toast:dt,Alert:be,Message:be,Tooltip:ct,Drawer:Be,Sidebar:Be,Popover:_e,OverlayPanel:_e,Skeleton:mt,ProgressBar:ft,ProgressSpinner:pt,ConfirmDialog:ht,Navbar:Ee,Menubar:Ee,Tabs:$e,TabView:$e,Breadcrumb:gt,Pagination:ce,Paginator:ce,Steps:Ve,Stepper:Ve,ContextMenu:yt,ScrollTop:bt,DataTable:Bt,Column:_t,DataView:wt,Tree:Et,AutoComplete:$t,Cascader:Ce,CascadeSelect:Ce,TreeSelect:Vt,Knob:Ct,SelectButton:xt,ToggleButton:Nt,InputOtp:St,InputMask:Mt,InputGroup:Dt,InputGroupAddon:zt,IconField:Lt,InputIcon:Tt,Listbox:It,FloatLabel:Pt,IftaLabel:Rt,Editor:Ft,CodeEditor:jt,SplitButton:Kt,SpeedDial:Ot,Panel:Ut,Fieldset:Ht,Splitter:Wt,Toolbar:Gt,ScrollPanel:qt,Fluid:Yt,Deferred:Ne,DeferredContent:Ne,Menu:Xt,TieredMenu:Zt,SlideMenu:Jt,PanelMenu:Qt,MegaMenu:vt,Dock:el,TabMenu:tl,OrderList:ll,PickList:ol,TreeTable:nl,OrganizationChart:al,VirtualScroller:sl,MeterGroup:rl,Inplace:il,ConfirmPopup:dl,InlineMessage:cl,BlockUI:ml,Galleria:fl,FileUpload:pl,Terminal:ul,Chart:kl,ImageCropper:Re,AvatarGroup:hl,OverlayBadge:gl,ImageCompare:yl,Portal:bl,Chips:Se,InputChips:Se,CheckboxGroup:Bl,RadioButtonGroup:_l,DynamicDialog:El,CommandPalette:$l,InfiniteScroll:Vl,Mentions:Cl,SignaturePad:xl,Form:Nl,FormField:Sl},tg={ripple:Il,tooltip:Ke,focustrap:Kl,animateonscroll:Hl,styleclass:Gl,badge:Oe,keyfilter:He},lg={install(t,s={}){for(const[l,o]of Object.entries(eg))t.component(l,o);for(const[l,o]of Object.entries(tg))t.directive(l,o);if(typeof window<"u"){const{initTheme:l}=Ll();l(s.defaultTheme||"clay")}}};x.Accordion=ot,x.Alert=be,x.AutoComplete=$t,x.Avatar=ye,x.AvatarGroup=hl,x.Badge=Le,x.BadgeDirective=Zh,x.BlockUI=ml,x.Breadcrumb=gt,x.Button=ie,x.ButtonGroup=qe,x.Calendar=ge,x.Card=Ye,x.Carousel=at,x.CascadeSelect=Ce,x.Cascader=Ce,x.Chart=kl,x.Checkbox=ne,x.CheckboxGroup=Bl,x.Chip=de,x.Chips=Se,x.CodeEditor=jt,x.ColorPicker=tt,x.Column=_t,x.CommandPalette=$l,x.ConfirmDialog=ht,x.ConfirmPopup=dl,x.ContextMenu=yt,x.DataTable=Bt,x.DataView=wt,x.DatePicker=ge,x.Deferred=Ne,x.DeferredContent=Ne,x.Dialog=oe,x.Divider=lt,x.Dock=el,x.Drawer=Be,x.Dropdown=he,x.DynamicDialog=El,x.Editor=Ft,x.Fieldset=Ht,x.FileUpload=pl,x.FloatLabel=Pt,x.Fluid=Yt,x.Form=Nl,x.FormField=Sl,x.Galleria=fl,x.IconField=Lt,x.IftaLabel=Rt,x.Image=st,x.ImageCompare=yl,x.ImageCropper=Re,x.InfiniteScroll=Vl,x.InlineMessage=cl,x.Inplace=il,x.Input=ke,x.InputChips=Se,x.InputGroup=Dt,x.InputGroupAddon=zt,x.InputIcon=Tt,x.InputMask=Mt,x.InputNumber=Ze,x.InputOtp=St,x.InputSwitch=le,x.InputText=ke,x.KeyFilter=vh,x.Knob=Ct,x.Listbox=It,x.MegaMenu=vt,x.Mentions=Cl,x.Menu=Xt,x.Menubar=Ee,x.Message=be,x.MeterGroup=rl,x.Modal=oe,x.MultiSelect=Qe,x.Navbar=Ee,x.OrderList=ll,x.OrganizationChart=al,x.OverlayBadge=gl,x.OverlayPanel=_e,x.Pagination=ce,x.Paginator=ce,x.Panel=Ut,x.PanelMenu=Qt,x.Password=Je,x.PickList=ol,x.Popover=_e,x.Portal=bl,x.ProgressBar=ft,x.ProgressSpinner=pt,x.RadioButton=Te,x.RadioButtonGroup=_l,x.Rating=et,x.ScrollPanel=qt,x.ScrollTop=bt,x.Select=he,x.SelectButton=xt,x.Sidebar=Be,x.SignaturePad=xl,x.Skeleton=mt,x.SlideMenu=Jt,x.Slider=ve,x.SpeedDial=Ot,x.SplitButton=Kt,x.Splitter=Wt,x.Stepper=Ve,x.Steps=Ve,x.Switch=le,x.THEME_OPTIONS=Ae,x.TabMenu=tl,x.TabView=$e,x.Tabs=$e,x.Tag=de,x.Terminal=ul,x.Textarea=Xe,x.TieredMenu=Zt,x.Timeline=nt,x.Toast=dt,x.ToggleButton=Nt,x.ToggleSwitch=le,x.Toolbar=Gt,x.Tooltip=ct,x.TooltipDirective=Ke,x.Tree=Et,x.TreeSelect=Vt,x.TreeTable=nl,x.VirtualScroller=sl,x.default=lg,x.useConfirm=kt,x.useDialog=wl,x.useStyle=jh,x.useTheme=Ll,x.useToast=it,x.vAnimateOnScroll=Hl,x.vBadge=Oe,x.vFocusTrap=Kl,x.vKeyFilter=He,x.vRipple=Il,x.vStyleClass=Gl,x.vTooltip=Ke,Object.defineProperties(x,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));
31
+ */const Bc=Gt("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"}]]),_c={class:"mfs-code-editor__header"},wc={key:0,class:"mfs-code-editor__tabs",role:"tablist","aria-label":"Code editor files"},Ec=["aria-selected","onClick"],$c={key:1,class:"mfs-code-editor__tabs"},Vc={key:0,class:"mfs-code-editor__tab mfs-code-editor__tab--active mfs-code-editor__tab--single mfs-font-mono"},Cc={class:"mfs-code-editor__actions"},xc={class:"mfs-code-editor__lang-pill mfs-font-mono"},Nc=["aria-label","title"],Sc={key:0,class:"mfs-code-editor__gutter mfs-font-mono","aria-hidden":"true"},Mc={class:"mfs-code-editor__stage"},Dc=["aria-hidden"],zc={class:"mfs-code-editor__code"},Tc=["value","disabled","placeholder","maxlength","aria-invalid","onKeydown"],Lc={class:"mfs-code-editor__footer mfs-font-mono"},Ic={class:"mfs-code-editor__status-group"},Rc={class:"mfs-code-editor__status-group"},Pc={class:"mfs-code-editor__mode-badge"},qt=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(!1),c=e.ref(!1),d=e.ref(l.activeTab);let n=null;e.watch(()=>l.activeTab,S=>{d.value=S});const k=e.computed(()=>!!(l.tabs&&l.tabs.length>0)),h=e.computed(()=>!k.value||!l.tabs?0:Math.min(Math.max(0,d.value),l.tabs.length-1)),y=e.computed(()=>k.value&&l.tabs?l.tabs[h.value]:void 0),f=e.computed(()=>{var S;return k.value?((S=y.value)==null?void 0:S.code)??"":l.modelValue??""}),p=e.computed(()=>{var S;return k.value?((S=y.value)==null?void 0:S.language)??l.language:l.language}),m=e.computed(()=>{var S,z;return k.value?((S=y.value)==null?void 0:S.filename)||((z=y.value)==null?void 0:z.label):l.filename}),u=e.computed(()=>{var S;return k.value?((S=y.value)==null?void 0:S.readonly)??l.readonly:l.readonly}),b=e.computed(()=>f.value.split(`
32
+ `)),g=e.computed(()=>Math.max(1,b.value.length)),B=e.computed(()=>f.value.length),w=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"]),$=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"]),C=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 V(S,z,W){if(!W)return;const O=S[S.length-1];O&&O.type===z?O.text+=W:S.push({type:z,text:W})}function M(S){return/[A-Za-z_$]/.test(S)}function N(S){return/[A-Za-z0-9_$-]/.test(S)}function I(S){return S>="0"&&S<="9"}function H(S,z,W){if(!S)return[];if(z==="text")return[{type:"plain",text:S}];const O=[],X=S.length;let F=0,ne=!1;for(;F<X;){if(W.inHtmlComment){const A=S.indexOf("-->",F);A===-1?(V(O,"comment",S.slice(F)),F=X):(V(O,"comment",S.slice(F,A+3)),F=A+3,W.inHtmlComment=!1);continue}if(W.inBlockComment){const A=S.indexOf("*/",F);A===-1?(V(O,"comment",S.slice(F)),F=X):(V(O,"comment",S.slice(F,A+2)),F=A+2,W.inBlockComment=!1);continue}const J=S[F],ae=S[F+1]??"";if(J===" "||J===" "||J==="\r"){let A=F+1;for(;A<X&&(S[A]===" "||S[A]===" "||S[A]==="\r");)A++;V(O,"plain",S.slice(F,A)),F=A;continue}if((z==="vue"||z==="html")&&S.startsWith("<!--",F)){const A=S.indexOf("-->",F+4);A===-1?(V(O,"comment",S.slice(F)),W.inHtmlComment=!0,F=X):(V(O,"comment",S.slice(F,A+3)),F=A+3);continue}if((z==="js"||z==="ts"||z==="vue"||z==="css"||z==="sql")&&J==="/"&&ae==="*"){const A=S.indexOf("*/",F+2);A===-1?(V(O,"comment",S.slice(F)),W.inBlockComment=!0,F=X):(V(O,"comment",S.slice(F,A+2)),F=A+2);continue}if((z==="js"||z==="ts"||z==="vue"||z==="css")&&J==="/"&&ae==="/"){V(O,"comment",S.slice(F)),F=X;continue}if(z==="bash"&&J==="#"){V(O,"comment",S.slice(F)),F=X;continue}if(z==="sql"&&J==="-"&&ae==="-"){V(O,"comment",S.slice(F)),F=X;continue}if(J==='"'||J==="'"||J==="`"&&z!=="sql"){const A=J;let Z=F+1;for(;Z<X;){if(S[Z]==="\\"&&Z+1<X){Z+=2;continue}if(S[Z]===A){Z++;break}Z++}V(O,"string",S.slice(F,Z)),F=Z;continue}if((z==="vue"||z==="html")&&J==="<"){const A=ae==="/";let Z=F+(A?2:1);if(Z<X&&/[A-Za-z]/.test(S[Z])){for(;Z<X&&/[A-Za-z0-9_:-]/.test(S[Z]);)Z++;V(O,"operator",S.slice(F,F+(A?2:1))),V(O,"tag",S.slice(F+(A?2:1),Z)),ne=!A,F=Z;continue}}if((z==="vue"||z==="html")&&ne){if(J==="/"&&ae===">"){V(O,"operator","/>"),ne=!1,F+=2;continue}if(J===">"){V(O,"operator",">"),ne=!1,F++;continue}if(/[A-Za-z:@#]/.test(J)){let A=F+1;for(;A<X&&/[A-Za-z0-9_.:-]/.test(S[A]);)A++;V(O,"attr",S.slice(F,A)),F=A;continue}}if(z==="css"&&J==="#"&&/[0-9A-Fa-f]/.test(ae)){let A=F+1;for(;A<X&&/[0-9A-Fa-f]/.test(S[A]);)A++;V(O,"number",S.slice(F,A)),F=A;continue}if(I(J)||J==="."&&I(ae)){let A=F+1;for(;A<X&&/[0-9._xXa-fA-F]/.test(S[A]);)A++;V(O,"number",S.slice(F,A)),F=A;continue}if(M(J)){let A=F+1;for(;A<X&&N(S[A]);)A++;const Z=S.slice(F,A);let se=!1;z==="js"||z==="ts"||z==="vue"?se=w.has(Z):z==="sql"?se=_.has(Z.toUpperCase()):z==="bash"?se=$.has(Z):z==="css"?se=C.has(Z):z==="json"&&(se=E.has(Z)),z==="json"&&S[A]===void 0?V(O,se?"keyword":"plain",Z):z==="css"&&S.slice(A).trimStart().startsWith(":")?V(O,"attr",Z):V(O,se?"keyword":"plain",Z),F=A;continue}if(/[+\-*/%=<>!&|^~?:]/.test(J)){let A=F+1;for(;A<X&&/[+\-*/%=<>!&|^~?:]/.test(S[A]);)A++;V(O,"operator",S.slice(F,A)),F=A;continue}V(O,"plain",J),F++}return O}const G=e.computed(()=>{const S={inBlockComment:!1,inHtmlComment:!1};return b.value.map(z=>H(z,p.value,S))}),Q=S=>{if(!k.value||!l.tabs)return;const z=l.tabs[S];z&&(d.value=S,o("update:activeTab",S),o("tab-change",{index:S,tab:z}))},ee=S=>{if(k.value&&l.tabs){const z=l.tabs.map((W,O)=>O===h.value?{...W,code:S}:W);o("update:tabs",z)}else o("update:modelValue",S);o("change",S)},K=()=>{var S;!u.value&&!l.disabled&&((S=r.value)==null||S.focus())},U=S=>{const z=S.target;ee(z.value)},Y=async S=>{if(u.value||l.disabled)return;const z=S.target,W=z.selectionStart??0,O=z.selectionEnd??0,X=" ".repeat(Math.max(1,l.tabSize)),F=f.value,ne=F.slice(0,W)+X+F.slice(O);l.maxLength!==void 0&&ne.length>l.maxLength||(ee(ne),await e.nextTick(),r.value&&(r.value.selectionStart=W+X.length,r.value.selectionEnd=W+X.length))},L=S=>{i.value=!0,o("focus",S)},T=S=>{i.value=!1,o("blur",S)},R=async()=>{var W;const S=f.value;let z=!1;if(typeof navigator<"u"&&((W=navigator.clipboard)!=null&&W.writeText))try{await navigator.clipboard.writeText(S),z=!0}catch{z=!1}if(!z&&typeof document<"u"){const O=document.createElement("textarea");O.value=S,O.setAttribute("readonly",""),O.style.position="fixed",O.style.opacity="0",document.body.appendChild(O),O.select();try{z=document.execCommand("copy")}catch{z=!1}document.body.removeChild(O)}z&&(c.value=!0,o("copy",S),n&&clearTimeout(n),n=setTimeout(()=>{c.value=!1},1800))};return(S,z)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-code-editor mfs-rounded mfs-shadow-card",{"mfs-code-editor--readonly":u.value,"mfs-code-editor--disabled mfs-disabled":t.disabled,"mfs-code-editor--invalid":t.invalid,"mfs-code-editor--focused":i.value}])},[e.createElementVNode("div",_c,[z[0]||(z[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)),k.value?(e.openBlock(),e.createElementBlock("div",wc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.tabs,(W,O)=>(e.openBlock(),e.createElementBlock("button",{key:`${W.filename||W.label}-${O}`,type:"button",role:"tab",class:e.normalizeClass(["mfs-code-editor__tab mfs-font-mono",{"mfs-code-editor__tab--active":O===h.value}]),"aria-selected":O===h.value,onClick:X=>Q(O)},e.toDisplayString(W.filename||W.label),11,Ec))),128))])):(e.openBlock(),e.createElementBlock("div",$c,[m.value?(e.openBlock(),e.createElementBlock("span",Vc,e.toDisplayString(m.value),1)):e.createCommentVNode("",!0)])),e.createElementVNode("div",Cc,[e.createElementVNode("span",xc,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":c.value?"Copied":"Copy code",title:c.value?"Copied!":"Copy code",onClick:R},[c.value?(e.openBlock(),e.createBlock(e.unref(bc),{key:0,size:14})):(e.openBlock(),e.createBlock(e.unref(Bc),{key:1,size:14})),e.createElementVNode("span",null,e.toDisplayString(c.value?"Copied":"Copy"),1)],8,Nc)):e.createCommentVNode("",!0)])]),e.createElementVNode("div",{ref_key:"bodyRef",ref:a,class:"mfs-code-editor__body",style:e.normalizeStyle({minHeight:t.minHeight,maxHeight:t.maxHeight}),onClick:K},[t.lineNumbers?(e.openBlock(),e.createElementBlock("div",Sc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,W=>(e.openBlock(),e.createElementBlock("div",{key:W,class:"mfs-code-editor__line-no"},e.toDisplayString(W),1))),128))])):e.createCommentVNode("",!0),e.createElementVNode("div",Mc,[e.createElementVNode("pre",{class:"mfs-code-editor__highlight mfs-font-mono","aria-hidden":!u.value,style:e.normalizeStyle({tabSize:String(t.tabSize)})},[e.createElementVNode("code",zc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(G.value,(W,O)=>(e.openBlock(),e.createElementBlock("span",{key:O,class:"mfs-code-editor__line"},[W.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(W,(X,F)=>(e.openBlock(),e.createElementBlock("span",{key:F,class:e.normalizeClass(`mfs-tok--${X.type}`)},e.toDisplayString(X.text),3))),128)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString("​"))],64)),z[1]||(z[1]=e.createTextVNode(e.toDisplayString(`
33
+ `),-1))]))),128))])],12,Dc),u.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:f.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:U,onKeydown:e.withKeys(e.withModifiers(Y,["prevent"]),["tab"]),onFocus:L,onBlur:T},null,44,Tc))])],4),e.createElementVNode("div",Lc,[e.createElementVNode("div",Ic,[e.createElementVNode("span",null,"Lines: "+e.toDisplayString(g.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",Rc,[e.createElementVNode("span",null,e.toDisplayString(p.value.toUpperCase()),1),e.createElementVNode("span",Pc,e.toDisplayString(u.value?"Readonly":"Editable"),1)])])],2))}}),[["__scopeId","data-v-c5eeb990"]]),Fc={class:"split-btn"},Ac=["disabled"],jc=["disabled","aria-expanded"],Kc=["disabled","onClick"],Oc={key:0,class:"split-btn__icon"},Yt=D(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:s}){const l=s,o=e.ref(!1),a=e.ref(null),r=e.ref(null),{overlayStyle:i,containsTarget:c}=oe(a,r,o,{offset:8,align:"right"}),d=h=>{h.disabled||(o.value=!1,l("select",h))},n=h=>{o.value&&!c(h.target)&&(o.value=!1)},k=h=>{h.key==="Escape"&&o.value&&(o.value=!1)};return e.onMounted(()=>{document.addEventListener("click",n),document.addEventListener("keydown",k)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",n),document.removeEventListener("keydown",k)}),(h,y)=>(e.openBlock(),e.createElementBlock("div",Fc,[e.createElementVNode("div",{ref_key:"triggerRef",ref:a,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:y[0]||(y[0]=f=>l("click",f))},[e.renderSlot(h.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)],10,Ac),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":o.value,"aria-label":"More actions",onClick:y[1]||(y[1]=f=>o.value=!o.value)},[...y[2]||(y[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,jc)],2),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"split-fade"},{default:e.withCtx(()=>[o.value&&t.items.length?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:r,style:e.normalizeStyle(e.unref(i)),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,(f,p)=>(e.openBlock(),e.createElementBlock("li",{key:p,role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:"split-btn__item mfs-text",disabled:f.disabled,onClick:m=>d(f)},[f.icon?(e.openBlock(),e.createElementBlock("span",Oc,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(f.label),1)],8,Kc)]))),128))],4)):e.createCommentVNode("",!0)]),_:1})]))]))}}),[["__scopeId","data-v-54cf96eb"]]),Uc=["aria-expanded"],Hc={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"},Wc=["title","aria-label","disabled","onClick"],Xt=D(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:s}){const l=t,o=s,a=e.ref(!1);e.watch(()=>l.modelValue,n=>{n!==void 0&&(a.value=n)});const r=e.computed(()=>l.modelValue!==void 0?l.modelValue:a.value),i=()=>{const n=!r.value;a.value=n,o("update:modelValue",n)},c=n=>{var k;n.disabled||((k=n.action)==null||k.call(n),o("select",n),a.value=!1,o("update:modelValue",!1))},d=n=>{if(l.type!=="radial"||!l.items.length)return;const k=l.items.length,h=l.direction==="up"?-90:l.direction==="down"?90:l.direction==="left"?180:0,y=120,f=k>1?y/(k-1):0,m=(h-y/2+n*f)*Math.PI/180,u=Math.round(Math.cos(m)*l.radius),b=Math.round(Math.sin(m)*l.radius);return{position:"absolute",transform:`translate(${u}px, ${b}px)`}};return(n,k)=>(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:i},[(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"},[...k[0]||(k[0]=[e.createElementVNode("path",{d:"M12 5v14M5 12h14",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round"},null,-1)])],2))],8,Uc),r.value?(e.openBlock(),e.createElementBlock("ul",Hc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,y)=>(e.openBlock(),e.createElementBlock("li",{key:y,class:"speed-dial__entry",style:e.normalizeStyle(d(y)),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":h.disabled}]),title:h.label,"aria-label":h.label,disabled:h.disabled,onClick:f=>c(h)},[e.renderSlot(n.$slots,"item",{item:h,index:y},()=>[e.createElementVNode("span",null,e.toDisplayString(h.icon||h.label.slice(0,2)),1)],!0)],10,Wc)],4))),128))])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-63f8f8f0"]]),Gc={key:0,class:"panel__header"},qc={class:"panel__title mfs-title"},Yc={class:"panel__actions"},Xc=["aria-expanded"],Zc={class:"panel__collapse"},Jc={class:"panel__inner"},Qc={class:"panel__body"},vc={key:0,class:"panel__footer mfs-surface-subtle mfs-caption"},Zt=D(e.defineComponent({__name:"Panel",props:{header:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1);e.watch(()=>l.collapsed,c=>{c!==void 0&&(a.value=c)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:a.value),i=()=>{const c=!r.value;a.value=c,o("update:collapsed",c),o("toggle",c)};return(c,d)=>(e.openBlock(),e.createElementBlock("section",{class:e.normalizeClass(["panel","mfs-surface","mfs-rounded","mfs-shadow-card",{"is-collapsed":r.value}])},[t.header||c.$slots.header||t.toggleable?(e.openBlock(),e.createElementBlock("header",Gc,[e.createElementVNode("div",qc,[e.renderSlot(c.$slots,"header",{},()=>[e.createTextVNode(e.toDisplayString(t.header),1)],!0)]),e.createElementVNode("div",Yc,[e.renderSlot(c.$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:i},[(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"},[...d[0]||(d[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,Xc)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",Zc,[e.createElementVNode("div",Jc,[e.createElementVNode("div",Qc,[e.renderSlot(c.$slots,"default",{},void 0,!0)]),c.$slots.footer?(e.openBlock(),e.createElementBlock("footer",vc,[e.renderSlot(c.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)])])],2))}}),[["__scopeId","data-v-0ea71fae"]]),em={key:0,class:"fieldset__legend mfs-surface-subtle mfs-pill mfs-shadow mfs-title mfs-text-sm mfs-font-bold"},tm=["aria-expanded"],lm={key:1,class:"mfs-text"},om={class:"fieldset__collapse"},nm={class:"mfs-overflow-hidden"},am={class:"mfs-pt-2"},Jt=D(e.defineComponent({__name:"Fieldset",props:{legend:{},toggleable:{type:Boolean,default:!1},collapsed:{type:Boolean,default:void 0}},emits:["update:collapsed","toggle"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1);e.watch(()=>l.collapsed,c=>{c!==void 0&&(a.value=c)},{immediate:!0});const r=e.computed(()=>l.collapsed!==void 0?l.collapsed:a.value),i=()=>{const c=!r.value;a.value=c,o("update:collapsed",c),o("toggle",c)};return(c,d)=>(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||c.$slots.legend?(e.openBlock(),e.createElementBlock("legend",em,[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:i},[(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"},[...d[0]||(d[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(c.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)],8,tm)):(e.openBlock(),e.createElementBlock("span",lm,[e.renderSlot(c.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)]))])):e.createCommentVNode("",!0),e.createElementVNode("div",om,[e.createElementVNode("div",nm,[e.createElementVNode("div",am,[e.renderSlot(c.$slots,"default",{},void 0,!0)])])])],2))}}),[["__scopeId","data-v-86bfdaad"]]),sm=["aria-orientation","aria-valuenow","aria-valuemin","aria-valuemax"],rm={class:"splitter__pane splitter__pane--second"},Qt=D(e.defineComponent({__name:"Splitter",props:{layout:{default:"horizontal"},initialSize:{default:50},minSize:{default:15}},emits:["resize"],setup(t,{emit:s}){const l=t,o=s,a=p=>Math.max(l.minSize,Math.min(100-l.minSize,p)),r=e.ref(a(l.initialSize)),i=e.ref(!1),c=e.ref(null),d=e.computed(()=>({flexBasis:`${r.value}%`})),n=p=>{if(!c.value)return;const m=c.value.getBoundingClientRect(),u=l.layout==="horizontal"?(p.clientX-m.left)/m.width*100:(p.clientY-m.top)/m.height*100;r.value=a(u),o("resize",r.value)},k=p=>{i.value=!0,p.currentTarget.setPointerCapture(p.pointerId),n(p)},h=p=>{i.value&&n(p)},y=p=>{i.value&&(i.value=!1,p.currentTarget.hasPointerCapture(p.pointerId)&&p.currentTarget.releasePointerCapture(p.pointerId))},f=p=>{const u=l.layout==="horizontal"?"ArrowLeft":"ArrowUp",b=l.layout==="horizontal"?"ArrowRight":"ArrowDown";p.key===u?(p.preventDefault(),r.value=a(r.value-5),o("resize",r.value)):p.key===b&&(p.preventDefault(),r.value=a(r.value+5),o("resize",r.value))};return(p,m)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:c,class:e.normalizeClass(["splitter",`splitter--${t.layout}`,"mfs-surface","mfs-rounded","mfs-shadow-card"])},[e.createElementVNode("div",{class:"splitter__pane",style:e.normalizeStyle(d.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:k,onPointermove:h,onPointerup:y,onPointercancel:y,onKeydown:f},[...m[0]||(m[0]=[e.createElementVNode("span",{class:"splitter__handle mfs-pill"},null,-1)])],40,sm),e.createElementVNode("div",rm,[e.renderSlot(p.$slots,"second",{},void 0,!0)])],2))}}),[["__scopeId","data-v-6fd2ec7c"]]),im={class:"toolbar mfs-surface mfs-rounded mfs-shadow-card",role:"toolbar"},dm={key:0,class:"toolbar__group toolbar__group--start"},cm={key:1,class:"toolbar__group toolbar__group--center"},mm={key:2,class:"toolbar__group toolbar__group--end"},vt=D(e.defineComponent({__name:"Toolbar",setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",im,[s.$slots.start||s.$slots.default?(e.openBlock(),e.createElementBlock("div",dm,[e.renderSlot(s.$slots,"start",{},()=>[e.renderSlot(s.$slots,"default",{},void 0,!0)],!0)])):e.createCommentVNode("",!0),s.$slots.center?(e.openBlock(),e.createElementBlock("div",cm,[e.renderSlot(s.$slots,"center",{},void 0,!0)])):e.createCommentVNode("",!0),s.$slots.end?(e.openBlock(),e.createElementBlock("div",mm,[e.renderSlot(s.$slots,"end",{},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cf5eff51"]]),fm={class:"scroll-panel__content"},el=D(e.defineComponent({__name:"ScrollPanel",props:{maxHeight:{default:"300px"},width:{}},setup(t){const s=t,l=a=>a===void 0?void 0:typeof a=="number"?`${a}px`:a,o=e.computed(()=>({maxHeight:l(s.maxHeight),width:l(s.width)}));return(a,r)=>(e.openBlock(),e.createElementBlock("div",{class:"scroll-panel mfs-surface mfs-rounded mfs-shadow-card mfs-focus-ring",style:e.normalizeStyle(o.value),tabindex:"0"},[e.createElementVNode("div",fm,[e.renderSlot(a.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-78b33875"]]),tl=D(e.defineComponent({__name:"Fluid",props:{tag:{default:"div"},padded:{type:Boolean,default:!1}},setup(t){return(s,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(s.$slots,"default",{},void 0,!0)]),_:3},8,["class"]))}}),[["__scopeId","data-v-94565fea"]]),Re=e.defineComponent({__name:"Deferred",props:{rootMargin:{default:"0px"},threshold:{default:0},once:{type:Boolean,default:!0}},emits:["load"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(!1),r=e.ref(null);let i=null;return e.onMounted(()=>{if(typeof IntersectionObserver>"u"||!r.value){a.value=!0,o("load");return}i=new IntersectionObserver(c=>{const d=c[0];d!=null&&d.isIntersecting&&(a.value=!0,o("load"),l.once&&(i==null||i.disconnect(),i=null))},{rootMargin:l.rootMargin,threshold:l.threshold}),i.observe(r.value)}),e.onBeforeUnmount(()=>{i==null||i.disconnect(),i=null}),(c,d)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"targetRef",ref:r,class:"mfs-w-full"},[a.value?e.renderSlot(c.$slots,"default",{},void 0,void 0,0):e.renderSlot(c.$slots,"placeholder",{},()=>[d[0]||(d[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))}}),pm={class:"menu__list"},um={key:0,class:"menu__separator mfs-divider",role:"separator"},km={key:1,class:"menu__group",role:"presentation"},hm={key:0,class:"menu__group-label mfs-text-muted"},gm={class:"menu__sublist"},ym=["disabled","onClick"],bm={key:0,class:"menu__icon","aria-hidden":"true"},Bm={class:"menu__label"},_m={key:0,class:"menu__icon","aria-hidden":"true"},wm={class:"menu__label"},Em={key:2,role:"none"},$m=["disabled","onClick"],Vm={key:0,class:"menu__icon","aria-hidden":"true"},Cm={class:"menu__label"},xm={key:0,class:"menu__icon","aria-hidden":"true"},Nm={class:"menu__label"},Sm={class:"menu__list"},Mm={key:0,class:"menu__separator mfs-divider",role:"separator"},Dm={key:1,class:"menu__group",role:"presentation"},zm={key:0,class:"menu__group-label mfs-text-muted"},Tm={class:"menu__sublist"},Lm=["disabled","onClick"],Im={key:0,class:"menu__icon","aria-hidden":"true"},Rm={class:"menu__label"},Pm={key:0,class:"menu__icon","aria-hidden":"true"},Fm={class:"menu__label"},Am={key:2,role:"none"},jm=["disabled","onClick"],Km={key:0,class:"menu__icon","aria-hidden":"true"},Om={class:"menu__label"},Um={key:0,class:"menu__icon","aria-hidden":"true"},Hm={class:"menu__label"},ll=D(e.defineComponent({__name:"Menu",props:{items:{},popup:{type:Boolean,default:!1}},emits:["select"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.ref(!1),i=e.ref(null),c=e.ref({x:0,y:0}),d=()=>{r.value=!1,m()},n=async u=>{if(!o.popup)return;r.value=!0;const b=u.currentTarget,g=b==null?void 0:b.getBoundingClientRect();if(c.value=g?{x:g.left,y:g.bottom+6}:{x:u.clientX,y:u.clientY},await e.nextTick(),i.value){const B=i.value.getBoundingClientRect(),w=8;c.value={x:Math.max(w,Math.min(c.value.x,window.innerWidth-B.width-w)),y:Math.max(w,Math.min(c.value.y,window.innerHeight-B.height-w))}}p()},k=u=>{r.value?d():n(u)},h=u=>{var b;u.disabled||((b=u.command)==null||b.call(u),a("select",u),o.popup&&d())},y=u=>{u.key==="Escape"&&o.popup&&d()},f=u=>{i.value&&!i.value.contains(u.target)&&d()},p=()=>{window.addEventListener("pointerdown",f),window.addEventListener("resize",d)},m=()=>{window.removeEventListener("pointerdown",f),window.removeEventListener("resize",d)};return e.onUnmounted(m),s({open:n,close:d,toggle:k}),(u,b)=>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:i,class:"menu menu--popup mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu",style:e.normalizeStyle({left:`${c.value.x}px`,top:`${c.value.y}px`}),onKeydown:y},[e.createElementVNode("ul",pm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>{var w;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[g.separator?(e.openBlock(),e.createElementBlock("li",um)):(w=g.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("li",km,[g.label?(e.openBlock(),e.createElementBlock("div",hm,e.toDisplayString(g.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",gm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.items,(_,$)=>(e.openBlock(),e.createElementBlock("li",{key:$,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:C=>h(_)},[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",bm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Bm,e.toDisplayString(_.label),1)],!0)],10,ym)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:_.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:C=>h(_)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",_m,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",wm,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",Em,[!g.to&&!g.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":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",Vm,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Cm,e.toDisplayString(g.label),1)],!0)],10,$m)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g.to?"router-link":"a"),{key:1,to:g.to,href:g.href,role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",xm,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Nm,e.toDisplayString(g.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:y},[e.createElementVNode("ul",Sm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(g,B)=>{var w;return e.openBlock(),e.createElementBlock(e.Fragment,{key:B},[g.separator?(e.openBlock(),e.createElementBlock("li",Mm)):(w=g.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("li",Dm,[g.label?(e.openBlock(),e.createElementBlock("div",zm,e.toDisplayString(g.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Tm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.items,(_,$)=>(e.openBlock(),e.createElementBlock("li",{key:$,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:C=>h(_)},[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Im,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Rm,e.toDisplayString(_.label),1)],!0)],10,Lm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(_.to?"router-link":"a"),{key:1,to:_.to,href:_.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:C=>h(_)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Pm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Fm,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",Am,[!g.to&&!g.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":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",Km,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Om,e.toDisplayString(g.label),1)],!0)],10,jm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(g.to?"router-link":"a"),{key:1,to:g.to,href:g.href,role:"menuitem",class:e.normalizeClass(["menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"menu__item--disabled mfs-disabled":g.disabled}]),disabled:g.disabled,onClick:_=>h(g)},{default:e.withCtx(()=>[e.renderSlot(u.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",Um,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Hm,e.toDisplayString(g.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],32))}}),[["__scopeId","data-v-b6f0d9c8"]]),Wm={class:"tiered-menu mfs-surface mfs-rounded-md mfs-blur","aria-label":"Tiered menu"},Gm={class:"tiered-menu__list",role:"menubar"},qm={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},Ym=["onMouseenter"],Xm=["aria-haspopup","aria-expanded","disabled","onClick"],Zm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Jm={class:"tiered-menu__label"},Qm={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"},vm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},ef={class:"tiered-menu__label"},tf={key:2,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu"},lf={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},of=["onMouseenter"],nf=["aria-haspopup","aria-expanded","disabled","onClick"],af={key:0,class:"tiered-menu__icon","aria-hidden":"true"},sf={class:"tiered-menu__label"},rf={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"},df={key:0,class:"tiered-menu__icon","aria-hidden":"true"},cf={class:"tiered-menu__label"},mf={key:2,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu"},ff={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},pf={key:1,role:"none"},uf=["disabled","onClick"],kf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},hf={class:"tiered-menu__label"},gf={key:0,class:"tiered-menu__icon","aria-hidden":"true"},yf={class:"tiered-menu__label"},ol=D(e.defineComponent({__name:"TieredMenu",props:{items:{}},emits:["select"],setup(t,{emit:s}){const l=s,o=e.ref(null),a=e.ref(null),r=(i,c,d)=>{var n,k;if(!i.disabled){if((n=i.items)!=null&&n.length){c===1?(o.value=o.value===d?null:d,a.value=null):c===2&&(a.value=a.value===d?null:d);return}(k=i.command)==null||k.call(i),l("select",i),o.value=null,a.value=null}};return(i,c)=>(e.openBlock(),e.createElementBlock("nav",Wm,[e.createElementVNode("ul",Gm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(d,n)=>{var k,h,y,f,p;return e.openBlock(),e.createElementBlock(e.Fragment,{key:n},[d.separator?(e.openBlock(),e.createElementBlock("li",qm)):(e.openBlock(),e.createElementBlock("li",{key:1,class:"tiered-menu__node",role:"none",onMouseenter:m=>o.value=n,onMouseleave:c[1]||(c[1]=m=>{o.value=null,a.value=null})},[(k=d.items)!=null&&k.length||!d.to&&!d.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===n,"tiered-menu__item--disabled mfs-disabled":d.disabled}]),"aria-haspopup":(h=d.items)!=null&&h.length?"true":void 0,"aria-expanded":(y=d.items)!=null&&y.length?o.value===n:void 0,disabled:d.disabled,onClick:m=>r(d,1,n)},[d.icon?(e.openBlock(),e.createElementBlock("span",Zm,e.toDisplayString(d.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Jm,e.toDisplayString(d.label),1),(f=d.items)!=null&&f.length?(e.openBlock(),e.createElementBlock("svg",Qm,[...c[2]||(c[2]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Xm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d.to?"router-link":"a"),{key:1,to:d.to,href:d.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":o.value===n,"tiered-menu__item--disabled mfs-disabled":d.disabled}]),disabled:d.disabled,onClick:m=>r(d,1,n)},{default:e.withCtx(()=>[d.icon?(e.openBlock(),e.createElementBlock("span",vm,e.toDisplayString(d.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",ef,e.toDisplayString(d.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),(p=d.items)!=null&&p.length&&o.value===n?(e.openBlock(),e.createElementBlock("ul",tf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.items,(m,u)=>{var b,g,B,w,_;return e.openBlock(),e.createElementBlock(e.Fragment,{key:u},[m.separator?(e.openBlock(),e.createElementBlock("li",lf)):(e.openBlock(),e.createElementBlock("li",{key:1,class:"tiered-menu__node",role:"none",onMouseenter:$=>a.value=u,onMouseleave:c[0]||(c[0]=$=>a.value=null)},[(b=m.items)!=null&&b.length||!m.to&&!m.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":a.value===u,"tiered-menu__item--disabled mfs-disabled":m.disabled}]),"aria-haspopup":(g=m.items)!=null&&g.length?"true":void 0,"aria-expanded":(B=m.items)!=null&&B.length?a.value===u:void 0,disabled:m.disabled,onClick:$=>r(m,2,u)},[m.icon?(e.openBlock(),e.createElementBlock("span",af,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",sf,e.toDisplayString(m.label),1),(w=m.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("svg",rf,[...c[3]||(c[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,nf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.to?"router-link":"a"),{key:1,to:m.to,href:m.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":a.value===u,"tiered-menu__item--disabled mfs-disabled":m.disabled}]),disabled:m.disabled,onClick:$=>r(m,2,u)},{default:e.withCtx(()=>[m.icon?(e.openBlock(),e.createElementBlock("span",df,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",cf,e.toDisplayString(m.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),(_=m.items)!=null&&_.length&&a.value===u?(e.openBlock(),e.createElementBlock("ul",mf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.items,($,C)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:C},[$.separator?(e.openBlock(),e.createElementBlock("li",ff)):(e.openBlock(),e.createElementBlock("li",pf,[!$.to&&!$.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":$.disabled}]),disabled:$.disabled,onClick:E=>r($,3,C)},[$.icon?(e.openBlock(),e.createElementBlock("span",kf,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",hf,e.toDisplayString($.label),1)],10,uf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent($.to?"router-link":"a"),{key:1,to:$.to,href:$.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--disabled mfs-disabled":$.disabled}]),disabled:$.disabled,onClick:E=>r($,3,C)},{default:e.withCtx(()=>[$.icon?(e.openBlock(),e.createElementBlock("span",gf,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",yf,e.toDisplayString($.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64))),128))])):e.createCommentVNode("",!0)],40,of))],64)}),128))])):e.createCommentVNode("",!0)],40,Ym))],64)}),128))])]))}}),[["__scopeId","data-v-b9d2bab9"]]),bf={key:0,class:"slide-menu__header"},Bf={class:"slide-menu__title mfs-title"},_f={class:"slide-menu__viewport"},wf=["disabled","onClick"],Ef={key:0,class:"slide-menu__icon","aria-hidden":"true"},$f={class:"slide-menu__label"},Vf={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"},Cf={key:0,class:"slide-menu__icon","aria-hidden":"true"},xf={class:"slide-menu__label"},nl=D(e.defineComponent({__name:"SlideMenu",props:{items:{},backLabel:{default:"Back"},menuWidth:{default:"260px"}},emits:["select"],setup(t,{emit:s}){const l=t,o=s,a=e.ref([]),r=e.ref("forward"),i=e.computed(()=>a.value.length?a.value[a.value.length-1].items:l.items),c=e.computed(()=>a.value.length?a.value[a.value.length-1].title:""),d=k=>{var h,y;if(!k.disabled){if((h=k.items)!=null&&h.length){r.value="forward",a.value.push({title:k.label,items:k.items});return}(y=k.command)==null||y.call(k),o("select",k)}},n=()=>{a.value.length&&(r.value="back",a.value.pop())};return(k,h)=>(e.openBlock(),e.createElementBlock("div",{class:"slide-menu mfs-surface mfs-overlay mfs-rounded-md mfs-blur",style:e.normalizeStyle({width:t.menuWidth})},[a.value.length>0?(e.openBlock(),e.createElementBlock("div",bf,[e.createElementVNode("button",{type:"button",class:"slide-menu__back mfs-surface-subtle mfs-rounded-sm mfs-interactive mfs-text",onClick:n},[h[0]||(h[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",Bf,e.toDisplayString(c.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",_f,[e.createVNode(e.Transition,{name:r.value==="forward"?"slide-fwd":"slide-bck",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("ul",{key:a.value.length,class:"slide-menu__list",role:"menu"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.value,(y,f)=>{var p,m;return e.openBlock(),e.createElementBlock("li",{key:f,role:"none"},[(p=y.items)!=null&&p.length||!y.to&&!y.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":y.disabled}]),disabled:y.disabled,onClick:u=>d(y)},[y.icon?(e.openBlock(),e.createElementBlock("span",Ef,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",$f,e.toDisplayString(y.label),1),(m=y.items)!=null&&m.length?(e.openBlock(),e.createElementBlock("svg",Vf,[...h[1]||(h[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,wf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(y.to?"router-link":"a"),{key:1,to:y.to,href:y.href,role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:u=>d(y)},{default:e.withCtx(()=>[y.icon?(e.openBlock(),e.createElementBlock("span",Cf,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",xf,e.toDisplayString(y.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))])}),128))]))]),_:1},8,["name"])])],4))}}),[["__scopeId","data-v-0c085066"]]),Nf={class:"panel-menu","aria-label":"Panel navigation"},Sf=["aria-expanded","disabled","onClick"],Mf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Df={class:"panel-menu__label"},zf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Tf={class:"panel-menu__label"},Lf={key:0,class:"panel-menu__list"},If=["disabled","onClick"],Rf={key:0,class:"panel-menu__icon","aria-hidden":"true"},Pf={key:0,class:"panel-menu__icon","aria-hidden":"true"},al=D(e.defineComponent({__name:"PanelMenu",props:{items:{},multiple:{type:Boolean,default:!0},expandedKeys:{}},emits:["update:expandedKeys","select"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(l.expandedKeys??[]);e.watch(()=>l.expandedKeys,n=>{n!==void 0&&(a.value=[...n])});const r=(n,k)=>n.key??`${k}-${n.label}`,i=n=>a.value.includes(n),c=(n,k)=>{var h,y;if(!n.disabled){if((h=n.items)!=null&&h.length){const f=r(n,k);let p;i(f)?p=a.value.filter(m=>m!==f):p=l.multiple?[...a.value,f]:[f],a.value=p,o("update:expandedKeys",p);return}(y=n.command)==null||y.call(n),o("select",n)}},d=n=>{var k;n.disabled||((k=n.command)==null||k.call(n),o("select",n))};return(n,k)=>(e.openBlock(),e.createElementBlock("nav",Nf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,y)=>{var f,p,m;return e.openBlock(),e.createElementBlock("div",{key:r(h,y),class:"panel-menu__panel mfs-surface mfs-rounded-md mfs-blur"},[(f=h.items)!=null&&f.length||!h.to&&!h.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":h.disabled}]),"aria-expanded":(p=h.items)!=null&&p.length?i(r(h,y)):void 0,disabled:h.disabled,onClick:u=>c(h,y)},[h.icon?(e.openBlock(),e.createElementBlock("span",Mf,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Df,e.toDisplayString(h.label),1),(m=h.items)!=null&&m.length?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(["panel-menu__chevron",{"panel-menu__chevron--open":i(r(h,y))}]),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"},[...k[0]||(k[0]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2)):e.createCommentVNode("",!0)],10,Sf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(h.to?"router-link":"a"),{key:1,to:h.to,href:h.href,class:e.normalizeClass(["panel-menu__header mfs-text",{"panel-menu__header--disabled mfs-disabled":h.disabled}]),disabled:h.disabled,onClick:u=>c(h,y)},{default:e.withCtx(()=>[h.icon?(e.openBlock(),e.createElementBlock("span",zf,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Tf,e.toDisplayString(h.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"panel-collapse"},{default:e.withCtx(()=>{var u;return[(u=h.items)!=null&&u.length&&i(r(h,y))?(e.openBlock(),e.createElementBlock("ul",Lf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(b,g)=>(e.openBlock(),e.createElementBlock("li",{key:g},[!b.to&&!b.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":b.disabled}]),disabled:b.disabled,onClick:B=>d(b)},[b.icon?(e.openBlock(),e.createElementBlock("span",Rf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(b.label),1)],10,If)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.to?"router-link":"a"),{key:1,to:b.to,href:b.href,class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:B=>d(b)},{default:e.withCtx(()=>[b.icon?(e.openBlock(),e.createElementBlock("span",Pf,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(b.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])):e.createCommentVNode("",!0)]}),_:2},1024)])}),128))]))}}),[["__scopeId","data-v-80eb0ae4"]]),Ff={class:"mega-menu__bar mfs-flex mfs-flex-col mfs-gap-2"},Af=["aria-expanded"],jf={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"},Kf={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"},Of=["onMouseenter"],Uf=["aria-haspopup","aria-expanded","disabled","onClick"],Hf={key:0,"aria-hidden":"true"},Wf={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"},Gf={key:0,"aria-hidden":"true"},qf={key:0,class:"mega-menu__panel mfs-card mfs-overlay mfs-blur mfs-p-4",role:"menu"},Yf={class:"mega-menu__columns"},Xf={key:0,class:"mega-menu__col-title mfs-text-muted mfs-font-bold mfs-mb-2 mfs-px-2"},Zf={class:"mega-menu__col-list mfs-flex mfs-flex-col mfs-gap-1"},Jf=["onClick"],Qf={class:"mega-menu__link-label mfs-font-semibold"},vf={key:0,class:"mega-menu__link-desc mfs-text-muted"},ep={class:"mega-menu__link-label mfs-font-semibold"},tp={key:0,class:"mega-menu__link-desc mfs-text-muted"},sl=D(e.defineComponent({__name:"MegaMenu",props:{items:{},orientation:{default:"horizontal"}},emits:["select"],setup(t,{emit:s}){const l=s,o=e.ref(null),a=e.ref(null),r=e.ref(!1),i=()=>typeof window<"u"&&window.innerWidth<768,c=f=>{i()||(a.value=f)},d=()=>{i()||(a.value=null)},n=(f,p)=>{var m,u;if(!f.disabled){if((m=f.columns)!=null&&m.length){a.value=a.value===p?null:p;return}(u=f.command)==null||u.call(f),l("select",f),a.value=null,r.value=!1}},k=f=>{var p;(p=f.command)==null||p.call(f),l("select",f),a.value=null,r.value=!1},h=f=>{o.value&&!o.value.contains(f.target)&&(a.value=null)},y=f=>{f.key==="Escape"&&(a.value=null,r.value=!1)};return e.onMounted(()=>{window.addEventListener("pointerdown",h),window.addEventListener("keydown",y)}),e.onUnmounted(()=>{window.removeEventListener("pointerdown",h),window.removeEventListener("keydown",y)}),(f,p)=>(e.openBlock(),e.createElementBlock("nav",{ref_key:"rootRef",ref:o,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",Ff,[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":r.value,"aria-label":"Toggle mega menu",onClick:p[0]||(p[0]=m=>r.value=!r.value)},[r.value?(e.openBlock(),e.createElementBlock("svg",Kf,[...p[2]||(p[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",jf,[...p[1]||(p[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)])])),p[3]||(p[3]=e.createElementVNode("span",null,"Menu",-1))],8,Af),e.createElementVNode("ul",{class:e.normalizeClass(["mega-menu__list mfs-flex-col mfs-gap-1-5",{"mega-menu__list--open":r.value}]),role:"menubar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(m,u)=>{var b,g,B,w;return e.openBlock(),e.createElementBlock("li",{key:u,class:"mega-menu__root mfs-relative",role:"none",onMouseenter:_=>c(u),onMouseleave:d},[(b=m.columns)!=null&&b.length||!m.to&&!m.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":a.value===u,"mega-menu__trigger--disabled mfs-disabled":m.disabled}]),"aria-haspopup":(g=m.columns)!=null&&g.length?"true":void 0,"aria-expanded":(B=m.columns)!=null&&B.length?a.value===u:void 0,disabled:m.disabled,onClick:_=>n(m,u)},[m.icon?(e.openBlock(),e.createElementBlock("span",Hf,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(m.label),1),(w=m.columns)!=null&&w.length?(e.openBlock(),e.createElementBlock("svg",Wf,[...p[4]||(p[4]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])])):e.createCommentVNode("",!0)],10,Uf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(m.to?"router-link":"a"),{key:1,to:m.to,href:m.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":a.value===u,"mega-menu__trigger--disabled mfs-disabled":m.disabled}]),disabled:m.disabled,onClick:_=>n(m,u)},{default:e.withCtx(()=>[m.icon?(e.openBlock(),e.createElementBlock("span",Gf,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(m.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"mega-fade"},{default:e.withCtx(()=>{var _;return[(_=m.columns)!=null&&_.length&&a.value===u?(e.openBlock(),e.createElementBlock("div",qf,[e.createElementVNode("div",Yf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.columns,($,C)=>(e.openBlock(),e.createElementBlock("div",{key:C,class:"mega-menu__col"},[$.title?(e.openBlock(),e.createElementBlock("div",Xf,e.toDisplayString($.title),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Zf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.items,(E,V)=>(e.openBlock(),e.createElementBlock("li",{key:V,role:"none"},[!E.to&&!E.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:M=>k(E)},[e.createElementVNode("span",Qf,e.toDisplayString(E.label),1),E.description?(e.openBlock(),e.createElementBlock("span",vf,e.toDisplayString(E.description),1)):e.createCommentVNode("",!0)],8,Jf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(E.to?"router-link":"a"),{key:1,to:E.to,href:E.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:M=>k(E)},{default:e.withCtx(()=>[e.createElementVNode("span",ep,e.toDisplayString(E.label),1),E.description?(e.openBlock(),e.createElementBlock("span",tp,e.toDisplayString(E.description),1)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","onClick"]))]))),128))])]))),128))])])):e.createCommentVNode("",!0)]}),_:2},1024)],40,Of)}),128))],2)])],2))}}),[["__scopeId","data-v-c1804bd7"]]),lp={class:"dock__list mfs-surface mfs-shadow-card mfs-pill mfs-blur",role:"menubar"},op=["onMouseenter"],np=["aria-label","disabled","onClick"],ap={class:"dock__glyph mfs-text"},sp={key:0,class:"dock__dot","aria-hidden":"true"},rp={class:"dock__glyph mfs-text"},ip={key:0,class:"dock__dot","aria-hidden":"true"},dp={class:"dock__tooltip mfs-surface mfs-shadow mfs-rounded-sm mfs-text",role:"tooltip"},rl=D(e.defineComponent({__name:"Dock",props:{items:{},position:{default:"bottom"},magnification:{type:Boolean,default:!0}},emits:["select"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=c=>{if(!l.magnification||a.value===null)return{};const d=Math.abs(a.value-c);return d===0?{transform:"scale(1.32)"}:d===1?{transform:"scale(1.14)"}:{}},i=(c,d)=>{var n;c.disabled||((n=c.command)==null||n.call(c),o("select",c,d))};return(c,d)=>(e.openBlock(),e.createElementBlock("nav",{class:e.normalizeClass(["dock",[`dock--${t.position}`]]),"aria-label":"Dock navigation",onMouseleave:d[0]||(d[0]=n=>a.value=null)},[e.createElementVNode("ul",lp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,k)=>(e.openBlock(),e.createElementBlock("li",{key:k,class:"dock__item-wrap",role:"none",onMouseenter:h=>a.value=k},[!n.to&&!n.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":n.active,"dock__item--disabled mfs-disabled":n.disabled}]),style:e.normalizeStyle(r(k)),"aria-label":n.label,disabled:n.disabled,onClick:h=>i(n,k)},[e.renderSlot(c.$slots,"item",{item:n,index:k,active:!!n.active},()=>[e.createElementVNode("span",ap,e.toDisplayString(n.icon??n.label.slice(0,2).toUpperCase()),1)],!0),n.active?(e.openBlock(),e.createElementBlock("span",sp)):e.createCommentVNode("",!0)],14,np)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.to?"router-link":"a"),{key:1,to:n.to,href:n.href,role:"menuitem",class:e.normalizeClass(["dock__item mfs-rounded-sm mfs-text",{"dock__item--active":n.active,"dock__item--disabled mfs-disabled":n.disabled}]),style:e.normalizeStyle(r(k)),"aria-label":n.label,disabled:n.disabled,onClick:h=>i(n,k)},{default:e.withCtx(()=>[e.renderSlot(c.$slots,"item",{item:n,index:k,active:!!n.active},()=>[e.createElementVNode("span",rp,e.toDisplayString(n.icon??n.label.slice(0,2).toUpperCase()),1)],!0),n.active?(e.openBlock(),e.createElementBlock("span",ip)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","class","style","aria-label","disabled","onClick"])),e.createElementVNode("span",dp,e.toDisplayString(n.label),1)],40,op))),128))])],34))}}),[["__scopeId","data-v-f3aec655"]]),cp={class:"tab-menu","aria-label":"Tab navigation"},mp=["aria-selected","aria-disabled","tabindex","onClick"],fp={key:0,class:"tab-menu__icon","aria-hidden":"true"},pp={key:0,class:"tab-menu__icon","aria-hidden":"true"},il=D(e.defineComponent({__name:"TabMenu",props:{items:{},modelValue:{default:0},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=new Map,i=e.ref({left:0,width:0,ready:!1}),c=(p,m)=>{const u=(m==null?void 0:m.$el)??m;u instanceof HTMLElement?r.set(p,u):r.delete(p)},d=e.computed(()=>({transform:`translateX(${i.value.left}px)`,width:`${i.value.width}px`,opacity:i.value.ready&&i.value.width>0?1:0})),n=async(p=!1)=>{await e.nextTick();const m=r.get(l.modelValue);if(!m){i.value={left:0,width:0,ready:!1};return}i.value={left:m.offsetLeft,width:m.offsetWidth,ready:!0},p&&l.scrollable&&m.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},k=(p,m,u)=>{var b;if(p.disabled){u.preventDefault();return}(b=p.command)==null||b.call(p),m!==l.modelValue&&(o("update:modelValue",m),o("change",{index:m,item:p}))},h=p=>{var g;const m=l.items.map((B,w)=>B.disabled?-1:w).filter(B=>B>=0);if(!m.length)return;const u=m.indexOf(l.modelValue);let b=-1;if(p.key==="ArrowRight"?b=m[(u+1)%m.length]:p.key==="ArrowLeft"?b=m[(u-1+m.length)%m.length]:p.key==="Home"?b=m[0]:p.key==="End"&&(b=m[m.length-1]),b>=0){p.preventDefault();const B=l.items[b];o("update:modelValue",b),o("change",{index:b,item:B}),(g=r.get(b))==null||g.focus()}},y=()=>n(!1);let f=null;return e.watch(()=>[l.modelValue,l.items],()=>n(!0),{deep:!0}),e.onMounted(()=>{n(!1),typeof ResizeObserver<"u"&&a.value&&(f=new ResizeObserver(y),f.observe(a.value)),window.addEventListener("resize",y)}),e.onUnmounted(()=>{f==null||f.disconnect(),window.removeEventListener("resize",y)}),(p,m)=>(e.openBlock(),e.createElementBlock("nav",cp,[e.createElementVNode("div",{ref_key:"listRef",ref:a,class:e.normalizeClass(["tab-menu__list mfs-surface-subtle mfs-pill mfs-shadow-inset",{"tab-menu__list--scrollable":t.scrollable}]),role:"tablist",onKeydown:h},[e.createElementVNode("span",{class:"tab-menu__indicator mfs-rounded-sm",style:e.normalizeStyle(d.value),"aria-hidden":"true"},null,4),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(u,b)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:u.key??b},[!u.to&&!u.href?(e.openBlock(),e.createElementBlock("button",{key:0,ref_for:!0,ref:g=>c(b,g),type:"button",role:"tab",class:e.normalizeClass(["tab-menu__item mfs-rounded-sm mfs-text",{"tab-menu__item--active":b===t.modelValue,"tab-menu__item--disabled mfs-disabled":u.disabled}]),"aria-selected":b===t.modelValue,"aria-disabled":u.disabled||void 0,tabindex:b===t.modelValue?0:-1,onClick:g=>k(u,b,g)},[u.icon?(e.openBlock(),e.createElementBlock("span",fp,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.label),1)],10,mp)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.to?"router-link":"a"),{key:1,ref_for:!0,ref:g=>c(b,g),to:u.to,href:u.href,role:"tab",class:e.normalizeClass(["tab-menu__item mfs-rounded-sm mfs-text",{"tab-menu__item--active":b===t.modelValue,"tab-menu__item--disabled mfs-disabled":u.disabled}]),"aria-selected":b===t.modelValue,"aria-disabled":u.disabled||void 0,tabindex:b===t.modelValue?0:-1,onClick:g=>k(u,b,g)},{default:e.withCtx(()=>[u.icon?(e.openBlock(),e.createElementBlock("span",pp,e.toDisplayString(u.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(u.label),1)]),_:2},1032,["to","href","class","aria-selected","aria-disabled","tabindex","onClick"]))],64))),128))],34)]))}}),[["__scopeId","data-v-8e6dcb53"]]),up={class:"order-list mfs-surface mfs-rounded mfs-shadow-card"},kp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},hp={key:1,class:"order-list__header"},gp={class:"order-list__title mfs-title"},yp={class:"order-list__body"},bp={class:"order-list__controls",role:"group","aria-label":"Reorder controls"},Bp=["disabled"],_p=["disabled"],wp=["disabled"],Ep=["disabled"],$p={class:"order-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Orderable items"},Vp={key:0,class:"mfs-empty-state"},Cp=["aria-selected","onClick","onKeydown"],xp={class:"mfs-text"},dl=D(e.defineComponent({__name:"OrderList",props:{modelValue:{},itemKey:{default:"id"},header:{default:""},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},emits:["update:modelValue","reorder"],setup(t,{emit:s}){const l=t,o=s,a=e.ref(null),r=e.computed(()=>a.value!==null&&a.value>0),i=e.computed(()=>a.value!==null&&a.value<l.modelValue.length-1);function c(y,f){a.value=f,o("update:modelValue",y),o("reorder",y)}function d(){if(!r.value||a.value===null)return;const y=a.value,f=[...l.modelValue];[f[y-1],f[y]]=[f[y],f[y-1]],c(f,y-1)}function n(){if(!i.value||a.value===null)return;const y=a.value,f=[...l.modelValue];[f[y+1],f[y]]=[f[y],f[y+1]],c(f,y+1)}function k(){if(!r.value||a.value===null)return;const y=a.value,f=[...l.modelValue],[p]=f.splice(y,1);f.unshift(p),c(f,0)}function h(){if(!i.value||a.value===null)return;const y=a.value,f=[...l.modelValue],[p]=f.splice(y,1);f.push(p),c(f,f.length-1)}return(y,f)=>(e.openBlock(),e.createElementBlock("div",up,[t.loading?(e.openBlock(),e.createElementBlock("div",kp,[e.renderSlot(y.$slots,"loading",{},()=>[f[0]||(f[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.header||y.$slots.header?(e.openBlock(),e.createElementBlock("div",hp,[e.renderSlot(y.$slots,"header",{},()=>[e.createElementVNode("span",gp,e.toDisplayString(t.header),1)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",yp,[e.createElementVNode("div",bp,[e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!r.value,"aria-label":"Move to top",onClick:k},[...f[1]||(f[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,Bp),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!r.value,"aria-label":"Move up",onClick:d},[...f[2]||(f[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,_p),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!i.value,"aria-label":"Move down",onClick:n},[...f[3]||(f[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,wp),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!i.value,"aria-label":"Move to bottom",onClick:h},[...f[4]||(f[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,Ep)]),e.createElementVNode("ul",$p,[!t.loading&&t.modelValue.length===0?(e.openBlock(),e.createElementBlock("li",Vp,[e.renderSlot(y.$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,(p,m)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(be)(p,m,t.itemKey),class:e.normalizeClass(["order-list__item mfs-rounded-sm",{"order-list__item--selected":a.value===m}]),role:"option","aria-selected":a.value===m,tabindex:"0",onClick:u=>a.value=m,onKeydown:[e.withKeys(e.withModifiers(u=>a.value=m,["prevent"]),["enter"]),e.withKeys(e.withModifiers(u=>a.value=m,["prevent"]),["space"])]},[e.renderSlot(y.$slots,"item",{item:p,index:m,selected:a.value===m},()=>[e.createElementVNode("span",xp,e.toDisplayString(p),1)],!0)],42,Cp))),128))])])]))}}),[["__scopeId","data-v-8ff7425c"]]),Np={class:"pick-list"},Sp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Mp={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},Dp={key:0,class:"pick-list__header mfs-text"},zp={class:"pick-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Source items"},Tp={key:0,class:"mfs-empty-state"},Lp=["aria-selected","onClick","onKeydown"],Ip={class:"mfs-text"},Rp={class:"pick-list__controls",role:"group","aria-label":"Transfer controls"},Pp=["disabled"],Fp=["disabled"],Ap=["disabled"],jp=["disabled"],Kp={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},Op={key:0,class:"pick-list__header mfs-text"},Up={class:"pick-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Target items"},Hp={key:0,class:"mfs-empty-state"},Wp=["aria-selected","onClick","onKeydown"],Gp={class:"mfs-text"},cl=D(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"}},emits:["update:source","update:target","transfer"],setup(t,{emit:s}){const l=t,o=s,a=e.ref([]),r=e.ref([]);function i(f,p){return(f==="source"?a.value:r.value).includes(p)}function c(f,p){const m=f==="source"?a:r,u=m.value.indexOf(p);u>=0?m.value.splice(u,1):m.value.push(p)}function d(f,p){a.value=[],r.value=[],o("update:source",f),o("update:target",p),o("transfer",{source:f,target:p})}function n(){const f=new Set(a.value),p=l.source.filter((u,b)=>f.has(b)),m=l.source.filter((u,b)=>!f.has(b));d(m,[...l.target,...p])}function k(){d([],[...l.target,...l.source])}function h(){const f=new Set(r.value),p=l.target.filter((u,b)=>f.has(b)),m=l.target.filter((u,b)=>!f.has(b));d([...l.source,...p],m)}function y(){d([...l.source,...l.target],[])}return(f,p)=>(e.openBlock(),e.createElementBlock("div",Np,[t.loading?(e.openBlock(),e.createElementBlock("div",Sp,[e.renderSlot(f.$slots,"loading",{},()=>[p[0]||(p[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Mp,[t.sourceHeader?(e.openBlock(),e.createElementBlock("div",Dp,e.toDisplayString(t.sourceHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",zp,[!t.loading&&t.source.length===0?(e.openBlock(),e.createElementBlock("li",Tp,[e.renderSlot(f.$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,(m,u)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(be)(m,u,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":i("source",u)}]),role:"option","aria-selected":i("source",u),tabindex:"0",onClick:b=>c("source",u),onKeydown:[e.withKeys(e.withModifiers(b=>c("source",u),["prevent"]),["enter"]),e.withKeys(e.withModifiers(b=>c("source",u),["prevent"]),["space"])]},[e.renderSlot(f.$slots,"item",{item:m,index:u,list:"source"},()=>[e.createElementVNode("span",Ip,e.toDisplayString(m),1)],!0)],42,Lp))),128))])]),e.createElementVNode("div",Rp,[e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:a.value.length===0,"aria-label":"Move selected to target",onClick:n},[...p[1]||(p[1]=[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,Pp),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:k},[...p[2]||(p[2]=[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,Fp),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:r.value.length===0,"aria-label":"Move selected to source",onClick:h},[...p[3]||(p[3]=[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[4]||(p[4]=[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,jp)]),e.createElementVNode("div",Kp,[t.targetHeader?(e.openBlock(),e.createElementBlock("div",Op,e.toDisplayString(t.targetHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Up,[!t.loading&&t.target.length===0?(e.openBlock(),e.createElementBlock("li",Hp,[e.renderSlot(f.$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,(m,u)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(be)(m,u,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":i("target",u)}]),role:"option","aria-selected":i("target",u),tabindex:"0",onClick:b=>c("target",u),onKeydown:[e.withKeys(e.withModifiers(b=>c("target",u),["prevent"]),["enter"]),e.withKeys(e.withModifiers(b=>c("target",u),["prevent"]),["space"])]},[e.renderSlot(f.$slots,"item",{item:m,index:u,list:"target"},()=>[e.createElementVNode("span",Gp,e.toDisplayString(m),1)],!0)],42,Wp))),128))])])]))}}),[["__scopeId","data-v-a25b1467"]]),qp={class:"tree-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card"},Yp={class:"tree-table__wrap"},Xp={class:"tree-table__table"},Zp={key:0},Jp=["colspan"],Qp=["aria-expanded","aria-label","onClick"],vp={key:1,class:"tree-table__spacer","aria-hidden":"true"},eu={key:0,class:"mfs-loading-overlay","aria-busy":"true"},ml=D(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:s}){const l=t,o=s,a=e.ref([...l.expandedKeys]);e.watch(()=>l.expandedKeys,c=>{a.value=[...c]});const r=e.computed(()=>{const c=[],d=new Set(a.value);function n(k,h){for(const y of k){const f=Array.isArray(y.children)&&y.children.length>0||l.lazy&&y.leaf!==!0,p=f&&d.has(y.key);c.push({node:y,depth:h,hasChildren:f,expanded:p}),p&&y.children&&n(y.children,h+1)}}return n(l.nodes,0),c});function i(c){const d=new Set(a.value),n=!d.has(c.key);n?d.add(c.key):d.delete(c.key);const k=Array.from(d);a.value=k,o("update:expandedKeys",k),o("node-toggle",c,n),n&&l.lazy&&(!c.children||c.children.length===0)&&o("lazy-load",c)}return(c,d)=>(e.openBlock(),e.createElementBlock("div",qp,[e.createElementVNode("div",Yp,[e.createElementVNode("table",Xp,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,n=>(e.openBlock(),e.createElementBlock("th",{key:n.key,class:e.normalizeClass(["tree-table__th mfs-text-muted",n.align?`tree-table__cell--${n.align}`:""]),style:e.normalizeStyle(n.width?{width:n.width}:void 0)},e.toDisplayString(n.label),7))),128))])]),e.createElementVNode("tbody",null,[r.value.length===0?(e.openBlock(),e.createElementBlock("tr",Zp,[e.createElementVNode("td",{colspan:t.columns.length,class:"tree-table__empty mfs-text-muted"},[e.renderSlot(c.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)],8,Jp)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(r.value,n=>(e.openBlock(),e.createElementBlock("tr",{key:n.node.key,class:"tree-table__row"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,(k,h)=>(e.openBlock(),e.createElementBlock("td",{key:k.key,class:e.normalizeClass(["tree-table__td mfs-text",k.align?`tree-table__cell--${k.align}`:""])},[h===0?(e.openBlock(),e.createElementBlock("div",{key:0,class:"tree-table__first-cell",style:e.normalizeStyle({paddingLeft:`${n.depth*20}px`})},[n.hasChildren?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree-table__toggle mfs-text-muted",{"tree-table__toggle--expanded":n.expanded}]),"aria-expanded":n.expanded,"aria-label":n.expanded?"Collapse row":"Expand row",onClick:y=>i(n.node)},[...d[0]||(d[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,Qp)):(e.openBlock(),e.createElementBlock("span",vp)),e.renderSlot(c.$slots,`cell-${k.key}`,{node:n.node,value:n.node.data[k.key],depth:n.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(n.node.data[k.key]??""),1)],!0)],4)):e.renderSlot(c.$slots,`cell-${k.key}`,{node:n.node,value:n.node.data[k.key],depth:n.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(n.node.data[k.key]??""),1)],!0,1)],2))),128))]))),128))])])]),t.loading?(e.openBlock(),e.createElementBlock("div",eu,[e.renderSlot(c.$slots,"loading",{},()=>[d[1]||(d[1]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7d4f20c5"]]),tu=["aria-busy"],lu={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ou={key:1,class:"mfs-empty-state"},nu={class:"org-chart__node-wrap"},au={class:"org-chart__label mfs-title"},su={key:0,class:"org-chart__title mfs-caption"},ru=["aria-expanded","aria-label"],iu={key:0,class:"org-chart__children"},fl=D(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:s}){const l=t,o=s,a=e.ref(!0),r=e.computed(()=>{var d;return Array.isArray((d=l.value)==null?void 0:d.children)&&l.value.children.length>0}),i=e.computed(()=>l.value?l.expandedKeys?l.expandedKeys.includes(l.value.key):a.value:!1);e.watch(()=>l.expandedKeys,()=>{l.expandedKeys&&l.value&&(a.value=l.expandedKeys.includes(l.value.key))});function c(){if(!(!l.value||!r.value))if(l.expandedKeys){const d=new Set(l.expandedKeys);d.has(l.value.key)?d.delete(l.value.key):d.add(l.value.key),o("update:expandedKeys",Array.from(d))}else a.value=!a.value}return(d,n)=>{const k=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",lu,[e.renderSlot(d.$slots,"loading",{},()=>[n[4]||(n[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",ou,[e.renderSlot(d.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):t.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[e.createElementVNode("div",nu,[e.createElementVNode("div",{class:"org-chart__node mfs-surface mfs-rounded mfs-shadow mfs-interactive mfs-focus-ring",tabindex:"0",onClick:n[0]||(n[0]=h=>d.$emit("node-click",t.value)),onKeydown:n[1]||(n[1]=e.withKeys(e.withModifiers(h=>d.$emit("node-click",t.value),["prevent"]),["enter"]))},[e.renderSlot(d.$slots,"node",{node:t.value,expanded:i.value},()=>[e.createElementVNode("div",au,e.toDisplayString(t.value.label),1),t.value.title?(e.openBlock(),e.createElementBlock("div",su,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":i.value,"aria-label":i.value?`Collapse ${t.value.label}`:`Expand ${t.value.label}`,onClick:e.withModifiers(c,["stop"])},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass({"org-chart__chevron--collapsed":!i.value}),viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[...n[5]||(n[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,ru)):e.createCommentVNode("",!0)]),r.value&&i.value?(e.openBlock(),e.createElementBlock("div",iu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.value.children,h=>(e.openBlock(),e.createElementBlock("div",{key:h.key,class:"org-chart__branch"},[e.createVNode(k,{value:h,collapsible:t.collapsible,"expanded-keys":t.expandedKeys,level:t.level+1,"onUpdate:expandedKeys":n[2]||(n[2]=y=>d.$emit("update:expandedKeys",y)),onNodeClick:n[3]||(n[3]=y=>d.$emit("node-click",y))},e.createSlots({_:2},[d.$slots.node?{name:"node",fn:e.withCtx(y=>[e.renderSlot(d.$slots,"node",e.mergeProps({ref_for:!0},y),void 0,!0)]),key:"0"}:void 0]),1032,["value","collapsible","expanded-keys","level"])]))),128))])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],10,tu)}}}),[["__scopeId","data-v-426d2664"]]),du={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},cu={key:1,class:"mfs-empty-state"},mu={class:"mfs-text"},pl=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(0),i=e.ref(300);e.onMounted(()=>{a.value&&(i.value=a.value.clientHeight||300)});function c(){a.value&&(r.value=a.value.scrollTop,i.value=a.value.clientHeight||i.value,l.lazy&&o("lazy-load",{first:n.value,last:k.value}))}const d=e.computed(()=>l.items.length*l.itemSize),n=e.computed(()=>{const f=Math.floor(r.value/l.itemSize)-l.buffer;return Math.max(0,f)}),k=e.computed(()=>{const f=Math.ceil(i.value/l.itemSize),p=Math.floor(r.value/l.itemSize)+f+l.buffer;return Math.min(l.items.length,p)}),h=e.computed(()=>n.value*l.itemSize),y=e.computed(()=>l.items.slice(n.value,k.value).map((f,p)=>({item:f,index:n.value+p})));return(f,p)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:a,class:"virtual-scroller mfs-surface mfs-rounded mfs-shadow-card",style:e.normalizeStyle({height:t.height}),onScroll:c},[t.loading?(e.openBlock(),e.createElementBlock("div",du,[e.renderSlot(f.$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",cu,[e.renderSlot(f.$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:`${d.value}px`})},[e.createElementVNode("div",{class:"virtual-scroller__content",style:e.normalizeStyle({transform:`translateY(${h.value}px)`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,m=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(be)(m.item,m.index,t.itemKey),class:"virtual-scroller__item",style:e.normalizeStyle({height:`${t.itemSize}px`})},[e.renderSlot(f.$slots,"item",{item:m.item,index:m.index},()=>[e.createElementVNode("span",mu,e.toDisplayString(m.item),1)],!0)],4))),128))],4)],4))],36))}}),[["__scopeId","data-v-5a8d047c"]]),fu={class:"meter-group mfs-card"},pu=["aria-valuenow","aria-valuemax"],uu=["title"],ku={key:0,class:"meter-group__legend"},hu={class:"meter-group__label mfs-text"},gu={class:"meter-group__value mfs-text-muted"},ul=D(e.defineComponent({__name:"MeterGroup",props:{values:{},max:{default:100},showLegend:{type:Boolean,default:!0}},setup(t){const s=t,l=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)"],o=e.computed(()=>s.values.reduce((i,c)=>i+Math.max(0,c.value),0));function a(i){const c=s.max>0?s.max:100;return Math.min(100,Math.max(0,i/c*100))}function r(i){return l[i%l.length]}return(i,c)=>(e.openBlock(),e.createElementBlock("div",fu,[e.createElementVNode("div",{class:"meter-group__track mfs-inset mfs-pill",role:"progressbar","aria-valuenow":o.value,"aria-valuemin":"0","aria-valuemax":t.max},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(d,n)=>(e.openBlock(),e.createElementBlock("div",{key:d.label,class:"meter-group__segment",style:e.normalizeStyle({width:`${a(d.value)}%`,backgroundColor:d.color||r(n)}),title:`${d.label}: ${d.value}`},null,12,uu))),128))],8,pu),t.showLegend?(e.openBlock(),e.createElementBlock("ol",ku,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.values,(d,n)=>(e.openBlock(),e.createElementBlock("li",{key:d.label,class:"meter-group__legend-item"},[e.createElementVNode("span",{class:"meter-group__dot mfs-pill",style:e.normalizeStyle({backgroundColor:d.color||r(n)}),"aria-hidden":"true"},null,4),e.createElementVNode("span",hu,e.toDisplayString(d.label),1),e.createElementVNode("span",gu,e.toDisplayString(d.value)+" ("+e.toDisplayString(Math.round(a(d.value)))+"%)",1)]))),128))])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7ff895f3"]]),yu={class:"inplace"},bu=["tabindex","aria-disabled","onKeydown"],Bu={class:"inplace__inner"},kl=D(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:s}){const l=t,o=s,a=e.ref(l.active);e.watch(()=>l.active,d=>{a.value=d});const r=e.computed(()=>a.value);function i(){l.disabled||r.value||(a.value=!0,o("update:active",!0),o("open"))}function c(){r.value&&(a.value=!1,o("update:active",!1),o("close"))}return(d,n)=>(e.openBlock(),e.createElementBlock("div",yu,[r.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"inplace__content mfs-surface mfs-rounded-md mfs-shadow",onKeydown:e.withKeys(c,["esc"])},[e.createElementVNode("div",Bu,[e.renderSlot(d.$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:c},[...n[1]||(n[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:i,onKeydown:[e.withKeys(e.withModifiers(i,["prevent"]),["enter"]),e.withKeys(e.withModifiers(i,["prevent"]),["space"])]},[e.renderSlot(d.$slots,"display",{},()=>[n[0]||(n[0]=e.createElementVNode("span",{class:"mfs-text-muted"},"Click to edit",-1))],!0)],42,bu))]))}}),[["__scopeId","data-v-befa9d74"]]),_u={class:"mfs-flex mfs-items-start mfs-gap-2-5 mfs-mb-3"},wu={class:"mfs-confirm-popup__message mfs-text mfs-m-0"},Eu={class:"mfs-flex mfs-justify-end mfs-gap-2"},hl=D(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:s,emit:l}){const o=t,a=l,r=e.ref(null),i=e.ref(!1),c=e.ref(null),d=e.ref({}),n=e.ref({top:0,left:0}),k=e.computed(()=>o.modelValue!==void 0),h=e.computed(()=>k.value?!!o.modelValue:i.value),y=e.computed(()=>d.value.message??o.message),f=e.computed(()=>d.value.acceptLabel??o.acceptLabel),p=e.computed(()=>d.value.rejectLabel??o.rejectLabel),m=e.computed(()=>d.value.variant??o.variant),u=e.computed(()=>({top:`${n.value.top}px`,left:`${n.value.left}px`}));function b(M){return M?M instanceof HTMLElement?M:M.currentTarget??M.target:null}async function g(){var Q;await e.nextTick();const M=c.value??b(o.target);if(!M||typeof window>"u")return;const N=M.getBoundingClientRect(),I=((Q=r.value)==null?void 0:Q.offsetWidth)??260,H=Math.min(Math.max(12,N.left+N.width/2-I/2),window.innerWidth-I-12),G=N.bottom+10;n.value={top:G,left:H}}function B(M){k.value||(i.value=M),a("update:modelValue",M)}function w(M,N={}){c.value=b(M),d.value=N,B(!0),g()}function _(){B(!1)}function $(){var M,N;(N=(M=d.value).onAccept)==null||N.call(M),a("accept"),_()}function C(){var M,N;(N=(M=d.value).onReject)==null||N.call(M),a("reject"),_()}const E=M=>{var H;const N=M.target,I=c.value??b(o.target);(H=r.value)!=null&&H.contains(N)||I!=null&&I.contains(N)||_()},V=M=>{M.key==="Escape"&&_()};return e.watch(h,M=>{typeof document>"u"||(M?(g(),document.addEventListener("pointerdown",E),document.addEventListener("keydown",V)):(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",V)))}),e.onBeforeUnmount(()=>{typeof document<"u"&&(document.removeEventListener("pointerdown",E),document.removeEventListener("keydown",V))}),s({show:w,hide:_}),(M,N)=>(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-confirm-popup"},{default:e.withCtx(()=>[h.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(u.value),role:"alertdialog","aria-modal":"false"},[e.createElementVNode("div",_u,[e.createElementVNode("span",{class:e.normalizeClass(["mfs-confirm-popup__icon mfs-shrink-0",[`mfs-text-${m.value}`]]),"aria-hidden":"true"},[...N[0]||(N[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",wu,e.toDisplayString(y.value),1)]),e.createElementVNode("div",Eu,[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:C},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-${m.value}`]]),onClick:$},e.toDisplayString(f.value),3)])],4)):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-57b1abca"]]),$u={class:"mfs-inline-msg__icon","aria-hidden":"true"},Vu={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Cu={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},xu={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Nu={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Su={class:"mfs-inline-msg__text"},gl=D(e.defineComponent({__name:"InlineMessage",props:{severity:{default:"info"},text:{default:""}},setup(t){return(s,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",$u,[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Vu,[...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",Cu,[...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",xu,[...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",Nu,[...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",Su,[e.renderSlot(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.text),1)],!0)])],2))}}),[["__scopeId","data-v-40ba4b5c"]]),Mu=["aria-busy"],Du=["aria-label"],zu={class:"mfs-blockui__content mfs-surface mfs-rounded mfs-shadow"},Tu={key:0,class:"mfs-blockui__label mfs-text"},yl=D(e.defineComponent({__name:"BlockUI",props:{blocked:{type:Boolean,default:!1},fullScreen:{type:Boolean,default:!1},label:{default:""}},setup(t){return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-blockui","aria-busy":t.blocked},[e.renderSlot(s.$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(s.$slots,"overlay",{},()=>[e.createElementVNode("div",zu,[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",Tu,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)])],!0)],10,Du)):e.createCommentVNode("",!0)]),_:3})],8,["disabled"]))],8,Mu))}}),[["__scopeId","data-v-59ef354e"]]),Lu=["aria-busy","onKeydown"],Iu={class:"mfs-galleria__stage"},Ru={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Pu={key:1,class:"mfs-empty-state"},Fu=["src","alt"],Au=["aria-label"],ju={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Ku={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Ou={key:4,class:"mfs-galleria__caption"},Uu={key:0,class:"mfs-galleria__thumbs"},Hu=["aria-label","onClick"],Wu=["src","alt"],bl=D(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:s}){const l=t,o=s,a=e.ref(l.activeIndex),r=e.ref(l.fullscreen);e.watch(()=>l.activeIndex,k=>{a.value=k});const i=e.computed(()=>l.images[a.value]??null),c=k=>{if(l.images.length===0)return;const h=(k+l.images.length)%l.images.length;a.value=h,o("update:activeIndex",h)},d=()=>c(a.value-1),n=()=>c(a.value+1);return(k,h)=>{var y;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(d,["prevent"]),["left"]),e.withKeys(e.withModifiers(n,["prevent"]),["right"]),h[1]||(h[1]=e.withKeys(f=>r.value=!1,["escape"]))]},[e.createElementVNode("div",Iu,[t.loading?(e.openBlock(),e.createElementBlock("div",Ru,[e.renderSlot(k.$slots,"loading",{},()=>[h[2]||(h[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",Pu,[e.renderSlot(k.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[i.value?(e.openBlock(),e.createElementBlock("img",{key:0,src:i.value.src,alt:i.value.alt||i.value.title||"Gallery image",class:"mfs-galleria__image"},null,8,Fu)):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:d},[...h[3]||(h[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:n},[...h[4]||(h[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:h[0]||(h[0]=f=>r.value=!r.value)},[r.value?(e.openBlock(),e.createElementBlock("svg",Ku,[...h[6]||(h[6]=[e.createElementVNode("path",{d:"M4 14h6v6M20 10h-6V4M14 10l7-7M3 21l7-7"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",ju,[...h[5]||(h[5]=[e.createElementVNode("path",{d:"M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"},null,-1)])]))],8,Au)):e.createCommentVNode("",!0),(y=i.value)!=null&&y.title?(e.openBlock(),e.createElementBlock("div",Ou,e.toDisplayString(i.value.title),1)):e.createCommentVNode("",!0)],64))]),t.showThumbnails&&t.images.length>1?(e.openBlock(),e.createElementBlock("div",Uu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(f,p)=>(e.openBlock(),e.createElementBlock("button",{key:p,type:"button",class:e.normalizeClass(["mfs-galleria__thumb mfs-rounded-sm",{"mfs-galleria__thumb--active":p===a.value}]),"aria-label":`View image ${p+1}`,onClick:m=>c(p)},[e.createElementVNode("img",{src:f.thumbnail||f.src,alt:f.alt||`Thumbnail ${p+1}`},null,8,Wu)],10,Hu))),128))])):e.createCommentVNode("",!0)],42,Lu)}}}),[["__scopeId","data-v-cfe349fe"]]),Gu=["disabled"],qu=["onKeydown"],Yu=["src"],Xu={key:2,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},Zu={key:3,class:"mfs-cropper__controls mfs-flex mfs-flex-col mfs-gap-3"},Ju={class:"mfs-row mfs-justify-between"},Qu={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-1 mfs-min-w-0"},vu=["disabled"],ek=["disabled"],tk=["disabled"],lk={class:"mfs-flex mfs-items-center mfs-gap-1-5 mfs-shrink-0"},ok=["disabled"],nk=["disabled"],ak=["disabled"],sk={class:"mfs-row mfs-justify-between mfs-flex-wrap mfs-gap-2"},rk={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-wrap"},ik=["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"},ck=["aria-pressed","disabled"],mk=["aria-pressed","disabled"],fk={class:"mfs-flex mfs-items-center mfs-gap-2"},pk=["disabled"],uk=["disabled"],He=D(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:s,emit:l}){const o=t,a=l,r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(null),n=e.ref(null),k=e.ref(!1),h=e.ref(null),y=e.ref(!1),f=e.ref(!1),p=e.ref(0),m=e.ref(0),u=e.ref(320),b=e.ref(260),g=e.ref(1),B=e.ref(0),w=e.ref(0),_=e.ref(0),$=e.ref(!1);let C=0,E=0,V=0,M=0,N=null;const I=e.ref(o.shape);e.watch(()=>o.shape,j=>{I.value=j});function H(j){o.disabled||I.value===j||(I.value=j,a("update:shape",j))}const G=e.computed(()=>n.value?n.value:o.src?o.src:typeof o.modelValue=="string"&&o.modelValue?o.modelValue:d.value?d.value:null),Q=e.computed(()=>I.value==="circle"?1:o.aspectRatio>0?o.aspectRatio:1),ee=e.computed(()=>{const j=Math.max(80,u.value*.82),P=Math.max(80,b.value*.82),q=Q.value;let v=j,le=v/q;return le>P&&(le=P,v=le*q),{width:v,height:le}}),K=e.computed(()=>Math.abs(B.value%180)===90),U=e.computed(()=>{if(!p.value||!m.value)return 1;const j=K.value?m.value:p.value,P=K.value?p.value:m.value;return Math.max(ee.value.width/j,ee.value.height/P)}),Y=e.computed(()=>U.value*g.value);function L(j,P,q){return Math.min(q,Math.max(P,j))}function T(){if(!p.value||!m.value)return;const j=K.value?m.value:p.value,P=K.value?p.value:m.value,q=j*Y.value,v=P*Y.value,le=Math.max(0,(q-ee.value.width)/2),te=Math.max(0,(v-ee.value.height)/2);w.value=L(w.value,-le,le),_.value=L(_.value,-te,te)}const R=e.computed(()=>({width:`${p.value}px`,height:`${m.value}px`,marginLeft:`${-p.value/2}px`,marginTop:`${-m.value/2}px`,transform:`translate(${w.value}px, ${_.value}px) rotate(${B.value}deg) scale(${Y.value})`})),S=e.computed(()=>({width:`${ee.value.width}px`,height:`${ee.value.height}px`}));function z(){d.value&&(URL.revokeObjectURL(d.value),d.value=null)}function W(j){if(!(j.type.startsWith("image/")||/\.(png|jpe?g|webp|gif|bmp|svg|avif)$/i.test(j.name))){const v=`Unsupported file type: ${j.name}`;h.value=v,a("error",v);return}z(),h.value=null,k.value=!1;const q=URL.createObjectURL(j);d.value=q,n.value=q,we()}function O(){var j;o.disabled||(j=r.value)==null||j.click()}function X(j){var v;const P=j.target,q=(v=P.files)==null?void 0:v[0];q&&W(q),P.value=""}function F(j){var q,v;if(y.value=!1,o.disabled)return;const P=(v=(q=j.dataTransfer)==null?void 0:q.files)==null?void 0:v[0];P&&W(P)}function ne(){const j=c.value;j&&(p.value=j.naturalWidth,m.value=j.naturalHeight,k.value=!0,h.value=null,T())}function J(){k.value=!1;const j="Failed to load image";h.value=j,a("error",j)}function ae(j){if(o.disabled||!k.value)return;const P=i.value;P&&($.value=!0,C=j.clientX,E=j.clientY,V=w.value,M=_.value,P.setPointerCapture(j.pointerId))}function A(j){$.value&&(w.value=V+(j.clientX-C),_.value=M+(j.clientY-E),T())}function Z(j){var P;$.value&&($.value=!1,(P=i.value)==null||P.releasePointerCapture(j.pointerId))}function se(j){if(o.disabled||!k.value)return;const P=j.deltaY<0?.1:-.1;Qe(P)}function Qe(j){g.value=Number(L(g.value+j,1,3).toFixed(2))}function oo(j){B.value=(B.value+j)%360,T()}function we(){g.value=1,B.value=0,w.value=0,_.value=0,T()}async function no(){const j=c.value;if(!j||!k.value||f.value)return null;f.value=!0,h.value=null;try{const P=Q.value,q=P>=1?o.outputSize:Math.round(o.outputSize*P),v=P>=1?Math.round(o.outputSize/P):o.outputSize,le=document.createElement("canvas");le.width=q,le.height=v;const te=le.getContext("2d");if(!te)throw new Error("Canvas 2D context is unavailable");o.outputType==="image/jpeg"&&(te.fillStyle="#ffffff",te.fillRect(0,0,q,v)),I.value==="circle"&&(te.beginPath(),te.arc(q/2,v/2,Math.min(q,v)/2,0,Math.PI*2),te.clip());const ve=q/ee.value.width;te.save(),te.translate(q/2+w.value*ve,v/2+_.value*ve),te.rotate(B.value*Math.PI/180);const ro=Y.value*ve;te.scale(ro,ro),te.drawImage(j,-p.value/2,-m.value/2,p.value,m.value),te.restore();const io=await new Promise((pg,ug)=>{le.toBlob(fo=>fo?pg(fo):ug(new Error("Failed to export cropped image")),o.outputType,o.quality)}),fg=le.toDataURL(o.outputType,o.quality),co=new File([io],o.fileName,{type:o.outputType}),mo={blob:io,dataUrl:fg,file:co};return a("update:modelValue",co),a("crop",mo),mo}catch(P){const q=P instanceof Error?P.message:"Failed to crop image";return h.value=q,a("error",q),null}finally{f.value=!1}}function ao(){const j=i.value;if(!j)return;const P=j.getBoundingClientRect();P.width>0&&P.height>0&&(u.value=P.width,b.value=P.height,T())}function so(){N==null||N.disconnect(),!(!i.value||typeof ResizeObserver>"u")&&(N=new ResizeObserver(ao),N.observe(i.value),ao())}return e.watch(()=>o.modelValue,j=>{n.value=null,z(),k.value=!1,j instanceof File&&(d.value=URL.createObjectURL(j)),we()},{immediate:!0}),e.watch(()=>o.src,()=>{n.value=null,k.value=!1,we()}),e.watch([g,Q],()=>{T()}),e.watch(i,j=>{j&&so()}),e.onMounted(()=>{so()}),e.onBeforeUnmount(()=>{N==null||N.disconnect(),z()}),s({crop:no,reset:we}),(j,P)=>(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:X},null,40,Gu),G.value?(e.openBlock(),e.createElementBlock("div",{key:1,ref_key:"stageRef",ref:i,class:e.normalizeClass(["mfs-cropper__stage mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none",$.value?"mfs-cropper__stage--grabbing":"mfs-cropper__stage--grab"]),onPointerdown:ae,onPointermove:A,onPointerup:Z,onPointercancel:Z,onWheel:e.withModifiers(se,["prevent"])},[e.createElementVNode("img",{ref_key:"imgRef",ref:c,src:G.value,alt:"Crop source",draggable:"false",class:"mfs-cropper__img",style:e.normalizeStyle(R.value),onLoad:ne,onError:J},null,44,Yu),k.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__viewport mfs-absolute",{"mfs-cropper__viewport--circle":I.value==="circle"}]),style:e.normalizeStyle(S.value),"aria-hidden":"true"},[...P[11]||(P[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":y.value}]),role:"button",tabindex:"0","aria-label":"Select an image to crop",onClick:O,onKeydown:[e.withKeys(e.withModifiers(O,["prevent"]),["enter"]),e.withKeys(e.withModifiers(O,["prevent"]),["space"])],onDragover:P[0]||(P[0]=e.withModifiers(q=>y.value=!0,["prevent"])),onDragleave:P[1]||(P[1]=e.withModifiers(q=>y.value=!1,["prevent"])),onDrop:e.withModifiers(F,["prevent"])},[...P[10]||(P[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,qu)),h.value?(e.openBlock(),e.createElementBlock("div",Xu,e.toDisplayString(h.value),1)):e.createCommentVNode("",!0),t.showControls&&G.value?(e.openBlock(),e.createElementBlock("div",Zu,[e.createElementVNode("div",Ju,[e.createElementVNode("div",Qu,[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||g.value<=1,onClick:P[2]||(P[2]=q=>Qe(-.15))},[...P[12]||(P[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,vu),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":P[3]||(P[3]=q=>g.value=q),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,ek),[[e.vModelText,g.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||g.value>=3,onClick:P[4]||(P[4]=q=>Qe(.15))},[...P[13]||(P[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,tk)]),e.createElementVNode("div",lk,[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:P[5]||(P[5]=q=>oo(-90))},[...P[14]||(P[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,ok),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:P[6]||(P[6]=q=>oo(90))},[...P[15]||(P[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,nk),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:we}," Reset ",8,ak)])]),e.createElementVNode("div",sk,[e.createElementVNode("div",rk,[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:O}," Change Image ",8,ik),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",I.value==="rect"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":I.value==="rect",disabled:t.disabled,onClick:P[7]||(P[7]=q=>H("rect"))},[...P[16]||(P[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,ck),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",I.value==="circle"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":I.value==="circle",disabled:t.disabled,onClick:P[8]||(P[8]=q=>H("circle"))},[...P[17]||(P[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,mk)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",fk,[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:P[9]||(P[9]=q=>a("cancel"))}," Cancel ",8,pk),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||!k.value||f.value,onClick:no},e.toDisplayString(f.value?"Cropping...":"Crop"),9,uk)])])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4a71ca25"]]),kk=["aria-busy"],hk={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},gk=["onKeydown"],yk=["accept","multiple","disabled"],bk={key:0,class:"mfs-upload__hint mfs-caption mfs-m-0"},Bk={key:0},_k={key:1},wk={key:2},Ek={key:1,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},$k={key:2,class:"mfs-upload__progress-wrap mfs-flex mfs-items-center mfs-gap-2-5"},Vk={class:"mfs-upload__progress-track mfs-pill mfs-shadow-inset mfs-flex-1 mfs-overflow-hidden"},Ck={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"},Nk={class:"mfs-upload__file-info mfs-flex mfs-flex-col mfs-min-w-0"},Sk={class:"mfs-upload__file-name mfs-text mfs-font-semibold mfs-truncate"},Mk={class:"mfs-upload__file-size mfs-caption"},Dk=["onClick"],Bl=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(l.modelValue?[...l.modelValue]:[]),i=e.ref([]),c=e.ref(!1),d=e.ref(null),n=e.computed(()=>l.error||d.value),k=e.computed(()=>i.value[0]??null),h=e.computed(()=>k.value!==null),y=e.computed(()=>{const C=k.value;return C?`${C.name.replace(/\.[^.]+$/,"")||"cropped-image"}.png`:"cropped-image.png"});e.watch(()=>l.modelValue,C=>{C&&(r.value=[...C])});function f(C){return C<1024?`${C} B`:C<1024*1024?`${(C/1024).toFixed(1)} KB`:`${(C/(1024*1024)).toFixed(1)} MB`}function p(C,E){if(!E)return!0;const V=E.split(",").map(I=>I.trim().toLowerCase()).filter(Boolean);if(V.length===0)return!0;const M=C.name.toLowerCase(),N=C.type.toLowerCase();return V.some(I=>I.startsWith(".")?M.endsWith(I):I.endsWith("/*")?N.startsWith(I.slice(0,-1)):N===I)}function m(C){if(!C||l.disabled||l.loading)return;d.value=null;const E=[];for(const V of Array.from(C)){if(!p(V,l.accept)){const M=`Invalid file type: ${V.name}`;d.value=M,o("error",M);continue}if(l.maxFileSize&&V.size>l.maxFileSize){const M=`File too large: ${V.name} (max ${f(l.maxFileSize)})`;d.value=M,o("error",M);continue}E.push(V)}if(E.length!==0){if(l.crop){const V=l.multiple?E:[E[0]],M=V.filter(I=>I.type.startsWith("image/")),N=V.filter(I=>!I.type.startsWith("image/"));N.length>0&&(r.value=l.multiple?[...r.value,...N]:[N[0]],o("update:modelValue",r.value),o("select",r.value)),M.length>0&&(i.value=l.multiple?[...i.value,...M]:[M[0]]);return}r.value=l.multiple?[...r.value,...E]:[E[0]],o("update:modelValue",r.value),o("select",r.value)}}function u(C){r.value=l.multiple?[...r.value,C.file]:[C.file],o("update:modelValue",r.value),o("select",r.value),i.value.shift()}function b(){i.value.shift()}const g=()=>{var C;!l.disabled&&!l.loading&&((C=a.value)==null||C.click())},B=C=>{const E=C.target;m(E.files),E.value=""},w=()=>{!l.disabled&&!l.loading&&(c.value=!0)},_=C=>{var E;c.value=!1,m(((E=C.dataTransfer)==null?void 0:E.files)??null)},$=C=>{const[E]=r.value.splice(C,1);o("update:modelValue",r.value),E&&o("remove",E),r.value.length===0&&o("clear")};return(C,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",hk,[...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":c.value,"mfs-upload__dropzone--disabled mfs-disabled":t.disabled||t.loading}]),role:"button",tabindex:"0","aria-label":"Upload files",onClick:g,onKeydown:[e.withKeys(e.withModifiers(g,["prevent"]),["enter"]),e.withKeys(e.withModifiers(g,["prevent"]),["space"])],onDragover:e.withModifiers(w,["prevent"]),onDragleave:E[0]||(E[0]=e.withModifiers(V=>c.value=!1,["prevent"])),onDrop:e.withModifiers(_,["prevent"])},[e.createElementVNode("input",{ref_key:"inputRef",ref:a,type:"file",class:"mfs-upload__input",accept:t.accept,multiple:t.multiple,disabled:t.disabled||t.loading,onChange:B},null,40,yk),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-56400c6e><svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" data-v-56400c6e><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" data-v-56400c6e></path><polyline points="17 8 12 3 7 8" data-v-56400c6e></polyline><line x1="12" x2="12" y1="3" y2="15" data-v-56400c6e></line></svg></span><p class="mfs-upload__title mfs-title mfs-m-0 mfs-font-semibold" data-v-56400c6e> Drag &amp; drop files here or <span class="mfs-upload__link mfs-text-primary" data-v-56400c6e>browse</span></p>',2)),t.accept||t.maxFileSize?(e.openBlock(),e.createElementBlock("p",bk,[t.accept?(e.openBlock(),e.createElementBlock("span",Bk,"Accepted: "+e.toDisplayString(t.accept),1)):e.createCommentVNode("",!0),t.accept&&t.maxFileSize?(e.openBlock(),e.createElementBlock("span",_k," · ")):e.createCommentVNode("",!0),t.maxFileSize?(e.openBlock(),e.createElementBlock("span",wk,"Max: "+e.toDisplayString(f(t.maxFileSize)),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],42,gk),n.value?(e.openBlock(),e.createElementBlock("div",Ek,e.toDisplayString(n.value),1)):e.createCommentVNode("",!0),typeof t.progress=="number"&&t.progress>0?(e.openBlock(),e.createElementBlock("div",$k,[e.createElementVNode("div",Vk,[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",Ck,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,(V,M)=>(e.openBlock(),e.createElementBlock("li",{key:`${V.name}-${V.size}-${M}`,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",Nk,[e.createElementVNode("span",Sk,e.toDisplayString(V.name),1),e.createElementVNode("span",Mk,e.toDisplayString(f(V.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:N=>$(M)},[...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,Dk)]))),128))])):e.createCommentVNode("",!0),e.createVNode(me,{"model-value":h.value,title:"Crop Image",size:"md","close-on-backdrop":!1,onClose:b},{default:e.withCtx(()=>[k.value?(e.openBlock(),e.createBlock(He,{key:0,"model-value":k.value,shape:t.cropShape,"aspect-ratio":t.cropAspectRatio,"file-name":y.value,onCrop:u,onCancel:b},null,8,["model-value","shape","aspect-ratio","file-name"])):e.createCommentVNode("",!0)]),_:1},8,["model-value"])],8,kk))}}),[["__scopeId","data-v-56400c6e"]]),zk={key:0,class:"mfs-terminal__welcome mfs-text-muted"},Tk={class:"mfs-flex mfs-gap-2"},Lk={class:"mfs-text-primary mfs-font-bold mfs-select-none"},Ik={class:"mfs-terminal__cmd"},Rk={key:0,class:"mfs-terminal__response"},Pk={class:"mfs-text-primary mfs-font-bold mfs-select-none"},Fk=["onKeydown"],_l=D(e.defineComponent({__name:"Terminal",props:{welcomeMessage:{default:""},prompt:{default:"$"},commands:{}},emits:["command"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.ref([]),i=e.ref([]),c=e.ref(-1),d=e.ref(""),n=e.ref(null),k=e.ref(null),h=()=>{var u;(u=n.value)==null||u.focus()},y=async()=>{await e.nextTick(),k.value&&(k.value.scrollTop=k.value.scrollHeight)},f=async()=>{const u=d.value.trim();if(!u)return;d.value="",i.value.push(u),c.value=i.value.length;const[b,...g]=u.split(/\s+/);if(b==="clear"){r.value=[];return}const B={command:u};r.value.push(B);const w=r.value.length-1,_=$=>{r.value[w].response=$,y()};if(o.commands&&b in o.commands){const $=await o.commands[b](g);_($)}else a("command",{command:b,args:g,raw:u,respond:_});y()},p=()=>{i.value.length!==0&&(c.value=Math.max(0,c.value-1),d.value=i.value[c.value]??"")},m=()=>{i.value.length!==0&&(c.value=Math.min(i.value.length,c.value+1),d.value=i.value[c.value]??"")};return s({clear:()=>{r.value=[]}}),(u,b)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-terminal mfs-surface mfs-font-mono mfs-rounded mfs-shadow-card mfs-blur mfs-p-4",onClick:h},[t.welcomeMessage?(e.openBlock(),e.createElementBlock("div",zk,e.toDisplayString(t.welcomeMessage),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"logRef",ref:k,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,(g,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"mfs-terminal__entry"},[e.createElementVNode("div",Tk,[e.createElementVNode("span",Lk,e.toDisplayString(t.prompt),1),e.createElementVNode("span",Ik,e.toDisplayString(g.command),1)]),g.response?(e.openBlock(),e.createElementBlock("div",Rk,e.toDisplayString(g.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(f,["prevent"])},[e.createElementVNode("span",Pk,e.toDisplayString(t.prompt),1),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:n,"onUpdate:modelValue":b[0]||(b[0]=g=>d.value=g),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(m,["prevent"]),["down"])]},null,40,Fk),[[e.vModelText,d.value]])],32)]))}}),[["__scopeId","data-v-7db4de65"]]),Ak=["aria-busy"],jk={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Kk=["viewBox","aria-label"],Ok=["x2","y1","y2"],Uk=["x","y"],Hk=["x","y","width","height","fill","onMouseenter"],Wk=["x","y","width","height","fill"],Gk=["stroke","points"],qk=["cx","cy","fill","onMouseenter"],Yk=["cx","cy"],Xk=["transform"],Zk=["d","fill","onMouseenter"],Jk=["d","fill"],Qk={key:0,class:"mfs-chart__legend mfs-flex mfs-flex-wrap mfs-gap-3 mfs-justify-center"},ue=480,Be=24,We=24,ke=20,_e=30,wl=D(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 s=t,l=e.computed(()=>{var $;return(($=s.data)==null?void 0:$.labels)??[]}),o=e.computed(()=>{var $;return(($=s.data)==null?void 0:$.datasets)??[]}),a=e.computed(()=>o.value.length===0?!0:o.value.every($=>!$.data||$.data.length===0)),r=e.computed(()=>s.height),i=Math.random().toString(36).slice(2,8),c=`mfs-chart-clay-${i}`,d=`mfs-chart-clay-pt-${i}`,n=`mfs-chart-clay-gloss-${i}`,k={"--mfs-clay-filter":`url(#${c})`,"--mfs-clay-point-filter":`url(#${d})`},h=["#8b5cf6","#06b6d4","#10b981","#f59e0b","#f43f5e","#38bdf8"],y=e.ref(null),f=e.computed(()=>{const $=o.value.flatMap(C=>C.data);return Math.max(1,...$)}),p=$=>{const C=Math.max(1,l.value.length),E=ue-Be-We;return C===1?Be+E/2:Be+E*($+.5)/C},m=$=>{const C=r.value-ke-_e;return ke+C-$/f.value*C},u=e.computed(()=>{const $=Math.max(1,l.value.length),C=Math.max(1,o.value.length),E=(ue-Be-We)/$;return Math.max(6,Math.min(34,E*.68/C))}),b=($,C)=>{const E=Math.max(1,o.value.length),V=E*u.value+(E-1)*4;return p($)-V/2+C*(u.value+4)},g=$=>$.map((C,E)=>`${p(E)},${m(C)}`).join(" "),B=e.computed(()=>{const $=o.value[0];if(!$)return[];const C=$.data.reduce((N,I)=>N+Math.max(0,I),0)||1,E=Math.min(ue,r.value)*.4,V=s.type==="doughnut"?E*.55:0;let M=-Math.PI/2;return $.data.map((N,I)=>{const H=Math.max(0,N)/C*Math.PI*2,G=M+H,Q=H>Math.PI?1:0,ee=Math.cos(M)*E,K=Math.sin(M)*E,U=Math.cos(G)*E,Y=Math.sin(G)*E;let L="";if(V>0){const T=Math.cos(G)*V,R=Math.sin(G)*V,S=Math.cos(M)*V,z=Math.sin(M)*V;L=`M ${ee} ${K} A ${E} ${E} 0 ${Q} 1 ${U} ${Y} L ${T} ${R} A ${V} ${V} 0 ${Q} 0 ${S} ${z} Z`}else L=`M 0 0 L ${ee} ${K} A ${E} ${E} 0 ${Q} 1 ${U} ${Y} Z`;return M=G,{d:L,value:N,label:l.value[I]??`Item ${I+1}`,color:h[I%h.length]}})}),w=e.computed(()=>s.type==="pie"||s.type==="doughnut"?l.value.map(($,C)=>({label:$,color:h[C%h.length]})):o.value.map(($,C)=>({label:$.label??`Series ${C+1}`,color:$.color??h[C%h.length]}))),_=($,C)=>{const E=$.currentTarget.closest(".mfs-chart__canvas");if(!E)return;const V=E.getBoundingClientRect();y.value={x:$.clientX-V.left+10,y:$.clientY-V.top-28,text:C}};return($,C)=>(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:k,"aria-busy":t.loading||void 0},[e.createElementVNode("div",{class:"mfs-chart__canvas mfs-relative mfs-w-full",style:e.normalizeStyle(t.loading&&a.value?{minHeight:`${t.height}px`}:void 0)},[t.loading?(e.openBlock(),e.createElementBlock("div",jk,[e.renderSlot($.$slots,"loading",{},()=>[C[3]||(C[3]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&a.value?(e.openBlock(),e.createElementBlock("div",{key:1,class:"mfs-empty-state",style:e.normalizeStyle({minHeight:`${t.height}px`})},[e.renderSlot($.$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 ${ue} ${r.value}`,role:"img","aria-label":`${t.type} chart`},[e.createElementVNode("defs",null,[e.createElementVNode("filter",{id:c,x:"-25%",y:"-25%",width:"150%",height:"150%"},[...C[4]||(C[4]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="3.5" result="dropBlur" data-v-20ce0a30></feGaussianBlur><feOffset dx="2" dy="5" in="dropBlur" result="dropOffset" data-v-20ce0a30></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.24" result="dropColor" data-v-20ce0a30></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-20ce0a30></feComposite><feOffset dx="2" dy="2.5" in="SourceAlpha" result="hlOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="2" in="hlOffset" result="hlBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.72" result="hlColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-20ce0a30></feComposite><feOffset dx="-2" dy="-2.5" in="SourceAlpha" result="shOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="2.2" in="shOffset" result="shBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.28" result="shColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-20ce0a30></feComposite><feMerge data-v-20ce0a30><feMergeNode in="dropShadow" data-v-20ce0a30></feMergeNode><feMergeNode in="SourceGraphic" data-v-20ce0a30></feMergeNode><feMergeNode in="innerShade" data-v-20ce0a30></feMergeNode><feMergeNode in="innerHighlight" data-v-20ce0a30></feMergeNode></feMerge>',15)])]),e.createElementVNode("filter",{id:d,x:"-40%",y:"-40%",width:"180%",height:"180%"},[...C[5]||(C[5]=[e.createStaticVNode('<feGaussianBlur in="SourceAlpha" stdDeviation="2" result="dropBlur" data-v-20ce0a30></feGaussianBlur><feOffset dx="1.5" dy="2.5" in="dropBlur" result="dropOffset" data-v-20ce0a30></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.26" result="dropColor" data-v-20ce0a30></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-20ce0a30></feComposite><feOffset dx="1.2" dy="1.4" in="SourceAlpha" result="hlOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="1.1" in="hlOffset" result="hlBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.8" result="hlColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-20ce0a30></feComposite><feOffset dx="-1.2" dy="-1.4" in="SourceAlpha" result="shOffset" data-v-20ce0a30></feOffset><feGaussianBlur stdDeviation="1.2" in="shOffset" result="shBlur" data-v-20ce0a30></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-20ce0a30></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.3" result="shColor" data-v-20ce0a30></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-20ce0a30></feComposite><feMerge data-v-20ce0a30><feMergeNode in="dropShadow" data-v-20ce0a30></feMergeNode><feMergeNode in="SourceGraphic" data-v-20ce0a30></feMergeNode><feMergeNode in="innerShade" data-v-20ce0a30></feMergeNode><feMergeNode in="innerHighlight" data-v-20ce0a30></feMergeNode></feMerge>',15)])]),e.createElementVNode("linearGradient",{id:n,x1:"0%",y1:"0%",x2:"0%",y2:"100%"},[...C[6]||(C[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:Be,x2:ue-We,y1:ke+(r.value-ke-_e)*(E-1)/3,y2:ke+(r.value-ke-_e)*(E-1)/3,class:"mfs-chart__grid"},null,8,Ok)),64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(E,V)=>(e.openBlock(),e.createElementBlock("text",{key:V,x:p(V),y:r.value-8,"text-anchor":"middle",class:"mfs-chart__label"},e.toDisplayString(E),9,Uk))),128))],64)):e.createCommentVNode("",!0),t.type==="bar"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(o.value,(E,V)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:V},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(M,N)=>(e.openBlock(),e.createElementBlock("g",{key:N},[e.createElementVNode("rect",{x:b(N,V),y:m(M),width:u.value,height:Math.max(2,r.value-_e-m(M)),fill:E.color||h[V%h.length],rx:"4",class:"mfs-chart__bar",onMouseenter:I=>_(I,`${l.value[N]??N}: ${M}`),onMouseleave:C[0]||(C[0]=I=>y.value=null)},null,40,Hk),e.createElementVNode("rect",{x:b(N,V)+2,y:m(M)+2,width:Math.max(0,u.value-4),height:Math.max(0,Math.min(14,(r.value-_e-m(M))*.45)),fill:`url(#${n})`,rx:"4",class:"mfs-chart__clay-gloss"},null,8,Wk)]))),128))],64))),128)):t.type==="line"?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:2},e.renderList(o.value,(E,V)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:V},[e.createElementVNode("polyline",{fill:"none",stroke:E.color||h[V%h.length],"stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round",points:g(E.data),class:"mfs-chart__line"},null,8,Gk),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.data,(M,N)=>(e.openBlock(),e.createElementBlock("g",{key:N},[e.createElementVNode("circle",{cx:p(N),cy:m(M),r:"5",fill:E.color||h[V%h.length],class:"mfs-chart__point",onMouseenter:I=>_(I,`${l.value[N]??N}: ${M}`),onMouseleave:C[1]||(C[1]=I=>y.value=null)},null,40,qk),e.createElementVNode("circle",{cx:p(N)-1.5,cy:m(M)-1.5,r:"1.6",fill:"var(--bevel-light, currentColor)","fill-opacity":"0.7",class:"mfs-chart__clay-gloss"},null,8,Yk)]))),128))],64))),128)):(e.openBlock(),e.createElementBlock("g",{key:3,transform:`translate(${ue/2}, ${r.value/2})`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,V)=>(e.openBlock(),e.createElementBlock("path",{key:V,d:E.d,fill:E.color,class:"mfs-chart__slice",onMouseenter:M=>_(M,`${E.label}: ${E.value}`),onMouseleave:C[2]||(C[2]=M=>y.value=null)},null,40,Zk))),128)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,(E,V)=>(e.openBlock(),e.createElementBlock("path",{key:`gloss-${V}`,d:E.d,fill:`url(#${n})`,class:"mfs-chart__clay-gloss"},null,8,Jk))),128))],8,Xk))],8,Kk)),y.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:`${y.value.x}px`,top:`${y.value.y}px`})},e.toDisplayString(y.value.text),5)):e.createCommentVNode("",!0)],4),!a.value&&w.value.length>0?(e.openBlock(),e.createElementBlock("div",Qk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(E,V)=>(e.openBlock(),e.createElementBlock("span",{key:V,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,Ak))}}),[["__scopeId","data-v-20ce0a30"]]),El=D(e.defineComponent({__name:"AvatarGroup",props:{max:{},size:{default:"md"},items:{}},setup(t){const s=t,l=e.computed(()=>s.items?s.max!==void 0&&s.max>=0&&s.items.length>s.max?s.items.slice(0,s.max):s.items:[]),o=e.computed(()=>!s.items||s.max===void 0||s.max<0?0:Math.max(0,s.items.length-s.max));return(a,r)=>{var i;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"},[(i=t.items)!=null&&i.length?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(c,d)=>(e.openBlock(),e.createBlock(Ce,{key:d,src:c.src,label:c.label,size:t.size},null,8,["src","label","size"]))),128)),o.value>0?(e.openBlock(),e.createBlock(Ce,{key:0,size:t.size,label:`+${o.value} more`,class:"mfs-avatar-group__overflow"},{default:e.withCtx(()=>[e.createTextVNode(" +"+e.toDisplayString(o.value),1)]),_:1},8,["size","label"])):e.createCommentVNode("",!0)],64)):e.renderSlot(a.$slots,"default",{},void 0,!0,1)],2)}}}),[["__scopeId","data-v-865c01f7"]]),vk={class:"mfs-overlay-badge mfs-relative mfs-inline-flex"},$l=D(e.defineComponent({__name:"OverlayBadge",props:{value:{},variant:{default:"primary"},size:{default:"sm"}},setup(t){const s=t,l=e.computed(()=>s.value!==void 0&&s.value!=="");return(o,a)=>(e.openBlock(),e.createElementBlock("span",vk,[e.renderSlot(o.$slots,"default",{},void 0,!0),l.value?(e.openBlock(),e.createBlock(je,{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"]]),eh=["src","alt"],th=["src","alt"],lh=["value"],Vl=D(e.defineComponent({__name:"ImageCompare",props:{leftSrc:{},rightSrc:{},leftAlt:{default:"Before image"},rightAlt:{default:"After image"},modelValue:{default:50}},emits:["update:modelValue"],setup(t,{emit:s}){const l=t,o=s,a=p=>Math.min(100,Math.max(0,p)),r=e.ref(null),i=e.ref(a(l.modelValue)),c=e.ref(!1);e.watch(()=>l.modelValue,p=>{i.value=a(p)});const d=p=>{const m=Math.round(a(p)*10)/10;i.value=m,o("update:modelValue",m)},n=p=>{const m=r.value;if(!m)return;const u=m.getBoundingClientRect();if(u.width<=0)return;const b=(p-u.left)/u.width*100;d(b)},k=p=>{var m,u;c.value=!0,(u=(m=p.currentTarget)==null?void 0:m.setPointerCapture)==null||u.call(m,p.pointerId),n(p.clientX)},h=p=>{c.value&&n(p.clientX)},y=p=>{var m,u;c.value&&(c.value=!1,(u=(m=p.currentTarget)==null?void 0:m.releasePointerCapture)==null||u.call(m,p.pointerId))},f=p=>{const m=p.target;d(Number(m.value))};return(p,m)=>(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:k,onPointermove:h,onPointerup:y,onPointercancel:y},[e.createElementVNode("img",{src:t.rightSrc,alt:t.rightAlt,class:"mfs-image-compare__img mfs-w-full mfs-h-full",draggable:"false"},null,8,eh),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-i.value}% 0 0)`}),draggable:"false"},null,12,th),e.createElementVNode("div",{class:"mfs-image-compare__divider mfs-absolute",style:e.normalizeStyle({left:`${i.value}%`}),"aria-hidden":"true"},[...m[0]||(m[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:i.value,class:"mfs-image-compare__range mfs-sr-only","aria-label":"Image comparison slider",onInput:f},null,40,lh)],544))}}),[["__scopeId","data-v-0e55644e"]]),Cl=e.defineComponent({__name:"Portal",props:{appendTo:{default:"body"},disabled:{type:Boolean,default:!1}},setup(t){return(s,l)=>(e.openBlock(),e.createBlock(e.Teleport,{to:t.appendTo,disabled:t.disabled},[e.renderSlot(s.$slots,"default")],8,["to","disabled"]))}}),oh=["for"],nh=["id","placeholder","disabled","aria-invalid"],ah={key:1,class:"mfs-chips-msg mfs-text-danger"},sh={key:2,class:"mfs-chips-msg mfs-caption"},Pe=D(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:s}){const l=t,o=s,a=e.useId(),r=e.ref(null),i=e.ref(""),c=e.computed(()=>l.max!==void 0&&l.modelValue.length>=l.max),d=()=>{var p;l.disabled||(p=r.value)==null||p.focus()},n=p=>{if(l.disabled)return;const m=l.separator?p.split(l.separator):[p],u=[...l.modelValue],b=[];for(const g of m){const B=g.trim();if(B){if(l.max!==void 0&&u.length>=l.max)break;!l.allowDuplicate&&u.includes(B)||(u.push(B),b.push(B))}}if(b.length>0){o("update:modelValue",u);for(const g of b)o("add",g)}i.value=""},k=p=>{if(l.disabled)return;const m=l.modelValue[p];if(m===void 0)return;const u=l.modelValue.filter((b,g)=>g!==p);o("update:modelValue",u),o("remove",m)},h=p=>{if(!l.disabled){if(p.key==="Enter"||l.separator&&p.key===l.separator){p.preventDefault(),i.value.trim()&&n(i.value);return}p.key==="Backspace"&&i.value===""&&l.modelValue.length>0&&(p.preventDefault(),k(l.modelValue.length-1))}},y=()=>{l.separator&&i.value.includes(l.separator)&&n(i.value)},f=()=>{i.value.trim()&&n(i.value)};return(p,m)=>(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(a),class:"mfs-chips-label mfs-text"},e.toDisplayString(t.label),9,oh)):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:d},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.modelValue,(u,b)=>(e.openBlock(),e.createBlock(ge,{key:`${u}-${b}`,label:u,removable:!t.disabled,onRemove:g=>k(b)},null,8,["label","removable","onRemove"]))),128)),e.withDirectives(e.createElementVNode("input",{id:e.unref(a),ref_key:"inputRef",ref:r,"onUpdate:modelValue":m[0]||(m[0]=u=>i.value=u),type:"text",class:"mfs-chips-input mfs-text",placeholder:c.value?"":t.placeholder,disabled:t.disabled||c.value,"aria-invalid":t.invalid||!!t.error||void 0,onKeydown:h,onInput:y,onBlur:f},null,40,nh),[[e.vModelText,i.value]])],2),t.error?(e.openBlock(),e.createElementBlock("p",ah,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",sh,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-0e7176f9"]]),rh=["aria-invalid"],ih=Symbol("CheckboxGroup"),xl=D(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:s}){const l=t,o=s,a=i=>{if(l.disabled)return;const d=l.modelValue.includes(i)?l.modelValue.filter(n=>n!==i):[...l.modelValue,i];o("update:modelValue",d),o("change",d)},r=i=>{l.disabled||!Array.isArray(i)||(o("update:modelValue",i),o("change",i))};return e.provide(ih,{modelValue:e.computed(()=>l.modelValue),name:e.computed(()=>l.name),disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),toggleValue:a}),(i,c)=>(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(i.$slots,t.name,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,toggleValue:a},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(d,n)=>(e.openBlock(),e.createBlock(fe,{key:n,"model-value":t.modelValue,value:d.value,label:d.label,disabled:t.disabled||d.disabled,"onUpdate:modelValue":r},null,8,["model-value","value","label","disabled"]))),128))],!0)],10,rh))}}),[["__scopeId","data-v-bde4c6e4"]]),dh=["aria-invalid"],ch=Symbol("RadioButtonGroup"),Nl=D(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:s}){const l=t,o=s,a=`mfs-radio-group-${e.useId()}`,r=e.computed(()=>l.name||a),i=c=>{l.disabled||(o("update:modelValue",c),o("change",c))};return e.provide(ch,{modelValue:e.computed(()=>l.modelValue),name:r,disabled:e.computed(()=>l.disabled),invalid:e.computed(()=>l.invalid),selectValue:i}),(c,d)=>(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(c.$slots,r.value,{modelValue:t.modelValue,disabled:t.disabled,invalid:t.invalid,selectValue:i},()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.options,(n,k)=>(e.openBlock(),e.createBlock(Ke,{key:k,"model-value":t.modelValue,value:n.value,name:r.value,label:n.label,disabled:t.disabled||n.disabled,"onUpdate:modelValue":i},null,8,["model-value","value","name","label","disabled"]))),128))],!0)],10,dh))}}),[["__scopeId","data-v-2e9ea155"]]),de=e.ref([]);let mh=1;function fh(t,s={}){const l=`mfs-dialog-${mh++}`;return de.value=[...de.value,{id:l,component:e.markRaw(t),options:s}],l}function ph(t,s){var a,r;const l=de.value.findIndex(i=>i.id===t);if(l===-1)return;const o=de.value[l];de.value=de.value.filter(i=>i.id!==t),(r=(a=o.options).onClose)==null||r.call(a,s)}function Sl(){return{dialogs:e.readonly(de),open:fh,close:ph}}const Ml=e.defineComponent({__name:"DynamicDialog",setup(t){const{dialogs:s,close:l}=Sl(),o=e.defineComponent({name:"MfsDynamicDialogContent",props:{component:{type:Object,required:!0},componentProps:{type:Object,default:()=>({})},onClose:{type:Function,required:!0}},setup(a){const r={close:i=>a.onClose(i)};return e.provide("dialogRef",r),()=>e.h(a.component,a.componentProps)}});return(a,r)=>(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(s),i=>(e.openBlock(),e.createBlock(me,{key:i.id,"model-value":!0,title:i.options.header,"onUpdate:modelValue":c=>!c&&e.unref(l)(i.id)},{default:e.withCtx(()=>[e.createElementVNode("div",{style:e.normalizeStyle(i.options.width?{width:i.options.width,maxWidth:"100%"}:void 0)},[e.createVNode(e.unref(o),{component:i.component,"component-props":i.options.props,"on-close":c=>e.unref(l)(i.id,c)},null,8,["component","component-props","on-close"])],4)]),_:2},1032,["title","onUpdate:modelValue"]))),128))}}),uh={class:"cmd-header mfs-flex mfs-items-center mfs-gap-2 mfs-border-b"},kh=["placeholder"],hh={key:0,class:"mfs-spinner mfs-spinner--sm",role:"status","aria-label":"Loading"},gh={key:1,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},yh={key:0,class:"mfs-empty-state"},bh={key:1,class:"mfs-empty-state"},Bh={key:0,class:"cmd-group-label mfs-text-muted"},_h=["aria-selected","aria-disabled","disabled","onMouseenter","onClick"],wh={class:"cmd-item-main mfs-flex mfs-flex-col"},Eh={class:"cmd-item-label"},$h={key:0,class:"cmd-item-desc mfs-text-muted"},Vh={key:0,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},Dl=D(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:s}){const l=t,o=s,a=e.ref(""),r=e.ref(-1),i=e.ref(null),c=e.ref(null),d=new Map,n=(_,$)=>{$?d.set(_,$):d.delete(_)},k=e.computed(()=>{if(l.remote)return l.items;const _=a.value.trim().toLowerCase();return _?l.items.filter($=>$.label.toLowerCase().includes(_)||$.description&&$.description.toLowerCase().includes(_)||$.group&&$.group.toLowerCase().includes(_)):l.items}),h=e.computed(()=>{const _=new Map;let $=0;for(const C of k.value){const E=C.group??"";_.has(E)||_.set(E,[]),_.get(E).push({item:C,flatIndex:$++})}return Array.from(_.entries()).map(([C,E])=>({group:C,entries:E}))}),y=e.computed(()=>h.value.flatMap(_=>_.entries.map($=>$.item))),f=_=>_.findIndex($=>!$.disabled);e.watch(y,_=>{d.clear(),r.value=f(_)},{immediate:!0});const p=()=>{o("update:modelValue",!1)},m=()=>{o("search",a.value)},u=(_,$)=>{$.disabled||(r.value=_)},b=_=>{_.disabled||(o("select",_),p())},g=_=>{var V;const $=y.value,C=$.length;if(C===0)return;let E=r.value;for(let M=0;M<C;M++)if(E=(E+_+C)%C,!((V=$[E])!=null&&V.disabled)){r.value=E,e.nextTick(()=>{var N;(N=d.get(E))==null||N.scrollIntoView({block:"nearest"})});return}},B=_=>{if(_.key==="ArrowDown")_.preventDefault(),g(1);else if(_.key==="ArrowUp")_.preventDefault(),g(-1);else if(_.key==="Enter"){const $=y.value[r.value];$&&!$.disabled&&(_.preventDefault(),b($))}else _.key==="Escape"&&(_.preventDefault(),p())},w=_=>{l.shortcut&&(_.metaKey||_.ctrlKey)&&_.key.toLowerCase()==="k"&&(_.preventDefault(),o("update:modelValue",!l.modelValue))};return e.watch(()=>l.modelValue,async _=>{var $;_&&(a.value="",r.value=f(y.value),await e.nextTick(),($=i.value)==null||$.focus())}),e.onMounted(()=>{typeof window<"u"&&window.addEventListener("keydown",w)}),e.onBeforeUnmount(()=>{typeof window<"u"&&window.removeEventListener("keydown",w)}),(_,$)=>(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:$[1]||($[1]=e.withModifiers(()=>{},["stop"])),onKeydown:B},[e.createElementVNode("div",uh,[$[2]||($[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:i,"onUpdate:modelValue":$[0]||($[0]=C=>a.value=C),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:m},null,40,kh),[[e.vModelText,a.value]]),t.loading?(e.openBlock(),e.createElementBlock("span",hh)):(e.openBlock(),e.createElementBlock("kbd",gh,"ESC"))]),e.createElementVNode("div",{ref_key:"listRef",ref:c,class:"cmd-list",role:"listbox"},[t.loading&&y.value.length===0?(e.openBlock(),e.createElementBlock("div",yh,[...$[3]||($[3]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-label":"Loading"},null,-1)])])):y.value.length===0?(e.openBlock(),e.createElementBlock("div",bh,[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(h.value,C=>(e.openBlock(),e.createElementBlock("div",{key:C.group,class:"cmd-group",role:"group"},[C.group?(e.openBlock(),e.createElementBlock("div",Bh,e.toDisplayString(C.group),1)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.entries,E=>(e.openBlock(),e.createElementBlock("button",{key:E.item.id,ref_for:!0,ref:V=>n(E.flatIndex,V),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:V=>u(E.flatIndex,E.item),onClick:V=>b(E.item)},[e.createElementVNode("div",wh,[e.createElementVNode("span",Eh,e.toDisplayString(E.item.label),1),E.item.description?(e.openBlock(),e.createElementBlock("span",$h,e.toDisplayString(E.item.description),1)):e.createCommentVNode("",!0)]),E.item.shortcut?(e.openBlock(),e.createElementBlock("kbd",Vh,e.toDisplayString(E.item.shortcut),1)):e.createCommentVNode("",!0)],42,_h))),128))]))),128))],512)],32)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-a0f21f67"]]),Ch={class:"infinite-scroll mfs-flex mfs-flex-col"},xh={key:0,class:"mfs-empty-state"},Nh={key:1,class:"infinite-scroll__status mfs-flex mfs-items-center mfs-justify-center mfs-p-4",role:"status","aria-live":"polite"},Sh={key:2,class:"mfs-soft-danger mfs-rounded mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-p-3",role:"alert"},Mh={class:"mfs-text-sm mfs-font-medium"},Dh={key:3,class:"mfs-text-sm mfs-text-muted mfs-text-center mfs-p-4"},zl=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:s}){const l=t,o=s,a=e.ref(null);let r=null;const i=()=>{o("load")},c=()=>l.hasMore&&!l.loading&&!l.error,d=()=>{r==null||r.disconnect(),r=null,!(typeof IntersectionObserver>"u"||!a.value)&&(r=new IntersectionObserver(n=>{n.some(k=>k.isIntersecting)&&c()&&i()},{rootMargin:l.rootMargin}),r.observe(a.value))};return e.watch(()=>l.rootMargin,d),e.onMounted(()=>{d()}),e.onBeforeUnmount(()=>{r==null||r.disconnect(),r=null}),(n,k)=>(e.openBlock(),e.createElementBlock("div",Ch,[e.renderSlot(n.$slots,"default"),t.isEmpty&&!t.loading&&!t.error?(e.openBlock(),e.createElementBlock("div",xh,[e.renderSlot(n.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Nh,[e.renderSlot(n.$slots,"loading",{},()=>[k[0]||(k[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))])])):t.error?(e.openBlock(),e.createElementBlock("div",Sh,[e.renderSlot(n.$slots,"error",{error:t.error,retry:i},()=>[e.createElementVNode("span",Mh,e.toDisplayString(t.error),1),e.createVNode(he,{size:"sm",variant:"danger",onClick:i},{default:e.withCtx(()=>[...k[1]||(k[1]=[e.createTextVNode("Retry",-1)])]),_:1})])])):!t.hasMore&&!t.isEmpty?(e.openBlock(),e.createElementBlock("div",Dh,[e.renderSlot(n.$slots,"finished",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.finishedText),1)])])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"sentinelRef",ref:a,class:"mfs-w-full mfs-h-px mfs-pointer-events-none","aria-hidden":"true"},null,512)]))}}),zh=["value","placeholder","rows","disabled","aria-expanded"],Th={key:0,class:"mfs-mentions__loading mfs-flex mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-3"},Lh={key:1,class:"mfs-mentions__list"},Ih=["aria-selected","onMousedown","onMouseenter"],Rh={class:"mfs-mentions__label mfs-text mfs-text-sm mfs-font-medium"},Ph={key:0,class:"mfs-mentions__desc mfs-text-muted mfs-text-xs"},Fh={key:2,class:"mfs-empty-state",role:"status"},Tl=D(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:s}){const l=t,o=s,a=e.ref(null),r=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(0),k=e.ref(""),h=e.ref(-1),y=e.ref(""),{overlayStyle:f,containsTarget:p}=oe(r,i,d,{matchWidth:!0}),m=e.computed(()=>{if(l.remote)return l.options;const C=y.value.trim().toLowerCase();return C?l.options.filter(E=>{var V;return E.label.toLowerCase().includes(C)||E.value.toLowerCase().includes(C)||(((V=E.description)==null?void 0:V.toLowerCase().includes(C))??!1)}):l.options});e.watch(m,C=>{C.length===0?n.value=-1:(n.value<0||n.value>=C.length)&&(n.value=0)});const u=(C,E)=>{const V=C.slice(0,E),M=[...l.triggers].filter(Boolean).sort((N,I)=>I.length-N.length);if(!M.length)return null;for(let N=V.length-1;N>=0;N--){const I=V[N];if(/\s/.test(I))return null;for(const H of M){const G=N-H.length+1;if(!(G<0)&&V.slice(G,N+1)===H){const Q=G===0?"":V[G-1];if(G===0||/\s/.test(Q))return{trigger:H,start:G,query:V.slice(N+1)}}}}return null},b=()=>{const C=c.value;if(!C||l.disabled){d.value=!1;return}const E=C.selectionStart??(l.modelValue??"").length,V=u(C.value,E);V?(k.value=V.trigger,h.value=V.start,y.value=V.query,d.value=!0,n.value=m.value.length?0:-1,o("search",{trigger:V.trigger,query:V.query})):(d.value=!1,k.value="",h.value=-1,y.value="")},g=C=>{const E=C.target;o("update:modelValue",E.value),b()},B=C=>{["ArrowUp","ArrowDown","Enter","Escape"].includes(C.key)||b()},w=C=>{const E=c.value,V=E?E.value:l.modelValue??"",M=(E==null?void 0:E.selectionStart)??V.length,N=h.value>=0?h.value:M,I=`${k.value}${C.value} `,H=V.slice(0,N)+I+V.slice(M),G=N+I.length;o("update:modelValue",H),o("select",C),d.value=!1,k.value="",h.value=-1,y.value="",e.nextTick(()=>{c.value&&(c.value.focus(),c.value.setSelectionRange(G,G))})},_=C=>{if(!d.value)return;const E=m.value.length;if(C.key==="Escape")C.preventDefault(),d.value=!1;else if(C.key==="ArrowDown")C.preventDefault(),E>0&&(n.value=(n.value+1)%E);else if(C.key==="ArrowUp")C.preventDefault(),E>0&&(n.value=(n.value-1+E)%E);else if(C.key==="Enter"&&E>0&&n.value>=0){C.preventDefault();const V=m.value[n.value];V&&w(V)}},$=C=>{p(C.target)||(d.value=!1)};return e.onMounted(()=>document.addEventListener("mousedown",$)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",$)),(C,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"rootRef",ref:a,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:c,value:t.modelValue,placeholder:t.placeholder,rows:t.rows,disabled:t.disabled,role:"combobox","aria-autocomplete":"list","aria-expanded":d.value,class:"mfs-mentions__textarea mfs-w-full mfs-border-none mfs-text",onInput:g,onClick:b,onKeyup:B,onKeydown:_},null,40,zh)],512),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"mfs-mentions-pop"},{default:e.withCtx(()=>[d.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:i,style:e.normalizeStyle(e.unref(f)),role:"listbox",class:"mfs-mentions__dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading?(e.openBlock(),e.createElementBlock("div",Th,[...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)])])):m.value.length?(e.openBlock(),e.createElementBlock("ul",Lh,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(V,M)=>(e.openBlock(),e.createElementBlock("li",{key:`${V.value}-${M}`,role:"option","aria-selected":M===n.value,class:e.normalizeClass(["mfs-mentions__option mfs-flex mfs-flex-col mfs-rounded-sm mfs-cursor-pointer",{"mfs-mentions__option--active":M===n.value}]),onMousedown:e.withModifiers(N=>w(V),["prevent"]),onMouseenter:N=>n.value=M},[e.createElementVNode("span",Rh,e.toDisplayString(V.label),1),V.description?(e.openBlock(),e.createElementBlock("span",Ph,e.toDisplayString(V.description),1)):e.createCommentVNode("",!0)],42,Ih))),128))])):(e.openBlock(),e.createElementBlock("div",Fh,[e.renderSlot(C.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)]))],4)):e.createCommentVNode("",!0)]),_:3})]))],2))}}),[["__scopeId","data-v-b46fcff1"]]),Ah={class:"mfs-signature__stage mfs-inset mfs-rounded-sm mfs-relative"},jh=["width","height"],Kh={key:0,class:"mfs-signature__hint mfs-text-muted mfs-text-sm mfs-select-none"},Oh={class:"mfs-signature__actions mfs-flex mfs-items-center mfs-justify-end mfs-gap-2"},Ll=D(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:s,emit:l}){const o=t,a=l,r=e.ref(null),i=e.ref(!1),c=e.ref(!0),d=()=>{var g;return((g=r.value)==null?void 0:g.getContext("2d"))??null},n=g=>{if(o.penColor&&o.penColor!=="currentColor")return o.penColor;if(typeof window<"u"){const B=window.getComputedStyle(g).color;if(B)return B}return"#0f172a"},k=g=>{const B=r.value,w=B.getBoundingClientRect(),_=w.width>0?B.width/w.width:1,$=w.height>0?B.height/w.height:1;return{x:(g.clientX-w.left)*_,y:(g.clientY-w.top)*$}},h=g=>{var $;if(o.disabled)return;const B=r.value,w=d();if(!B||!w)return;($=B.setPointerCapture)==null||$.call(B,g.pointerId);const _=k(g);w.strokeStyle=n(B),w.lineWidth=o.lineWidth,w.lineCap="round",w.lineJoin="round",w.beginPath(),w.moveTo(_.x,_.y),w.lineTo(_.x+.01,_.y+.01),w.stroke(),i.value=!0,c.value=!1},y=g=>{if(!i.value||o.disabled)return;const B=d();if(!B)return;const w=k(g);B.lineTo(w.x,w.y),B.stroke()},f=g=>{var w;if(!i.value)return;const B=r.value;(w=B==null?void 0:B.hasPointerCapture)!=null&&w.call(B,g.pointerId)&&B.releasePointerCapture(g.pointerId),i.value=!1},p=()=>c.value,m=()=>{const g=r.value,B=d();g&&B&&B.clearRect(0,0,g.width,g.height),i.value=!1,c.value=!0,a("update:modelValue",null),a("change",{blob:null,dataUrl:null,file:null})},u=()=>{const g=r.value;if(!g||c.value){const w={blob:null,dataUrl:null,file:null};return a("update:modelValue",null),a("change",w),Promise.resolve(w)}const B=g.toDataURL(o.outputType);return new Promise(w=>{g.toBlob(_=>{const $=_?new File([_],o.fileName,{type:o.outputType}):null,C={blob:_,dataUrl:B,file:$};a("update:modelValue",B),a("change",C),w(C)},o.outputType)})},b=g=>{const B=r.value,w=d();if(!B||!w)return;if(w.clearRect(0,0,B.width,B.height),!g){c.value=!0;return}const _=new Image;_.onload=()=>{w.clearRect(0,0,B.width,B.height),w.drawImage(_,0,0,B.width,B.height),c.value=!1},_.src=g};return e.watch(()=>o.modelValue,g=>{if(g)r.value&&r.value.toDataURL(o.outputType)!==g&&b(g);else{const B=r.value,w=d();B&&w&&w.clearRect(0,0,B.width,B.height),c.value=!0}}),e.onMounted(()=>{o.modelValue&&b(o.modelValue)}),s({clear:m,isEmpty:p,exportSignature:u}),(g,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",Ah,[e.createElementVNode("canvas",{ref_key:"canvasRef",ref:r,width:t.width,height:t.height,class:"mfs-signature__canvas mfs-w-full",onPointerdown:h,onPointermove:y,onPointerup:f,onPointercancel:f,onPointerleave:f},null,40,jh),c.value?(e.openBlock(),e.createElementBlock("span",Kh," Sign here ")):e.createCommentVNode("",!0)]),e.createElementVNode("div",Oh,[e.createVNode(he,{variant:"surface",size:"sm",disabled:t.disabled||c.value,onClick:m},{default:e.withCtx(()=>[...B[0]||(B[0]=[e.createTextVNode(" Clear ",-1)])]),_:1},8,["disabled"]),e.createVNode(he,{variant:"primary",size:"sm",disabled:t.disabled||c.value,onClick:u},{default:e.withCtx(()=>[...B[1]||(B[1]=[e.createTextVNode(" Save ",-1)])]),_:1},8,["disabled"])])],2))}}),[["__scopeId","data-v-7b44dca2"]]),Il=e.defineComponent({__name:"Form",props:{initialValues:{},errors:{},resolver:{},submitting:{type:Boolean,default:!1},validateOnSubmit:{type:Boolean,default:!0}},emits:["submit","reset"],setup(t,{expose:s,emit:l}){const o=t,a=l,r=e.reactive({...o.initialValues??{}}),i=e.reactive({}),c=m=>{for(const u of Object.keys(i))delete i[u];for(const[u,b]of Object.entries(m))(Array.isArray(b)?b.length>0:b)&&(i[u]=b)};e.watch(()=>o.errors,m=>{c(m??{})},{immediate:!0,deep:!0});const d=(m,u)=>{r[m]=u,m in i&&delete i[m]},n=(m,u)=>{(Array.isArray(u)?u.length>0:u)?i[m]=u:delete i[m]},k=m=>{if(m!==void 0){delete i[m];return}for(const u of Object.keys(i))delete i[u]},h=()=>{if(k(),!o.resolver)return!0;const m=o.resolver({...r});for(const[u,b]of Object.entries(m))b&&(i[u]=b);return Object.keys(i).length===0},y=()=>{const m=o.initialValues??{};for(const u of Object.keys(r))u in m||delete r[u];for(const[u,b]of Object.entries(m))r[u]=b;k(),a("reset")},f=()=>{const m={};for(const[u,b]of Object.entries(i)){const g=Array.isArray(b)?b[0]:b;g&&(m[u]=g)}return m},p=()=>{const m=o.validateOnSubmit?h():!0;a("submit",{values:{...r},valid:m,errors:f()})};return e.provide("mfsFormContext",{values:r,errors:i,submitting:e.computed(()=>o.submitting),setFieldValue:d,setFieldError:n,clearErrors:k,reset:y}),s({values:r,errors:i,validate:h,reset:y,setErrors:c}),(m,u)=>(e.openBlock(),e.createElementBlock("form",{class:"mfs-form mfs-flex mfs-flex-col mfs-gap-4",novalidate:"",onSubmit:e.withModifiers(p,["prevent"])},[e.renderSlot(m.$slots,"default",{values:r,errors:i,submitting:t.submitting,reset:y,validate:h})],32))}}),Uh={class:"mfs-form-field mfs-flex mfs-flex-col mfs-gap-1-5"},Hh=["for"],Wh={key:0,class:"mfs-text-danger"},Gh={key:1,class:"mfs-form-field__msg mfs-text-danger mfs-text-xs mfs-font-medium mfs-m-0"},qh={key:2,class:"mfs-form-field__msg mfs-caption mfs-m-0"},Rl=e.defineComponent({__name:"FormField",props:{name:{},label:{},hint:{},error:{},required:{type:Boolean,default:!1}},setup(t){const s=t,l=e.inject("mfsFormContext",null),o=e.computed(()=>l==null?void 0:l.values[s.name]),a=e.computed(()=>{if(s.error)return s.error;const i=l==null?void 0:l.errors[s.name];return Array.isArray(i)?i[0]||void 0:i||void 0}),r=i=>{l==null||l.setFieldValue(s.name,i)};return(i,c)=>(e.openBlock(),e.createElementBlock("div",Uh,[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",Wh,"*")):e.createCommentVNode("",!0)],8,Hh)):e.createCommentVNode("",!0),e.renderSlot(i.$slots,"default",{value:o.value,error:a.value,setValue:r}),a.value?(e.openBlock(),e.createElementBlock("p",Gh,e.toDisplayString(a.value),1)):t.hint?(e.openBlock(),e.createElementBlock("p",qh,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)]))}}),Ge=[{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%)"}],qe=Ge.map(t=>t.id),Pl=qe.map(t=>`theme-${t}`),Fe=e.ref("clay");let Fl=!1;const Al=t=>{if(typeof document>"u")return;const s=document.documentElement,l=document.body;s.classList.remove(...Pl),s.classList.add(`theme-${t}`),l==null||l.classList.remove(...Pl)};function jl(){const t=l=>{if(Fe.value=l,typeof document<"u"){const o=document.documentElement;o.getAttribute("data-theme")!==l&&o.setAttribute("data-theme",l),Al(l),localStorage.setItem("active-theme",l)}};return{currentTheme:Fe,themeOptions:Ge,setTheme:t,initTheme:(l="clay")=>{if(typeof window<"u"){const o=localStorage.getItem("active-theme");o&&qe.includes(o)?t(o):t(l),!Fl&&typeof MutationObserver<"u"&&(Fl=!0,new MutationObserver(()=>{const r=document.documentElement.getAttribute("data-theme");r&&qe.includes(r)&&(Fe.value!==r&&(Fe.value=r),Al(r))}).observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}))}}}}let Yh=1;function Xh(t,s={}){const l=s.id??`mfs-style-${Yh++}`,o=s.name,a=e.ref(!1);let r=null;function i(){if(typeof document>"u")return;const d=document.getElementById(l);if(d instanceof HTMLStyleElement){d.textContent=t,r=d,a.value=!0;return}const n=document.createElement("style");n.id=l,n.type="text/css",o&&n.setAttribute("data-mfs-style",o),n.textContent=t,document.head.appendChild(n),r=n,a.value=!0}function c(){if(typeof document>"u")return;const d=r??document.getElementById(l);d&&d.parentNode&&d.parentNode.removeChild(d),r=null,a.value=!1}return(s.immediate??!0)&&i(),e.getCurrentInstance()&&e.onUnmounted(c),{id:l,name:o,css:t,isLoaded:e.readonly(a),load:i,unload:c}}function Kl(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 Ol={mounted(t,s){const l=Kl(s.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color;const o=getComputedStyle(t);o.position==="static"&&(t.style.position="relative"),o.overflow!=="hidden"&&(t.style.overflow="hidden");const a=r=>{if(t.__mfsRippleDisabled)return;const i=t.getBoundingClientRect(),c=Math.max(i.width,i.height)*2,d=r.clientX-i.left-c/2,n=r.clientY-i.top-c/2,k=document.createElement("span");k.style.position="absolute",k.style.width=`${c}px`,k.style.height=`${c}px`,k.style.left=`${d}px`,k.style.top=`${n}px`,k.style.borderRadius="50%",k.style.pointerEvents="none",k.style.backgroundColor=t.__mfsRippleColor??"currentColor",k.style.opacity="0.25",k.style.transform="scale(0)",t.appendChild(k);const h=k.animate([{transform:"scale(0)",opacity:.28},{transform:"scale(1)",opacity:0}],{duration:500,easing:"cubic-bezier(0.22, 1, 0.36, 1)"});h.onfinish=()=>k.remove()};t.__mfsRippleHandler=a,t.addEventListener("pointerdown",a)},updated(t,s){const l=Kl(s.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color},unmounted(t){t.__mfsRippleHandler&&(t.removeEventListener("pointerdown",t.__mfsRippleHandler),delete t.__mfsRippleHandler)}};function Zh(t){return t.right?"right":t.bottom?"bottom":t.left?"left":"top"}function Ul(t){const s=Zh(t.modifiers),l=t.value;return typeof l=="string"?{text:l,disabled:!1,placement:s}:l&&typeof l=="object"?{text:l.value??"",disabled:!!l.disabled,placement:s,customClass:l.class}:{text:"",disabled:!0,placement:s}}function Hl(t,s,l){const o=t.getBoundingClientRect(),a=s.getBoundingClientRect(),r=8;let i=0,c=0;switch(l){case"bottom":i=o.bottom+r,c=o.left+o.width/2-a.width/2;break;case"left":i=o.top+o.height/2-a.height/2,c=o.left-a.width-r;break;case"right":i=o.top+o.height/2-a.height/2,c=o.right+r;break;case"top":default:i=o.top-a.height-r,c=o.left+o.width/2-a.width/2;break}const d=Math.max(8,window.innerWidth-a.width-8),n=Math.max(8,window.innerHeight-a.height-8);s.style.top=`${Math.min(Math.max(8,i),n)}px`,s.style.left=`${Math.min(Math.max(8,c),d)}px`}function Ae(t){t.tipEl&&(t.tipEl.remove(),t.tipEl=void 0)}const Ye={mounted(t,s){const o={...Ul(s),show:()=>{if(o.disabled||!o.text)return;Ae(o);const a=document.createElement("div");a.setAttribute("role","tooltip"),a.textContent=o.text,o.customClass&&(a.className=o.customClass),Object.assign(a.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(a),Hl(t,a,o.placement),o.tipEl=a},hide:()=>Ae(o)};t.__mfsTooltipState=o,t.addEventListener("mouseenter",o.show),t.addEventListener("mouseleave",o.hide),t.addEventListener("focusin",o.show),t.addEventListener("focusout",o.hide)},updated(t,s){const l=t.__mfsTooltipState;if(!l)return;const o=Ul(s);l.text=o.text,l.disabled=o.disabled,l.placement=o.placement,l.customClass=o.customClass,l.disabled||!l.text?Ae(l):l.tipEl&&(l.tipEl.textContent=l.text,Hl(t,l.tipEl,l.placement))},unmounted(t){const s=t.__mfsTooltipState;s&&(t.removeEventListener("mouseenter",s.show),t.removeEventListener("mouseleave",s.hide),t.removeEventListener("focusin",s.show),t.removeEventListener("focusout",s.hide),Ae(s),delete t.__mfsTooltipState)}},Jh=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(",");function Wl(t){return Array.from(t.querySelectorAll(Jh)).filter(s=>s.offsetParent!==null||s===document.activeElement)}function Gl(t){if(t.__mfsTrapActive)return;t.__mfsTrapActive=!0,t.__mfsPrevFocus=document.activeElement;const s=Wl(t);s.length>0&&s[0].focus();const l=o=>{if(o.key!=="Tab")return;const a=Wl(t);if(a.length===0){o.preventDefault();return}const r=a[0],i=a[a.length-1];o.shiftKey&&document.activeElement===r?(o.preventDefault(),i.focus()):!o.shiftKey&&document.activeElement===i&&(o.preventDefault(),r.focus())};t.__mfsFocusTrapHandler=l,t.addEventListener("keydown",l)}function ql(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 Yl={mounted(t,s){s.value!==!1&&Gl(t)},updated(t,s){s.value===!1?ql(t):Gl(t)},unmounted(t){ql(t)}},Qh=new Set(["fade-up","fade-down","fade-left","fade-right","zoom-in"]),Xl="cubic-bezier(0.22, 1, 0.36, 1)";function vh(t){return typeof t=="string"&&Qh.has(t)}function Zl(t,s){switch(t){case"fade-down":return`translate3d(0, -${s}px, 0)`;case"fade-left":return`translate3d(${s}px, 0, 0)`;case"fade-right":return`translate3d(-${s}px, 0, 0)`;case"zoom-in":return"scale(0.92)";case"fade-up":default:return`translate3d(0, ${s}px, 0)`}}function eg(t){return t==="zoom-in"?"scale(1)":"translate3d(0, 0, 0)"}const Jl={mounted(t,s){var p;if(typeof IntersectionObserver>"u")return;const l=typeof s.value=="string"?vh(s.value)?{animation:s.value}:{enterClass:s.value}:s.value??{},o=l.enterClass===void 0,a=l.animation??"fade-up",r=l.duration??500,i=l.delay??0,c=l.distance??24,d=l.threshold??.1,n=l.once??!0,k=l.enterClass??"",h=l.leaveClass??"",y=typeof window<"u"&&((p=window.matchMedia)==null?void 0:p.call(window,"(prefers-reduced-motion: reduce)").matches);o&&!y&&(t.style.opacity="0",t.style.transform=Zl(a,c),t.style.transition=`opacity ${r}ms ${Xl} ${i}ms, transform ${r}ms ${Xl} ${i}ms`);const f=new IntersectionObserver(m=>{for(const u of m)u.isIntersecting?(h&&t.classList.remove(h),k&&t.classList.add(k),o&&(t.style.opacity="1",t.style.transform=eg(a)),n&&f.unobserve(t)):n||(k&&t.classList.remove(k),h&&t.classList.add(h),o&&!y&&(t.style.opacity="0",t.style.transform=Zl(a,c)))},{threshold:d});t.__mfsAosObserver=f,f.observe(t)},unmounted(t){t.__mfsAosObserver&&(t.__mfsAosObserver.disconnect(),delete t.__mfsAosObserver)}};function tg(t,s){var l;return!s||s==="@self"?t:s==="@next"?t.nextElementSibling:s==="@prev"?t.previousElementSibling:s==="@parent"?t.parentElement:s==="@grandparent"?((l=t.parentElement)==null?void 0:l.parentElement)??null:document.querySelector(s)}function Ql(t){return typeof t=="string"?{toggleClass:t}:t}const vl={mounted(t,s){t.__mfsStyleClassOpts=Ql(s.value);const l=()=>{const o=t.__mfsStyleClassOpts;if(!o)return;const a=tg(t,o.selector);a&&(o.toggleClass?o.toggleClass.split(/\s+/).filter(Boolean).forEach(r=>a.classList.toggle(r)):(o.leaveClass&&o.leaveClass.split(/\s+/).filter(Boolean).forEach(r=>a.classList.remove(r)),o.enterClass&&o.enterClass.split(/\s+/).filter(Boolean).forEach(r=>a.classList.add(r))))};t.__mfsStyleClassHandler=l,t.addEventListener("click",l)},updated(t,s){t.__mfsStyleClassOpts=Ql(s.value)},unmounted(t){t.__mfsStyleClassHandler&&(t.removeEventListener("click",t.__mfsStyleClassHandler),delete t.__mfsStyleClassHandler)}},eo={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 lg(t){const s=t.value;return s==null||s===""?null:typeof s=="string"||typeof s=="number"?{text:String(s),severity:"primary"}:typeof s=="object"?s.value===null||s.value===void 0||s.value===""?null:{text:String(s.value),severity:s.severity??"primary"}:null}function og(t,s){if(typeof window>"u")return;getComputedStyle(t).position==="static"&&(s.hadStaticPosition=!0,s.previousPosition=t.style.position,t.style.position="relative")}function ng(){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 to(t,s,l){const o=lg(s);if(!o){l.badgeEl&&(l.badgeEl.remove(),l.badgeEl=void 0);return}og(t,l),l.badgeEl||(l.badgeEl=ng(),t.appendChild(l.badgeEl));const a=eo[o.severity]??eo.primary;l.badgeEl.className=`mfs-badge mfs-pill mfs-bg-${o.severity}`,l.badgeEl.style.backgroundColor=a.bg,l.badgeEl.style.color=a.color,l.badgeEl.textContent=o.text}const Xe={mounted(t,s){const l={hadStaticPosition:!1,previousPosition:""};t.__mfsBadgeState=l,to(t,s,l)},updated(t,s){const l=t.__mfsBadgeState;l&&to(t,s,l)},unmounted(t){const s=t.__mfsBadgeState;s&&(s.badgeEl&&(s.badgeEl.remove(),s.badgeEl=void 0),s.hadStaticPosition&&(t.style.position=s.previousPosition),delete t.__mfsBadgeState)}},ag=Xe,lo={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 Ze(t,s){return(t.global||t.sticky)&&(t.lastIndex=0),t.test(s)}function sg(t,s){if(!s)return!0;if(s instanceof RegExp)return Ze(s,t);const l=lo[s];return l?l.charPattern.test(t):!0}function rg(t,s){if(!s||t==="")return!0;if(s instanceof RegExp)return s.source.startsWith("^")||s.source.endsWith("$")?Ze(s,t):[...t].every(o=>Ze(s,o));const l=lo[s];return l?l.pastePattern.test(t):!0}const Je={mounted(t,s){const l={filter:s.value,onKeyPress(o){o.ctrlKey||o.metaKey||o.altKey||o.key.length!==1||sg(o.key,l.filter)||o.preventDefault()},onPaste(o){var r;const a=((r=o.clipboardData)==null?void 0:r.getData("text"))??"";rg(a,l.filter)||o.preventDefault()}};t.__mfsKeyFilterState=l,t.addEventListener("keypress",l.onKeyPress),t.addEventListener("paste",l.onPaste)},updated(t,s){t.__mfsKeyFilterState&&(t.__mfsKeyFilterState.filter=s.value)},unmounted(t){const s=t.__mfsKeyFilterState;s&&(t.removeEventListener("keypress",s.onKeyPress),t.removeEventListener("paste",s.onPaste),delete t.__mfsKeyFilterState)}},ig=Je,dg={Button:he,ButtonGroup:et,Card:tt,Input:Ee,InputText:Ee,Badge:je,Switch:ce,ToggleSwitch:ce,InputSwitch:ce,Modal:me,Dialog:me,Textarea:lt,InputNumber:ot,Password:nt,Checkbox:fe,RadioButton:Ke,Select:$e,Dropdown:$e,MultiSelect:at,Slider:st,Rating:rt,ColorPicker:it,DatePicker:Ve,Calendar:Ve,Avatar:Ce,Chip:ge,Tag:ge,Divider:dt,Accordion:ct,Timeline:mt,Carousel:ft,Image:pt,Toast:ht,Alert:xe,Message:xe,Tooltip:gt,Drawer:Ne,Sidebar:Ne,Popover:Se,OverlayPanel:Se,Skeleton:yt,ProgressBar:bt,ProgressSpinner:Bt,ConfirmDialog:Et,Navbar:De,Menubar:De,Tabs:ze,TabView:ze,Breadcrumb:$t,Pagination:ye,Paginator:ye,Steps:Te,Stepper:Te,ContextMenu:Vt,ScrollTop:Ct,DataTable:xt,Column:Nt,DataView:St,Tree:Mt,AutoComplete:Dt,Cascader:Le,CascadeSelect:Le,TreeSelect:zt,Knob:Tt,SelectButton:Lt,ToggleButton:It,InputOtp:Rt,InputMask:Pt,InputGroup:Ft,InputGroupAddon:At,IconField:jt,InputIcon:Kt,Listbox:Ot,FloatLabel:Ut,IftaLabel:Ht,Editor:Wt,CodeEditor:qt,SplitButton:Yt,SpeedDial:Xt,Panel:Zt,Fieldset:Jt,Splitter:Qt,Toolbar:vt,ScrollPanel:el,Fluid:tl,Deferred:Re,DeferredContent:Re,Menu:ll,TieredMenu:ol,SlideMenu:nl,PanelMenu:al,MegaMenu:sl,Dock:rl,TabMenu:il,OrderList:dl,PickList:cl,TreeTable:ml,OrganizationChart:fl,VirtualScroller:pl,MeterGroup:ul,Inplace:kl,ConfirmPopup:hl,InlineMessage:gl,BlockUI:yl,Galleria:bl,FileUpload:Bl,Terminal:_l,Chart:wl,ImageCropper:He,AvatarGroup:El,OverlayBadge:$l,ImageCompare:Vl,Portal:Cl,Chips:Pe,InputChips:Pe,CheckboxGroup:xl,RadioButtonGroup:Nl,DynamicDialog:Ml,CommandPalette:Dl,InfiniteScroll:zl,Mentions:Tl,SignaturePad:Ll,Form:Il,FormField:Rl},cg={ripple:Ol,tooltip:Ye,focustrap:Yl,animateonscroll:Jl,styleclass:vl,badge:Xe,keyfilter:Je},mg={install(t,s={}){for(const[l,o]of Object.entries(dg))t.component(l,o);for(const[l,o]of Object.entries(cg))t.directive(l,o);if(typeof window<"u"){const{initTheme:l}=jl();l(s.defaultTheme||"clay")}}};x.Accordion=ct,x.Alert=xe,x.AutoComplete=Dt,x.Avatar=Ce,x.AvatarGroup=El,x.Badge=je,x.BadgeDirective=ag,x.BlockUI=yl,x.Breadcrumb=$t,x.Button=he,x.ButtonGroup=et,x.Calendar=Ve,x.Card=tt,x.Carousel=ft,x.CascadeSelect=Le,x.Cascader=Le,x.Chart=wl,x.Checkbox=fe,x.CheckboxGroup=xl,x.Chip=ge,x.Chips=Pe,x.CodeEditor=qt,x.ColorPicker=it,x.Column=Nt,x.CommandPalette=Dl,x.ConfirmDialog=Et,x.ConfirmPopup=hl,x.ContextMenu=Vt,x.DataTable=xt,x.DataView=St,x.DatePicker=Ve,x.Deferred=Re,x.DeferredContent=Re,x.Dialog=me,x.Divider=dt,x.Dock=rl,x.Drawer=Ne,x.Dropdown=$e,x.DynamicDialog=Ml,x.Editor=Wt,x.Fieldset=Jt,x.FileUpload=Bl,x.FloatLabel=Ut,x.Fluid=tl,x.Form=Il,x.FormField=Rl,x.Galleria=bl,x.IconField=jt,x.IftaLabel=Ht,x.Image=pt,x.ImageCompare=Vl,x.ImageCropper=He,x.InfiniteScroll=zl,x.InlineMessage=gl,x.Inplace=kl,x.Input=Ee,x.InputChips=Pe,x.InputGroup=Ft,x.InputGroupAddon=At,x.InputIcon=Kt,x.InputMask=Pt,x.InputNumber=ot,x.InputOtp=Rt,x.InputSwitch=ce,x.InputText=Ee,x.KeyFilter=ig,x.Knob=Tt,x.Listbox=Ot,x.MegaMenu=sl,x.Mentions=Tl,x.Menu=ll,x.Menubar=De,x.Message=xe,x.MeterGroup=ul,x.Modal=me,x.MultiSelect=at,x.Navbar=De,x.OrderList=dl,x.OrganizationChart=fl,x.OverlayBadge=$l,x.OverlayPanel=Se,x.Pagination=ye,x.Paginator=ye,x.Panel=Zt,x.PanelMenu=al,x.Password=nt,x.PickList=cl,x.Popover=Se,x.Portal=Cl,x.ProgressBar=bt,x.ProgressSpinner=Bt,x.RadioButton=Ke,x.RadioButtonGroup=Nl,x.Rating=rt,x.ScrollPanel=el,x.ScrollTop=Ct,x.Select=$e,x.SelectButton=Lt,x.Sidebar=Ne,x.SignaturePad=Ll,x.Skeleton=yt,x.SlideMenu=nl,x.Slider=st,x.SpeedDial=Xt,x.SplitButton=Yt,x.Splitter=Qt,x.Stepper=Te,x.Steps=Te,x.Switch=ce,x.THEME_OPTIONS=Ge,x.TabMenu=il,x.TabView=ze,x.Tabs=ze,x.Tag=ge,x.Terminal=_l,x.Textarea=lt,x.TieredMenu=ol,x.Timeline=mt,x.Toast=ht,x.ToggleButton=It,x.ToggleSwitch=ce,x.Toolbar=vt,x.Tooltip=gt,x.TooltipDirective=Ye,x.Tree=Mt,x.TreeSelect=zt,x.TreeTable=ml,x.VirtualScroller=pl,x.default=mg,x.useConfirm=wt,x.useDialog=Sl,x.useStyle=Xh,x.useTheme=jl,x.useToast=kt,x.vAnimateOnScroll=Jl,x.vBadge=Xe,x.vFocusTrap=Yl,x.vKeyFilter=Je,x.vRipple=Ol,x.vStyleClass=vl,x.vTooltip=Ye,Object.defineProperties(x,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));