@mfs-atomic/ui 0.0.0-stage → 1.0.0

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.
@@ -0,0 +1 @@
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 eo=["disabled","type"],to={key:0,class:"btn__spinner"},lo={key:1,class:"btn__icon btn__icon--prepend"},oo={class:"btn__content"},no={key:2,class:"btn__icon btn__icon--append"},ao=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:r}){const l=r,o=a=>{l("click",a)};return(a,s)=>(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",to)):e.createCommentVNode("",!0),a.$slots.prepend&&!t.loading?(e.openBlock(),e.createElementBlock("span",lo,[e.renderSlot(a.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",oo,[e.renderSlot(a.$slots,"default",{},void 0,!0)]),a.$slots.append&&!t.loading?(e.openBlock(),e.createElementBlock("span",no,[e.renderSlot(a.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],10,eo))}}),D=(t,r)=>{const l=t.__vccOpts||t;for(const[o,a]of r)l[o]=a;return l},ne=D(ao,[["__scopeId","data-v-76212e60"]]),so={},ro={class:"mfs-btn-group mfs-inline-flex mfs-items-center",role:"group"};function io(t,r){return e.openBlock(),e.createElementBlock("div",ro,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const He=D(so,[["render",io],["__scopeId","data-v-3e6bbebb"]]),co={key:0,class:"card__header"},mo={key:0,class:"card__title mfs-title"},fo={key:1,class:"card__subtitle mfs-caption"},po={class:"card__body"},uo={key:1,class:"card__footer"},We=D(e.defineComponent({__name:"Card",props:{title:{},subtitle:{},hoverable:{type:Boolean,default:!1},bordered:{type:Boolean,default:!1}},setup(t){return(r,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["card","mfs-card",{"card--hoverable":t.hoverable,"card--bordered":t.bordered}])},[r.$slots.header||t.title?(e.openBlock(),e.createElementBlock("div",co,[e.renderSlot(r.$slots,"header",{},()=>[e.createElementVNode("div",null,[t.title?(e.openBlock(),e.createElementBlock("h3",mo,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),t.subtitle?(e.openBlock(),e.createElementBlock("p",fo,e.toDisplayString(t.subtitle),1)):e.createCommentVNode("",!0)])],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",po,[e.renderSlot(r.$slots,"default",{},void 0,!0)]),r.$slots.footer?(e.openBlock(),e.createElementBlock("div",uo,[e.renderSlot(r.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-38a6c076"]]),ko={key:0,class:"input-label mfs-text"},ho={key:0,class:"input-required"},go={key:0,class:"input-affix mfs-text-muted input-affix--prepend"},yo=["id","type","value","placeholder","disabled","readonly"],bo={key:1,class:"input-affix mfs-text-muted input-affix--append"},Bo={key:1,class:"input-msg input-msg--error mfs-text-danger"},_o={key:2,class:"input-msg mfs-caption"},fe=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:r}){const l=r,o=a=>{const s=a.target;l("update:modelValue",s.value)};return(a,s)=>(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",ko,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",ho,"*")):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",go,[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:s[0]||(s[0]=i=>a.$emit("focus",i)),onBlur:s[1]||(s[1]=i=>a.$emit("blur",i))},null,40,yo),a.$slots.append?(e.openBlock(),e.createElementBlock("span",bo,[e.renderSlot(a.$slots,"append",{},void 0,!0)])):e.createCommentVNode("",!0)],2),t.error?(e.openBlock(),e.createElementBlock("p",Bo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",_o,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-b6818f92"]]),Se=D(e.defineComponent({__name:"Badge",props:{variant:{default:"primary"},size:{default:"md"}},setup(t){return(r,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(r.$slots,"prepend",{},void 0,!0),e.renderSlot(r.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-649f6dac"]]),wo=["checked","disabled"],Eo={key:0,class:"switch__label"},Q=D(e.defineComponent({__name:"Switch",props:{modelValue:{type:Boolean,default:!1},label:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue","change"],setup(t,{emit:r}){const l=r,o=a=>{const s=a.target;l("update:modelValue",s.checked),l("change",s.checked)};return(a,s)=>(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,wo),s[0]||(s[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",Eo,[e.renderSlot(a.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-de02acdb"]]),$o={key:0,class:"modal-header mfs-flex mfs-items-center mfs-justify-between"},Vo={class:"modal-title mfs-title"},Co={class:"modal-body"},xo={key:1,class:"modal-footer mfs-flex mfs-items-center mfs-justify-end mfs-gap-3"},v=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:r}){const l=t,o=r,a=()=>{o("update:modelValue",!1),o("close")},s=()=>{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,u)=>(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:s},[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:u[0]||(u[0]=e.withModifiers(()=>{},["stop"]))},[t.title||n.$slots.header?(e.openBlock(),e.createElementBlock("div",$o,[e.renderSlot(n.$slots,"header",{},()=>[e.createElementVNode("h3",Vo,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",Co,[e.renderSlot(n.$slots,"default",{},void 0,!0)]),n.$slots.footer?(e.openBlock(),e.createElementBlock("div",xo,[e.renderSlot(n.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],2)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-3a4fa0a7"]]),No=["for"],So={key:0,class:"mfs-text-danger"},Mo=["id","value","placeholder","disabled","readonly","rows","maxlength","aria-invalid"],Do={key:1,class:"textarea-footer mfs-flex mfs-items-center mfs-justify-between mfs-gap-2"},zo={key:0,class:"textarea-msg textarea-msg--error mfs-text-danger"},Lo={key:1,class:"textarea-msg mfs-caption"},To={key:2,class:"textarea-spacer mfs-flex-1"},Io={key:3,class:"textarea-count mfs-caption"},Ge=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:r}){const l=t,o=r,a=e.useId(),s=e.computed(()=>l.id||`mfs-textarea-${a}`),i=e.ref(null),c=e.computed(()=>(l.modelValue??"").length),d=()=>{const u=i.value;!u||!l.autoResize||(u.style.height="auto",u.style.height=`${u.scrollHeight}px`)},n=u=>{const h=u.target;o("update:modelValue",h.value),e.nextTick(d)};return e.watch(()=>l.modelValue,()=>e.nextTick(d)),e.onMounted(d),(u,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:s.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",So,"*")):e.createCommentVNode("",!0)],8,No)):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:s.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]=b=>u.$emit("focus",b)),onBlur:h[1]||(h[1]=b=>u.$emit("blur",b))},null,40,Mo)],2),t.error||t.hint||t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("div",Do,[t.error?(e.openBlock(),e.createElementBlock("p",zo,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Lo,e.toDisplayString(t.hint),1)):(e.openBlock(),e.createElementBlock("span",To)),t.showCount||t.maxlength!==void 0?(e.openBlock(),e.createElementBlock("span",Io,[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"]]),Po=["for"],Ro={key:0,class:"num-required mfs-text-danger"},Fo={class:"num-box mfs-surface mfs-rounded mfs-shadow-inset mfs-flex mfs-items-center mfs-gap-1-5"},Ao=["disabled"],jo={class:"num-input-area mfs-flex-1 mfs-flex mfs-items-center mfs-gap-1 mfs-min-w-0 mfs-px-1"},Ko={key:0,class:"num-prefix mfs-text-muted mfs-font-semibold mfs-select-none"},Oo=["id","value","placeholder","disabled","readonly","aria-invalid","aria-valuemin","aria-valuemax","aria-valuenow"],Uo=["disabled"],Ho={key:1,class:"num-msg num-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Wo={key:2,class:"num-msg mfs-caption mfs-m-0"},qe=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:r}){const l=t,o=r,a=e.useId(),s=e.computed(()=>l.id||`mfs-num-${a}`),i=e.ref(!1),c=e.ref(""),d=k=>{let y=k;l.min!==void 0&&(y=Math.max(l.min,y)),l.max!==void 0&&(y=Math.min(l.max,y));const g=Math.pow(10,l.decimals);return Math.round(y*g)/g},n=e.computed(()=>l.min!==void 0&&l.modelValue!==null&&l.modelValue<=l.min),u=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)),b=()=>{i.value=!0,c.value=l.modelValue!==null&&l.modelValue!==void 0?String(l.modelValue):""},m=k=>{const y=k.target.value;if(c.value=y,y.trim()===""||y==="-"){y.trim()===""&&o("update:modelValue",null);return}const g=Number(y);Number.isNaN(g)||o("update:modelValue",g)},p=()=>{if(i.value=!1,c.value.trim()===""){o("update:modelValue",null),o("change",null);return}const k=Number(c.value);if(Number.isNaN(k)){o("update:modelValue",null),o("change",null);return}const y=d(k);o("update:modelValue",y),o("change",y)},f=k=>{if(l.disabled||l.readonly)return;const y=l.modelValue??(l.min!==void 0?l.min:0),g=d(y+k*l.step);o("update:modelValue",g),o("change",g)};return(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["num-wrapper mfs-flex mfs-flex-col mfs-gap-1-5 mfs-w-full",{"num-wrapper--error":!!t.error,"num-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:s.value,class:"num-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",Ro,"*")):e.createCommentVNode("",!0)],8,Po)):e.createCommentVNode("",!0),e.createElementVNode("div",Fo,[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:y[0]||(y[0]=g=>f(-1))},[...y[4]||(y[4]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,Ao),e.createElementVNode("div",jo,[t.prefix?(e.openBlock(),e.createElementBlock("span",Ko,e.toDisplayString(t.prefix),1)):e.createCommentVNode("",!0),e.createElementVNode("input",{id:s.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:b,onBlur:p,onInput:m,onKeydown:[y[1]||(y[1]=e.withKeys(e.withModifiers(g=>f(1),["prevent"]),["up"])),y[2]||(y[2]=e.withKeys(e.withModifiers(g=>f(-1),["prevent"]),["down"]))]},null,40,Oo)]),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||u.value,onClick:y[3]||(y[3]=g=>f(1))},[...y[5]||(y[5]=[e.createElementVNode("svg",{viewBox:"0 0 24 24",width:"16",height:"16",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round"},[e.createElementVNode("line",{x1:"12",y1:"5",x2:"12",y2:"19"}),e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"})],-1)])],8,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.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-94f092b6"]]),Go=["for"],qo={key:0,class:"mfs-text-danger"},Yo={class:"pwd-box mfs-flex mfs-items-center mfs-surface mfs-rounded mfs-shadow-inset"},Xo=["id","type","value","placeholder","disabled","readonly","aria-invalid"],Zo=["aria-label","aria-pressed","disabled"],Jo={key:0,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},Qo={key:1,viewBox:"0 0 24 24",width:"18",height:"18",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},vo={key:1,class:"pwd-strength mfs-flex mfs-items-center mfs-gap-2","aria-live":"polite"},en={class:"pwd-bars mfs-flex-1"},tn={key:2,class:"pwd-msg pwd-msg--error mfs-text-danger"},ln={key:3,class:"pwd-msg mfs-caption"},Ye=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:r}){const l=t,o=r,a=e.useId(),s=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 u=0;return n.length>=6&&u++,n.length>=10&&u++,/[a-z]/.test(n)&&/[A-Z]/.test(n)&&u++,/\d/.test(n)&&/[^A-Za-z0-9]/.test(n)&&u++,u=Math.max(1,Math.min(4,u)),{score:u,...{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)"}}[u]}});return(n,u)=>(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:s.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",qo,"*")):e.createCommentVNode("",!0)],8,Go)):e.createCommentVNode("",!0),e.createElementVNode("div",Yo,[e.createElementVNode("input",{id:s.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:u[0]||(u[0]=h=>n.$emit("focus",h)),onBlur:u[1]||(u[1]=h=>n.$emit("blur",h))},null,40,Xo),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:u[2]||(u[2]=h=>i.value=!i.value)},[i.value?(e.openBlock(),e.createElementBlock("svg",Jo,[...u[3]||(u[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",Qo,[...u[4]||(u[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,Zo)]),t.showStrength&&t.modelValue?(e.openBlock(),e.createElementBlock("div",vo,[e.createElementVNode("div",en,[(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",tn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",ln,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-e18398e6"]]),on=["id","checked","disabled","aria-label","tabindex"],nn={key:0,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round",class:"checkbox__icon"},an={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"},sn={key:0,class:"checkbox__label"},ee=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:r}){const l=t,o=r,a=e.ref(null),s=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(u=>u!==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:s.value,disabled:t.disabled,"aria-label":t.ariaLabel,tabindex:t.tabindex,onChange:i},null,40,on),e.createElementVNode("span",{class:e.normalizeClass(["checkbox__box mfs-surface mfs-shadow-inset",{"checkbox__box--checked":s.value||t.indeterminate}])},[t.indeterminate?(e.openBlock(),e.createElementBlock("svg",nn,[...d[0]||(d[0]=[e.createElementVNode("line",{x1:"5",y1:"12",x2:"19",y2:"12"},null,-1)])])):s.value?(e.openBlock(),e.createElementBlock("svg",an,[...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",sn,[e.renderSlot(c.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-c6f5af78"]]),rn=["id","name","value","checked","disabled"],dn={key:0,class:"radio__label"},Me=D(e.defineComponent({__name:"RadioButton",props:{modelValue:{},value:{},name:{},label:{},disabled:{type:Boolean,default:!1},id:{}},emits:["update:modelValue","change"],setup(t,{emit:r}){const l=t,o=r,a=e.computed(()=>l.modelValue===l.value),s=()=>{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:s},null,40,rn),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",dn,[e.renderSlot(i.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.label),1)],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-7cb79a2c"]]);function q(t,r,l,o){const a=(o==null?void 0:o.offset)??6,s=(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),u=()=>{var E;if(typeof window>"u"||!t.value)return;const p=t.value.getBoundingClientRect(),f=(E=r.value)==null?void 0:E.getBoundingClientRect(),k=Math.max((f==null?void 0:f.width)??0,s?p.width:0)||p.width,y=(f==null?void 0:f.height)??0;let g=p.left;i==="right"?g=p.right-k:i==="center"&&(g=p.left+(p.width-k)/2);const B=8,w=Math.max(B,window.innerWidth-k-B);g=Math.min(Math.max(B,g),w);const _=window.innerHeight-p.bottom,$=p.top;let V=p.bottom+a;y>0&&p.bottom+a+y>window.innerHeight-B&&$>_&&(V=Math.max(B,p.top-y-a)),c.value=V,d.value=g,n.value=s?p.width:void 0},h=e.computed(()=>{const p={position:"fixed",top:`${c.value}px`,left:`${d.value}px`,zIndex:10100};return s&&n.value!==void 0&&(p.minWidth=`${n.value}px`),p}),b=p=>{var f,k;return p instanceof Node?!!((f=t.value)!=null&&f.contains(p)||(k=r.value)!=null&&k.contains(p)):!1},m=()=>{l.value&&u()};return e.watch(l,p=>{p&&(u(),e.nextTick(u))}),e.watch(r,p=>{p&&l.value&&u()}),e.onMounted(()=>{typeof window>"u"||(window.addEventListener("scroll",m,!0),window.addEventListener("resize",m),l.value&&u())}),e.onBeforeUnmount(()=>{typeof window>"u"||(window.removeEventListener("scroll",m,!0),window.removeEventListener("resize",m))}),{overlayStyle:h,updatePosition:u,containsTarget:b}}const cn={key:0,class:"mfs-text-danger"},mn=["aria-expanded","aria-invalid","disabled"],fn={class:"select-actions mfs-inline-flex mfs-items-center mfs-text-muted"},pn={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},un={key:0,class:"select-search-box"},kn={class:"select-options mfs-flex mfs-flex-col"},hn=["aria-selected","disabled","onClick","onMouseenter"],gn={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"},yn={key:0,class:"select-empty mfs-empty-state"},bn={key:1,class:"select-empty mfs-empty-state"},Bn={key:1,class:"select-msg select-msg--error mfs-text-danger"},_n={key:2,class:"select-msg mfs-caption"},pe=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:r}){const l=t,o=r,a=e.useId(),s=`mfs-select-${a}`,i=`mfs-select-list-${a}`,c=e.ref(null),d=e.ref(null),n=e.ref(null),u=e.ref(null),h=e.ref(!1),b=e.ref(""),m=e.ref(-1),{overlayStyle:p,containsTarget:f}=q(d,n,h,{matchWidth:!0}),k=e.computed(()=>l.options.map(N=>typeof N=="string"?{label:N,value:N}:N)),y=e.computed(()=>{if(l.remote)return k.value;const N=b.value.trim().toLowerCase();return N?k.value.filter(L=>L.label.toLowerCase().includes(N)):k.value}),g=N=>{o("filter",{value:N.target.value})},B=e.computed(()=>k.value.find(N=>N.value===l.modelValue)),w=()=>{l.disabled||(h.value=!0,m.value=y.value.findIndex(N=>N.value===l.modelValue),l.searchable&&e.nextTick(()=>{var N;return(N=u.value)==null?void 0:N.focus()}))},_=()=>{h.value=!1,b.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 L=y.value;if(N.key==="Escape")N.preventDefault(),_();else if(N.key==="ArrowDown"){if(N.preventDefault(),!L.length)return;m.value=(m.value+1)%L.length}else if(N.key==="ArrowUp"){if(N.preventDefault(),!L.length)return;m.value=(m.value-1+L.length)%L.length}else if(N.key==="Enter"){N.preventDefault();const A=L[m.value];A&&!A.disabled&&V(A)}},S=N=>{f(N.target)||_()};return e.onMounted(()=>document.addEventListener("mousedown",S)),e.onBeforeUnmount(()=>document.removeEventListener("mousedown",S)),(N,L)=>(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:s,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",cn,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:d,class:"select-container"},[e.createElementVNode("button",{id:s,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",fn,[t.loading?(e.openBlock(),e.createElementBlock("span",pn)):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"])},[...L[1]||(L[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}])},[...L[2]||(L[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:"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",un,[e.withDirectives(e.createElementVNode("input",{ref_key:"searchRef",ref:u,"onUpdate:modelValue":L[0]||(L[0]=A=>b.value=A),type:"text",class:"select-search mfs-w-full mfs-text-sm mfs-inset",placeholder:"Search...",onInput:g,onKeydown:C},null,544),[[e.vModelText,b.value]])])):e.createCommentVNode("",!0),e.createElementVNode("div",kn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y.value,(A,K)=>(e.openBlock(),e.createElementBlock("button",{key:String(A.value)+K,type:"button",role:"option","aria-selected":A.value===t.modelValue,disabled:A.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":A.value===t.modelValue,"select-option--active":K===m.value}]),onClick:T=>V(A),onMouseenter:T=>m.value=K},[e.renderSlot(N.$slots,"option",{option:A,selected:A.value===t.modelValue},()=>[e.createElementVNode("span",null,e.toDisplayString(A.label),1),A.value===t.modelValue?(e.openBlock(),e.createElementBlock("svg",gn,[...L[3]||(L[3]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],!0)],42,hn))),128)),t.loading&&y.value.length===0?(e.openBlock(),e.createElementBlock("div",yn,[...L[4]||(L[4]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):y.value.length===0?(e.openBlock(),e.createElementBlock("div",bn,[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",Bn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",_n,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-96053d34"]]),wn={key:0,class:"ms-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},En={key:0,class:"mfs-text-danger"},$n=["aria-expanded","aria-invalid","onKeydown"],Vn={class:"ms-chips mfs-flex-1 mfs-flex mfs-flex-wrap mfs-items-center mfs-gap-1-5"},Cn={class:"ms-chip-text"},xn=["aria-label","onClick"],Nn={key:0,class:"ms-placeholder mfs-text-muted"},Sn={key:0,class:"mfs-spinner mfs-spinner--sm mfs-shrink-0","aria-hidden":"true"},Mn={key:0,class:"ms-search-box"},Dn={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},zn={class:"ms-options mfs-flex mfs-flex-col mfs-overflow-y-auto"},Ln=["aria-selected","disabled","onClick"],Tn={key:0,viewBox:"0 0 24 24",width:"12",height:"12",fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},In={key:0,class:"ms-empty mfs-empty-state"},Pn={key:1,class:"ms-empty mfs-empty-state"},Rn={key:1,class:"ms-msg ms-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Fn={key:2,class:"ms-msg mfs-caption mfs-m-0"},Xe=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(""),{overlayStyle:u,containsTarget:h}=q(s,i,d,{matchWidth:!0}),b=e.computed(()=>l.options.map(C=>typeof C=="string"?{label:C,value:C}:C)),m=e.computed(()=>{if(l.remote)return b.value;const C=n.value.trim().toLowerCase();return C?b.value.filter(S=>S.label.toLowerCase().includes(C)):b.value}),p=C=>{o("filter",{value:C.target.value})},f=e.computed(()=>b.value.filter(C=>!C.disabled)),k=e.computed(()=>b.value.filter(C=>l.modelValue.includes(C.value))),y=e.computed(()=>f.value.length>0&&f.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=y.value?[]:f.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",wn,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",En,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"triggerRef",ref:s,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",Vn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k.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",Cn,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(L=>$(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,xn))]))),128)),k.value.length===0?(e.openBlock(),e.createElementBlock("span",Nn,e.toDisplayString(t.placeholder),1)):e.createCommentVNode("",!0)]),t.loading?(e.openBlock(),e.createElementBlock("span",Sn)):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,$n),(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(u)),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",Mn,[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&&f.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":y.value}])},[y.value?(e.openBlock(),e.createElementBlock("svg",Dn,[...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",zn,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(N,L)=>(e.openBlock(),e.createElementBlock("button",{key:String(N.value)+L,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:A=>_(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",Tn,[...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,Ln))),128)),t.loading&&m.value.length===0?(e.openBlock(),e.createElementBlock("div",In,[...S[6]||(S[6]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},null,-1)])])):m.value.length===0?(e.openBlock(),e.createElementBlock("div",Pn,[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",Rn,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Fn,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-196f1d68"]]),An={key:0,class:"slider-header"},jn={class:"slider-label mfs-text"},Kn={class:"slider-readout"},On=["aria-valuemin","aria-valuemax","aria-valuenow"],Un={key:0,class:"slider-tooltip"},Hn=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],Wn={key:0,class:"slider-tooltip"},Ze=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:r}){const l=t,o=r,a=e.ref(null),s=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))},u=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))))},b=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))},m=(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=>{s.value!==null&&m(s.value,b(B.clientX))},f=()=>{s.value!==null&&(s.value=null,o("change",l.modelValue)),window.removeEventListener("pointermove",p),window.removeEventListener("pointerup",f)},k=(B,w)=>{l.disabled||(w.preventDefault(),s.value=B,window.addEventListener("pointermove",p),window.addEventListener("pointerup",f))},y=B=>{if(l.disabled)return;const w=b(B.clientX);let _=0;l.range&&(_=Math.abs(w-c.value)<=Math.abs(w-d.value)?0:1),m(_,w),k(_,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;m(B,h($+_)),o("change",l.modelValue)};return e.onBeforeUnmount(f),(B,w)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["slider-wrapper",{"slider-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("div",An,[e.createElementVNode("span",jn,e.toDisplayString(t.label),1),e.createElementVNode("span",Kn,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-surface mfs-pill mfs-shadow-inset",onPointerdown:y},[e.createElementVNode("div",{class:"slider-fill mfs-pill",style:e.normalizeStyle(u.value)},null,4),t.range?(e.openBlock(),e.createElementBlock("div",{key:0,role:"slider",tabindex:"0",class:e.normalizeClass(["slider-thumb mfs-shadow mfs-focus-ring",{"slider-thumb--active":s.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(_=>k(0,_),["stop"])),onKeydown:w[1]||(w[1]=_=>g(0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",Un,e.toDisplayString(c.value),1)):e.createCommentVNode("",!0)],46,On)):e.createCommentVNode("",!0),e.createElementVNode("div",{role:"slider",tabindex:"0",class:e.normalizeClass(["slider-thumb mfs-shadow mfs-focus-ring",{"slider-thumb--active":s.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(_=>k(t.range?1:0,_),["stop"])),onKeydown:w[3]||(w[3]=_=>g(t.range?1:0,_))},[t.showTooltip?(e.openBlock(),e.createElementBlock("span",Wn,e.toDisplayString(t.range?d.value:i.value),1)):e.createCommentVNode("",!0)],46,Hn)],544)],2))}}),[["__scopeId","data-v-4dc2f81c"]]),Gn={key:0,class:"rating-label mfs-text"},qn=["aria-label","aria-valuemax","aria-valuenow"],Yn=["disabled","aria-label","onMousemove","onClick"],Xn={viewBox:"0 0 24 24",width:"24",height:"24",class:"rating-svg"},Zn=["id"],Jn=["fill","stroke"],Je=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:r}){const l=t,o=r,a=`mfs-star-${e.useId()}`,s=e.ref(null),i=e.computed(()=>s.value!==null?s.value:l.modelValue),c=(m,p)=>{if(!l.allowHalf)return m;const f=p.currentTarget.getBoundingClientRect();return p.clientX-f.left<f.width/2?m-.5:m},d=(m,p)=>{l.disabled||l.readonly||(s.value=c(m,p))},n=(m,p)=>{if(l.disabled||l.readonly)return;const f=c(m,p);o("update:modelValue",f),o("change",f)},u=m=>{if(l.disabled||l.readonly)return;const p=l.allowHalf?.5:1;if(m.key==="ArrowRight"||m.key==="ArrowUp"){m.preventDefault();const f=Math.min(l.stars,l.modelValue+p);o("update:modelValue",f),o("change",f)}else if(m.key==="ArrowLeft"||m.key==="ArrowDown"){m.preventDefault();const f=Math.max(0,l.modelValue-p);o("update:modelValue",f),o("change",f)}},h=m=>{const p=i.value;return p>=m?"var(--warning, #f59e0b)":l.allowHalf&&p>=m-.5?`url(#${a}-${m})`:"transparent"},b=m=>i.value>=m-.5?"var(--warning, #f59e0b)":"var(--text-muted, #94a3b8)";return(m,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",Gn,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]=f=>s.value=null),onKeydown:u},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.stars,f=>(e.openBlock(),e.createElementBlock("button",{key:f,type:"button",class:"rating-star",disabled:t.disabled,"aria-label":`Rate ${f} of ${t.stars}`,onMousemove:k=>d(f,k),onClick:k=>n(f,k)},[(e.openBlock(),e.createElementBlock("svg",Xn,[e.createElementVNode("defs",null,[e.createElementVNode("linearGradient",{id:`${a}-${f}`,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,Zn)]),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(f),stroke:b(f),"stroke-width":"1.8","stroke-linejoin":"round"},null,8,Jn)]))],40,Yn))),128))],40,qn)],2))}}),[["__scopeId","data-v-2a8aa484"]]),Qn={key:0,class:"cp-label mfs-text mfs-text-sm mfs-font-semibold"},vn={class:"cp-container mfs-relative"},ea=["disabled","aria-expanded"],ta={class:"cp-hex mfs-font-mono"},la={class:"cp-native-row mfs-flex mfs-items-center mfs-gap-2"},oa=["value"],na=["value"],aa={class:"cp-rgb mfs-grid mfs-grid-cols-3 mfs-gap-1-5"},sa={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},ra=["value"],ia={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},da=["value"],ca={class:"cp-rgb-item mfs-flex mfs-flex-col mfs-font-semibold mfs-text-muted"},ma=["value"],fa={key:0,class:"cp-presets mfs-grid mfs-grid-cols-4 mfs-gap-2"},pa=["aria-label","onClick"],Qe=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=q(a,s,i,{offset:8}),n=e.computed(()=>/^#[0-9a-fA-F]{6}$/.test(l.modelValue)?l.modelValue:"#8b5cf6"),u=e.computed(()=>{const y=n.value.slice(1);return{r:parseInt(y.slice(0,2),16),g:parseInt(y.slice(2,4),16),b:parseInt(y.slice(4,6),16)}}),h=y=>{o("update:modelValue",y),o("change",y)},b=y=>{const g=y.startsWith("#")?y:`#${y}`;/^#[0-9a-fA-F]{6}$/.test(g)&&h(g.toLowerCase())},m=y=>Math.max(0,Math.min(255,y)).toString(16).padStart(2,"0"),p=(y,g)=>{const B=Number(g.target.value);if(Number.isNaN(B))return;const w={...u.value,[y]:B};h(`#${m(w.r)}${m(w.g)}${m(w.b)}`)},f=y=>{i.value&&!d(y.target)&&(i.value=!1)},k=y=>{y.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",f),document.addEventListener("keydown",k)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",f),document.removeEventListener("keydown",k)}),(y,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",Qn,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",vn,[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",ta,e.toDisplayString(t.modelValue.toUpperCase()),1)],8,ea),(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:s,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",la,[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=>b(B.target.value))},null,40,oa),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=>b(B.target.value))},null,40,na)]),e.createElementVNode("div",aa,[e.createElementVNode("label",sa,[g[6]||(g[6]=e.createElementVNode("span",null,"R",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:u.value.r,onInput:g[3]||(g[3]=B=>p("r",B))},null,40,ra)]),e.createElementVNode("label",ia,[g[7]||(g[7]=e.createElementVNode("span",null,"G",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:u.value.g,onInput:g[4]||(g[4]=B=>p("g",B))},null,40,da)]),e.createElementVNode("label",ca,[g[8]||(g[8]=e.createElementVNode("span",null,"B",-1)),e.createElementVNode("input",{type:"number",min:"0",max:"255",value:u.value.b,onInput:g[5]||(g[5]=B=>p("b",B))},null,40,ma)])]),t.presets.length?(e.openBlock(),e.createElementBlock("div",fa,[(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,pa))),128))])):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0)]),_:1})]))])],2))}}),[["__scopeId","data-v-5c82328d"]]),ua={key:0,class:"dp-label mfs-text mfs-text-sm mfs-font-semibold mfs-flex mfs-items-center mfs-gap-1"},ka={key:0,class:"dp-required mfs-text-danger"},ha={class:"dp-container mfs-relative"},ga=["disabled","aria-expanded","aria-invalid"],ya={class:"dp-header mfs-flex mfs-items-center mfs-justify-between"},ba={class:"dp-month-year mfs-font-bold mfs-text"},Ba={class:"dp-weekdays"},_a=["disabled","onClick"],wa={key:1,class:"dp-msg dp-msg--error mfs-text-danger mfs-font-medium mfs-m-0"},Ea={key:2,class:"dp-msg mfs-caption mfs-m-0"},ue=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=q(a,s,i,{offset:8}),n=new Date,u=M=>{if(!M)return null;const z=M instanceof Date?new Date(M.getTime()):new Date(M);return Number.isNaN(z.getTime())?null:new Date(z.getFullYear(),z.getMonth(),z.getDate())},h=e.computed(()=>Array.isArray(l.modelValue)?u(l.modelValue[0])||n:u(l.modelValue)||n),b=e.ref(h.value.getFullYear()),m=e.ref(h.value.getMonth()),p=e.ref(null),f=["Su","Mo","Tu","We","Th","Fr","Sa"],k=["January","February","March","April","May","June","July","August","September","October","November","December"],y=e.computed(()=>k[m.value]),g=M=>{const z=new Date(b.value,m.value+M,1);b.value=z.getFullYear(),m.value=z.getMonth()},B=e.computed(()=>{const z=new Date(b.value,m.value,1).getDay(),F=[];for(let H=0;H<42;H++){const O=new Date(b.value,m.value,1-z+H);F.push({key:`${O.getFullYear()}-${O.getMonth()}-${O.getDate()}`,date:O,inMonth:O.getMonth()===m.value})}return F}),w=(M,z)=>!!(M&&z&&M.getFullYear()===z.getFullYear()&&M.getMonth()===z.getMonth()&&M.getDate()===z.getDate()),_=e.computed(()=>u(l.min)),$=e.computed(()=>u(l.max)),V=M=>!!(_.value&&M<_.value||$.value&&M>$.value),E=e.computed(()=>!l.range&&!Array.isArray(l.modelValue)?u(l.modelValue):null),C=e.computed(()=>l.range?p.value?[p.value,null]:Array.isArray(l.modelValue)?[u(l.modelValue[0]),u(l.modelValue[1])]:[null,null]:[null,null]),S=M=>{if(!l.range)return w(M,E.value);const[z,F]=C.value;return w(M,z)||w(M,F)},N=M=>{if(!l.range)return!1;const[z,F]=C.value;return!!(z&&F&&M>z&&M<F)},L=M=>M?`${M.getFullYear()}-${String(M.getMonth()+1).padStart(2,"0")}-${String(M.getDate()).padStart(2,"0")}`:"",A=e.computed(()=>{if(!l.range)return L(E.value);if(Array.isArray(l.modelValue)){const M=L(u(l.modelValue[0])),z=L(u(l.modelValue[1]));return M&&z?`${M} – ${z}`:M}return""}),K=M=>{if(!V(M)){if(!l.range){o("update:modelValue",M),o("change",M),i.value=!1;return}if(!p.value)p.value=M;else{const z=M<p.value?[M,p.value]:[p.value,M];p.value=null,o("update:modelValue",z),o("change",z),i.value=!1}}},T=M=>{d(M.target)||(i.value=!1)},P=M=>{M.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",T),document.addEventListener("keydown",P)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",T),document.removeEventListener("keydown",P)}),(M,z)=>(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",ua,[e.createTextVNode(e.toDisplayString(t.label)+" ",1),t.required?(e.openBlock(),e.createElementBlock("span",ka,"*")):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",ha,[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:z[0]||(z[0]=F=>i.value=!i.value)},[z[3]||(z[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":!A.value}])},e.toDisplayString(A.value||t.placeholder),3)],8,ga),(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:s,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",ya,[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:z[1]||(z[1]=F=>g(-1))},[...z[4]||(z[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",ba,e.toDisplayString(y.value)+" "+e.toDisplayString(b.value),1),e.createElementVNode("button",{type:"button",class:"dp-nav mfs-surface-subtle mfs-rounded-md mfs-interactive mfs-inline-flex mfs-items-center mfs-justify-center mfs-border-none mfs-text","aria-label":"Next month",onClick:z[2]||(z[2]=F=>g(1))},[...z[5]||(z[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",Ba,[(e.openBlock(),e.createElementBlock(e.Fragment,null,e.renderList(f,F=>e.createElementVNode("span",{key:F,class:"dp-weekday mfs-text-center mfs-text-xs mfs-font-semibold mfs-text-muted mfs-py-1"},e.toDisplayString(F),1)),64))]),e.createVNode(e.Transition,{name:"dp-fade",mode:"out-in"},{default:e.withCtx(()=>[(e.openBlock(),e.createElementBlock("div",{key:`${b.value}-${m.value}`,class:"dp-grid"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,F=>(e.openBlock(),e.createElementBlock("button",{key:F.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":!F.inMonth,"dp-day--selected":S(F.date),"dp-day--in-range":N(F.date),"dp-day--today":w(F.date,e.unref(n))}]),disabled:V(F.date),onClick:H=>K(F.date)},e.toDisplayString(F.date.getDate()),11,_a))),128))]))]),_:1})],4)):e.createCommentVNode("",!0)]),_:1})]))]),t.error?(e.openBlock(),e.createElementBlock("p",wa,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",Ea,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-cbbd3b1e"]]),$a=["role","aria-label"],Va=["src","alt"],Ca={key:1,class:"avatar__fallback"},xa=["aria-label"],ke=D(e.defineComponent({__name:"Avatar",props:{src:{},alt:{},label:{},size:{default:"md"},shape:{default:"circle"},status:{}},setup(t){const r=t,l=e.ref(!1);e.watch(()=>r.src,()=>{l.value=!1});const o=e.computed(()=>r.src&&!l.value?r.src:""),a=()=>{l.value=!0},s=e.computed(()=>{const i=(r.label||r.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,Va)):(e.openBlock(),e.createElementBlock("span",Ca,[e.renderSlot(i.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(s.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,xa)):e.createCommentVNode("",!0)],10,$a))}}),[["__scopeId","data-v-05a4906f"]]),Na=["role","tabindex","aria-pressed","onKeydown"],Sa={key:0,class:"chip__prepend"},Ma={class:"chip__label"},ae=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:r}){const l=t,o=r,a=s=>{l.clickable&&o("click",s)};return(s,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"])]},[s.$slots.prepend?(e.openBlock(),e.createElementBlock("span",Sa,[e.renderSlot(s.$slots,"prepend",{},void 0,!0)])):e.createCommentVNode("",!0),e.createElementVNode("span",Ma,[e.renderSlot(s.$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,Na))}}),[["__scopeId","data-v-1d8fa890"]]),Da=["aria-orientation"],za={key:0,class:"divider__label mfs-caption"},ve=D(e.defineComponent({__name:"Divider",props:{orientation:{default:"horizontal"},align:{default:"center"},dashed:{type:Boolean,default:!1}},setup(t){const r=e.useSlots(),l=e.computed(()=>!!r.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",za,[e.renderSlot(o.$slots,"default",{},void 0,!0)])):e.createCommentVNode("",!0)],10,Da))}}),[["__scopeId","data-v-2cc4685f"]]),La={class:"accordion mfs-flex mfs-flex-col mfs-gap-3 mfs-w-full"},Ta=["aria-expanded","aria-controls","disabled","onClick"],Ia={class:"accordion__title mfs-title"},Pa=["id"],Ra={class:"accordion__body mfs-overflow-hidden"},Fa={key:0,class:"accordion__text mfs-text-muted"},et=D(e.defineComponent({__name:"Accordion",props:{items:{default:()=>[]},multiple:{type:Boolean,default:!1},modelValue:{default:void 0}},emits:["update:modelValue","change"],setup(t,{emit:r}){const l=t,o=r,a=n=>n==null?[]:Array.isArray(n)?n:[n],s=e.ref(a(l.modelValue));e.watch(()=>l.modelValue,n=>{n!==void 0&&(s.value=a(n))});const i=e.computed(()=>l.modelValue!==void 0?a(l.modelValue):s.value),c=n=>i.value.includes(n),d=n=>{const u=c(n);let h;l.multiple?h=u?i.value.filter(m=>m!==n):[...i.value,n]:h=u?[]:[n],s.value=h;const b=l.multiple?h:h[0]??null;o("update:modelValue",b),o("change",b)};return(n,u)=>(e.openBlock(),e.createElementBlock("div",La,[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:b=>d(h.key)},[e.createElementVNode("span",Ia,e.toDisplayString(h.title),1),u[0]||(u[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,Ta),e.createElementVNode("div",{id:`acc-panel-${h.key}`,class:"accordion__panel",role:"region"},[e.createElementVNode("div",Ra,[e.renderSlot(n.$slots,"item",{item:h,open:c(h.key)},()=>[h.content?(e.openBlock(),e.createElementBlock("p",Fa,e.toDisplayString(h.content),1)):e.createCommentVNode("",!0)],!0)])],8,Pa)],2))),128))]))}}),[["__scopeId","data-v-91745f4e"]]),Aa=["aria-busy"],ja={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Ka={key:1,class:"mfs-empty-state"},Oa={class:"timeline__rail mfs-flex mfs-flex-col mfs-items-center mfs-shrink-0","aria-hidden":"true"},Ua={key:0,class:"timeline__icon-text"},Ha={key:0,class:"timeline__line mfs-flex-1 mfs-my-1"},Wa={class:"timeline__content mfs-surface mfs-rounded mfs-shadow-card mfs-flex-1 mfs-mb-4"},Ga={class:"timeline__header mfs-flex mfs-justify-between mfs-gap-2-5 mfs-flex-wrap"},qa={class:"timeline__title mfs-title mfs-m-0 mfs-font-bold"},Ya={key:0,class:"timeline__time mfs-caption"},Xa={key:0,class:"timeline__desc mfs-text-muted mfs-m-0"},tt=D(e.defineComponent({__name:"Timeline",props:{items:{default:()=>[]},layout:{default:"vertical"},loading:{type:Boolean,default:!1},emptyText:{default:"No items"}},setup(t){return(r,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",ja,[e.renderSlot(r.$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",Ka,[e.renderSlot(r.$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",Oa,[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(r.$slots,"icon",{item:o,index:a},()=>[o.icon?(e.openBlock(),e.createElementBlock("span",Ua,e.toDisplayString(o.icon),1)):e.createCommentVNode("",!0)],!0)],2),a<t.items.length-1?(e.openBlock(),e.createElementBlock("span",Ha)):e.createCommentVNode("",!0)]),e.createElementVNode("div",Wa,[e.renderSlot(r.$slots,"item",{item:o,index:a},()=>[e.createElementVNode("div",Ga,[e.createElementVNode("h4",qa,e.toDisplayString(o.title),1),o.timestamp?(e.openBlock(),e.createElementBlock("time",Ya,e.toDisplayString(o.timestamp),1)):e.createCommentVNode("",!0)]),o.description?(e.openBlock(),e.createElementBlock("p",Xa,e.toDisplayString(o.description),1)):e.createCommentVNode("",!0)],!0)])]))),128))],2)):e.createCommentVNode("",!0)],10,Aa))}}),[["__scopeId","data-v-e4d2eafc"]]),Za=["aria-busy"],Ja={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Qa={key:1,class:"mfs-empty-state"},va={key:2,class:"carousel__stage"},es=["aria-hidden"],ts={class:"carousel__fallback mfs-text"},ls=["disabled"],os=["disabled"],ns={key:3,class:"carousel__indicators mfs-flex mfs-justify-center mfs-py-3"},as={class:"carousel__dots mfs-surface-subtle mfs-pill mfs-blur",role:"tablist","aria-label":"Slide indicators"},ss=["aria-selected","aria-label","onClick"],lt=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:r}){const l=t,o=r,a=e.ref(l.modelValue),s=e.ref(!1);let i=null,c=null;e.watch(()=>l.modelValue,k=>{k>=0&&k<l.items.length&&(a.value=k)});const d=k=>{const y=l.items.length;if(!y)return;let g=k;l.loop?g=(k+y)%y:g=Math.max(0,Math.min(y-1,k)),a.value=g,o("update:modelValue",g),o("change",g)},n=()=>d(a.value+1),u=()=>d(a.value-1),h=k=>{i=k.clientX},b=k=>{if(i===null)return;const y=k.clientX-i;i=null,Math.abs(y)>40&&(y<0?n():u())},m=()=>{i=null},p=()=>{c&&(clearInterval(c),c=null)},f=()=>{p(),l.autoplay&&l.items.length>1&&(c=setInterval(()=>{s.value||n()},l.interval))};return e.watch(()=>[l.autoplay,l.interval,l.items.length],f),e.onMounted(f),e.onBeforeUnmount(p),(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["carousel mfs-surface mfs-rounded mfs-shadow-card",{"carousel--loading-empty":t.loading&&t.items.length===0}]),role:"region","aria-roledescription":"carousel","aria-busy":t.loading||void 0,onMouseenter:y[0]||(y[0]=g=>s.value=!0),onMouseleave:y[1]||(y[1]=g=>s.value=!1),onFocusin:y[2]||(y[2]=g=>s.value=!0),onFocusout:y[3]||(y[3]=g=>s.value=!1)},[t.loading?(e.openBlock(),e.createElementBlock("div",Ja,[e.renderSlot(k.$slots,"loading",{},()=>[y[4]||(y[4]=e.createElementVNode("span",{class:"mfs-spinner","aria-hidden":"true"},null,-1))],!0)])):e.createCommentVNode("",!0),!t.loading&&t.items.length===0?(e.openBlock(),e.createElementBlock("div",Qa,[e.renderSlot(k.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)])):(e.openBlock(),e.createElementBlock("div",va,[e.createElementVNode("div",{class:"carousel__viewport",onPointerdown:h,onPointerup:b,onPointercancel:m},[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(k.$slots,"default",{item:g,index:B},()=>[e.createElementVNode("div",ts,e.toDisplayString(g),1)],!0)],8,es))),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:u},[...y[5]||(y[5]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M12.5 5L7.5 10L12.5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,ls),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},[...y[6]||(y[6]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"18",height:"18",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M7.5 5L12.5 10L7.5 15",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],8,os)],64)):e.createCommentVNode("",!0)])),t.items.length>1?(e.openBlock(),e.createElementBlock("div",ns,[e.createElementVNode("div",as,[(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,ss))),128))])])):e.createCommentVNode("",!0)],42,Za))}}),[["__scopeId","data-v-a3ec7623"]]),rs={key:0,class:"mfs-image__placeholder","aria-hidden":"true"},is=["aria-label"],ds=["src","alt"],cs=["aria-label"],ms=["src","alt"],ot=D(e.defineComponent({__name:"Image",props:{src:{},alt:{default:""},width:{},height:{},preview:{type:Boolean,default:!1},fit:{default:"cover"}},setup(t){const r=t,l=e.ref(!1),o=e.ref(!1),a=e.ref(!1),s=b=>b===void 0?void 0:typeof b=="number"?`${b}px`:b,i=e.computed(()=>({width:s(r.width),height:s(r.height)}));e.watch(()=>r.src,()=>{l.value=!1,o.value=!1});const c=()=>{l.value=!0,o.value=!1},d=()=>{l.value=!1,o.value=!0},n=b=>{b.key==="Escape"&&h()},u=()=>{r.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)}),(b,m)=>(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:u},[!l.value&&!o.value?(e.openBlock(),e.createElementBlock("div",rs)):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"},[...m[1]||(m[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,is)):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,ds),[[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"])},[...m[2]||(m[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:m[0]||(m[0]=e.withModifiers(()=>{},["stop"]))},null,8,ms)],8,cs)):e.createCommentVNode("",!0)]),_:1})]))],6))}}),[["__scopeId","data-v-66fca7b1"]]),X=e.ref([]),Z=new Map;let fs=0;function De(t){const r=Z.get(t);r!=null&&r.timerId&&(clearTimeout(r.timerId),r.timerId=null)}function ps(t,r){if(r<=0)return;De(t);const l=setTimeout(()=>{ze(t)},r);Z.set(t,{timerId:l,remaining:r,startedAt:Date.now()})}function ze(t){De(t),Z.delete(t),X.value=X.value.filter(r=>r.id!==t)}function us(t){const r=Z.get(t);!r||!r.timerId||(clearTimeout(r.timerId),r.timerId=null,r.remaining=Math.max(0,r.remaining-(Date.now()-r.startedAt)))}function ks(t){const r=Z.get(t);!r||r.timerId||r.remaining<=0||(r.startedAt=Date.now(),r.timerId=setTimeout(()=>{ze(t)},r.remaining))}function nt(t){const r=t.id??`mfs-toast-${++fs}`,l=t.duration??4e3,o={id:r,title:t.title,message:t.message,severity:t.severity??"info",duration:l,closable:t.closable??!0},a=X.value.findIndex(s=>s.id===r);return a!==-1?X.value.splice(a,1,o):X.value.push(o),l>0&&ps(r,l),r}function hs(){for(const t of Z.keys())De(t);Z.clear(),X.value=[]}function at(){return{toasts:e.readonly(X),add:nt,show:nt,remove:ze,clear:hs,pause:us,resume:ks}}const gs=["role","onMouseenter","onMouseleave","onFocusin","onFocusout"],ys={class:"mfs-toast__icon mfs-shrink-0","aria-hidden":"true"},bs={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Bs={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},_s={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},ws={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Es={class:"mfs-toast__body mfs-flex-1 mfs-min-w-0"},$s={key:0,class:"mfs-toast__title mfs-title mfs-font-bold"},Vs={class:"mfs-toast__message mfs-text-muted mfs-text-sm"},Cs=["onClick"],st=D(e.defineComponent({__name:"Toast",props:{position:{default:"top-right"},max:{}},setup(t){const r=t,{toasts:l,remove:o,pause:a,resume:s}=at(),i=e.computed(()=>r.max&&r.max>0?l.value.slice(-r.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:u=>e.unref(a)(n.id),onMouseleave:u=>e.unref(s)(n.id),onFocusin:u=>e.unref(a)(n.id),onFocusout:u=>e.unref(s)(n.id)},[e.createElementVNode("span",ys,[n.severity==="success"?(e.openBlock(),e.createElementBlock("svg",bs,[...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",Bs,[...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",_s,[...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",ws,[...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",Es,[n.title?(e.openBlock(),e.createElementBlock("div",$s,e.toDisplayString(n.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Vs,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:u=>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,Cs)):e.createCommentVNode("",!0)],42,gs))),128))]),_:1})],2)]))}}),[["__scopeId","data-v-e95e4289"]]),xs={class:"mfs-alert__icon","aria-hidden":"true"},Ns={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ss={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ms={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Ds={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},zs={class:"mfs-alert__content"},Ls={key:0,class:"mfs-alert__title mfs-title"},Ts={class:"mfs-alert__body mfs-text-muted"},he=D(e.defineComponent({__name:"Alert",props:{severity:{default:"info"},title:{},closable:{type:Boolean,default:!1}},emits:["close"],setup(t,{emit:r}){const l=r;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",xs,[e.renderSlot(o.$slots,"icon",{},()=>[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Ns,[...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",Ss,[...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",Ms,[...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",Ds,[...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",zs,[t.title?(e.openBlock(),e.createElementBlock("div",Ls,e.toDisplayString(t.title),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Ts,[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]=s=>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"]]),Is=["aria-describedby"],Ps=["id"],rt=D(e.defineComponent({__name:"Tooltip",props:{content:{default:""},placement:{default:"top"},disabled:{type:Boolean,default:!1}},setup(t){const r=t,l=e.ref(!1),o=e.useId(),a=()=>{!r.disabled&&r.content&&(l.value=!0)},s=()=>{l.value=!1};return(i,c)=>(e.openBlock(),e.createElementBlock("span",{class:"mfs-tooltip-wrapper",onMouseenter:a,onMouseleave:s,onFocusin:a,onFocusout:s,onKeydown:e.withKeys(s,["escape"])},[e.createElementVNode("span",{class:"mfs-tooltip__trigger","aria-describedby":l.value&&t.content?e.unref(o):void 0},[e.renderSlot(i.$slots,"default",{},void 0,!0)],8,Is),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-rounded-sm mfs-blur",[`mfs-tooltip--${t.placement}`]])},[e.createTextVNode(e.toDisplayString(t.content)+" ",1),c[0]||(c[0]=e.createElementVNode("span",{class:"mfs-tooltip__arrow","aria-hidden":"true"},null,-1))],10,Ps)):e.createCommentVNode("",!0)]),_:1})],32))}}),[["__scopeId","data-v-573f32ab"]]),Rs=["aria-label"],Fs={key:0,class:"mfs-drawer__header mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},As={class:"mfs-drawer__title mfs-title mfs-m-0 mfs-font-bold"},js={class:"mfs-drawer__body mfs-flex-1 mfs-p-5 mfs-overflow-y-auto"},Ks={key:1,class:"mfs-drawer__footer mfs-border-t mfs-flex mfs-justify-end mfs-gap-2-5"},ge=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:r}){const l=t,o=r,a=e.computed(()=>l.position==="left"||l.position==="right"),s=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=b=>{b.key==="Escape"&&l.modelValue&&i()};let n="",u=!1;const h=b=>{if(!(typeof document>"u"))if(b){if(u)return;n=document.body.style.overflow,document.body.style.overflow="hidden",document.addEventListener("keydown",d),u=!0}else u&&(document.body.style.overflow=n,document.removeEventListener("keydown",d),u=!1)};return e.onMounted(()=>{l.modelValue&&h(!0)}),e.watch(()=>l.modelValue,b=>h(b)),e.onBeforeUnmount(()=>{h(!1)}),(b,m)=>(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(s.value),role:"dialog","aria-modal":"true","aria-label":t.title||"Drawer",onClick:m[0]||(m[0]=e.withModifiers(()=>{},["stop"]))},[t.title||b.$slots.header?(e.openBlock(),e.createElementBlock("div",Fs,[e.renderSlot(b.$slots,"header",{},()=>[e.createElementVNode("h3",As,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},[...m[1]||(m[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",js,[e.renderSlot(b.$slots,"default",{},void 0,!0)]),b.$slots.footer?(e.openBlock(),e.createElementBlock("div",Ks,[e.renderSlot(b.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],14,Rs)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-1d638027"]]),Os={class:"mfs-popover-wrapper"},Us=["aria-expanded"],ye=D(e.defineComponent({__name:"Popover",props:{modelValue:{type:Boolean,default:void 0},placement:{default:"bottom"}},emits:["update:modelValue"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(null),s=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:u}=q(a,s,d,{offset:10,align:"center"}),h=y=>{c.value||(i.value=y),o("update:modelValue",y)},b=()=>h(!d.value),m=()=>h(!1),p=y=>{u(y.target)||m()},f=y=>{y.key==="Escape"&&m()},k=y=>{typeof document>"u"||(y?(document.addEventListener("pointerdown",p),document.addEventListener("keydown",f)):(document.removeEventListener("pointerdown",p),document.removeEventListener("keydown",f)))};return e.watch(d,y=>k(y),{immediate:!0}),e.onBeforeUnmount(()=>{k(!1)}),(y,g)=>(e.openBlock(),e.createElementBlock("div",Os,[e.createElementVNode("div",{ref_key:"triggerRef",ref:a,class:"mfs-popover__trigger","aria-expanded":d.value,"aria-haspopup":"dialog",onClick:b},[e.renderSlot(y.$slots,"trigger",{open:d.value,toggle:b},void 0,!0)],8,Us),(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:s,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(y.$slots,"default",{close:m},void 0,!0)],6)):e.createCommentVNode("",!0)]),_:3})]))]))}}),[["__scopeId","data-v-cd2807a7"]]),it=D(e.defineComponent({__name:"Skeleton",props:{variant:{default:"text"},width:{},height:{},lines:{default:1},animated:{type:Boolean,default:!0}},setup(t){const r=t,l=e.computed(()=>r.variant!=="text"?1:Math.max(1,Math.floor(r.lines))),o=a=>{const s=r.variant==="text"&&l.value>1&&a===l.value,i=r.variant==="circle"?"48px":s?"72%":"100%",c=r.variant==="circle"?r.width??"48px":r.variant==="text"?"14px":"80px";return{width:s&&!r.width?"72%":r.width??i,height:r.height??c}};return(a,s)=>(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"]]),Hs={class:"mfs-progress"},Ws=["aria-valuenow"],Gs={key:0,class:"mfs-progress__label mfs-caption"},dt=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 r=t,l=e.computed(()=>Math.min(100,Math.max(0,r.value)));return(o,a)=>(e.openBlock(),e.createElementBlock("div",Hs,[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,Ws),t.showValue&&!t.indeterminate?(e.openBlock(),e.createElementBlock("span",Gs,e.toDisplayString(Math.round(l.value))+"% ",1)):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-9a84cdec"]]),qs={class:"mfs-spinner__svg",viewBox:"0 0 50 50"},Ys=["stroke-width"],Xs=["stroke-width"],ct=D(e.defineComponent({__name:"ProgressSpinner",props:{size:{default:"md"},strokeWidth:{default:4},variant:{default:"primary"}},setup(t){const r=t,l={sm:"22px",md:"36px",lg:"52px"},o=e.computed(()=>typeof r.size=="number"?`${r.size}px`:l[r.size]);return(a,s)=>(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",qs,[e.createElementVNode("circle",{class:"mfs-spinner__track",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth},null,8,Ys),e.createElementVNode("circle",{class:"mfs-spinner__ring",cx:"25",cy:"25",r:"20",fill:"none","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,Xs)]))],6))}}),[["__scopeId","data-v-fcb783c0"]]),be=e.ref({isOpen:!1,options:null});let te=null;function mt(t){var o,a;const r=be.value.options,l=te;te=null,be.value={isOpen:!1,options:null},t?(o=r==null?void 0:r.onAccept)==null||o.call(r):(a=r==null?void 0:r.onReject)==null||a.call(r),l==null||l(t)}function Zs(t){return te&&(te(!1),te=null),be.value={isOpen:!0,options:{confirmLabel:"Confirm",cancelLabel:"Cancel",variant:"primary",...t}},new Promise(r=>{te=r})}function ft(){return{state:e.readonly(be),confirm:Zs,accept:()=>mt(!0),reject:()=>mt(!1)}}const Js=["aria-labelledby","aria-describedby"],Qs={class:"mfs-confirm__header"},vs=["id"],er=["id"],tr={class:"mfs-confirm__actions"},pt=D(e.defineComponent({__name:"ConfirmDialog",setup(t){const{state:r,accept:l,reject:o}=ft(),a=e.useId(),s=e.useId(),i=c=>{c.key==="Escape"&&r.value.isOpen&&o()};return e.watch(()=>r.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(r).isOpen&&e.unref(r).options?(e.openBlock(),e.createElementBlock("div",{key:0,class:"mfs-confirm-backdrop mfs-backdrop",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",role:"alertdialog","aria-modal":"true","aria-labelledby":e.unref(a),"aria-describedby":e.unref(s),onClick:d[2]||(d[2]=e.withModifiers(()=>{},["stop"]))},[e.createElementVNode("div",Qs,[e.createElementVNode("h3",{id:e.unref(a),class:"mfs-confirm__title mfs-title"},e.toDisplayString(e.unref(r).options.title),9,vs)]),e.createElementVNode("p",{id:e.unref(s),class:"mfs-confirm__message mfs-text-muted"},e.toDisplayString(e.unref(r).options.message),9,er),e.createElementVNode("div",tr,[e.createElementVNode("button",{type:"button",class:"mfs-confirm__btn mfs-confirm__btn--cancel mfs-surface-subtle mfs-pill mfs-shadow mfs-focus-ring",onClick:d[0]||(d[0]=(...n)=>e.unref(o)&&e.unref(o)(...n))},e.toDisplayString(e.unref(r).options.cancelLabel??"Cancel"),1),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-confirm__btn mfs-confirm__btn--accept mfs-pill mfs-shadow mfs-focus-ring",[`mfs-confirm__btn--${e.unref(r).options.variant??"primary"}`]]),onClick:d[1]||(d[1]=(...n)=>e.unref(l)&&e.unref(l)(...n))},e.toDisplayString(e.unref(r).options.confirmLabel??"Confirm"),3)])],8,Js)])):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-a2ebf57e"]]),lr={class:"navbar__inner mfs-flex mfs-items-center mfs-justify-between mfs-gap-4"},or={class:"navbar__brand mfs-flex mfs-items-center mfs-font-bold"},nr={class:"navbar__nav","aria-label":"Main navigation"},ar={class:"navbar__list mfs-flex mfs-items-center"},sr=["aria-current","onClick"],rr={class:"navbar__actions mfs-flex mfs-items-center"},ir=["aria-expanded"],dr={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"},cr={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"},mr={key:0,id:"navbar-mobile-drawer",class:"navbar__drawer",role:"region","aria-label":"Mobile navigation"},fr={class:"navbar__mobile-list mfs-flex mfs-flex-col"},pr=["aria-current","onClick"],Be=D(e.defineComponent({__name:"Navbar",props:{items:{default:()=>[]},sticky:{type:Boolean,default:!0},bordered:{type:Boolean,default:!0}},emits:["navigate"],setup(t,{emit:r}){const l=r,o=e.ref(!1),a=(c,d)=>{l("navigate",c,d)},s=(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",lr,[e.createElementVNode("div",or,[e.renderSlot(c.$slots,"brand",{},void 0,!0)]),e.createElementVNode("nav",nr,[e.renderSlot(c.$slots,"links",{items:t.items,navigate:a},()=>[e.createElementVNode("ul",ar,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,u)=>(e.openBlock(),e.createElementBlock("li",{key:u,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,sr)):(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",rr,[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",cr,[...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",dr,[...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,ir)])]),e.createVNode(e.Transition,{name:"navbar-drawer"},{default:e.withCtx(()=>[o.value?(e.openBlock(),e.createElementBlock("div",mr,[e.renderSlot(c.$slots,"links",{items:t.items,navigate:s},()=>[e.createElementVNode("ul",fr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,u)=>(e.openBlock(),e.createElementBlock("li",{key:u},[!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=>s(n,h)},e.toDisplayString(n.label),11,pr)):(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=>s(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"]]),ur={class:"tabs"},kr=["aria-selected","aria-disabled","disabled","tabindex","onClick"],hr={key:0,class:"tabs__panel",role:"tabpanel"},_e=D(e.defineComponent({__name:"Tabs",props:{items:{},modelValue:{},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(null),s=new Map,i=e.ref({left:0,width:0,ready:!1}),c=e.computed(()=>{var k;if(l.modelValue!==void 0)return l.modelValue;const f=l.items.find(y=>!y.disabled);return(f==null?void 0:f.key)??((k=l.items[0])==null?void 0:k.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=(f,k)=>{k?s.set(f,k):s.delete(f)},u=async(f=!1)=>{await e.nextTick();const k=s.get(c.value);if(!k){i.value={left:0,width:0,ready:!1};return}i.value={left:k.offsetLeft,width:k.offsetWidth,ready:!0},f&&l.scrollable&&k.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},h=(f,k)=>{f.disabled||f.key===c.value||(o("update:modelValue",f.key),o("change",f.key))},b=f=>{var B;const k=l.items.filter(w=>!w.disabled);if(!k.length)return;const y=k.findIndex(w=>w.key===c.value);let g=-1;if(f.key==="ArrowRight"?g=(y+1)%k.length:f.key==="ArrowLeft"?g=(y-1+k.length)%k.length:f.key==="Home"?g=0:f.key==="End"&&(g=k.length-1),g>=0){f.preventDefault();const w=k[g];h(w),(B=s.get(w.key))==null||B.focus()}};let m=null;e.watch(()=>[c.value,l.items],()=>u(!0),{deep:!0});const p=()=>u(!1);return e.onMounted(()=>{u(!1),typeof ResizeObserver<"u"&&a.value&&(m=new ResizeObserver(p),m.observe(a.value)),window.addEventListener("resize",p)}),e.onUnmounted(()=>{m==null||m.disconnect(),window.removeEventListener("resize",p)}),(f,k)=>(e.openBlock(),e.createElementBlock("div",ur,[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:b},[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,(y,g)=>(e.openBlock(),e.createElementBlock("button",{key:y.key,ref_for:!0,ref:B=>n(y.key,B),type:"button",role:"tab",class:e.normalizeClass(["tabs__tab mfs-pill mfs-bg-transparent",{"tabs__tab--active":y.key===c.value,"tabs__tab--disabled mfs-disabled":y.disabled}]),"aria-selected":y.key===c.value,"aria-disabled":y.disabled||void 0,disabled:y.disabled,tabindex:y.key===c.value?0:-1,onClick:B=>h(y)},[e.renderSlot(f.$slots,"tab",{item:y,active:y.key===c.value},()=>[e.createTextVNode(e.toDisplayString(y.label),1)],!0)],10,kr))),128))],34),f.$slots.default?(e.openBlock(),e.createElementBlock("div",hr,[e.renderSlot(f.$slots,"default",{activeKey:c.value},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-80912f0b"]]),gr={class:"breadcrumb mfs-surface mfs-pill mfs-inline-flex mfs-items-center","aria-label":"Breadcrumb"},yr={class:"breadcrumb__list mfs-flex mfs-flex-wrap mfs-items-center"},br={key:0,class:"breadcrumb__separator mfs-inline-flex mfs-items-center mfs-text-muted","aria-hidden":"true"},Br={key:0},_r={key:1,width:"14",height:"14",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},wr=["aria-current"],Er=["onClick"],ut=D(e.defineComponent({__name:"Breadcrumb",props:{items:{},separator:{default:"chevron"}},emits:["navigate"],setup(t,{emit:r}){const l=r;return(o,a)=>(e.openBlock(),e.createElementBlock("nav",gr,[e.createElementVNode("ol",yr,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(s,i)=>(e.openBlock(),e.createElementBlock("li",{key:i,class:"breadcrumb__item mfs-inline-flex mfs-items-center"},[i>0?(e.openBlock(),e.createElementBlock("span",br,[e.renderSlot(o.$slots,"separator",{},()=>[t.separator==="slash"?(e.openBlock(),e.createElementBlock("span",Br,"/")):(e.openBlock(),e.createElementBlock("svg",_r,[...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:s,isLast:i===t.items.length-1},()=>[i===t.items.length-1||s.disabled?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(["breadcrumb__leaf mfs-text mfs-font-semibold",{"breadcrumb__leaf--disabled mfs-disabled":s.disabled}]),"aria-current":i===t.items.length-1?"page":void 0},e.toDisplayString(s.label),11,wr)):!s.to&&!s.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",s,c)},e.toDisplayString(s.label),9,Er)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(s.to?"router-link":"a"),{key:2,to:s.to,href:s.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",s,c)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s.label),1)]),_:2},1032,["to","href","onClick"]))],!0)]))),128))])]))}}),[["__scopeId","data-v-79984457"]]),$r=["aria-busy"],Vr={class:"pagination__controls"},Cr=["disabled"],xr=["disabled"],Nr={key:0,class:"pagination__ellipsis mfs-text-muted","aria-hidden":"true"},Sr=["disabled","aria-label","aria-current","onClick"],Mr=["disabled"],Dr=["disabled"],zr={key:0,class:"pagination__extras"},Lr={key:0,class:"pagination__per-page"},Tr=["value","disabled"],Ir=["value"],Pr={class:"pagination__label mfs-text-muted"},Rr=["max","disabled"],se=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:r}){const l=t,o=e.computed(()=>l.disabled||l.loading),a=r,s=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 b=i.value,m=c.value,p=l.siblingCount,f=p*2+5;if(b<=f)return Array.from({length:b},(_,$)=>$+1);const k=Math.max(m-p,1),y=Math.min(m+p,b),g=k>2,B=y<b-1,w=[1];if(g)w.push("ellipsis");else for(let _=2;_<k;_++)w.push(_);for(let _=Math.max(2,k);_<=Math.min(b-1,y);_++)w.push(_);if(B)w.push("ellipsis");else for(let _=y+1;_<b;_++)w.push(_);return b>1&&w.push(b),w}),n=b=>{if(o.value)return;const m=Math.min(Math.max(1,b),i.value);m!==c.value&&(a("update:modelValue",m),a("change",{page:m,perPage:l.perPage}))},u=b=>{if(o.value)return;const m=Number(b.target.value),p=Math.max(1,Math.ceil(l.total/Math.max(1,m))),f=Math.min(c.value,p);a("update:perPage",m),f!==c.value&&a("update:modelValue",f),a("change",{page:f,perPage:m})},h=()=>{if(o.value)return;const b=Number.parseInt(s.value,10);Number.isNaN(b)||n(b),s.value=""};return(b,m)=>(e.openBlock(),e.createElementBlock("nav",{class:"pagination mfs-row mfs-text","aria-label":"Pagination","aria-busy":t.loading||void 0},[e.createElementVNode("div",Vr,[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:m[0]||(m[0]=p=>n(1))},[...m[5]||(m[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,Cr),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:m[1]||(m[1]=p=>n(c.value-1))},[...m[6]||(m[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,xr),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(p,f)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:f},[p==="ellipsis"?(e.openBlock(),e.createElementBlock("span",Nr," … ")):(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:k=>n(p)},e.toDisplayString(p),11,Sr))],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:m[2]||(m[2]=p=>n(c.value+1))},[...m[7]||(m[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,Mr),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:m[3]||(m[3]=p=>n(i.value))},[...m[8]||(m[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,Dr)]),t.perPageOptions.length||t.showJumpTo?(e.openBlock(),e.createElementBlock("div",zr,[t.perPageOptions.length?(e.openBlock(),e.createElementBlock("label",Lr,[m[9]||(m[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:u},[(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,Ir))),128))],40,Tr)])):e.createCommentVNode("",!0),t.showJumpTo?(e.openBlock(),e.createElementBlock("form",{key:1,class:"pagination__jump",onSubmit:e.withModifiers(h,["prevent"])},[e.createElementVNode("label",Pr,[m[10]||(m[10]=e.createTextVNode(" Go ",-1)),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":m[4]||(m[4]=p=>s.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,Rr),[[e.vModelText,s.value]])])],32)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],8,$r))}}),[["__scopeId","data-v-81601b38"]]),Fr=["aria-current"],Ar=["onClick"],jr={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},Kr={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"},Or={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"},Ur={key:2},Hr={class:"steps__content mfs-flex mfs-flex-col"},Wr={class:"steps__label mfs-font-semibold"},Gr={key:0,class:"steps__desc mfs-text-muted"},qr={key:1,class:"steps__trigger mfs-inline-flex mfs-items-center mfs-border-none mfs-rounded-md"},Yr={class:"steps__circle mfs-inline-flex mfs-items-center mfs-justify-center mfs-font-bold mfs-surface mfs-shadow"},Xr={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"},Zr={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"},Jr={key:2},Qr={class:"steps__content mfs-flex mfs-flex-col"},vr={class:"steps__label mfs-font-semibold"},ei={key:0,class:"steps__desc mfs-text-muted"},we=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:r}){const l=t,o=r,a=(i,c)=>i.status?i.status:c<l.modelValue?"completed":c===l.modelValue?"active":"upcoming",s=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:u=>s(n)},[e.createElementVNode("span",jr,[a(d,n)==="completed"?(e.openBlock(),e.createElementBlock("svg",Kr,[...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",Or,[...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",Ur,e.toDisplayString(n+1),1))]),e.createElementVNode("span",Hr,[e.createElementVNode("span",Wr,e.toDisplayString(d.label),1),d.description?(e.openBlock(),e.createElementBlock("span",Gr,e.toDisplayString(d.description),1)):e.createCommentVNode("",!0)])],8,Ar)):(e.openBlock(),e.createElementBlock("div",qr,[e.createElementVNode("span",Yr,[a(d,n)==="completed"?(e.openBlock(),e.createElementBlock("svg",Xr,[...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",Zr,[...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",Jr,e.toDisplayString(n+1),1))]),e.createElementVNode("span",Qr,[e.createElementVNode("span",vr,e.toDisplayString(d.label),1),d.description?(e.openBlock(),e.createElementBlock("span",ei,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,Fr))),128))],2))}}),[["__scopeId","data-v-b60b46b4"]]),ti={key:0,class:"ctx-menu__divider mfs-divider",role:"separator"},li={key:1,role:"none"},oi=["disabled","onClick"],ni={key:0,class:"ctx-menu__icon","aria-hidden":"true"},ai={class:"ctx-menu__label"},kt=D(e.defineComponent({__name:"ContextMenu",props:{items:{}},emits:["select","open","close"],setup(t,{expose:r,emit:l}){const o=t,a=l,s=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)},u=()=>{s.value&&(s.value=!1,y(),a("close"))},h=async g=>{var w;s.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())}k()},b=g=>{var B;g.disabled||((B=g.action)==null||B.call(g),a("select",g),u())},m=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(),u())},p=g=>{i.value&&!i.value.contains(g.target)&&u()},f=g=>{g.key==="Escape"&&u()},k=()=>{window.addEventListener("pointerdown",p),window.addEventListener("keydown",f),window.addEventListener("resize",u)},y=()=>{window.removeEventListener("pointerdown",p),window.removeEventListener("keydown",f),window.removeEventListener("resize",u)};return e.onUnmounted(()=>{y()}),r({open:h,close:u}),(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(()=>[s.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:m},[(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",ti)):(e.openBlock(),e.createElementBlock("li",li,[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:$=>b(w)},[e.renderSlot(g.$slots,"item",{item:w},()=>[w.icon?(e.openBlock(),e.createElementBlock("span",ni,e.toDisplayString(w.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",ai,e.toDisplayString(w.label),1)],!0)],10,oi)]))],64))),128))],36)):e.createCommentVNode("",!0)]),_:3})]))],32))}}),[["__scopeId","data-v-abdbc3af"]]),ht=D(e.defineComponent({__name:"ScrollTop",props:{threshold:{default:200},behavior:{default:"smooth"},target:{default:null}},emits:["click"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(!1);let s=null;const i=()=>typeof l.target=="string"?document.querySelector(l.target)??window:l.target instanceof HTMLElement?l.target:window,c=()=>{if(!s)return;const n=s===window?window.scrollY:s.scrollTop;a.value=n>=l.threshold},d=n=>{i().scrollTo({top:0,behavior:l.behavior}),o("click",n)};return e.onMounted(()=>{s=i(),s.addEventListener("scroll",c,{passive:!0}),c()}),e.onUnmounted(()=>{s==null||s.removeEventListener("scroll",c)}),(n,u)=>(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",{},()=>[u[0]||(u[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"]]),si={key:0,class:"data-table__toolbar mfs-flex mfs-flex-wrap mfs-items-center mfs-justify-between mfs-gap-3 mfs-border-b"},ri={key:0,class:"data-table__search mfs-relative mfs-flex mfs-items-center"},ii=["value"],di={class:"data-table__wrap mfs-w-full mfs-overflow-x-auto"},ci={class:"data-table__table mfs-w-full mfs-text-left"},mi={class:"data-table__head"},fi={key:0,class:"data-table__th data-table__th--select mfs-text-muted mfs-whitespace-nowrap"},pi=["aria-sort"],ui=["onClick"],ki={class:"data-table__sort-icon mfs-shrink-0",viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},hi=["fill"],gi=["fill"],yi={key:1},bi={class:"data-table__body"},Bi={key:0,class:"data-table__empty-row"},_i=["colspan"],wi={class:"data-table__empty-content mfs-inline-flex mfs-flex-col mfs-items-center mfs-gap-2"},Ei=["aria-selected","onClick"],$i=["checked","aria-label","onChange"],Vi=["data-label"],Ci={class:"data-table__cell-value"},xi={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"},Ni={key:0,class:"data-table__per-page mfs-inline-flex mfs-items-center mfs-gap-2 mfs-text-sm mfs-text-muted"},Si=["value","disabled"],Mi=["value"],Di={key:2,class:"mfs-loading-overlay","aria-busy":"true"},gt=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}},emits:["update:selection","update:searchQuery","update:page","update:rows","update:rowsPerPage","update:first","page","sort","filter","row-click"],setup(t,{emit:r}){const l=t,o=r,a=`dt-radio-${e.useId()}`,s=e.ref(l.searchQuery),i=e.ref(null),c=e.ref(null),d=e.computed(()=>l.value??(Array.isArray(l.rows)?l.rows:[])),n=e.ref(typeof l.rows=="number"?l.rows:l.rowsPerPage??10);e.watch(()=>l.rows,T=>{typeof T=="number"&&(n.value=T)}),e.watch(()=>l.rowsPerPage,T=>{T!==void 0&&(n.value=T)});const u=e.computed(()=>Math.max(1,typeof l.rows=="number"?l.rows:l.rowsPerPage??n.value)),h=e.ref(l.page!==void 0?Math.max(1,l.page):l.first>0?Math.floor(l.first/u.value)+1:1);e.watch(()=>l.page,T=>{T!==void 0&&(h.value=Math.max(1,T))}),e.watch(()=>l.first,T=>{T!==void 0&&l.page===void 0&&(h.value=Math.floor(Math.max(0,T)/u.value)+1)}),e.watch(()=>l.searchQuery,T=>{s.value=T});const b=e.computed(()=>l.searchQuery!==""?l.searchQuery:s.value);e.watch(b,()=>{!l.lazy&&l.paginator&&_.value!==1&&(h.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 p(T,P){const M=T==null?void 0:T[l.rowKey];return typeof M=="string"||typeof M=="number"?M:P}function f(T){const P=T.target.value;s.value=P,o("update:searchQuery",P),o("filter",P)}function k(T){i.value!==T?(i.value=T,c.value="asc"):c.value==="asc"?c.value="desc":(i.value=null,c.value=null),o("sort",{key:T,order:c.value})}function y(T){if(T.sortable)return i.value!==T.key||!c.value?"none":c.value==="asc"?"ascending":"descending"}const g=e.computed(()=>{if(l.lazy)return d.value;const T=b.value.trim().toLowerCase();let P=d.value;if(T){const M=l.columns.map(z=>z.key);P=P.filter(z=>M.some(F=>String(z[F]??"").toLowerCase().includes(T)))}if(i.value&&c.value){const M=i.value,z=c.value==="asc"?1:-1;P=[...P].sort((F,H)=>{const O=F[M],Y=H[M];return O==null&&Y==null?0:O==null?-1*z:Y==null?1*z:typeof O=="number"&&typeof Y=="number"?(O-Y)*z:String(O).localeCompare(String(Y))*z})}return P}),B=e.computed(()=>l.lazy?l.totalRecords??d.value.length:l.totalRecords??g.value.length),w=e.computed(()=>Math.max(1,Math.ceil(B.value/u.value))),_=e.computed(()=>{const T=l.page!==void 0?l.page:h.value;return Math.min(Math.max(1,T),w.value)}),$=e.computed(()=>{if(l.lazy||!l.paginator)return g.value;const T=(_.value-1)*u.value;return g.value.slice(T,T+u.value)});function V(T){const P=u.value,M=w.value,z=Math.min(Math.max(1,T),M),F=(z-1)*P;h.value=z,o("update:page",z),o("update:first",F),o("page",{page:z,first:F,rows:P,pageCount:M,rowsPerPage:P})}function E(T){if(l.loading)return;const P=Number(T.target.value);if(!Number.isFinite(P)||P<=0)return;n.value=P;const M=Math.max(1,Math.ceil(B.value/P)),z=Math.min(_.value,M),F=(z-1)*P;h.value=z,o("update:rows",P),o("update:rowsPerPage",P),o("update:page",z),o("update:first",F),o("page",{page:z,first:F,rows:P,pageCount:M,rowsPerPage:P})}function C(T,P){if(!m.value||!l.selection)return!1;const M=p(T,P);return m.value==="single"?Array.isArray(l.selection)?!1:p(l.selection,-1)===M:Array.isArray(l.selection)&&l.selection.some((z,F)=>p(z,F)===M)}const S=e.computed(()=>m.value!=="multiple"||$.value.length===0?!1:$.value.every((T,P)=>C(T,P))),N=e.computed(()=>{if(m.value!=="multiple"||$.value.length===0)return!1;const T=$.value.filter((P,M)=>C(P,M)).length;return T>0&&T<$.value.length});function L(T,P){if(!m.value)return;if(m.value==="single"){o("update:selection",T);return}const M=p(T,P),z=Array.isArray(l.selection)?[...l.selection]:[],F=z.findIndex((H,O)=>p(H,O)===M);F>=0?z.splice(F,1):z.push(T),o("update:selection",z)}function A(){m.value==="multiple"&&(S.value?o("update:selection",[]):o("update:selection",[...$.value]))}function K(T,P){o("row-click",T),m.value&&L(T,P)}return(T,P)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["data-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card mfs-overflow-hidden",`data-table--${t.responsiveMode}`])},[t.searchable||T.$slots.header?(e.openBlock(),e.createElementBlock("div",si,[e.renderSlot(T.$slots,"header",{},void 0,!0),t.searchable?(e.openBlock(),e.createElementBlock("div",ri,[P[3]||(P[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:b.value,placeholder:"Search...","aria-label":"Search table",onInput:f},null,40,ii)])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",di,[e.createElementVNode("table",ci,[e.createElementVNode("thead",mi,[e.createElementVNode("tr",null,[m.value?(e.openBlock(),e.createElementBlock("th",fi,[m.value==="multiple"?(e.openBlock(),e.createBlock(ee,{key:0,class:"data-table__checkbox","model-value":S.value,indeterminate:N.value,"aria-label":"Select all rows",onClick:P[0]||(P[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":A},null,8,["model-value","indeterminate"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,M=>(e.openBlock(),e.createElementBlock("th",{key:M.key,class:e.normalizeClass(["data-table__th mfs-text-muted mfs-whitespace-nowrap",[M.align?`data-table__cell--${M.align}`:"",{"data-table__th--sortable":M.sortable}]]),style:e.normalizeStyle(M.width?{width:M.width}:void 0),"aria-sort":y(M)},[M.sortable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"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",onClick:z=>k(M.key)},[e.createElementVNode("span",null,e.toDisplayString(M.label),1),(e.openBlock(),e.createElementBlock("svg",ki,[e.createElementVNode("path",{d:"M8 3L11 6.5H5L8 3Z",fill:i.value===M.key&&c.value==="asc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,hi),e.createElementVNode("path",{d:"M8 13L5 9.5H11L8 13Z",fill:i.value===M.key&&c.value==="desc"?"currentColor":"none",stroke:"currentColor","stroke-width":"1.2"},null,8,gi)]))],8,ui)):(e.openBlock(),e.createElementBlock("span",yi,e.toDisplayString(M.label),1))],14,pi))),128))])]),e.createElementVNode("tbody",bi,[$.value.length===0?(e.openBlock(),e.createElementBlock("tr",Bi,[e.createElementVNode("td",{colspan:t.columns.length+(m.value?1:0),class:"data-table__empty mfs-text-muted mfs-text-center"},[e.renderSlot(T.$slots,"empty",{},()=>[e.createElementVNode("div",wi,[P[4]||(P[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,_i)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList($.value,(M,z)=>(e.openBlock(),e.createElementBlock("tr",{key:p(M,z),class:e.normalizeClass(["data-table__row",{"data-table__row--selected":C(M,z)}]),"aria-selected":m.value?C(M,z):void 0,onClick:F=>K(M,z)},[m.value?(e.openBlock(),e.createElementBlock("td",{key:0,class:"data-table__td data-table__td--select","data-label":"Select",onClick:P[2]||(P[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:C(M,z),"aria-label":`Select row ${z+1}`,onChange:F=>L(M,z)},null,40,$i)):(e.openBlock(),e.createBlock(ee,{key:1,class:"data-table__checkbox","model-value":C(M,z),"aria-label":`Select row ${z+1}`,onClick:P[1]||(P[1]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":F=>L(M,z)},null,8,["model-value","aria-label","onUpdate:modelValue"]))])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.columns,F=>(e.openBlock(),e.createElementBlock("td",{key:F.key,class:e.normalizeClass(["data-table__td",F.align?`data-table__cell--${F.align}`:""]),"data-label":F.label},[e.renderSlot(T.$slots,`cell-${F.key}`,{row:M,value:M[F.key],column:F,index:z},()=>[e.createElementVNode("span",Ci,e.toDisplayString(M[F.key]??""),1)],!0)],10,Vi))),128))],10,Ei))),128))])])]),t.paginator?(e.openBlock(),e.createElementBlock("div",xi,[t.rowsPerPageOptions.length?(e.openBlock(),e.createElementBlock("label",Ni,[P[5]||(P[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:u.value,disabled:t.loading,"aria-label":"Rows per page",onChange:E},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.rowsPerPageOptions,M=>(e.openBlock(),e.createElementBlock("option",{key:M,value:M},e.toDisplayString(M),9,Mi))),128))],40,Si),P[6]||(P[6]=e.createElementVNode("span",null,"per page",-1))])):e.createCommentVNode("",!0),e.createVNode(se,{"model-value":_.value,total:B.value,"per-page":u.value,"per-page-options":[],loading:t.loading,"onUpdate:modelValue":V},null,8,["model-value","total","per-page","loading"])])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Di,[e.renderSlot(T.$slots,"loading",{},()=>[P[7]||(P[7]=e.createElementVNode("span",{class:"mfs-spinner"},null,-1))],!0)])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-7aecf5cc"]]),yt=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(r,l)=>null}});function re(t,r,l="id"){if(t&&typeof t=="object"&&l in t){const o=t[l];if(typeof o=="string"||typeof o=="number")return o}return r}const zi={class:"data-view mfs-relative"},Li={class:"data-view__header"},Ti={class:"data-view__header-left"},Ii={class:"data-view__toggle mfs-inset mfs-rounded-md",role:"group","aria-label":"View layout"},Pi=["aria-pressed"],Ri=["aria-pressed"],Fi={key:0,class:"data-view__empty mfs-card mfs-text-muted"},Ai={class:"data-view__empty-content"},ji={class:"data-view__fallback-card mfs-card"},Ki={key:2,class:"mfs-loading-overlay","aria-busy":"true"},bt=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:r}){const l=t,o=r,a=e.ref(l.layout);e.watch(()=>l.layout,d=>{a.value=d});const s=e.computed(()=>a.value),i=e.computed(()=>{if(!(s.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",zi,[e.createElementVNode("div",Li,[e.createElementVNode("div",Ti,[e.renderSlot(d.$slots,"header",{},void 0,!0)]),e.createElementVNode("div",Ii,[e.createElementVNode("button",{type:"button",class:e.normalizeClass(["data-view__toggle-btn mfs-rounded-sm",{"data-view__toggle-btn--active mfs-shadow":s.value==="grid"}]),"aria-pressed":s.value==="grid","aria-label":"Grid layout",onClick:n[0]||(n[0]=u=>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,Pi),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["data-view__toggle-btn mfs-rounded-sm",{"data-view__toggle-btn--active mfs-shadow":s.value==="list"}]),"aria-pressed":s.value==="list","aria-label":"List layout",onClick:n[1]||(n[1]=u=>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,Ri)])]),t.items.length===0?(e.openBlock(),e.createElementBlock("div",Fi,[e.renderSlot(d.$slots,"empty",{},()=>[e.createElementVNode("div",Ai,[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--${s.value}`]),style:e.normalizeStyle(i.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(u,h)=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(re)(u,h,t.itemKey),class:"data-view__item"},[s.value==="grid"&&d.$slots.grid?e.renderSlot(d.$slots,"grid",{item:u,index:h},void 0,!0,0):s.value==="list"&&d.$slots.list?e.renderSlot(d.$slots,"list",{item:u,index:h},void 0,!0,1):e.renderSlot(d.$slots,"default",{item:u,index:h,layout:s.value},()=>[e.createElementVNode("div",ji,e.toDisplayString(u),1)],!0,2)]))),128))],6)),t.loading?(e.openBlock(),e.createElementBlock("div",Ki,[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"]]),Oi=["role"],Ui={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Hi={key:1,class:"mfs-empty-state"},Wi=["aria-expanded","aria-selected","aria-disabled"],Gi=["onClick","onKeydown"],qi=["aria-label","onClick"],Yi={key:1,class:"tree__spacer","aria-hidden":"true"},Xi={key:3,class:"tree__icon","aria-hidden":"true"},Zi={class:"tree__content"},Ji={class:"tree__label"},Bt=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:r}){const l=t,o=r;function a(m){return Array.isArray(m.children)&&m.children.length>0}function s(m){return a(m)||l.lazy&&!m.leaf}function i(m){return l.expandedKeys.includes(m)}function c(m){return l.selectedKeys.includes(m)}function d(m){var k;if(!s(m))return;const p=new Set(l.expandedKeys),f=!p.has(m.key);f?(p.add(m.key),l.lazy&&!((k=m.children)!=null&&k.length)&&o("lazy-load",m)):p.delete(m.key),o("update:expandedKeys",Array.from(p)),o("node-toggle",m,f)}function n(m){s(m)&&!i(m.key)&&d(m)}function u(m){s(m)&&i(m.key)&&d(m)}function h(m){if(m.disabled||l.selectionMode==="none")return;if(l.selectionMode==="single"){o("update:selectedKeys",c(m.key)?[]:[m.key]);return}const p=new Set(l.selectedKeys);p.has(m.key)?p.delete(m.key):p.add(m.key),o("update:selectedKeys",Array.from(p))}function b(m){m.disabled||(o("node-click",m),l.selectionMode!=="none"?h(m):s(m)&&d(m))}return(m,p)=>{const f=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",Ui,[e.renderSlot(m.$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",Hi,[e.renderSlot(m.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.nodes,k=>(e.openBlock(),e.createElementBlock("li",{key:k.key,class:"tree__item",role:"treeitem","aria-expanded":s(k)?i(k.key):void 0,"aria-selected":t.selectionMode!=="none"?c(k.key):void 0,"aria-disabled":k.disabled||void 0},[e.createElementVNode("div",{class:e.normalizeClass(["tree__row mfs-rounded-sm mfs-focus-ring",{"tree__row--selected":c(k.key),"tree__row--disabled mfs-disabled":k.disabled}]),style:e.normalizeStyle({paddingLeft:`${t.level*20+8}px`}),tabindex:"0",onClick:y=>b(k),onKeydown:[e.withKeys(e.withModifiers(y=>b(k),["prevent"]),["enter"]),e.withKeys(e.withModifiers(y=>b(k),["prevent"]),["space"]),e.withKeys(e.withModifiers(y=>n(k),["prevent"]),["right"]),e.withKeys(e.withModifiers(y=>u(k),["prevent"]),["left"])]},[s(k)?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["tree__toggle mfs-text-muted",{"tree__toggle--expanded":i(k.key)}]),"aria-label":i(k.key)?`Collapse ${k.label}`:`Expand ${k.label}`,tabindex:"-1",onClick:e.withModifiers(y=>d(k),["stop"])},[...p[7]||(p[7]=[e.createElementVNode("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M6 4L10 8L6 12",stroke:"currentColor","stroke-width":"1.8","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,qi)):(e.openBlock(),e.createElementBlock("span",Yi)),t.selectionMode==="checkbox"?(e.openBlock(),e.createBlock(ee,{key:2,class:"tree__checkbox","model-value":c(k.key),disabled:k.disabled,"aria-label":`Select ${k.label}`,tabindex:-1,onClick:p[0]||(p[0]=e.withModifiers(()=>{},["stop"])),"onUpdate:modelValue":y=>h(k)},null,8,["model-value","disabled","aria-label","onUpdate:modelValue"])):e.createCommentVNode("",!0),k.icon?(e.openBlock(),e.createElementBlock("span",Xi,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("div",Zi,[e.renderSlot(m.$slots,"node",{node:k,expanded:i(k.key),selected:c(k.key),level:t.level},()=>[e.createElementVNode("span",Ji,e.toDisplayString(k.label),1)],!0)])],46,Gi),a(k)&&i(k.key)?(e.openBlock(),e.createBlock(f,{key:0,nodes:k.children,"expanded-keys":t.expandedKeys,"selection-mode":t.selectionMode,"selected-keys":t.selectedKeys,lazy:t.lazy,level:t.level+1,"onUpdate:expandedKeys":p[1]||(p[1]=y=>m.$emit("update:expandedKeys",y)),"onUpdate:selectedKeys":p[2]||(p[2]=y=>m.$emit("update:selectedKeys",y)),onNodeClick:p[3]||(p[3]=y=>m.$emit("node-click",y)),onNodeToggle:p[4]||(p[4]=(y,g)=>m.$emit("node-toggle",y,g)),onLazyLoad:p[5]||(p[5]=y=>m.$emit("lazy-load",y))},e.createSlots({_:2},[m.$slots.node?{name:"node",fn:e.withCtx(y=>[e.renderSlot(m.$slots,"node",e.mergeProps({ref_for:!0},y),void 0,!0)]),key:"0"}:void 0]),1032,["nodes","expanded-keys","selection-mode","selected-keys","lazy","level"])):e.createCommentVNode("",!0)],8,Wi))),128))],10,Oi)}}}),[["__scopeId","data-v-0e17bf40"]]),Qi={class:"ac-box mfs-surface mfs-rounded mfs-shadow-inset"},vi=["aria-expanded","value","placeholder","disabled"],ed={key:0,class:"ac-spinner","aria-hidden":"true"},td=["aria-selected","onMousedown","onMouseenter"],ld={key:0,class:"mfs-empty-state",role:"status"},_t=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:r}){const l=t,o=r,a=`mfs-ac-${e.useId()}`,s=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(-1),{overlayStyle:u,containsTarget:h}=q(i,c,d,{matchWidth:!0}),b=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))}),m=e.computed(()=>(l.modelValue||"").length>=l.minLength&&!l.loading&&b.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},f=()=>{(l.modelValue||"").length>=l.minLength&&(b.value.length||!l.loading)&&(d.value=!0)},k=B=>{o("update:modelValue",B.label),o("select",B),d.value=!1},y=B=>{if(d.value){if(B.key==="Escape")d.value=!1;else if(B.key==="ArrowDown")B.preventDefault(),b.value.length&&(n.value=(n.value+1)%b.value.length);else if(B.key==="ArrowUp")B.preventDefault(),b.value.length&&(n.value=(n.value-1+b.value.length)%b.value.length);else if(B.key==="Enter"&&n.value>=0){B.preventDefault();const w=b.value[n.value];w&&k(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:s,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",Qi,[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:f,onKeydown:y},null,40,vi),t.loading?(e.openBlock(),e.createElementBlock("span",ed)):e.createCommentVNode("",!0)]),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"ac-pop"},{default:e.withCtx(()=>[d.value&&(b.value.length||m.value)?(e.openBlock(),e.createElementBlock("ul",{key:0,ref_key:"overlayRef",ref:c,role:"listbox",style:e.normalizeStyle(e.unref(u)),class:"ac-dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.value,(_,$)=>(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=>k(_),["prevent"]),onMouseenter:V=>n.value=$},e.toDisplayString(_.label),43,td))),128)),m.value?(e.openBlock(),e.createElementBlock("li",ld,[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"]]),od={key:0,class:"cas-label mfs-text"},nd={class:"cas-container"},ad=["disabled","aria-expanded"],sd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},rd={key:0,class:"cas-col"},id={key:1,class:"cas-col"},dd={class:"mfs-empty-state"},cd=["disabled","onClick"],md={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},fd={key:1,viewBox:"0 0 24 24",width:"14",height:"14",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},pd={key:0,class:"cas-col"},Ee=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=q(a,s,i,{offset:6}),n=e.ref([...l.modelValue]);e.watch(()=>l.modelValue,f=>{n.value=[...f||[]]});const u=e.computed(()=>{const f=[];let k=l.options,y=0;for(;k&&k.length;){f.push(k);const g=n.value[y],B=k.find(w=>w.value===g);k=B==null?void 0:B.children,y++}return f}),h=e.computed(()=>{const f=[];let k=l.options;for(const y of l.modelValue||[]){const g=k==null?void 0:k.find(B=>B.value===y);if(!g)break;f.push(g.label),k=g.children}return f.join(l.separator)}),b=(f,k)=>{var g,B;if(k.disabled)return;const y=[...n.value.slice(0,f),k.value];if(n.value=y,l.lazy&&!k.isLeaf&&!((g=k.children)!=null&&g.length)){o("lazy-load",k);return}(B=k.children)!=null&&B.length||(o("update:modelValue",y),o("change",y),i.value=!1)},m=f=>{d(f.target)||(i.value=!1)},p=f=>{f.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",m),document.addEventListener("keydown",p)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",m),document.removeEventListener("keydown",p)}),(f,k)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["cas-wrapper",{"cas-wrapper--disabled mfs-disabled":t.disabled}])},[t.label?(e.openBlock(),e.createElementBlock("span",od,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",nd,[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:k[0]||(k[0]=y=>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",sd)):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}])},[...k[1]||(k[1]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2))],8,ad),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[e.createVNode(e.Transition,{name:"cas-pop"},{default:e.withCtx(()=>[i.value?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"overlayRef",ref:s,style:e.normalizeStyle(e.unref(c)),class:"cas-panel mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading&&u.value.length===0?(e.openBlock(),e.createElementBlock("div",rd,[e.renderSlot(f.$slots,"loading",{},()=>[k[2]||(k[2]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):u.value.length===0?(e.openBlock(),e.createElementBlock("div",id,[e.createElementVNode("div",dd,[e.renderSlot(f.$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(u.value,(y,g)=>(e.openBlock(),e.createElementBlock("div",{key:g,class:"cas-col"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(y,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:_=>b(g,B)},[e.createElementVNode("span",null,e.toDisplayString(B.label),1),B.loading?(e.openBlock(),e.createElementBlock("span",md)):(w=B.children)!=null&&w.length||t.lazy&&!B.isLeaf?(e.openBlock(),e.createElementBlock("svg",fd,[...k[3]||(k[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,cd)}),128))]))),128)),t.loading?(e.openBlock(),e.createElementBlock("div",pd,[e.renderSlot(f.$slots,"loading",{},()=>[k[4]||(k[4]=e.createElementVNode("div",{class:"mfs-empty-state"},[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"})],-1))],!0)])):e.createCommentVNode("",!0)],64))],4)):e.createCommentVNode("",!0)]),_:3})]))])],2))}}),[["__scopeId","data-v-63dca0d2"]]),ud={key:0,class:"ts-label mfs-text"},kd={class:"ts-container"},hd=["disabled","aria-expanded"],gd={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},yd={key:1,class:"mfs-empty-state"},bd=["aria-selected"],Bd=["aria-label","onClick"],_d={key:0,class:"mfs-spinner mfs-spinner--sm","aria-hidden":"true"},wd={key:1,class:"ts-expand-spacer"},Ed=["disabled","onClick"],$d={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"},wt=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(null),i=e.ref(!1),{overlayStyle:c,containsTarget:d}=q(a,s,i,{offset:6,matchWidth:!0}),n=e.reactive(new Set),u=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}),b=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}),m=e.computed(()=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.map(g=>b.value.get(g)??String(g)).join(", "):l.modelValue===null||l.modelValue===void 0?"":b.value.get(l.modelValue)??String(l.modelValue)),p=g=>l.multiple&&Array.isArray(l.modelValue)?l.modelValue.includes(g):l.modelValue===g,f=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},k=g=>{d(g.target)||(i.value=!1)},y=g=>{g.key==="Escape"&&(i.value=!1)};return e.onMounted(()=>{document.addEventListener("mousedown",k),document.addEventListener("keydown",y)}),e.onBeforeUnmount(()=>{document.removeEventListener("mousedown",k),document.removeEventListener("keydown",y)}),(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",ud,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0),e.createElementVNode("div",kd,[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":!m.value}])},e.toDisplayString(m.value||t.placeholder),3),t.loading?(e.openBlock(),e.createElementBlock("span",gd)):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,hd),(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:s,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",yd,[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($=>u(w.node),["stop"])},[w.node.loading?(e.openBlock(),e.createElementBlock("span",_d)):(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,Bd)):(e.openBlock(),e.createElementBlock("span",wd)),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["ts-node mfs-text",{"ts-node--selected":p(w.node.value)}]),disabled:w.node.disabled,onClick:$=>f(w.node)},[e.createElementVNode("span",null,e.toDisplayString(w.node.label),1),p(w.node.value)?(e.openBlock(),e.createElementBlock("svg",$d,[...B[4]||(B[4]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],10,Ed)],12,bd)}),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"]]),Vd=["aria-valuemin","aria-valuemax","aria-valuenow","aria-label"],Cd=["viewBox","width","height"],xd=["d","stroke-width"],Nd=["d","stroke-width"],Sd={class:"knob-value mfs-text mfs-font-mono"},Md={key:0,class:"knob-label mfs-caption"},Et=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:r}){const l=t,o=r,a=e.ref(null),s=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}`},u=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)),b=e.computed(()=>{const B=225+u.value*270;return B<=225.1?"":n(225,B)}),m=e.computed(()=>l.valueTemplate.replace("{value}",String(l.modelValue))),p=(B,w)=>{var A;const _=(A=a.value)==null?void 0:A.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,L=Math.max(l.min,Math.min(l.max,Number(N.toFixed(6))));o("update:modelValue",L)},f=B=>{s.value&&p(B.clientX,B.clientY)},k=()=>{s.value&&(s.value=!1,o("change",l.modelValue)),window.removeEventListener("pointermove",f),window.removeEventListener("pointerup",k)},y=B=>{l.disabled||l.readonly||(B.preventDefault(),s.value=!0,p(B.clientX,B.clientY),window.addEventListener("pointermove",f),window.addEventListener("pointerup",k))},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(k),(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:y,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,xd),e.createElementVNode("path",{d:b.value,fill:"none",stroke:"var(--primary, #8b5cf6)","stroke-width":t.strokeWidth,"stroke-linecap":"round"},null,8,Nd)],8,Cd)),e.createElementVNode("span",Sd,e.toDisplayString(m.value),1)],44,Vd),t.label?(e.openBlock(),e.createElementBlock("span",Md,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-5002b75d"]]),Dd=["disabled","aria-pressed","onClick"],$t=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:r}){const l=t,o=r,a=e.computed(()=>l.options.map(c=>typeof c=="string"?{label:c,value:c}:c)),s=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(u=>u!==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,u)=>(e.openBlock(),e.createElementBlock("button",{key:String(n.value)+u,type:"button",class:e.normalizeClass(["sb-btn mfs-text mfs-focus-ring",{"sb-btn--active mfs-shadow":s(n.value)}]),disabled:t.disabled||n.disabled,"aria-pressed":s(n.value),onClick:h=>i(n)},e.toDisplayString(n.label),11,Dd))),128))],2))}}),[["__scopeId","data-v-80282f25"]]),zd=["aria-pressed","disabled"],Vt=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:r}){const l=t,o=r,a=()=>{if(l.disabled)return;const s=!l.modelValue;o("update:modelValue",s),o("change",s)};return(s,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(s.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.modelValue?t.onLabel:t.offLabel),1)],!0)],10,zd))}}),[["__scopeId","data-v-84c00cdb"]]),Ld=["type","inputmode","value","disabled","aria-label","onInput","onKeydown","onPaste"],Ct=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:r}){const l=t,o=r,a=e.ref([]),s=(h,b)=>{a.value[b]=h},i=e.computed(()=>Array.from({length:l.length},(h,b)=>l.modelValue[b]??"")),c=h=>{const b=h.join("").slice(0,l.length);o("update:modelValue",b),b.length===l.length&&!h.includes("")&&o("complete",b)},d=(h,b)=>{var k;const p=b.target.value.slice(-1);if(l.integerOnly&&p&&!/^\d$/.test(p)){b.target.value=i.value[h];return}const f=[...i.value];f[h]=p,c(f),p&&h<l.length-1&&((k=a.value[h+1])==null||k.focus())},n=(h,b)=>{var m,p,f;b.key==="Backspace"&&!i.value[h]&&h>0?(m=a.value[h-1])==null||m.focus():b.key==="ArrowLeft"&&h>0?(b.preventDefault(),(p=a.value[h-1])==null||p.focus()):b.key==="ArrowRight"&&h<l.length-1&&(b.preventDefault(),(f=a.value[h+1])==null||f.focus())},u=(h,b)=>{var y,g;b.preventDefault();const m=((y=b.clipboardData)==null?void 0:y.getData("text"))??"",p=l.integerOnly?m.replace(/\D/g,""):m;if(!p)return;const f=[...i.value];for(let B=0;B<p.length&&h+B<l.length;B++)f[h+B]=p[B];c(f);const k=Math.min(l.length-1,h+p.length);(g=a.value[k])==null||g.focus()};return(h,b)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["otp-wrapper",{"otp-wrapper--disabled mfs-disabled":t.disabled}]),role:"group","aria-label":"One-time password"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.length,m=>(e.openBlock(),e.createElementBlock("input",{key:m,ref_for:!0,ref:p=>s(p,m-1),type:t.mask?"password":"text",inputmode:t.integerOnly?"numeric":"text",maxlength:"1",value:i.value[m-1],disabled:t.disabled,"aria-label":`Digit ${m} of ${t.length}`,class:"otp-cell mfs-surface mfs-rounded mfs-shadow-inset mfs-text mfs-font-mono",onInput:p=>d(m-1,p),onKeydown:p=>n(m-1,p),onPaste:p=>u(m-1,p)},null,40,Ld))),128))],2))}}),[["__scopeId","data-v-825a2351"]]),Td={class:"mask-box mfs-surface mfs-rounded mfs-shadow-inset"},Id=["value","placeholder","disabled"],xt=D(e.defineComponent({__name:"InputMask",props:{modelValue:{default:""},mask:{},label:{},placeholder:{},disabled:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(t,{emit:r}){const l=t,o=r,a=`mfs-mask-${e.useId()}`,s=(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 u="",h=0;for(let b=0;b<l.mask.length&&h<n.length;b++){const m=l.mask[b];if(m==="9"||m==="a"||m==="*"){for(;h<n.length&&!s(m,n[h]);)h++;h<n.length&&(u+=n[h],h++)}else u+=m,n[h]===m&&h++}return u},c=d=>{const n=d.target,u=i(n.value);n.value=u,o("update:modelValue",u)};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",Td,[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,Id)])],2))}}),[["__scopeId","data-v-5d657e20"]]),Pd={},Rd={class:"ig-wrapper mfs-surface mfs-rounded mfs-shadow-inset"};function Fd(t,r){return e.openBlock(),e.createElementBlock("div",Rd,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const Nt=D(Pd,[["render",Fd],["__scopeId","data-v-9b55039f"]]),Ad={},jd={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 Kd(t,r){return e.openBlock(),e.createElementBlock("span",jd,[e.renderSlot(t.$slots,"default",{},void 0,!0)])}const St=D(Ad,[["render",Kd],["__scopeId","data-v-06440459"]]),Od={key:0,class:"icon-field__icon mfs-text-muted","aria-hidden":"true"},Mt=D(e.defineComponent({__name:"IconField",props:{iconPosition:{default:"left"},fluid:{type:Boolean,default:!1}},setup(t){return(r,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["icon-field",[`icon-field--${t.iconPosition}`,{"icon-field--fluid":t.fluid}]])},[r.$slots.icon?(e.openBlock(),e.createElementBlock("span",Od,[e.renderSlot(r.$slots,"icon",{},void 0,!0)])):e.createCommentVNode("",!0),e.renderSlot(r.$slots,"default",{},void 0,!0)],2))}}),[["__scopeId","data-v-aafeb221"]]),Ud={},Hd={class:"input-icon mfs-inline-flex mfs-items-center mfs-justify-center mfs-text-muted","aria-hidden":"true"};function Wd(t,r){return e.openBlock(),e.createElementBlock("span",Hd,[e.renderSlot(t.$slots,"default")])}const Dt=D(Ud,[["render",Wd]]),Gd={key:0,class:"lb-filter-box"},qd=["disabled"],Yd=["aria-multiselectable"],Xd=["aria-selected","onClick","onKeydown"],Zd={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"},Jd={key:0,class:"lb-empty mfs-text-muted"},zt=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:r}){const l=t,o=r,a=e.ref(""),s=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?s.value.filter(u=>u.label.toLowerCase().includes(n)):s.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 u=Array.isArray(l.modelValue)?l.modelValue:[],h=u.includes(n.value)?u.filter(b=>b!==n.value):[...u,n.value];o("update:modelValue",h),o("change",h)}else o("update:modelValue",n.value),o("change",n.value)};return(n,u)=>(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",Gd,[e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":u[0]||(u[0]=h=>a.value=h),type:"text",class:"lb-filter mfs-inset mfs-text",placeholder:"Filter...",disabled:t.disabled},null,8,qd),[[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,b)=>(e.openBlock(),e.createElementBlock("li",{key:String(h.value)+b,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:m=>d(h),onKeydown:[e.withKeys(e.withModifiers(m=>d(h),["prevent"]),["enter"]),e.withKeys(e.withModifiers(m=>d(h),["prevent"]),["space"])]},[e.createElementVNode("span",null,e.toDisplayString(h.label),1),c(h.value)?(e.openBlock(),e.createElementBlock("svg",Zd,[...u[1]||(u[1]=[e.createElementVNode("polyline",{points:"20 6 9 17 4 12"},null,-1)])])):e.createCommentVNode("",!0)],42,Xd))),128)),i.value.length===0?(e.openBlock(),e.createElementBlock("li",Jd,"No options")):e.createCommentVNode("",!0)],8,Yd)],2))}}),[["__scopeId","data-v-57e05a19"]]),Qd=["for"],Lt=D(e.defineComponent({__name:"FloatLabel",props:{label:{},forId:{},active:{type:Boolean}},setup(t){return(r,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["fl-wrapper",{"fl-wrapper--active":t.active}])},[e.renderSlot(r.$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,Qd)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-c37f1a9e"]]),vd={class:"ifta-wrapper mfs-surface mfs-rounded mfs-shadow-inset"},ec=["for"],tc={class:"ifta-control"},Tt=D(e.defineComponent({__name:"IftaLabel",props:{label:{},forId:{}},setup(t){return(r,l)=>(e.openBlock(),e.createElementBlock("div",vd,[t.label?(e.openBlock(),e.createElementBlock("label",{key:0,for:t.forId,class:"ifta-label mfs-text-muted"},e.toDisplayString(t.label),9,ec)):e.createCommentVNode("",!0),e.createElementVNode("div",tc,[e.renderSlot(r.$slots,"default",{},void 0,!0)])]))}}),[["__scopeId","data-v-289391b4"]]),lc={key:0,class:"ed-toolbar mfs-surface-subtle",role:"toolbar","aria-label":"Formatting"},oc=["contenteditable","data-placeholder"],It=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:r}){const l=t,o=r,a=e.ref(null),s=n=>{const u=new DOMParser().parseFromString(n||"","text/html");return u.body.querySelectorAll("script, iframe, object, embed").forEach(h=>h.remove()),u.body.querySelectorAll("*").forEach(h=>{for(const b of Array.from(h.attributes)){const m=b.name.toLowerCase(),p=b.value.trim().toLowerCase();(m.startsWith("on")||(m==="href"||m==="src")&&p.startsWith("javascript:"))&&h.removeAttribute(b.name)}}),Array.from(u.body.childNodes)},i=n=>{!a.value||a.value.innerHTML===n||a.value.replaceChildren(...s(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 u;l.disabled||l.readonly||((u=a.value)==null||u.focus(),document.execCommand(n,!1),c())};return(n,u)=>(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",lc,[e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Bold","aria-label":"Bold",onMousedown:u[0]||(u[0]=e.withModifiers(h=>d("bold"),["prevent"]))},[...u[7]||(u[7]=[e.createElementVNode("strong",null,"B",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Italic","aria-label":"Italic",onMousedown:u[1]||(u[1]=e.withModifiers(h=>d("italic"),["prevent"]))},[...u[8]||(u[8]=[e.createElementVNode("em",null,"I",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Underline","aria-label":"Underline",onMousedown:u[2]||(u[2]=e.withModifiers(h=>d("underline"),["prevent"]))},[...u[9]||(u[9]=[e.createElementVNode("u",null,"U",-1)])],32),e.createElementVNode("button",{type:"button",class:"ed-btn mfs-text",title:"Strikethrough","aria-label":"Strikethrough",onMousedown:u[3]||(u[3]=e.withModifiers(h=>d("strikeThrough"),["prevent"]))},[...u[10]||(u[10]=[e.createElementVNode("s",null,"S",-1)])],32),u[11]||(u[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:u[4]||(u[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:u[5]||(u[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:u[6]||(u[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,oc)],2))}}),[["__scopeId","data-v-8aa9e8cf"]]),nc={class:"split-btn"},ac=["disabled"],sc=["disabled","aria-expanded"],rc=["disabled","onClick"],ic={key:0,class:"split-btn__icon"},Pt=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:r}){const l=r,o=e.ref(!1),a=e.ref(null),s=e.ref(null),{overlayStyle:i,containsTarget:c}=q(a,s,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)},u=h=>{h.key==="Escape"&&o.value&&(o.value=!1)};return e.onMounted(()=>{document.addEventListener("click",n),document.addEventListener("keydown",u)}),e.onBeforeUnmount(()=>{document.removeEventListener("click",n),document.removeEventListener("keydown",u)}),(h,b)=>(e.openBlock(),e.createElementBlock("div",nc,[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:b[0]||(b[0]=m=>l("click",m))},[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:b[1]||(b[1]=m=>o.value=!o.value)},[...b[2]||(b[2]=[e.createElementVNode("svg",{viewBox:"0 0 20 20",width:"16",height:"16",fill:"none","aria-hidden":"true"},[e.createElementVNode("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])],10,sc)],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:s,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,(m,p)=>(e.openBlock(),e.createElementBlock("li",{key:p,role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:"split-btn__item mfs-text",disabled:m.disabled,onClick:f=>d(m)},[m.icon?(e.openBlock(),e.createElementBlock("span",ic,e.toDisplayString(m.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(m.label),1)],8,rc)]))),128))],4)):e.createCommentVNode("",!0)]),_:1})]))]))}}),[["__scopeId","data-v-54cf96eb"]]),dc=["aria-expanded"],cc={key:0,class:"speed-dial__list",role:"menu"},mc=["title","aria-label","disabled","onClick"],fc={class:"speed-dial__icon"},Rt=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:r}){const l=t,o=r,a=e.ref(!1);e.watch(()=>l.modelValue,n=>{n!==void 0&&(a.value=n)});const s=e.computed(()=>l.modelValue!==void 0?l.modelValue:a.value),i=()=>{const n=!s.value;a.value=n,o("update:modelValue",n)},c=n=>{var u;n.disabled||((u=n.action)==null||u.call(n),o("select",n),a.value=!1,o("update:modelValue",!1))},d=n=>{if(l.type!=="radial"||!l.items.length)return;const u=l.items.length,h=l.direction==="up"?-90:l.direction==="down"?90:l.direction==="left"?180:0,b=120,m=u>1?b/(u-1):0,f=(h-b/2+n*m)*Math.PI/180,k=Math.round(Math.cos(f)*l.radius),y=Math.round(Math.sin(f)*l.radius);return{position:"absolute",transform:`translate(${k}px, ${y}px)`}};return(n,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["speed-dial",`speed-dial--${t.direction}`])},[e.createElementVNode("button",{type:"button",class:"speed-dial__fab mfs-bg-primary mfs-pill mfs-shadow mfs-interactive mfs-focus-ring","aria-expanded":s.value,"aria-label":"Toggle quick actions",onClick:i},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["speed-dial__plus",{"is-open":s.value}]),viewBox:"0 0 24 24",width:"22",height:"22",fill:"none","aria-hidden":"true"},[...u[0]||(u[0]=[e.createElementVNode("path",{d:"M12 5v14M5 12h14",stroke:"currentColor","stroke-width":"2.4","stroke-linecap":"round"},null,-1)])],2))],8,dc),s.value?(e.openBlock(),e.createElementBlock("ul",cc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,b)=>(e.openBlock(),e.createElementBlock("li",{key:b,class:"speed-dial__entry",style:e.normalizeStyle(d(b)),role:"none"},[e.createElementVNode("button",{type:"button",role:"menuitem",class:e.normalizeClass(["speed-dial__item","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:m=>c(h)},[e.renderSlot(n.$slots,"item",{item:h,index:b},()=>[e.createElementVNode("span",fc,e.toDisplayString(h.icon||h.label.slice(0,2)),1)],!0)],10,mc)],4))),128))])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-7be19b81"]]),pc={key:0,class:"panel__header"},uc={class:"panel__title mfs-title"},kc={class:"panel__actions"},hc=["aria-expanded"],gc={class:"panel__collapse"},yc={class:"panel__inner"},bc={class:"panel__body"},Bc={key:0,class:"panel__footer mfs-surface-subtle mfs-caption"},Ft=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:r}){const l=t,o=r,a=e.ref(!1);e.watch(()=>l.collapsed,c=>{c!==void 0&&(a.value=c)},{immediate:!0});const s=e.computed(()=>l.collapsed!==void 0?l.collapsed:a.value),i=()=>{const c=!s.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":s.value}])},[t.header||c.$slots.header||t.toggleable?(e.openBlock(),e.createElementBlock("header",pc,[e.createElementVNode("div",uc,[e.renderSlot(c.$slots,"header",{},()=>[e.createTextVNode(e.toDisplayString(t.header),1)],!0)]),e.createElementVNode("div",kc,[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":!s.value,"aria-label":"Toggle panel",onClick:i},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["panel__chevron",{"is-collapsed":s.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,hc)):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),e.createElementVNode("div",gc,[e.createElementVNode("div",yc,[e.createElementVNode("div",bc,[e.renderSlot(c.$slots,"default",{},void 0,!0)]),c.$slots.footer?(e.openBlock(),e.createElementBlock("footer",Bc,[e.renderSlot(c.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)])])],2))}}),[["__scopeId","data-v-0ea71fae"]]),_c={key:0,class:"fieldset__legend mfs-surface-subtle mfs-pill mfs-shadow mfs-title"},wc=["aria-expanded"],Ec={key:1,class:"fieldset__label mfs-text"},$c={class:"fieldset__collapse"},Vc={class:"fieldset__inner"},Cc={class:"fieldset__body"},At=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:r}){const l=t,o=r,a=e.ref(!1);e.watch(()=>l.collapsed,c=>{c!==void 0&&(a.value=c)},{immediate:!0});const s=e.computed(()=>l.collapsed!==void 0?l.collapsed:a.value),i=()=>{const c=!s.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",{"is-collapsed":s.value}])},[t.legend||c.$slots.legend?(e.openBlock(),e.createElementBlock("legend",_c,[t.toggleable?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"fieldset__btn mfs-text mfs-focus-ring","aria-expanded":!s.value,onClick:i},[(e.openBlock(),e.createElementBlock("svg",{class:e.normalizeClass(["fieldset__chevron",{"is-collapsed":s.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,wc)):(e.openBlock(),e.createElementBlock("span",Ec,[e.renderSlot(c.$slots,"legend",{},()=>[e.createTextVNode(e.toDisplayString(t.legend),1)],!0)]))])):e.createCommentVNode("",!0),e.createElementVNode("div",$c,[e.createElementVNode("div",Vc,[e.createElementVNode("div",Cc,[e.renderSlot(c.$slots,"default",{},void 0,!0)])])])],2))}}),[["__scopeId","data-v-448527f9"]]),xc=["aria-orientation","aria-valuenow","aria-valuemin","aria-valuemax"],Nc={class:"splitter__pane splitter__pane--second"},jt=D(e.defineComponent({__name:"Splitter",props:{layout:{default:"horizontal"},initialSize:{default:50},minSize:{default:15}},emits:["resize"],setup(t,{emit:r}){const l=t,o=r,a=p=>Math.max(l.minSize,Math.min(100-l.minSize,p)),s=e.ref(a(l.initialSize)),i=e.ref(!1),c=e.ref(null),d=e.computed(()=>({flexBasis:`${s.value}%`})),n=p=>{if(!c.value)return;const f=c.value.getBoundingClientRect(),k=l.layout==="horizontal"?(p.clientX-f.left)/f.width*100:(p.clientY-f.top)/f.height*100;s.value=a(k),o("resize",s.value)},u=p=>{i.value=!0,p.currentTarget.setPointerCapture(p.pointerId),n(p)},h=p=>{i.value&&n(p)},b=p=>{i.value&&(i.value=!1,p.currentTarget.hasPointerCapture(p.pointerId)&&p.currentTarget.releasePointerCapture(p.pointerId))},m=p=>{const k=l.layout==="horizontal"?"ArrowLeft":"ArrowUp",y=l.layout==="horizontal"?"ArrowRight":"ArrowDown";p.key===k?(p.preventDefault(),s.value=a(s.value-5),o("resize",s.value)):p.key===y&&(p.preventDefault(),s.value=a(s.value+5),o("resize",s.value))};return(p,f)=>(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(s.value),"aria-valuemin":t.minSize,"aria-valuemax":100-t.minSize,onPointerdown:u,onPointermove:h,onPointerup:b,onPointercancel:b,onKeydown:m},[...f[0]||(f[0]=[e.createElementVNode("span",{class:"splitter__handle mfs-pill"},null,-1)])],40,xc),e.createElementVNode("div",Nc,[e.renderSlot(p.$slots,"second",{},void 0,!0)])],2))}}),[["__scopeId","data-v-6fd2ec7c"]]),Sc={class:"toolbar mfs-surface mfs-rounded mfs-shadow-card",role:"toolbar"},Mc={key:0,class:"toolbar__group toolbar__group--start"},Dc={key:1,class:"toolbar__group toolbar__group--center"},zc={key:2,class:"toolbar__group toolbar__group--end"},Kt=D(e.defineComponent({__name:"Toolbar",setup(t){return(r,l)=>(e.openBlock(),e.createElementBlock("div",Sc,[r.$slots.start||r.$slots.default?(e.openBlock(),e.createElementBlock("div",Mc,[e.renderSlot(r.$slots,"start",{},()=>[e.renderSlot(r.$slots,"default",{},void 0,!0)],!0)])):e.createCommentVNode("",!0),r.$slots.center?(e.openBlock(),e.createElementBlock("div",Dc,[e.renderSlot(r.$slots,"center",{},void 0,!0)])):e.createCommentVNode("",!0),r.$slots.end?(e.openBlock(),e.createElementBlock("div",zc,[e.renderSlot(r.$slots,"end",{},void 0,!0)])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-cf5eff51"]]),Lc={class:"scroll-panel__content"},Ot=D(e.defineComponent({__name:"ScrollPanel",props:{maxHeight:{default:"300px"},width:{}},setup(t){const r=t,l=a=>a===void 0?void 0:typeof a=="number"?`${a}px`:a,o=e.computed(()=>({maxHeight:l(r.maxHeight),width:l(r.width)}));return(a,s)=>(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",Lc,[e.renderSlot(a.$slots,"default",{},void 0,!0)])],4))}}),[["__scopeId","data-v-78b33875"]]),Ut=D(e.defineComponent({__name:"Fluid",props:{tag:{default:"div"},padded:{type:Boolean,default:!1}},setup(t){return(r,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(r.$slots,"default",{},void 0,!0)]),_:3},8,["class"]))}}),[["__scopeId","data-v-94565fea"]]),$e=D(e.defineComponent({__name:"Deferred",props:{rootMargin:{default:"0px"},threshold:{default:0},once:{type:Boolean,default:!0}},emits:["load"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(!1),s=e.ref(null);let i=null;return e.onMounted(()=>{if(typeof IntersectionObserver>"u"||!s.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(s.value)}),e.onBeforeUnmount(()=>{i==null||i.disconnect(),i=null}),(c,d)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"targetRef",ref:s,class:"deferred"},[a.value?e.renderSlot(c.$slots,"default",{},void 0,!0,0):e.renderSlot(c.$slots,"placeholder",{},()=>[d[0]||(d[0]=e.createElementVNode("div",{class:"deferred__placeholder mfs-surface-subtle mfs-rounded mfs-caption"}," Loading... ",-1))],!0,1)],512))}}),[["__scopeId","data-v-799cd224"]]),Tc={class:"menu__list"},Ic={key:0,class:"menu__separator mfs-divider",role:"separator"},Pc={key:1,class:"menu__group",role:"presentation"},Rc={key:0,class:"menu__group-label mfs-text-muted"},Fc={class:"menu__sublist"},Ac=["disabled","onClick"],jc={key:0,class:"menu__icon","aria-hidden":"true"},Kc={class:"menu__label"},Oc={key:0,class:"menu__icon","aria-hidden":"true"},Uc={class:"menu__label"},Hc={key:2,role:"none"},Wc=["disabled","onClick"],Gc={key:0,class:"menu__icon","aria-hidden":"true"},qc={class:"menu__label"},Yc={key:0,class:"menu__icon","aria-hidden":"true"},Xc={class:"menu__label"},Zc={class:"menu__list"},Jc={key:0,class:"menu__separator mfs-divider",role:"separator"},Qc={key:1,class:"menu__group",role:"presentation"},vc={key:0,class:"menu__group-label mfs-text-muted"},em={class:"menu__sublist"},tm=["disabled","onClick"],lm={key:0,class:"menu__icon","aria-hidden":"true"},om={class:"menu__label"},nm={key:0,class:"menu__icon","aria-hidden":"true"},am={class:"menu__label"},sm={key:2,role:"none"},rm=["disabled","onClick"],im={key:0,class:"menu__icon","aria-hidden":"true"},dm={class:"menu__label"},cm={key:0,class:"menu__icon","aria-hidden":"true"},mm={class:"menu__label"},Ht=D(e.defineComponent({__name:"Menu",props:{items:{},popup:{type:Boolean,default:!1}},emits:["select"],setup(t,{expose:r,emit:l}){const o=t,a=l,s=e.ref(!1),i=e.ref(null),c=e.ref({x:0,y:0}),d=()=>{s.value=!1,f()},n=async k=>{if(!o.popup)return;s.value=!0;const y=k.currentTarget,g=y==null?void 0:y.getBoundingClientRect();if(c.value=g?{x:g.left,y:g.bottom+6}:{x:k.clientX,y:k.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()},u=k=>{s.value?d():n(k)},h=k=>{var y;k.disabled||((y=k.command)==null||y.call(k),a("select",k),o.popup&&d())},b=k=>{k.key==="Escape"&&o.popup&&d()},m=k=>{i.value&&!i.value.contains(k.target)&&d()},p=()=>{window.addEventListener("pointerdown",m),window.addEventListener("resize",d)},f=()=>{window.removeEventListener("pointerdown",m),window.removeEventListener("resize",d)};return e.onUnmounted(f),r({open:n,close:d,toggle:u}),(k,y)=>t.popup?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:"body"},[e.createVNode(e.Transition,{name:"menu-pop"},{default:e.withCtx(()=>[s.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:b},[e.createElementVNode("ul",Tc,[(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",Ic)):(w=g.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("li",Pc,[g.label?(e.openBlock(),e.createElementBlock("div",Rc,e.toDisplayString(g.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",Fc,[(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(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",jc,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Kc,e.toDisplayString(_.label),1)],!0)],10,Ac)):(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(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",Oc,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Uc,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",Hc,[!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(k.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",Gc,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",qc,e.toDisplayString(g.label),1)],!0)],10,Wc)):(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(k.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",Yc,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Xc,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:b},[e.createElementVNode("ul",Zc,[(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",Jc)):(w=g.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("li",Qc,[g.label?(e.openBlock(),e.createElementBlock("div",vc,e.toDisplayString(g.label),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",em,[(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(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",lm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",om,e.toDisplayString(_.label),1)],!0)],10,tm)):(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(k.$slots,"item",{item:_},()=>[_.icon?(e.openBlock(),e.createElementBlock("span",nm,e.toDisplayString(_.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",am,e.toDisplayString(_.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])])):(e.openBlock(),e.createElementBlock("li",sm,[!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(k.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",im,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",dm,e.toDisplayString(g.label),1)],!0)],10,rm)):(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(k.$slots,"item",{item:g},()=>[g.icon?(e.openBlock(),e.createElementBlock("span",cm,e.toDisplayString(g.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",mm,e.toDisplayString(g.label),1)],!0)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64)}),128))])],32))}}),[["__scopeId","data-v-b6f0d9c8"]]),fm={class:"tiered-menu mfs-surface mfs-rounded-md mfs-blur","aria-label":"Tiered menu"},pm={class:"tiered-menu__list",role:"menubar"},um={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},km=["onMouseenter"],hm=["aria-haspopup","aria-expanded","disabled","onClick"],gm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},ym={class:"tiered-menu__label"},bm={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"},Bm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},_m={class:"tiered-menu__label"},wm={key:2,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu"},Em={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},$m=["onMouseenter"],Vm=["aria-haspopup","aria-expanded","disabled","onClick"],Cm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},xm={class:"tiered-menu__label"},Nm={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"},Sm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Mm={class:"tiered-menu__label"},Dm={key:2,class:"tiered-menu__submenu mfs-surface mfs-overlay mfs-shadow-card mfs-rounded-md mfs-blur",role:"menu"},zm={key:0,class:"tiered-menu__separator mfs-divider",role:"separator"},Lm={key:1,role:"none"},Tm=["disabled","onClick"],Im={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Pm={class:"tiered-menu__label"},Rm={key:0,class:"tiered-menu__icon","aria-hidden":"true"},Fm={class:"tiered-menu__label"},Wt=D(e.defineComponent({__name:"TieredMenu",props:{items:{}},emits:["select"],setup(t,{emit:r}){const l=r,o=e.ref(null),a=e.ref(null),s=(i,c,d)=>{var n,u;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}(u=i.command)==null||u.call(i),l("select",i),o.value=null,a.value=null}};return(i,c)=>(e.openBlock(),e.createElementBlock("nav",fm,[e.createElementVNode("ul",pm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(d,n)=>{var u,h,b,m,p;return e.openBlock(),e.createElementBlock(e.Fragment,{key:n},[d.separator?(e.openBlock(),e.createElementBlock("li",um)):(e.openBlock(),e.createElementBlock("li",{key:1,class:"tiered-menu__node",role:"none",onMouseenter:f=>o.value=n,onMouseleave:c[1]||(c[1]=f=>{o.value=null,a.value=null})},[(u=d.items)!=null&&u.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":(b=d.items)!=null&&b.length?o.value===n:void 0,disabled:d.disabled,onClick:f=>s(d,1,n)},[d.icon?(e.openBlock(),e.createElementBlock("span",gm,e.toDisplayString(d.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",ym,e.toDisplayString(d.label),1),(m=d.items)!=null&&m.length?(e.openBlock(),e.createElementBlock("svg",bm,[...c[2]||(c[2]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,hm)):(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:f=>s(d,1,n)},{default:e.withCtx(()=>[d.icon?(e.openBlock(),e.createElementBlock("span",Bm,e.toDisplayString(d.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",_m,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",wm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.items,(f,k)=>{var y,g,B,w,_;return e.openBlock(),e.createElementBlock(e.Fragment,{key:k},[f.separator?(e.openBlock(),e.createElementBlock("li",Em)):(e.openBlock(),e.createElementBlock("li",{key:1,class:"tiered-menu__node",role:"none",onMouseenter:$=>a.value=k,onMouseleave:c[0]||(c[0]=$=>a.value=null)},[(y=f.items)!=null&&y.length||!f.to&&!f.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===k,"tiered-menu__item--disabled mfs-disabled":f.disabled}]),"aria-haspopup":(g=f.items)!=null&&g.length?"true":void 0,"aria-expanded":(B=f.items)!=null&&B.length?a.value===k:void 0,disabled:f.disabled,onClick:$=>s(f,2,k)},[f.icon?(e.openBlock(),e.createElementBlock("span",Cm,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",xm,e.toDisplayString(f.label),1),(w=f.items)!=null&&w.length?(e.openBlock(),e.createElementBlock("svg",Nm,[...c[3]||(c[3]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Vm)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(f.to?"router-link":"a"),{key:1,to:f.to,href:f.href,role:"menuitem",class:e.normalizeClass(["tiered-menu__item mfs-rounded-sm mfs-text mfs-focus-ring",{"tiered-menu__item--active":a.value===k,"tiered-menu__item--disabled mfs-disabled":f.disabled}]),disabled:f.disabled,onClick:$=>s(f,2,k)},{default:e.withCtx(()=>[f.icon?(e.openBlock(),e.createElementBlock("span",Sm,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Mm,e.toDisplayString(f.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),(_=f.items)!=null&&_.length&&a.value===k?(e.openBlock(),e.createElementBlock("ul",Dm,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.items,($,V)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:V},[$.separator?(e.openBlock(),e.createElementBlock("li",zm)):(e.openBlock(),e.createElementBlock("li",Lm,[!$.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=>s($,3,V)},[$.icon?(e.openBlock(),e.createElementBlock("span",Im,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Pm,e.toDisplayString($.label),1)],10,Tm)):(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=>s($,3,V)},{default:e.withCtx(()=>[$.icon?(e.openBlock(),e.createElementBlock("span",Rm,e.toDisplayString($.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Fm,e.toDisplayString($.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))],64))),128))])):e.createCommentVNode("",!0)],40,$m))],64)}),128))])):e.createCommentVNode("",!0)],40,km))],64)}),128))])]))}}),[["__scopeId","data-v-b9d2bab9"]]),Am={key:0,class:"slide-menu__header"},jm={class:"slide-menu__title mfs-title"},Km={class:"slide-menu__viewport"},Om=["disabled","onClick"],Um={key:0,class:"slide-menu__icon","aria-hidden":"true"},Hm={class:"slide-menu__label"},Wm={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"},Gm={key:0,class:"slide-menu__icon","aria-hidden":"true"},qm={class:"slide-menu__label"},Gt=D(e.defineComponent({__name:"SlideMenu",props:{items:{},backLabel:{default:"Back"},menuWidth:{default:"260px"}},emits:["select"],setup(t,{emit:r}){const l=t,o=r,a=e.ref([]),s=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=u=>{var h,b;if(!u.disabled){if((h=u.items)!=null&&h.length){s.value="forward",a.value.push({title:u.label,items:u.items});return}(b=u.command)==null||b.call(u),o("select",u)}},n=()=>{a.value.length&&(s.value="back",a.value.pop())};return(u,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",Am,[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",jm,e.toDisplayString(c.value),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",Km,[e.createVNode(e.Transition,{name:s.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,(b,m)=>{var p,f;return e.openBlock(),e.createElementBlock("li",{key:m,role:"none"},[(p=b.items)!=null&&p.length||!b.to&&!b.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:k=>d(b)},[b.icon?(e.openBlock(),e.createElementBlock("span",Um,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Hm,e.toDisplayString(b.label),1),(f=b.items)!=null&&f.length?(e.openBlock(),e.createElementBlock("svg",Wm,[...h[1]||(h[1]=[e.createElementVNode("polyline",{points:"9 18 15 12 9 6"},null,-1)])])):e.createCommentVNode("",!0)],10,Om)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(b.to?"router-link":"a"),{key:1,to:b.to,href:b.href,role:"menuitem",class:e.normalizeClass(["slide-menu__item mfs-rounded-sm mfs-text",{"slide-menu__item--disabled mfs-disabled":b.disabled}]),disabled:b.disabled,onClick:k=>d(b)},{default:e.withCtx(()=>[b.icon?(e.openBlock(),e.createElementBlock("span",Gm,e.toDisplayString(b.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",qm,e.toDisplayString(b.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))])}),128))]))]),_:1},8,["name"])])],4))}}),[["__scopeId","data-v-0c085066"]]),Ym={class:"panel-menu","aria-label":"Panel navigation"},Xm=["aria-expanded","disabled","onClick"],Zm={key:0,class:"panel-menu__icon","aria-hidden":"true"},Jm={class:"panel-menu__label"},Qm={key:0,class:"panel-menu__icon","aria-hidden":"true"},vm={class:"panel-menu__label"},ef={key:0,class:"panel-menu__list"},tf=["disabled","onClick"],lf={key:0,class:"panel-menu__icon","aria-hidden":"true"},of={key:0,class:"panel-menu__icon","aria-hidden":"true"},qt=D(e.defineComponent({__name:"PanelMenu",props:{items:{},multiple:{type:Boolean,default:!0},expandedKeys:{}},emits:["update:expandedKeys","select"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(l.expandedKeys??[]);e.watch(()=>l.expandedKeys,n=>{n!==void 0&&(a.value=[...n])});const s=(n,u)=>n.key??`${u}-${n.label}`,i=n=>a.value.includes(n),c=(n,u)=>{var h,b;if(!n.disabled){if((h=n.items)!=null&&h.length){const m=s(n,u);let p;i(m)?p=a.value.filter(f=>f!==m):p=l.multiple?[...a.value,m]:[m],a.value=p,o("update:expandedKeys",p);return}(b=n.command)==null||b.call(n),o("select",n)}},d=n=>{var u;n.disabled||((u=n.command)==null||u.call(n),o("select",n))};return(n,u)=>(e.openBlock(),e.createElementBlock("nav",Ym,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(h,b)=>{var m,p,f;return e.openBlock(),e.createElementBlock("div",{key:s(h,b),class:"panel-menu__panel mfs-surface mfs-rounded-md mfs-blur"},[(m=h.items)!=null&&m.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(s(h,b)):void 0,disabled:h.disabled,onClick:k=>c(h,b)},[h.icon?(e.openBlock(),e.createElementBlock("span",Zm,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",Jm,e.toDisplayString(h.label),1),(f=h.items)!=null&&f.length?(e.openBlock(),e.createElementBlock("svg",{key:1,class:e.normalizeClass(["panel-menu__chevron",{"panel-menu__chevron--open":i(s(h,b))}]),width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":"true"},[...u[0]||(u[0]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])],2)):e.createCommentVNode("",!0)],10,Xm)):(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:k=>c(h,b)},{default:e.withCtx(()=>[h.icon?(e.openBlock(),e.createElementBlock("span",Qm,e.toDisplayString(h.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",vm,e.toDisplayString(h.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"panel-collapse"},{default:e.withCtx(()=>{var k;return[(k=h.items)!=null&&k.length&&i(s(h,b))?(e.openBlock(),e.createElementBlock("ul",ef,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.items,(y,g)=>(e.openBlock(),e.createElementBlock("li",{key:g},[!y.to&&!y.href?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:B=>d(y)},[y.icon?(e.openBlock(),e.createElementBlock("span",lf,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(y.label),1)],10,tf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(y.to?"router-link":"a"),{key:1,to:y.to,href:y.href,class:e.normalizeClass(["panel-menu__subitem mfs-rounded-sm mfs-text",{"panel-menu__subitem--disabled mfs-disabled":y.disabled}]),disabled:y.disabled,onClick:B=>d(y)},{default:e.withCtx(()=>[y.icon?(e.openBlock(),e.createElementBlock("span",of,e.toDisplayString(y.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(y.label),1)]),_:2},1032,["to","href","class","disabled","onClick"]))]))),128))])):e.createCommentVNode("",!0)]}),_:2},1024)])}),128))]))}}),[["__scopeId","data-v-80eb0ae4"]]),nf={class:"mega-menu__bar mfs-flex mfs-flex-col mfs-gap-2"},af=["aria-expanded"],sf={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"},rf={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"},df=["onMouseenter"],cf=["aria-haspopup","aria-expanded","disabled","onClick"],mf={key:0,"aria-hidden":"true"},ff={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"},pf={key:0,"aria-hidden":"true"},uf={key:0,class:"mega-menu__panel mfs-card mfs-overlay mfs-blur mfs-p-4",role:"menu"},kf={class:"mega-menu__columns"},hf={key:0,class:"mega-menu__col-title mfs-text-muted mfs-font-bold mfs-mb-2 mfs-px-2"},gf={class:"mega-menu__col-list mfs-flex mfs-flex-col mfs-gap-1"},yf=["onClick"],bf={class:"mega-menu__link-label mfs-font-semibold"},Bf={key:0,class:"mega-menu__link-desc mfs-text-muted"},_f={class:"mega-menu__link-label mfs-font-semibold"},wf={key:0,class:"mega-menu__link-desc mfs-text-muted"},Yt=D(e.defineComponent({__name:"MegaMenu",props:{items:{},orientation:{default:"horizontal"}},emits:["select"],setup(t,{emit:r}){const l=r,o=e.ref(null),a=e.ref(null),s=e.ref(!1),i=()=>typeof window<"u"&&window.innerWidth<768,c=m=>{i()||(a.value=m)},d=()=>{i()||(a.value=null)},n=(m,p)=>{var f,k;if(!m.disabled){if((f=m.columns)!=null&&f.length){a.value=a.value===p?null:p;return}(k=m.command)==null||k.call(m),l("select",m),a.value=null,s.value=!1}},u=m=>{var p;(p=m.command)==null||p.call(m),l("select",m),a.value=null,s.value=!1},h=m=>{o.value&&!o.value.contains(m.target)&&(a.value=null)},b=m=>{m.key==="Escape"&&(a.value=null,s.value=!1)};return e.onMounted(()=>{window.addEventListener("pointerdown",h),window.addEventListener("keydown",b)}),e.onUnmounted(()=>{window.removeEventListener("pointerdown",h),window.removeEventListener("keydown",b)}),(m,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",nf,[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":s.value,"aria-label":"Toggle mega menu",onClick:p[0]||(p[0]=f=>s.value=!s.value)},[s.value?(e.openBlock(),e.createElementBlock("svg",rf,[...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",sf,[...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":s.value}]),role:"menubar"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(f,k)=>{var y,g,B,w;return e.openBlock(),e.createElementBlock("li",{key:k,class:"mega-menu__root mfs-relative",role:"none",onMouseenter:_=>c(k),onMouseleave:d},[(y=f.columns)!=null&&y.length||!f.to&&!f.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===k,"mega-menu__trigger--disabled mfs-disabled":f.disabled}]),"aria-haspopup":(g=f.columns)!=null&&g.length?"true":void 0,"aria-expanded":(B=f.columns)!=null&&B.length?a.value===k:void 0,disabled:f.disabled,onClick:_=>n(f,k)},[f.icon?(e.openBlock(),e.createElementBlock("span",mf,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(f.label),1),(w=f.columns)!=null&&w.length?(e.openBlock(),e.createElementBlock("svg",ff,[...p[4]||(p[4]=[e.createElementVNode("polyline",{points:"6 9 12 15 18 9"},null,-1)])])):e.createCommentVNode("",!0)],10,cf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(f.to?"router-link":"a"),{key:1,to:f.to,href:f.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===k,"mega-menu__trigger--disabled mfs-disabled":f.disabled}]),disabled:f.disabled,onClick:_=>n(f,k)},{default:e.withCtx(()=>[f.icon?(e.openBlock(),e.createElementBlock("span",pf,e.toDisplayString(f.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(f.label),1)]),_:2},1032,["to","href","class","disabled","onClick"])),e.createVNode(e.Transition,{name:"mega-fade"},{default:e.withCtx(()=>{var _;return[(_=f.columns)!=null&&_.length&&a.value===k?(e.openBlock(),e.createElementBlock("div",uf,[e.createElementVNode("div",kf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.columns,($,V)=>(e.openBlock(),e.createElementBlock("div",{key:V,class:"mega-menu__col"},[$.title?(e.openBlock(),e.createElementBlock("div",hf,e.toDisplayString($.title),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",gf,[(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=>u(E)},[e.createElementVNode("span",bf,e.toDisplayString(E.label),1),E.description?(e.openBlock(),e.createElementBlock("span",Bf,e.toDisplayString(E.description),1)):e.createCommentVNode("",!0)],8,yf)):(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=>u(E)},{default:e.withCtx(()=>[e.createElementVNode("span",_f,e.toDisplayString(E.label),1),E.description?(e.openBlock(),e.createElementBlock("span",wf,e.toDisplayString(E.description),1)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","onClick"]))]))),128))])]))),128))])])):e.createCommentVNode("",!0)]}),_:2},1024)],40,df)}),128))],2)])],2))}}),[["__scopeId","data-v-c1804bd7"]]),Ef={class:"dock__list mfs-surface mfs-shadow-card mfs-pill mfs-blur",role:"menubar"},$f=["onMouseenter"],Vf=["aria-label","disabled","onClick"],Cf={class:"dock__glyph mfs-text"},xf={key:0,class:"dock__dot","aria-hidden":"true"},Nf={class:"dock__glyph mfs-text"},Sf={key:0,class:"dock__dot","aria-hidden":"true"},Mf={class:"dock__tooltip mfs-surface mfs-shadow mfs-rounded-sm mfs-text",role:"tooltip"},Xt=D(e.defineComponent({__name:"Dock",props:{items:{},position:{default:"bottom"},magnification:{type:Boolean,default:!0}},emits:["select"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(null),s=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",Ef,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.items,(n,u)=>(e.openBlock(),e.createElementBlock("li",{key:u,class:"dock__item-wrap",role:"none",onMouseenter:h=>a.value=u},[!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(s(u)),"aria-label":n.label,disabled:n.disabled,onClick:h=>i(n,u)},[e.renderSlot(c.$slots,"item",{item:n,index:u,active:!!n.active},()=>[e.createElementVNode("span",Cf,e.toDisplayString(n.icon??n.label.slice(0,2).toUpperCase()),1)],!0),n.active?(e.openBlock(),e.createElementBlock("span",xf)):e.createCommentVNode("",!0)],14,Vf)):(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(s(u)),"aria-label":n.label,disabled:n.disabled,onClick:h=>i(n,u)},{default:e.withCtx(()=>[e.renderSlot(c.$slots,"item",{item:n,index:u,active:!!n.active},()=>[e.createElementVNode("span",Nf,e.toDisplayString(n.icon??n.label.slice(0,2).toUpperCase()),1)],!0),n.active?(e.openBlock(),e.createElementBlock("span",Sf)):e.createCommentVNode("",!0)]),_:2},1032,["to","href","class","style","aria-label","disabled","onClick"])),e.createElementVNode("span",Mf,e.toDisplayString(n.label),1)],40,$f))),128))])],34))}}),[["__scopeId","data-v-f3aec655"]]),Df={class:"tab-menu","aria-label":"Tab navigation"},zf=["aria-selected","aria-disabled","tabindex","onClick"],Lf={key:0,class:"tab-menu__icon","aria-hidden":"true"},Tf={key:0,class:"tab-menu__icon","aria-hidden":"true"},Zt=D(e.defineComponent({__name:"TabMenu",props:{items:{},modelValue:{default:0},scrollable:{type:Boolean,default:!0}},emits:["update:modelValue","change"],setup(t,{emit:r}){const l=t,o=r,a=e.ref(null),s=new Map,i=e.ref({left:0,width:0,ready:!1}),c=(p,f)=>{const k=(f==null?void 0:f.$el)??f;k instanceof HTMLElement?s.set(p,k):s.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 f=s.get(l.modelValue);if(!f){i.value={left:0,width:0,ready:!1};return}i.value={left:f.offsetLeft,width:f.offsetWidth,ready:!0},p&&l.scrollable&&f.scrollIntoView({behavior:"smooth",block:"nearest",inline:"center"})},u=(p,f,k)=>{var y;if(p.disabled){k.preventDefault();return}(y=p.command)==null||y.call(p),f!==l.modelValue&&(o("update:modelValue",f),o("change",{index:f,item:p}))},h=p=>{var g;const f=l.items.map((B,w)=>B.disabled?-1:w).filter(B=>B>=0);if(!f.length)return;const k=f.indexOf(l.modelValue);let y=-1;if(p.key==="ArrowRight"?y=f[(k+1)%f.length]:p.key==="ArrowLeft"?y=f[(k-1+f.length)%f.length]:p.key==="Home"?y=f[0]:p.key==="End"&&(y=f[f.length-1]),y>=0){p.preventDefault();const B=l.items[y];o("update:modelValue",y),o("change",{index:y,item:B}),(g=s.get(y))==null||g.focus()}},b=()=>n(!1);let m=null;return e.watch(()=>[l.modelValue,l.items],()=>n(!0),{deep:!0}),e.onMounted(()=>{n(!1),typeof ResizeObserver<"u"&&a.value&&(m=new ResizeObserver(b),m.observe(a.value)),window.addEventListener("resize",b)}),e.onUnmounted(()=>{m==null||m.disconnect(),window.removeEventListener("resize",b)}),(p,f)=>(e.openBlock(),e.createElementBlock("nav",Df,[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,(k,y)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:k.key??y},[!k.to&&!k.href?(e.openBlock(),e.createElementBlock("button",{key:0,ref_for:!0,ref:g=>c(y,g),type:"button",role:"tab",class:e.normalizeClass(["tab-menu__item mfs-rounded-sm mfs-text",{"tab-menu__item--active":y===t.modelValue,"tab-menu__item--disabled mfs-disabled":k.disabled}]),"aria-selected":y===t.modelValue,"aria-disabled":k.disabled||void 0,tabindex:y===t.modelValue?0:-1,onClick:g=>u(k,y,g)},[k.icon?(e.openBlock(),e.createElementBlock("span",Lf,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(k.label),1)],10,zf)):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(k.to?"router-link":"a"),{key:1,ref_for:!0,ref:g=>c(y,g),to:k.to,href:k.href,role:"tab",class:e.normalizeClass(["tab-menu__item mfs-rounded-sm mfs-text",{"tab-menu__item--active":y===t.modelValue,"tab-menu__item--disabled mfs-disabled":k.disabled}]),"aria-selected":y===t.modelValue,"aria-disabled":k.disabled||void 0,tabindex:y===t.modelValue?0:-1,onClick:g=>u(k,y,g)},{default:e.withCtx(()=>[k.icon?(e.openBlock(),e.createElementBlock("span",Tf,e.toDisplayString(k.icon),1)):e.createCommentVNode("",!0),e.createElementVNode("span",null,e.toDisplayString(k.label),1)]),_:2},1032,["to","href","class","aria-selected","aria-disabled","tabindex","onClick"]))],64))),128))],34)]))}}),[["__scopeId","data-v-8e6dcb53"]]),If={class:"order-list mfs-surface mfs-rounded mfs-shadow-card"},Pf={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Rf={key:1,class:"order-list__header"},Ff={class:"order-list__title mfs-title"},Af={class:"order-list__body"},jf={class:"order-list__controls",role:"group","aria-label":"Reorder controls"},Kf=["disabled"],Of=["disabled"],Uf=["disabled"],Hf=["disabled"],Wf={class:"order-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Orderable items"},Gf={key:0,class:"mfs-empty-state"},qf=["aria-selected","onClick","onKeydown"],Yf={class:"mfs-text"},Jt=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:r}){const l=t,o=r,a=e.ref(null),s=e.computed(()=>a.value!==null&&a.value>0),i=e.computed(()=>a.value!==null&&a.value<l.modelValue.length-1);function c(b,m){a.value=m,o("update:modelValue",b),o("reorder",b)}function d(){if(!s.value||a.value===null)return;const b=a.value,m=[...l.modelValue];[m[b-1],m[b]]=[m[b],m[b-1]],c(m,b-1)}function n(){if(!i.value||a.value===null)return;const b=a.value,m=[...l.modelValue];[m[b+1],m[b]]=[m[b],m[b+1]],c(m,b+1)}function u(){if(!s.value||a.value===null)return;const b=a.value,m=[...l.modelValue],[p]=m.splice(b,1);m.unshift(p),c(m,0)}function h(){if(!i.value||a.value===null)return;const b=a.value,m=[...l.modelValue],[p]=m.splice(b,1);m.push(p),c(m,m.length-1)}return(b,m)=>(e.openBlock(),e.createElementBlock("div",If,[t.loading?(e.openBlock(),e.createElementBlock("div",Pf,[e.renderSlot(b.$slots,"loading",{},()=>[m[0]||(m[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),t.header||b.$slots.header?(e.openBlock(),e.createElementBlock("div",Rf,[e.renderSlot(b.$slots,"header",{},()=>[e.createElementVNode("span",Ff,e.toDisplayString(t.header),1)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Af,[e.createElementVNode("div",jf,[e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!s.value,"aria-label":"Move to top",onClick:u},[...m[1]||(m[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,Kf),e.createElementVNode("button",{type:"button",class:"order-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:!s.value,"aria-label":"Move up",onClick:d},[...m[2]||(m[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,Of),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},[...m[3]||(m[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,Uf),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},[...m[4]||(m[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,Hf)]),e.createElementVNode("ul",Wf,[!t.loading&&t.modelValue.length===0?(e.openBlock(),e.createElementBlock("li",Gf,[e.renderSlot(b.$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,f)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(re)(p,f,t.itemKey),class:e.normalizeClass(["order-list__item mfs-rounded-sm",{"order-list__item--selected":a.value===f}]),role:"option","aria-selected":a.value===f,tabindex:"0",onClick:k=>a.value=f,onKeydown:[e.withKeys(e.withModifiers(k=>a.value=f,["prevent"]),["enter"]),e.withKeys(e.withModifiers(k=>a.value=f,["prevent"]),["space"])]},[e.renderSlot(b.$slots,"item",{item:p,index:f,selected:a.value===f},()=>[e.createElementVNode("span",Yf,e.toDisplayString(p),1)],!0)],42,qf))),128))])])]))}}),[["__scopeId","data-v-8ff7425c"]]),Xf={class:"pick-list"},Zf={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Jf={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},Qf={key:0,class:"pick-list__header mfs-text"},vf={class:"pick-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Source items"},ep={key:0,class:"mfs-empty-state"},tp=["aria-selected","onClick","onKeydown"],lp={class:"mfs-text"},op={class:"pick-list__controls",role:"group","aria-label":"Transfer controls"},np=["disabled"],ap=["disabled"],sp=["disabled"],rp=["disabled"],ip={class:"pick-list__panel mfs-surface mfs-rounded mfs-shadow-card"},dp={key:0,class:"pick-list__header mfs-text"},cp={class:"pick-list__list mfs-inset mfs-rounded-md",role:"listbox","aria-label":"Target items"},mp={key:0,class:"mfs-empty-state"},fp=["aria-selected","onClick","onKeydown"],pp={class:"mfs-text"},Qt=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:r}){const l=t,o=r,a=e.ref([]),s=e.ref([]);function i(m,p){return(m==="source"?a.value:s.value).includes(p)}function c(m,p){const f=m==="source"?a:s,k=f.value.indexOf(p);k>=0?f.value.splice(k,1):f.value.push(p)}function d(m,p){a.value=[],s.value=[],o("update:source",m),o("update:target",p),o("transfer",{source:m,target:p})}function n(){const m=new Set(a.value),p=l.source.filter((k,y)=>m.has(y)),f=l.source.filter((k,y)=>!m.has(y));d(f,[...l.target,...p])}function u(){d([],[...l.target,...l.source])}function h(){const m=new Set(s.value),p=l.target.filter((k,y)=>m.has(y)),f=l.target.filter((k,y)=>!m.has(y));d([...l.source,...p],f)}function b(){d([...l.source,...l.target],[])}return(m,p)=>(e.openBlock(),e.createElementBlock("div",Xf,[t.loading?(e.openBlock(),e.createElementBlock("div",Zf,[e.renderSlot(m.$slots,"loading",{},()=>[p[0]||(p[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",Jf,[t.sourceHeader?(e.openBlock(),e.createElementBlock("div",Qf,e.toDisplayString(t.sourceHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",vf,[!t.loading&&t.source.length===0?(e.openBlock(),e.createElementBlock("li",ep,[e.renderSlot(m.$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,(f,k)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(re)(f,k,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":i("source",k)}]),role:"option","aria-selected":i("source",k),tabindex:"0",onClick:y=>c("source",k),onKeydown:[e.withKeys(e.withModifiers(y=>c("source",k),["prevent"]),["enter"]),e.withKeys(e.withModifiers(y=>c("source",k),["prevent"]),["space"])]},[e.renderSlot(m.$slots,"item",{item:f,index:k,list:"source"},()=>[e.createElementVNode("span",lp,e.toDisplayString(f),1)],!0)],42,tp))),128))])]),e.createElementVNode("div",op,[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:u},[...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,ap),e.createElementVNode("button",{type:"button",class:"pick-list__btn mfs-surface-subtle mfs-rounded-sm mfs-interactive",disabled:s.value.length===0,"aria-label":"Move selected to 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,sp),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:b},[...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,rp)]),e.createElementVNode("div",ip,[t.targetHeader?(e.openBlock(),e.createElementBlock("div",dp,e.toDisplayString(t.targetHeader),1)):e.createCommentVNode("",!0),e.createElementVNode("ul",cp,[!t.loading&&t.target.length===0?(e.openBlock(),e.createElementBlock("li",mp,[e.renderSlot(m.$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,(f,k)=>(e.openBlock(),e.createElementBlock("li",{key:e.unref(re)(f,k,t.itemKey),class:e.normalizeClass(["pick-list__item mfs-rounded-sm",{"pick-list__item--selected":i("target",k)}]),role:"option","aria-selected":i("target",k),tabindex:"0",onClick:y=>c("target",k),onKeydown:[e.withKeys(e.withModifiers(y=>c("target",k),["prevent"]),["enter"]),e.withKeys(e.withModifiers(y=>c("target",k),["prevent"]),["space"])]},[e.renderSlot(m.$slots,"item",{item:f,index:k,list:"target"},()=>[e.createElementVNode("span",pp,e.toDisplayString(f),1)],!0)],42,fp))),128))])])]))}}),[["__scopeId","data-v-a25b1467"]]),up={class:"tree-table mfs-relative mfs-surface mfs-rounded mfs-shadow-card"},kp={class:"tree-table__wrap"},hp={class:"tree-table__table"},gp={key:0},yp=["colspan"],bp=["aria-expanded","aria-label","onClick"],Bp={key:1,class:"tree-table__spacer","aria-hidden":"true"},_p={key:0,class:"mfs-loading-overlay","aria-busy":"true"},vt=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:r}){const l=t,o=r,a=e.ref([...l.expandedKeys]);e.watch(()=>l.expandedKeys,c=>{a.value=[...c]});const s=e.computed(()=>{const c=[],d=new Set(a.value);function n(u,h){for(const b of u){const m=Array.isArray(b.children)&&b.children.length>0||l.lazy&&b.leaf!==!0,p=m&&d.has(b.key);c.push({node:b,depth:h,hasChildren:m,expanded:p}),p&&b.children&&n(b.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 u=Array.from(d);a.value=u,o("update:expandedKeys",u),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",up,[e.createElementVNode("div",kp,[e.createElementVNode("table",hp,[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,[s.value.length===0?(e.openBlock(),e.createElementBlock("tr",gp,[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,yp)])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(s.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,(u,h)=>(e.openBlock(),e.createElementBlock("td",{key:u.key,class:e.normalizeClass(["tree-table__td mfs-text",u.align?`tree-table__cell--${u.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:b=>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,bp)):(e.openBlock(),e.createElementBlock("span",Bp)),e.renderSlot(c.$slots,`cell-${u.key}`,{node:n.node,value:n.node.data[u.key],depth:n.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(n.node.data[u.key]??""),1)],!0)],4)):e.renderSlot(c.$slots,`cell-${u.key}`,{node:n.node,value:n.node.data[u.key],depth:n.depth},()=>[e.createElementVNode("span",null,e.toDisplayString(n.node.data[u.key]??""),1)],!0,1)],2))),128))]))),128))])])]),t.loading?(e.openBlock(),e.createElementBlock("div",_p,[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"]]),wp=["aria-busy"],Ep={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},$p={key:1,class:"mfs-empty-state"},Vp={class:"org-chart__node-wrap"},Cp={class:"org-chart__label mfs-title"},xp={key:0,class:"org-chart__title mfs-caption"},Np=["aria-expanded","aria-label"],Sp={key:0,class:"org-chart__children"},el=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:r}){const l=t,o=r,a=e.ref(!0),s=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||!s.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 u=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",Ep,[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",$p,[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",Vp,[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",Cp,e.toDisplayString(t.value.label),1),t.value.title?(e.openBlock(),e.createElementBlock("div",xp,e.toDisplayString(t.value.title),1)):e.createCommentVNode("",!0)],!0)],32),t.collapsible&&s.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,Np)):e.createCommentVNode("",!0)]),s.value&&i.value?(e.openBlock(),e.createElementBlock("div",Sp,[(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(u,{value:h,collapsible:t.collapsible,"expanded-keys":t.expandedKeys,level:t.level+1,"onUpdate:expandedKeys":n[2]||(n[2]=b=>d.$emit("update:expandedKeys",b)),onNodeClick:n[3]||(n[3]=b=>d.$emit("node-click",b))},e.createSlots({_:2},[d.$slots.node?{name:"node",fn:e.withCtx(b=>[e.renderSlot(d.$slots,"node",e.mergeProps({ref_for:!0},b),void 0,!0)]),key:"0"}:void 0]),1032,["value","collapsible","expanded-keys","level"])]))),128))])):e.createCommentVNode("",!0)],64)):e.createCommentVNode("",!0)],10,wp)}}}),[["__scopeId","data-v-426d2664"]]),Mp={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Dp={key:1,class:"mfs-empty-state"},zp={class:"mfs-text"},tl=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(0),i=e.ref(300);e.onMounted(()=>{a.value&&(i.value=a.value.clientHeight||300)});function c(){a.value&&(s.value=a.value.scrollTop,i.value=a.value.clientHeight||i.value,l.lazy&&o("lazy-load",{first:n.value,last:u.value}))}const d=e.computed(()=>l.items.length*l.itemSize),n=e.computed(()=>{const m=Math.floor(s.value/l.itemSize)-l.buffer;return Math.max(0,m)}),u=e.computed(()=>{const m=Math.ceil(i.value/l.itemSize),p=Math.floor(s.value/l.itemSize)+m+l.buffer;return Math.min(l.items.length,p)}),h=e.computed(()=>n.value*l.itemSize),b=e.computed(()=>l.items.slice(n.value,u.value).map((m,p)=>({item:m,index:n.value+p})));return(m,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",Mp,[e.renderSlot(m.$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",Dp,[e.renderSlot(m.$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(b.value,f=>(e.openBlock(),e.createElementBlock("div",{key:e.unref(re)(f.item,f.index,t.itemKey),class:"virtual-scroller__item",style:e.normalizeStyle({height:`${t.itemSize}px`})},[e.renderSlot(m.$slots,"item",{item:f.item,index:f.index},()=>[e.createElementVNode("span",zp,e.toDisplayString(f.item),1)],!0)],4))),128))],4)],4))],36))}}),[["__scopeId","data-v-5a8d047c"]]),Lp={class:"meter-group mfs-card"},Tp=["aria-valuenow","aria-valuemax"],Ip=["title"],Pp={key:0,class:"meter-group__legend"},Rp={class:"meter-group__label mfs-text"},Fp={class:"meter-group__value mfs-text-muted"},ll=D(e.defineComponent({__name:"MeterGroup",props:{values:{},max:{default:100},showLegend:{type:Boolean,default:!0}},setup(t){const r=t,l=["var(--primary)","var(--secondary)","var(--success)","var(--warning)","var(--danger)"],o=e.computed(()=>r.values.reduce((i,c)=>i+Math.max(0,c.value),0));function a(i){const c=r.max>0?r.max:100;return Math.min(100,Math.max(0,i/c*100))}function s(i){return l[i%l.length]}return(i,c)=>(e.openBlock(),e.createElementBlock("div",Lp,[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||s(n)}),title:`${d.label}: ${d.value}`},null,12,Ip))),128))],8,Tp),t.showLegend?(e.openBlock(),e.createElementBlock("ol",Pp,[(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||s(n)}),"aria-hidden":"true"},null,4),e.createElementVNode("span",Rp,e.toDisplayString(d.label),1),e.createElementVNode("span",Fp,e.toDisplayString(d.value)+" ("+e.toDisplayString(Math.round(a(d.value)))+"%)",1)]))),128))])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-7ff895f3"]]),Ap={class:"inplace"},jp=["tabindex","aria-disabled","onKeydown"],Kp={class:"inplace__inner"},ol=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:r}){const l=t,o=r,a=e.ref(l.active);e.watch(()=>l.active,d=>{a.value=d});const s=e.computed(()=>a.value);function i(){l.disabled||s.value||(a.value=!0,o("update:active",!0),o("open"))}function c(){s.value&&(a.value=!1,o("update:active",!1),o("close"))}return(d,n)=>(e.openBlock(),e.createElementBlock("div",Ap,[s.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",Kp,[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,jp))]))}}),[["__scopeId","data-v-befa9d74"]]),Op={class:"mfs-confirm-popup__body"},Up={class:"mfs-confirm-popup__message mfs-text"},Hp={class:"mfs-confirm-popup__actions"},nl=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:r,emit:l}){const o=t,a=l,s=e.ref(null),i=e.ref(!1),c=e.ref(null),d=e.ref({}),n=e.ref({top:0,left:0}),u=e.computed(()=>o.modelValue!==void 0),h=e.computed(()=>u.value?!!o.modelValue:i.value),b=e.computed(()=>d.value.message??o.message),m=e.computed(()=>d.value.acceptLabel??o.acceptLabel),p=e.computed(()=>d.value.rejectLabel??o.rejectLabel),f=e.computed(()=>d.value.variant??o.variant),k=e.computed(()=>({top:`${n.value.top}px`,left:`${n.value.left}px`}));function y(S){return S?S instanceof HTMLElement?S:S.currentTarget??S.target:null}async function g(){var T;await e.nextTick();const S=c.value??y(o.target);if(!S||typeof window>"u")return;const N=S.getBoundingClientRect(),L=((T=s.value)==null?void 0:T.offsetWidth)??260,A=Math.min(Math.max(12,N.left+N.width/2-L/2),window.innerWidth-L-12),K=N.bottom+10;n.value={top:K,left:A}}function B(S){u.value||(i.value=S),a("update:modelValue",S)}function w(S,N={}){c.value=y(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 A;const N=S.target,L=c.value??y(o.target);(A=s.value)!=null&&A.contains(N)||L!=null&&L.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))}),r({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:s,class:"mfs-confirm-popup mfs-overlay mfs-surface mfs-rounded mfs-shadow-card mfs-blur",style:e.normalizeStyle(k.value),role:"alertdialog","aria-modal":"false"},[e.createElementVNode("div",Op,[e.createElementVNode("span",{class:e.normalizeClass(["mfs-confirm-popup__icon",[`mfs-confirm-popup__icon--${f.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",Up,e.toDisplayString(b.value),1)]),e.createElementVNode("div",Hp,[e.createElementVNode("button",{type:"button",class:"mfs-confirm-popup__btn mfs-confirm-popup__btn--reject mfs-surface-subtle mfs-pill mfs-focus-ring",onClick:V},e.toDisplayString(p.value),1),e.createElementVNode("button",{type:"button",class:e.normalizeClass(["mfs-confirm-popup__btn mfs-confirm-popup__btn--accept mfs-pill mfs-shadow mfs-focus-ring",[`mfs-confirm-popup__btn--${f.value}`]]),onClick:$},e.toDisplayString(m.value),3)])],4)):e.createCommentVNode("",!0)]),_:1})]))}}),[["__scopeId","data-v-20774263"]]),Wp={class:"mfs-inline-msg__icon","aria-hidden":"true"},Gp={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},qp={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Yp={key:2,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Xp={key:3,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.2","stroke-linecap":"round","stroke-linejoin":"round"},Zp={class:"mfs-inline-msg__text"},al=D(e.defineComponent({__name:"InlineMessage",props:{severity:{default:"info"},text:{default:""}},setup(t){return(r,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",Wp,[t.severity==="success"?(e.openBlock(),e.createElementBlock("svg",Gp,[...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",qp,[...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",Yp,[...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",Xp,[...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",Zp,[e.renderSlot(r.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(t.text),1)],!0)])],2))}}),[["__scopeId","data-v-40ba4b5c"]]),Jp=["aria-busy"],Qp=["aria-label"],vp={class:"mfs-blockui__content mfs-surface mfs-rounded mfs-shadow"},eu={key:0,class:"mfs-blockui__label mfs-text"},sl=D(e.defineComponent({__name:"BlockUI",props:{blocked:{type:Boolean,default:!1},fullScreen:{type:Boolean,default:!1},label:{default:""}},setup(t){return(r,l)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-blockui","aria-busy":t.blocked},[e.renderSlot(r.$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(r.$slots,"overlay",{},()=>[e.createElementVNode("div",vp,[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",eu,e.toDisplayString(t.label),1)):e.createCommentVNode("",!0)])],!0)],10,Qp)):e.createCommentVNode("",!0)]),_:3})],8,["disabled"]))],8,Jp))}}),[["__scopeId","data-v-59ef354e"]]),tu=["aria-busy","onKeydown"],lu={class:"mfs-galleria__stage"},ou={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},nu={key:1,class:"mfs-empty-state"},au=["src","alt"],su=["aria-label"],ru={key:0,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},iu={key:1,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"},du={key:4,class:"mfs-galleria__caption"},cu={key:0,class:"mfs-galleria__thumbs"},mu=["aria-label","onClick"],fu=["src","alt"],rl=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:r}){const l=t,o=r,a=e.ref(l.activeIndex),s=e.ref(l.fullscreen);e.watch(()=>l.activeIndex,u=>{a.value=u});const i=e.computed(()=>l.images[a.value]??null),c=u=>{if(l.images.length===0)return;const h=(u+l.images.length)%l.images.length;a.value=h,o("update:activeIndex",h)},d=()=>c(a.value-1),n=()=>c(a.value+1);return(u,h)=>{var b;return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["mfs-galleria mfs-surface mfs-rounded mfs-shadow-card mfs-blur",{"mfs-galleria--fullscreen":s.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(m=>s.value=!1,["escape"]))]},[e.createElementVNode("div",lu,[t.loading?(e.openBlock(),e.createElementBlock("div",ou,[e.renderSlot(u.$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(u.$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,au)):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":s.value?"Exit fullscreen":"Enter fullscreen",onClick:h[0]||(h[0]=m=>s.value=!s.value)},[s.value?(e.openBlock(),e.createElementBlock("svg",iu,[...h[6]||(h[6]=[e.createElementVNode("path",{d:"M4 14h6v6M20 10h-6V4M14 10l7-7M3 21l7-7"},null,-1)])])):(e.openBlock(),e.createElementBlock("svg",ru,[...h[5]||(h[5]=[e.createElementVNode("path",{d:"M15 3h6v6M9 21H3v-6M21 3l-7 7M3 21l7-7"},null,-1)])]))],8,su)):e.createCommentVNode("",!0),(b=i.value)!=null&&b.title?(e.openBlock(),e.createElementBlock("div",du,e.toDisplayString(i.value.title),1)):e.createCommentVNode("",!0)],64))]),t.showThumbnails&&t.images.length>1?(e.openBlock(),e.createElementBlock("div",cu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.images,(m,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:f=>c(p)},[e.createElementVNode("img",{src:m.thumbnail||m.src,alt:m.alt||`Thumbnail ${p+1}`},null,8,fu)],10,mu))),128))])):e.createCommentVNode("",!0)],42,tu)}}}),[["__scopeId","data-v-cfe349fe"]]),pu=["disabled"],uu=["onKeydown"],ku=["src"],hu={key:2,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},gu={key:3,class:"mfs-cropper__controls mfs-flex mfs-flex-col mfs-gap-3"},yu={class:"mfs-row mfs-justify-between"},bu={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-1 mfs-min-w-0"},Bu=["disabled"],_u=["disabled"],wu=["disabled"],Eu={class:"mfs-flex mfs-items-center mfs-gap-1-5 mfs-shrink-0"},$u=["disabled"],Vu=["disabled"],Cu=["disabled"],xu={class:"mfs-row mfs-justify-between mfs-flex-wrap mfs-gap-2"},Nu={class:"mfs-flex mfs-items-center mfs-gap-2 mfs-flex-wrap"},Su=["disabled"],Mu={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"},Du=["aria-pressed","disabled"],zu=["aria-pressed","disabled"],Lu={class:"mfs-flex mfs-items-center mfs-gap-2"},Tu=["disabled"],Iu=["disabled"],Le=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:r,emit:l}){const o=t,a=l,s=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(null),n=e.ref(null),u=e.ref(!1),h=e.ref(null),b=e.ref(!1),m=e.ref(!1),p=e.ref(0),f=e.ref(0),k=e.ref(320),y=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 L=e.ref(o.shape);e.watch(()=>o.shape,R=>{L.value=R});function A(R){o.disabled||L.value===R||(L.value=R,a("update:shape",R))}const K=e.computed(()=>n.value?n.value:o.src?o.src:typeof o.modelValue=="string"&&o.modelValue?o.modelValue:d.value?d.value:null),T=e.computed(()=>L.value==="circle"?1:o.aspectRatio>0?o.aspectRatio:1),P=e.computed(()=>{const R=Math.max(80,k.value*.82),I=Math.max(80,y.value*.82),j=T.value;let U=R,G=U/j;return G>I&&(G=I,U=G*j),{width:U,height:G}}),M=e.computed(()=>Math.abs(B.value%180)===90),z=e.computed(()=>{if(!p.value||!f.value)return 1;const R=M.value?f.value:p.value,I=M.value?p.value:f.value;return Math.max(P.value.width/R,P.value.height/I)}),F=e.computed(()=>z.value*g.value);function H(R,I,j){return Math.min(j,Math.max(I,R))}function O(){if(!p.value||!f.value)return;const R=M.value?f.value:p.value,I=M.value?p.value:f.value,j=R*F.value,U=I*F.value,G=Math.max(0,(j-P.value.width)/2),W=Math.max(0,(U-P.value.height)/2);w.value=H(w.value,-G,G),_.value=H(_.value,-W,W)}const Y=e.computed(()=>({width:`${p.value}px`,height:`${f.value}px`,marginLeft:`${-p.value/2}px`,marginTop:`${-f.value/2}px`,transform:`translate(${w.value}px, ${_.value}px) rotate(${B.value}deg) scale(${F.value})`})),Ke=e.computed(()=>({width:`${P.value.width}px`,height:`${P.value.height}px`}));function ce(){d.value&&(URL.revokeObjectURL(d.value),d.value=null)}function Ul(R){if(!(R.type.startsWith("image/")||/\.(png|jpe?g|webp|gif|bmp|svg|avif)$/i.test(R.name))){const U=`Unsupported file type: ${R.name}`;h.value=U,a("error",U);return}ce(),h.value=null,u.value=!1;const j=URL.createObjectURL(R);d.value=j,n.value=j,me()}function Ne(){var R;o.disabled||(R=s.value)==null||R.click()}function Mh(R){var U;const I=R.target,j=(U=I.files)==null?void 0:U[0];j&&Ul(j),I.value=""}function Dh(R){var j,U;if(b.value=!1,o.disabled)return;const I=(U=(j=R.dataTransfer)==null?void 0:j.files)==null?void 0:U[0];I&&Ul(I)}function zh(){const R=c.value;R&&(p.value=R.naturalWidth,f.value=R.naturalHeight,u.value=!0,h.value=null,O())}function Lh(){u.value=!1;const R="Failed to load image";h.value=R,a("error",R)}function Th(R){if(o.disabled||!u.value)return;const I=i.value;I&&($.value=!0,V=R.clientX,E=R.clientY,C=w.value,S=_.value,I.setPointerCapture(R.pointerId))}function Ih(R){$.value&&(w.value=C+(R.clientX-V),_.value=S+(R.clientY-E),O())}function Hl(R){var I;$.value&&($.value=!1,(I=i.value)==null||I.releasePointerCapture(R.pointerId))}function Ph(R){if(o.disabled||!u.value)return;const I=R.deltaY<0?.1:-.1;Oe(I)}function Oe(R){g.value=Number(H(g.value+R,1,3).toFixed(2))}function Wl(R){B.value=(B.value+R)%360,O()}function me(){g.value=1,B.value=0,w.value=0,_.value=0,O()}async function Gl(){const R=c.value;if(!R||!u.value||m.value)return null;m.value=!0,h.value=null;try{const I=T.value,j=I>=1?o.outputSize:Math.round(o.outputSize*I),U=I>=1?Math.round(o.outputSize/I):o.outputSize,G=document.createElement("canvas");G.width=j,G.height=U;const W=G.getContext("2d");if(!W)throw new Error("Canvas 2D context is unavailable");o.outputType==="image/jpeg"&&(W.fillStyle="#ffffff",W.fillRect(0,0,j,U)),L.value==="circle"&&(W.beginPath(),W.arc(j/2,U/2,Math.min(j,U)/2,0,Math.PI*2),W.clip());const Ue=j/P.value.width;W.save(),W.translate(j/2+w.value*Ue,U/2+_.value*Ue),W.rotate(B.value*Math.PI/180);const Xl=F.value*Ue;W.scale(Xl,Xl),W.drawImage(R,-p.value/2,-f.value/2,p.value,f.value),W.restore();const Zl=await new Promise((Fh,Ah)=>{G.toBlob(vl=>vl?Fh(vl):Ah(new Error("Failed to export cropped image")),o.outputType,o.quality)}),Rh=G.toDataURL(o.outputType,o.quality),Jl=new File([Zl],o.fileName,{type:o.outputType}),Ql={blob:Zl,dataUrl:Rh,file:Jl};return a("update:modelValue",Jl),a("crop",Ql),Ql}catch(I){const j=I instanceof Error?I.message:"Failed to crop image";return h.value=j,a("error",j),null}finally{m.value=!1}}function ql(){const R=i.value;if(!R)return;const I=R.getBoundingClientRect();I.width>0&&I.height>0&&(k.value=I.width,y.value=I.height,O())}function Yl(){N==null||N.disconnect(),!(!i.value||typeof ResizeObserver>"u")&&(N=new ResizeObserver(ql),N.observe(i.value),ql())}return e.watch(()=>o.modelValue,R=>{n.value=null,ce(),u.value=!1,R instanceof File&&(d.value=URL.createObjectURL(R)),me()},{immediate:!0}),e.watch(()=>o.src,()=>{n.value=null,u.value=!1,me()}),e.watch([g,T],()=>{O()}),e.watch(i,R=>{R&&Yl()}),e.onMounted(()=>{Yl()}),e.onBeforeUnmount(()=>{N==null||N.disconnect(),ce()}),r({crop:Gl,reset:me}),(R,I)=>(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:s,type:"file",accept:"image/*",class:"mfs-sr-only",disabled:t.disabled,onChange:Mh},null,40,pu),K.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:Th,onPointermove:Ih,onPointerup:Hl,onPointercancel:Hl,onWheel:e.withModifiers(Ph,["prevent"])},[e.createElementVNode("img",{ref_key:"imgRef",ref:c,src:K.value,alt:"Crop source",draggable:"false",class:"mfs-cropper__img",style:e.normalizeStyle(Y.value),onLoad:zh,onError:Lh},null,44,ku),u.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__viewport mfs-absolute",{"mfs-cropper__viewport--circle":L.value==="circle"}]),style:e.normalizeStyle(Ke.value),"aria-hidden":"true"},[...I[11]||(I[11]=[e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--h1"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--h2"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--v1"},null,-1),e.createElementVNode("div",{class:"mfs-cropper__grid mfs-cropper__grid--v2"},null,-1)])],6)):e.createCommentVNode("",!0)],34)):(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(["mfs-cropper__empty mfs-surface-subtle mfs-rounded mfs-border mfs-flex mfs-flex-col mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-6 mfs-text-center mfs-cursor-pointer mfs-focus-ring",{"mfs-border-primary":b.value}]),role:"button",tabindex:"0","aria-label":"Select an image to crop",onClick:Ne,onKeydown:[e.withKeys(e.withModifiers(Ne,["prevent"]),["enter"]),e.withKeys(e.withModifiers(Ne,["prevent"]),["space"])],onDragover:I[0]||(I[0]=e.withModifiers(j=>b.value=!0,["prevent"])),onDragleave:I[1]||(I[1]=e.withModifiers(j=>b.value=!1,["prevent"])),onDrop:e.withModifiers(Dh,["prevent"])},[...I[10]||(I[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,uu)),h.value?(e.openBlock(),e.createElementBlock("div",hu,e.toDisplayString(h.value),1)):e.createCommentVNode("",!0),t.showControls&&K.value?(e.openBlock(),e.createElementBlock("div",gu,[e.createElementVNode("div",yu,[e.createElementVNode("div",bu,[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:I[2]||(I[2]=j=>Oe(-.15))},[...I[12]||(I[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,Bu),e.withDirectives(e.createElementVNode("input",{"onUpdate:modelValue":I[3]||(I[3]=j=>g.value=j),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,_u),[[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:I[4]||(I[4]=j=>Oe(.15))},[...I[13]||(I[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,wu)]),e.createElementVNode("div",Eu,[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:I[5]||(I[5]=j=>Wl(-90))},[...I[14]||(I[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,$u),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:I[6]||(I[6]=j=>Wl(90))},[...I[15]||(I[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,Vu),e.createElementVNode("button",{type:"button",class:"mfs-cropper__btn mfs-surface-subtle mfs-rounded-sm mfs-border mfs-text-muted mfs-cursor-pointer mfs-focus-ring mfs-inline-flex mfs-items-center mfs-justify-center mfs-px-2 mfs-text-xs mfs-font-semibold",disabled:t.disabled,onClick:me}," Reset ",8,Cu)])]),e.createElementVNode("div",xu,[e.createElementVNode("div",Nu,[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:Ne}," Change Image ",8,Su),t.allowShapeToggle?(e.openBlock(),e.createElementBlock("div",Mu,[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",L.value==="rect"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":L.value==="rect",disabled:t.disabled,onClick:I[7]||(I[7]=j=>A("rect"))},[...I[16]||(I[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,Du),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",L.value==="circle"?"mfs-bg-primary":"mfs-bg-transparent mfs-text-muted"]),"aria-pressed":L.value==="circle",disabled:t.disabled,onClick:I[8]||(I[8]=j=>A("circle"))},[...I[17]||(I[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,zu)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Lu,[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:I[9]||(I[9]=j=>a("cancel"))}," Cancel ",8,Tu),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||!u.value||m.value,onClick:Gl},e.toDisplayString(m.value?"Cropping...":"Crop"),9,Iu)])])])):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-4a71ca25"]]),Pu=["aria-busy"],Ru={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},Fu=["onKeydown"],Au=["accept","multiple","disabled"],ju={key:0,class:"mfs-upload__hint mfs-caption mfs-m-0"},Ku={key:0},Ou={key:1},Uu={key:2},Hu={key:1,class:"mfs-soft-danger mfs-rounded-sm mfs-p-2 mfs-text-sm",role:"alert"},Wu={key:2,class:"mfs-upload__progress-wrap mfs-flex mfs-items-center mfs-gap-2-5"},Gu={class:"mfs-upload__progress-track mfs-pill mfs-shadow-inset mfs-flex-1 mfs-overflow-hidden"},qu={class:"mfs-upload__progress-text mfs-text-muted mfs-font-bold"},Yu={key:3,class:"mfs-upload__list mfs-m-0 mfs-p-0 mfs-flex mfs-flex-col mfs-gap-2"},Xu={class:"mfs-upload__file-info mfs-flex mfs-flex-col mfs-min-w-0"},Zu={class:"mfs-upload__file-name mfs-text mfs-font-semibold mfs-truncate"},Ju={class:"mfs-upload__file-size mfs-caption"},Qu=["onClick"],il=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(l.modelValue?[...l.modelValue]:[]),i=e.ref([]),c=e.ref(!1),d=e.ref(null),n=e.computed(()=>l.error||d.value),u=e.computed(()=>i.value[0]??null),h=e.computed(()=>u.value!==null),b=e.computed(()=>{const V=u.value;return V?`${V.name.replace(/\.[^.]+$/,"")||"cropped-image"}.png`:"cropped-image.png"});e.watch(()=>l.modelValue,V=>{V&&(s.value=[...V])});function m(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(L=>L.trim().toLowerCase()).filter(Boolean);if(C.length===0)return!0;const S=V.name.toLowerCase(),N=V.type.toLowerCase();return C.some(L=>L.startsWith(".")?S.endsWith(L):L.endsWith("/*")?N.startsWith(L.slice(0,-1)):N===L)}function f(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 ${m(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(L=>L.type.startsWith("image/")),N=C.filter(L=>!L.type.startsWith("image/"));N.length>0&&(s.value=l.multiple?[...s.value,...N]:[N[0]],o("update:modelValue",s.value),o("select",s.value)),S.length>0&&(i.value=l.multiple?[...i.value,...S]:[S[0]]);return}s.value=l.multiple?[...s.value,...E]:[E[0]],o("update:modelValue",s.value),o("select",s.value)}}function k(V){s.value=l.multiple?[...s.value,V.file]:[V.file],o("update:modelValue",s.value),o("select",s.value),i.value.shift()}function y(){i.value.shift()}const g=()=>{var V;!l.disabled&&!l.loading&&((V=a.value)==null||V.click())},B=V=>{const E=V.target;f(E.files),E.value=""},w=()=>{!l.disabled&&!l.loading&&(c.value=!0)},_=V=>{var E;c.value=!1,f(((E=V.dataTransfer)==null?void 0:E.files)??null)},$=V=>{const[E]=s.value.splice(V,1);o("update:modelValue",s.value),E&&o("remove",E),s.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",Ru,[...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,Au),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",ju,[t.accept?(e.openBlock(),e.createElementBlock("span",Ku,"Accepted: "+e.toDisplayString(t.accept),1)):e.createCommentVNode("",!0),t.accept&&t.maxFileSize?(e.openBlock(),e.createElementBlock("span",Ou," · ")):e.createCommentVNode("",!0),t.maxFileSize?(e.openBlock(),e.createElementBlock("span",Uu,"Max: "+e.toDisplayString(m(t.maxFileSize)),1)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)],42,Fu),n.value?(e.openBlock(),e.createElementBlock("div",Hu,e.toDisplayString(n.value),1)):e.createCommentVNode("",!0),typeof t.progress=="number"&&t.progress>0?(e.openBlock(),e.createElementBlock("div",Wu,[e.createElementVNode("div",Gu,[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",qu,e.toDisplayString(Math.round(t.progress))+"%",1)])):e.createCommentVNode("",!0),s.value.length>0?(e.openBlock(),e.createElementBlock("ul",Yu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.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",Xu,[e.createElementVNode("span",Zu,e.toDisplayString(C.name),1),e.createElementVNode("span",Ju,e.toDisplayString(m(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,Qu)]))),128))])):e.createCommentVNode("",!0),e.createVNode(v,{"model-value":h.value,title:"Crop Image",size:"md","close-on-backdrop":!1,onClose:y},{default:e.withCtx(()=>[u.value?(e.openBlock(),e.createBlock(Le,{key:0,"model-value":u.value,shape:t.cropShape,"aspect-ratio":t.cropAspectRatio,"file-name":b.value,onCrop:k,onCancel:y},null,8,["model-value","shape","aspect-ratio","file-name"])):e.createCommentVNode("",!0)]),_:1},8,["model-value"])],8,Pu))}}),[["__scopeId","data-v-56400c6e"]]),vu={key:0,class:"mfs-terminal__welcome"},ek={class:"mfs-terminal__cmd-line"},tk={class:"mfs-terminal__prompt"},lk={class:"mfs-terminal__cmd"},ok={key:0,class:"mfs-terminal__response"},nk={class:"mfs-terminal__prompt"},ak=["onKeydown"],dl=D(e.defineComponent({__name:"Terminal",props:{welcomeMessage:{default:""},prompt:{default:"$"},commands:{}},emits:["command"],setup(t,{expose:r,emit:l}){const o=t,a=l,s=e.ref([]),i=e.ref([]),c=e.ref(-1),d=e.ref(""),n=e.ref(null),u=e.ref(null),h=()=>{var k;(k=n.value)==null||k.focus()},b=async()=>{await e.nextTick(),u.value&&(u.value.scrollTop=u.value.scrollHeight)},m=async()=>{const k=d.value.trim();if(!k)return;d.value="",i.value.push(k),c.value=i.value.length;const[y,...g]=k.split(/\s+/);if(y==="clear"){s.value=[];return}const B={command:k};s.value.push(B);const w=s.value.length-1,_=$=>{s.value[w].response=$,b()};if(o.commands&&y in o.commands){const $=await o.commands[y](g);_($)}else a("command",{command:y,args:g,raw:k,respond:_});b()},p=()=>{i.value.length!==0&&(c.value=Math.max(0,c.value-1),d.value=i.value[c.value]??"")},f=()=>{i.value.length!==0&&(c.value=Math.min(i.value.length,c.value+1),d.value=i.value[c.value]??"")};return r({clear:()=>{s.value=[]}}),(k,y)=>(e.openBlock(),e.createElementBlock("div",{class:"mfs-terminal mfs-font-mono mfs-rounded mfs-shadow-card mfs-blur",onClick:h},[t.welcomeMessage?(e.openBlock(),e.createElementBlock("div",vu,e.toDisplayString(t.welcomeMessage),1)):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"logRef",ref:u,class:"mfs-terminal__logs"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(g,B)=>(e.openBlock(),e.createElementBlock("div",{key:B,class:"mfs-terminal__entry"},[e.createElementVNode("div",ek,[e.createElementVNode("span",tk,e.toDisplayString(t.prompt),1),e.createElementVNode("span",lk,e.toDisplayString(g.command),1)]),g.response?(e.openBlock(),e.createElementBlock("div",ok,e.toDisplayString(g.response),1)):e.createCommentVNode("",!0)]))),128))],512),e.createElementVNode("form",{class:"mfs-terminal__input-row",onSubmit:e.withModifiers(m,["prevent"])},[e.createElementVNode("span",nk,e.toDisplayString(t.prompt),1),e.withDirectives(e.createElementVNode("input",{ref_key:"inputRef",ref:n,"onUpdate:modelValue":y[0]||(y[0]=g=>d.value=g),type:"text",class:"mfs-terminal__input",autocomplete:"off",spellcheck:"false","aria-label":"Terminal command input",onKeydown:[e.withKeys(e.withModifiers(p,["prevent"]),["up"]),e.withKeys(e.withModifiers(f,["prevent"]),["down"])]},null,40,ak),[[e.vModelText,d.value]])],32)]))}}),[["__scopeId","data-v-1c02f599"]]),sk=["aria-busy"],rk={key:0,class:"mfs-loading-overlay",role:"status","aria-live":"polite"},ik=["viewBox","aria-label"],dk=["x2","y1","y2"],ck=["x","y"],mk=["x","y","width","height","fill","onMouseenter"],fk=["x","y","width","height","fill"],pk=["stroke","points"],uk=["cx","cy","fill","onMouseenter"],kk=["cx","cy"],hk=["transform"],gk=["d","fill","onMouseenter"],yk=["d","fill"],bk={key:0,class:"mfs-chart__legend mfs-flex mfs-flex-wrap mfs-gap-3 mfs-justify-center"},le=480,ie=24,Te=24,oe=20,de=30,cl=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 r=t,l=e.computed(()=>{var $;return(($=r.data)==null?void 0:$.labels)??[]}),o=e.computed(()=>{var $;return(($=r.data)==null?void 0:$.datasets)??[]}),a=e.computed(()=>o.value.length===0?!0:o.value.every($=>!$.data||$.data.length===0)),s=e.computed(()=>r.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}`,u={"--mfs-clay-filter":`url(#${c})`,"--mfs-clay-point-filter":`url(#${d})`},h=["#8b5cf6","#06b6d4","#10b981","#f59e0b","#f43f5e","#38bdf8"],b=e.ref(null),m=e.computed(()=>{const $=o.value.flatMap(V=>V.data);return Math.max(1,...$)}),p=$=>{const V=Math.max(1,l.value.length),E=le-ie-Te;return V===1?ie+E/2:ie+E*($+.5)/V},f=$=>{const V=s.value-oe-de;return oe+V-$/m.value*V},k=e.computed(()=>{const $=Math.max(1,l.value.length),V=Math.max(1,o.value.length),E=(le-ie-Te)/$;return Math.max(6,Math.min(34,E*.68/V))}),y=($,V)=>{const E=Math.max(1,o.value.length),C=E*k.value+(E-1)*4;return p($)-C/2+V*(k.value+4)},g=$=>$.map((V,E)=>`${p(E)},${f(V)}`).join(" "),B=e.computed(()=>{const $=o.value[0];if(!$)return[];const V=$.data.reduce((N,L)=>N+Math.max(0,L),0)||1,E=Math.min(le,s.value)*.4,C=r.type==="doughnut"?E*.55:0;let S=-Math.PI/2;return $.data.map((N,L)=>{const A=Math.max(0,N)/V*Math.PI*2,K=S+A,T=A>Math.PI?1:0,P=Math.cos(S)*E,M=Math.sin(S)*E,z=Math.cos(K)*E,F=Math.sin(K)*E;let H="";if(C>0){const O=Math.cos(K)*C,Y=Math.sin(K)*C,Ke=Math.cos(S)*C,ce=Math.sin(S)*C;H=`M ${P} ${M} A ${E} ${E} 0 ${T} 1 ${z} ${F} L ${O} ${Y} A ${C} ${C} 0 ${T} 0 ${Ke} ${ce} Z`}else H=`M 0 0 L ${P} ${M} A ${E} ${E} 0 ${T} 1 ${z} ${F} Z`;return S=K,{d:H,value:N,label:l.value[L]??`Item ${L+1}`,color:h[L%h.length]}})}),w=e.computed(()=>r.type==="pie"||r.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();b.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:u,"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",rk,[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 ${le} ${s.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-0a959c5d></feGaussianBlur><feOffset dx="2" dy="5" in="dropBlur" result="dropOffset" data-v-0a959c5d></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.24" result="dropColor" data-v-0a959c5d></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-0a959c5d></feComposite><feOffset dx="2" dy="2.5" in="SourceAlpha" result="hlOffset" data-v-0a959c5d></feOffset><feGaussianBlur stdDeviation="2" in="hlOffset" result="hlBlur" data-v-0a959c5d></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-0a959c5d></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.72" result="hlColor" data-v-0a959c5d></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-0a959c5d></feComposite><feOffset dx="-2" dy="-2.5" in="SourceAlpha" result="shOffset" data-v-0a959c5d></feOffset><feGaussianBlur stdDeviation="2.2" in="shOffset" result="shBlur" data-v-0a959c5d></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-0a959c5d></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.28" result="shColor" data-v-0a959c5d></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-0a959c5d></feComposite><feMerge data-v-0a959c5d><feMergeNode in="dropShadow" data-v-0a959c5d></feMergeNode><feMergeNode in="SourceGraphic" data-v-0a959c5d></feMergeNode><feMergeNode in="innerShade" data-v-0a959c5d></feMergeNode><feMergeNode in="innerHighlight" data-v-0a959c5d></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-0a959c5d></feGaussianBlur><feOffset dx="1.5" dy="2.5" in="dropBlur" result="dropOffset" data-v-0a959c5d></feOffset><feFlood flood-color="#4c1d95" flood-opacity="0.26" result="dropColor" data-v-0a959c5d></feFlood><feComposite in="dropColor" in2="dropOffset" operator="in" result="dropShadow" data-v-0a959c5d></feComposite><feOffset dx="1.2" dy="1.4" in="SourceAlpha" result="hlOffset" data-v-0a959c5d></feOffset><feGaussianBlur stdDeviation="1.1" in="hlOffset" result="hlBlur" data-v-0a959c5d></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="hlBlur" result="hlEdge" data-v-0a959c5d></feComposite><feFlood flood-color="#ffffff" flood-opacity="0.8" result="hlColor" data-v-0a959c5d></feFlood><feComposite operator="in" in="hlColor" in2="hlEdge" result="innerHighlight" data-v-0a959c5d></feComposite><feOffset dx="-1.2" dy="-1.4" in="SourceAlpha" result="shOffset" data-v-0a959c5d></feOffset><feGaussianBlur stdDeviation="1.2" in="shOffset" result="shBlur" data-v-0a959c5d></feGaussianBlur><feComposite operator="out" in="SourceAlpha" in2="shBlur" result="shEdge" data-v-0a959c5d></feComposite><feFlood flood-color="#1e1b4b" flood-opacity="0.3" result="shColor" data-v-0a959c5d></feFlood><feComposite operator="in" in="shColor" in2="shEdge" result="innerShade" data-v-0a959c5d></feComposite><feMerge data-v-0a959c5d><feMergeNode in="dropShadow" data-v-0a959c5d></feMergeNode><feMergeNode in="SourceGraphic" data-v-0a959c5d></feMergeNode><feMergeNode in="innerShade" data-v-0a959c5d></feMergeNode><feMergeNode in="innerHighlight" data-v-0a959c5d></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:ie,x2:le-Te,y1:oe+(s.value-oe-de)*(E-1)/3,y2:oe+(s.value-oe-de)*(E-1)/3,class:"mfs-chart__grid"},null,8,dk)),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:s.value-8,"text-anchor":"middle",class:"mfs-chart__label"},e.toDisplayString(E),9,ck))),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:y(N,C),y:f(S),width:k.value,height:Math.max(2,s.value-de-f(S)),fill:E.color||h[C%h.length],rx:"4",class:"mfs-chart__bar",onMouseenter:L=>_(L,`${l.value[N]??N}: ${S}`),onMouseleave:V[0]||(V[0]=L=>b.value=null)},null,40,mk),e.createElementVNode("rect",{x:y(N,C)+2,y:f(S)+2,width:Math.max(0,k.value-4),height:Math.max(0,Math.min(14,(s.value-de-f(S))*.45)),fill:`url(#${n})`,rx:"4",class:"mfs-chart__clay-gloss"},null,8,fk)]))),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,pk),(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:f(S),r:"5",fill:E.color||h[C%h.length],class:"mfs-chart__point",onMouseenter:L=>_(L,`${l.value[N]??N}: ${S}`),onMouseleave:V[1]||(V[1]=L=>b.value=null)},null,40,uk),e.createElementVNode("circle",{cx:p(N)-1.5,cy:f(S)-1.5,r:"1.6",fill:"#ffffff","fill-opacity":"0.7",class:"mfs-chart__clay-gloss"},null,8,kk)]))),128))],64))),128)):(e.openBlock(),e.createElementBlock("g",{key:3,transform:`translate(${le/2}, ${s.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=>b.value=null)},null,40,gk))),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,yk))),128))],8,hk))],8,ik)),b.value?(e.openBlock(),e.createElementBlock("div",{key:3,class:"mfs-chart__tooltip mfs-rounded-sm",style:e.normalizeStyle({left:`${b.value.x}px`,top:`${b.value.y}px`})},e.toDisplayString(b.value.text),5)):e.createCommentVNode("",!0)],4),!a.value&&w.value.length>0?(e.openBlock(),e.createElementBlock("div",bk,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(E,C)=>(e.openBlock(),e.createElementBlock("span",{key:C,class:"mfs-chart__legend-item mfs-caption 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,sk))}}),[["__scopeId","data-v-0a959c5d"]]),ml=D(e.defineComponent({__name:"AvatarGroup",props:{max:{},size:{default:"md"},items:{}},setup(t){const r=t,l=e.computed(()=>r.items?r.max!==void 0&&r.max>=0&&r.items.length>r.max?r.items.slice(0,r.max):r.items:[]),o=e.computed(()=>!r.items||r.max===void 0||r.max<0?0:Math.max(0,r.items.length-r.max));return(a,s)=>{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(ke,{key:d,src:c.src,label:c.label,size:t.size},null,8,["src","label","size"]))),128)),o.value>0?(e.openBlock(),e.createBlock(ke,{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"]]),Bk={class:"mfs-overlay-badge mfs-relative mfs-inline-flex"},fl=D(e.defineComponent({__name:"OverlayBadge",props:{value:{},variant:{default:"primary"},size:{default:"sm"}},setup(t){const r=t,l=e.computed(()=>r.value!==void 0&&r.value!=="");return(o,a)=>(e.openBlock(),e.createElementBlock("span",Bk,[e.renderSlot(o.$slots,"default",{},void 0,!0),l.value?(e.openBlock(),e.createBlock(Se,{key:0,variant:t.variant,size:t.size,class:"mfs-overlay-badge__badge mfs-absolute mfs-shadow"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.value),1)]),_:1},8,["variant","size"])):e.createCommentVNode("",!0)]))}}),[["__scopeId","data-v-d997956f"]]),_k=["src","alt"],wk=["src","alt"],Ek=["value"],pl=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:r}){const l=t,o=r,a=p=>Math.min(100,Math.max(0,p)),s=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 f=Math.round(a(p)*10)/10;i.value=f,o("update:modelValue",f)},n=p=>{const f=s.value;if(!f)return;const k=f.getBoundingClientRect();if(k.width<=0)return;const y=(p-k.left)/k.width*100;d(y)},u=p=>{var f,k;c.value=!0,(k=(f=p.currentTarget)==null?void 0:f.setPointerCapture)==null||k.call(f,p.pointerId),n(p.clientX)},h=p=>{c.value&&n(p.clientX)},b=p=>{var f,k;c.value&&(c.value=!1,(k=(f=p.currentTarget)==null?void 0:f.releasePointerCapture)==null||k.call(f,p.pointerId))},m=p=>{const f=p.target;d(Number(f.value))};return(p,f)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"containerRef",ref:s,class:"mfs-image-compare mfs-relative mfs-overflow-hidden mfs-rounded mfs-select-none mfs-surface mfs-shadow",onPointerdown:u,onPointermove:h,onPointerup:b,onPointercancel:b},[e.createElementVNode("img",{src:t.rightSrc,alt:t.rightAlt,class:"mfs-image-compare__img mfs-w-full mfs-h-full",draggable:"false"},null,8,_k),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,wk),e.createElementVNode("div",{class:"mfs-image-compare__divider mfs-absolute",style:e.normalizeStyle({left:`${i.value}%`}),"aria-hidden":"true"},[...f[0]||(f[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:m},null,40,Ek)],544))}}),[["__scopeId","data-v-0e55644e"]]),ul=e.defineComponent({__name:"Portal",props:{appendTo:{default:"body"},disabled:{type:Boolean,default:!1}},setup(t){return(r,l)=>(e.openBlock(),e.createBlock(e.Teleport,{to:t.appendTo,disabled:t.disabled},[e.renderSlot(r.$slots,"default")],8,["to","disabled"]))}}),$k=["for"],Vk=["id","placeholder","disabled","aria-invalid"],Ck={key:1,class:"mfs-chips-msg mfs-text-danger"},xk={key:2,class:"mfs-chips-msg mfs-caption"},Ve=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:r}){const l=t,o=r,a=e.useId(),s=e.ref(null),i=e.ref(""),c=e.computed(()=>l.max!==void 0&&l.modelValue.length>=l.max),d=()=>{var p;l.disabled||(p=s.value)==null||p.focus()},n=p=>{if(l.disabled)return;const f=l.separator?p.split(l.separator):[p],k=[...l.modelValue],y=[];for(const g of f){const B=g.trim();if(B){if(l.max!==void 0&&k.length>=l.max)break;!l.allowDuplicate&&k.includes(B)||(k.push(B),y.push(B))}}if(y.length>0){o("update:modelValue",k);for(const g of y)o("add",g)}i.value=""},u=p=>{if(l.disabled)return;const f=l.modelValue[p];if(f===void 0)return;const k=l.modelValue.filter((y,g)=>g!==p);o("update:modelValue",k),o("remove",f)},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(),u(l.modelValue.length-1))}},b=()=>{l.separator&&i.value.includes(l.separator)&&n(i.value)},m=()=>{i.value.trim()&&n(i.value)};return(p,f)=>(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,$k)):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,(k,y)=>(e.openBlock(),e.createBlock(ae,{key:`${k}-${y}`,label:k,removable:!t.disabled,onRemove:g=>u(y)},null,8,["label","removable","onRemove"]))),128)),e.withDirectives(e.createElementVNode("input",{id:e.unref(a),ref_key:"inputRef",ref:s,"onUpdate:modelValue":f[0]||(f[0]=k=>i.value=k),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:b,onBlur:m},null,40,Vk),[[e.vModelText,i.value]])],2),t.error?(e.openBlock(),e.createElementBlock("p",Ck,e.toDisplayString(t.error),1)):t.hint?(e.openBlock(),e.createElementBlock("p",xk,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)],2))}}),[["__scopeId","data-v-0e7176f9"]]),Nk=["aria-invalid"],Sk=Symbol("CheckboxGroup"),kl=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:r}){const l=t,o=r,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)},s=i=>{l.disabled||!Array.isArray(i)||(o("update:modelValue",i),o("change",i))};return e.provide(Sk,{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(ee,{key:n,"model-value":t.modelValue,value:d.value,label:d.label,disabled:t.disabled||d.disabled,"onUpdate:modelValue":s},null,8,["model-value","value","label","disabled"]))),128))],!0)],10,Nk))}}),[["__scopeId","data-v-bde4c6e4"]]),Mk=["aria-invalid"],Dk=Symbol("RadioButtonGroup"),hl=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:r}){const l=t,o=r,a=`mfs-radio-group-${e.useId()}`,s=e.computed(()=>l.name||a),i=c=>{l.disabled||(o("update:modelValue",c),o("change",c))};return e.provide(Dk,{modelValue:e.computed(()=>l.modelValue),name:s,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,s.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,u)=>(e.openBlock(),e.createBlock(Me,{key:u,"model-value":t.modelValue,value:n.value,name:s.value,label:n.label,disabled:t.disabled||n.disabled,"onUpdate:modelValue":i},null,8,["model-value","value","name","label","disabled"]))),128))],!0)],10,Mk))}}),[["__scopeId","data-v-2e9ea155"]]),J=e.ref([]);let zk=1;function Lk(t,r={}){const l=`mfs-dialog-${zk++}`;return J.value=[...J.value,{id:l,component:e.markRaw(t),options:r}],l}function Tk(t,r){var a,s;const l=J.value.findIndex(i=>i.id===t);if(l===-1)return;const o=J.value[l];J.value=J.value.filter(i=>i.id!==t),(s=(a=o.options).onClose)==null||s.call(a,r)}function gl(){return{dialogs:e.readonly(J),open:Lk,close:Tk}}const yl=e.defineComponent({__name:"DynamicDialog",setup(t){const{dialogs:r,close:l}=gl(),o=e.defineComponent({name:"MfsDynamicDialogContent",props:{component:{type:Object,required:!0},componentProps:{type:Object,default:()=>({})},onClose:{type:Function,required:!0}},setup(a){const s={close:i=>a.onClose(i)};return e.provide("dialogRef",s),()=>e.h(a.component,a.componentProps)}});return(a,s)=>(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(r),i=>(e.openBlock(),e.createBlock(v,{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))}}),Ik={class:"cmd-header mfs-flex mfs-items-center mfs-gap-2 mfs-border-b"},Pk=["placeholder"],Rk={key:0,class:"mfs-spinner mfs-spinner--sm",role:"status","aria-label":"Loading"},Fk={key:1,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},Ak={key:0,class:"mfs-empty-state"},jk={key:1,class:"mfs-empty-state"},Kk={key:0,class:"cmd-group-label mfs-text-muted"},Ok=["aria-selected","aria-disabled","disabled","onMouseenter","onClick"],Uk={class:"cmd-item-main mfs-flex mfs-flex-col"},Hk={class:"cmd-item-label"},Wk={key:0,class:"cmd-item-desc mfs-text-muted"},Gk={key:0,class:"cmd-kbd mfs-surface-subtle mfs-rounded-sm mfs-text-muted"},bl=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:r}){const l=t,o=r,a=e.ref(""),s=e.ref(-1),i=e.ref(null),c=e.ref(null),d=new Map,n=(_,$)=>{$?d.set(_,$):d.delete(_)},u=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 u.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}))}),b=e.computed(()=>h.value.flatMap(_=>_.entries.map($=>$.item))),m=_=>_.findIndex($=>!$.disabled);e.watch(b,_=>{d.clear(),s.value=m(_)},{immediate:!0});const p=()=>{o("update:modelValue",!1)},f=()=>{o("search",a.value)},k=(_,$)=>{$.disabled||(s.value=_)},y=_=>{_.disabled||(o("select",_),p())},g=_=>{var C;const $=b.value,V=$.length;if(V===0)return;let E=s.value;for(let S=0;S<V;S++)if(E=(E+_+V)%V,!((C=$[E])!=null&&C.disabled)){s.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 $=b.value[s.value];$&&!$.disabled&&(_.preventDefault(),y($))}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="",s.value=m(b.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",Ik,[$[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:f},null,40,Pk),[[e.vModelText,a.value]]),t.loading?(e.openBlock(),e.createElementBlock("span",Rk)):(e.openBlock(),e.createElementBlock("kbd",Fk,"ESC"))]),e.createElementVNode("div",{ref_key:"listRef",ref:c,class:"cmd-list",role:"listbox"},[t.loading&&b.value.length===0?(e.openBlock(),e.createElementBlock("div",Ak,[...$[3]||($[3]=[e.createElementVNode("span",{class:"mfs-spinner mfs-spinner--sm","aria-label":"Loading"},null,-1)])])):b.value.length===0?(e.openBlock(),e.createElementBlock("div",jk,[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",Kk,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":s.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-border-none mfs-text mfs-transition",{"cmd-item--active mfs-surface-subtle":s.value===E.flatIndex,"mfs-disabled":E.item.disabled,"mfs-cursor-pointer":!E.item.disabled}]),onMouseenter:C=>k(E.flatIndex,E.item),onClick:C=>y(E.item)},[e.createElementVNode("div",Uk,[e.createElementVNode("span",Hk,e.toDisplayString(E.item.label),1),E.item.description?(e.openBlock(),e.createElementBlock("span",Wk,e.toDisplayString(E.item.description),1)):e.createCommentVNode("",!0)]),E.item.shortcut?(e.openBlock(),e.createElementBlock("kbd",Gk,e.toDisplayString(E.item.shortcut),1)):e.createCommentVNode("",!0)],42,Ok))),128))]))),128))],512)],32)])):e.createCommentVNode("",!0)]),_:3})]))}}),[["__scopeId","data-v-8c837bbe"]]),qk={class:"infinite-scroll mfs-flex mfs-flex-col"},Yk={key:0,class:"mfs-empty-state"},Xk={key:1,class:"infinite-scroll__status mfs-flex mfs-items-center mfs-justify-center mfs-p-4",role:"status","aria-live":"polite"},Zk={key:2,class:"infinite-scroll__error mfs-soft-danger mfs-rounded mfs-flex mfs-items-center mfs-justify-between mfs-gap-3 mfs-p-3",role:"alert"},Jk={class:"infinite-scroll__error-text"},Qk={key:3,class:"infinite-scroll__finished mfs-text-muted mfs-text-center mfs-p-4"},Bl=D(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:r}){const l=t,o=r,a=e.ref(null);let s=null;const i=()=>{o("load")},c=()=>l.hasMore&&!l.loading&&!l.error,d=()=>{s==null||s.disconnect(),s=null,!(typeof IntersectionObserver>"u"||!a.value)&&(s=new IntersectionObserver(n=>{n.some(u=>u.isIntersecting)&&c()&&i()},{rootMargin:l.rootMargin}),s.observe(a.value))};return e.watch(()=>l.rootMargin,d),e.onMounted(()=>{d()}),e.onBeforeUnmount(()=>{s==null||s.disconnect(),s=null}),(n,u)=>(e.openBlock(),e.createElementBlock("div",qk,[e.renderSlot(n.$slots,"default",{},void 0,!0),t.isEmpty&&!t.loading&&!t.error?(e.openBlock(),e.createElementBlock("div",Yk,[e.renderSlot(n.$slots,"empty",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.emptyText),1)],!0)])):e.createCommentVNode("",!0),t.loading?(e.openBlock(),e.createElementBlock("div",Xk,[e.renderSlot(n.$slots,"loading",{},()=>[u[0]||(u[0]=e.createElementVNode("span",{class:"mfs-spinner","aria-label":"Loading"},null,-1))],!0)])):t.error?(e.openBlock(),e.createElementBlock("div",Zk,[e.renderSlot(n.$slots,"error",{error:t.error,retry:i},()=>[e.createElementVNode("span",Jk,e.toDisplayString(t.error),1),e.createVNode(ne,{size:"sm",variant:"danger",onClick:i},{default:e.withCtx(()=>[...u[1]||(u[1]=[e.createTextVNode("Retry",-1)])]),_:1})],!0)])):!t.hasMore&&!t.isEmpty?(e.openBlock(),e.createElementBlock("div",Qk,[e.renderSlot(n.$slots,"finished",{},()=>[e.createElementVNode("span",null,e.toDisplayString(t.finishedText),1)],!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",{ref_key:"sentinelRef",ref:a,class:"infinite-scroll__sentinel","aria-hidden":"true"},null,512)]))}}),[["__scopeId","data-v-d740bcaf"]]),vk=["value","placeholder","rows","disabled","aria-expanded"],eh={key:0,class:"mfs-mentions__loading mfs-flex mfs-items-center mfs-justify-center mfs-gap-2 mfs-p-3"},th={key:1,class:"mfs-mentions__list"},lh=["aria-selected","onMousedown","onMouseenter"],oh={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"},ah={key:2,class:"mfs-empty-state",role:"status"},_l=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:r}){const l=t,o=r,a=e.ref(null),s=e.ref(null),i=e.ref(null),c=e.ref(null),d=e.ref(!1),n=e.ref(0),u=e.ref(""),h=e.ref(-1),b=e.ref(""),{overlayStyle:m,containsTarget:p}=q(s,i,d,{matchWidth:!0}),f=e.computed(()=>{if(l.remote)return l.options;const V=b.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(f,V=>{V.length===0?n.value=-1:(n.value<0||n.value>=V.length)&&(n.value=0)});const k=(V,E)=>{const C=V.slice(0,E),S=[...l.triggers].filter(Boolean).sort((N,L)=>L.length-N.length);if(!S.length)return null;for(let N=C.length-1;N>=0;N--){const L=C[N];if(/\s/.test(L))return null;for(const A of S){const K=N-A.length+1;if(!(K<0)&&C.slice(K,N+1)===A){const T=K===0?"":C[K-1];if(K===0||/\s/.test(T))return{trigger:A,start:K,query:C.slice(N+1)}}}}return null},y=()=>{const V=c.value;if(!V||l.disabled){d.value=!1;return}const E=V.selectionStart??(l.modelValue??"").length,C=k(V.value,E);C?(u.value=C.trigger,h.value=C.start,b.value=C.query,d.value=!0,n.value=f.value.length?0:-1,o("search",{trigger:C.trigger,query:C.query})):(d.value=!1,u.value="",h.value=-1,b.value="")},g=V=>{const E=V.target;o("update:modelValue",E.value),y()},B=V=>{["ArrowUp","ArrowDown","Enter","Escape"].includes(V.key)||y()},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,L=`${u.value}${V.value} `,A=C.slice(0,N)+L+C.slice(S),K=N+L.length;o("update:modelValue",A),o("select",V),d.value=!1,u.value="",h.value=-1,b.value="",e.nextTick(()=>{c.value&&(c.value.focus(),c.value.setSelectionRange(K,K))})},_=V=>{if(!d.value)return;const E=f.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=f.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:s,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:y,onKeyup:B,onKeydown:_},null,40,vk)],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(m)),role:"listbox",class:"mfs-mentions__dropdown mfs-surface mfs-overlay mfs-rounded mfs-blur mfs-shadow"},[t.loading?(e.openBlock(),e.createElementBlock("div",eh,[...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)])])):f.value.length?(e.openBlock(),e.createElementBlock("ul",th,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.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",oh,e.toDisplayString(C.label),1),C.description?(e.openBlock(),e.createElementBlock("span",nh,e.toDisplayString(C.description),1)):e.createCommentVNode("",!0)],42,lh))),128))])):(e.openBlock(),e.createElementBlock("div",ah,[e.renderSlot(V.$slots,"empty",{},()=>[e.createTextVNode(e.toDisplayString(t.emptyText),1)],!0)]))],4)):e.createCommentVNode("",!0)]),_:3})]))],2))}}),[["__scopeId","data-v-b46fcff1"]]),sh={class:"mfs-signature__stage mfs-inset mfs-rounded-sm mfs-relative"},rh=["width","height"],ih={key:0,class:"mfs-signature__hint mfs-text-muted mfs-text-sm mfs-select-none"},dh={class:"mfs-signature__actions mfs-flex mfs-items-center mfs-justify-end mfs-gap-2"},wl=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:r,emit:l}){const o=t,a=l,s=e.ref(null),i=e.ref(!1),c=e.ref(!0),d=()=>{var g;return((g=s.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"},u=g=>{const B=s.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=s.value,w=d();if(!B||!w)return;($=B.setPointerCapture)==null||$.call(B,g.pointerId);const _=u(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},b=g=>{if(!i.value||o.disabled)return;const B=d();if(!B)return;const w=u(g);B.lineTo(w.x,w.y),B.stroke()},m=g=>{var w;if(!i.value)return;const B=s.value;(w=B==null?void 0:B.hasPointerCapture)!=null&&w.call(B,g.pointerId)&&B.releasePointerCapture(g.pointerId),i.value=!1},p=()=>c.value,f=()=>{const g=s.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})},k=()=>{const g=s.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)})},y=g=>{const B=s.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)s.value&&s.value.toDataURL(o.outputType)!==g&&y(g);else{const B=s.value,w=d();B&&w&&w.clearRect(0,0,B.width,B.height),c.value=!0}}),e.onMounted(()=>{o.modelValue&&y(o.modelValue)}),r({clear:f,isEmpty:p,exportSignature:k}),(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",sh,[e.createElementVNode("canvas",{ref_key:"canvasRef",ref:s,width:t.width,height:t.height,class:"mfs-signature__canvas mfs-w-full",onPointerdown:h,onPointermove:b,onPointerup:m,onPointercancel:m,onPointerleave:m},null,40,rh),c.value?(e.openBlock(),e.createElementBlock("span",ih," Sign here ")):e.createCommentVNode("",!0)]),e.createElementVNode("div",dh,[e.createVNode(ne,{variant:"surface",size:"sm",disabled:t.disabled||c.value,onClick:f},{default:e.withCtx(()=>[...B[0]||(B[0]=[e.createTextVNode(" Clear ",-1)])]),_:1},8,["disabled"]),e.createVNode(ne,{variant:"primary",size:"sm",disabled:t.disabled||c.value,onClick:k},{default:e.withCtx(()=>[...B[1]||(B[1]=[e.createTextVNode(" Save ",-1)])]),_:1},8,["disabled"])])],2))}}),[["__scopeId","data-v-7b44dca2"]]),El=e.defineComponent({__name:"Form",props:{initialValues:{},errors:{},resolver:{},submitting:{type:Boolean,default:!1},validateOnSubmit:{type:Boolean,default:!0}},emits:["submit","reset"],setup(t,{expose:r,emit:l}){const o=t,a=l,s=e.reactive({...o.initialValues??{}}),i=e.reactive({}),c=f=>{for(const k of Object.keys(i))delete i[k];for(const[k,y]of Object.entries(f))(Array.isArray(y)?y.length>0:y)&&(i[k]=y)};e.watch(()=>o.errors,f=>{c(f??{})},{immediate:!0,deep:!0});const d=(f,k)=>{s[f]=k,f in i&&delete i[f]},n=(f,k)=>{(Array.isArray(k)?k.length>0:k)?i[f]=k:delete i[f]},u=f=>{if(f!==void 0){delete i[f];return}for(const k of Object.keys(i))delete i[k]},h=()=>{if(u(),!o.resolver)return!0;const f=o.resolver({...s});for(const[k,y]of Object.entries(f))y&&(i[k]=y);return Object.keys(i).length===0},b=()=>{const f=o.initialValues??{};for(const k of Object.keys(s))k in f||delete s[k];for(const[k,y]of Object.entries(f))s[k]=y;u(),a("reset")},m=()=>{const f={};for(const[k,y]of Object.entries(i)){const g=Array.isArray(y)?y[0]:y;g&&(f[k]=g)}return f},p=()=>{const f=o.validateOnSubmit?h():!0;a("submit",{values:{...s},valid:f,errors:m()})};return e.provide("mfsFormContext",{values:s,errors:i,submitting:e.computed(()=>o.submitting),setFieldValue:d,setFieldError:n,clearErrors:u,reset:b}),r({values:s,errors:i,validate:h,reset:b,setErrors:c}),(f,k)=>(e.openBlock(),e.createElementBlock("form",{class:"mfs-form mfs-flex mfs-flex-col mfs-gap-4",novalidate:"",onSubmit:e.withModifiers(p,["prevent"])},[e.renderSlot(f.$slots,"default",{values:s,errors:i,submitting:t.submitting,reset:b,validate:h})],32))}}),ch={class:"mfs-form-field mfs-flex mfs-flex-col mfs-gap-1-5"},mh=["for"],fh={key:0,class:"mfs-text-danger"},ph={key:1,class:"mfs-form-field__msg mfs-text-danger mfs-text-xs mfs-font-medium mfs-m-0"},uh={key:2,class:"mfs-form-field__msg mfs-caption mfs-m-0"},$l=e.defineComponent({__name:"FormField",props:{name:{},label:{},hint:{},error:{},required:{type:Boolean,default:!1}},setup(t){const r=t,l=e.inject("mfsFormContext",null),o=e.computed(()=>l==null?void 0:l.values[r.name]),a=e.computed(()=>{if(r.error)return r.error;const i=l==null?void 0:l.errors[r.name];return Array.isArray(i)?i[0]||void 0:i||void 0}),s=i=>{l==null||l.setFieldValue(r.name,i)};return(i,c)=>(e.openBlock(),e.createElementBlock("div",ch,[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",fh,"*")):e.createCommentVNode("",!0)],8,mh)):e.createCommentVNode("",!0),e.renderSlot(i.$slots,"default",{value:o.value,error:a.value,setValue:s}),a.value?(e.openBlock(),e.createElementBlock("p",ph,e.toDisplayString(a.value),1)):t.hint?(e.openBlock(),e.createElementBlock("p",uh,e.toDisplayString(t.hint),1)):e.createCommentVNode("",!0)]))}}),Ie=[{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%)"}],Pe=Ie.map(t=>t.id),Vl=Pe.map(t=>`theme-${t}`),Ce=e.ref("clay");let Cl=!1;const xl=t=>{if(typeof document>"u")return;const r=document.documentElement,l=document.body;r.classList.remove(...Vl),r.classList.add(`theme-${t}`),l==null||l.classList.remove(...Vl)};function Nl(){const t=l=>{if(Ce.value=l,typeof document<"u"){const o=document.documentElement;o.getAttribute("data-theme")!==l&&o.setAttribute("data-theme",l),xl(l),localStorage.setItem("active-theme",l)}};return{currentTheme:Ce,themeOptions:Ie,setTheme:t,initTheme:(l="clay")=>{if(typeof window<"u"){const o=localStorage.getItem("active-theme");o&&Pe.includes(o)?t(o):t(l),!Cl&&typeof MutationObserver<"u"&&(Cl=!0,new MutationObserver(()=>{const s=document.documentElement.getAttribute("data-theme");s&&Pe.includes(s)&&(Ce.value!==s&&(Ce.value=s),xl(s))}).observe(document.documentElement,{attributes:!0,attributeFilter:["data-theme"]}))}}}}let kh=1;function hh(t,r={}){const l=r.id??`mfs-style-${kh++}`,o=r.name,a=e.ref(!1);let s=null;function i(){if(typeof document>"u")return;const d=document.getElementById(l);if(d instanceof HTMLStyleElement){d.textContent=t,s=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),s=n,a.value=!0}function c(){if(typeof document>"u")return;const d=s??document.getElementById(l);d&&d.parentNode&&d.parentNode.removeChild(d),s=null,a.value=!1}return(r.immediate??!0)&&i(),e.getCurrentInstance()&&e.onUnmounted(c),{id:l,name:o,css:t,isLoaded:e.readonly(a),load:i,unload:c}}function Sl(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 Ml={mounted(t,r){const l=Sl(r.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=s=>{if(t.__mfsRippleDisabled)return;const i=t.getBoundingClientRect(),c=Math.max(i.width,i.height)*2,d=s.clientX-i.left-c/2,n=s.clientY-i.top-c/2,u=document.createElement("span");u.style.position="absolute",u.style.width=`${c}px`,u.style.height=`${c}px`,u.style.left=`${d}px`,u.style.top=`${n}px`,u.style.borderRadius="50%",u.style.pointerEvents="none",u.style.backgroundColor=t.__mfsRippleColor??"currentColor",u.style.opacity="0.25",u.style.transform="scale(0)",t.appendChild(u);const h=u.animate([{transform:"scale(0)",opacity:.28},{transform:"scale(1)",opacity:0}],{duration:500,easing:"cubic-bezier(0.22, 1, 0.36, 1)"});h.onfinish=()=>u.remove()};t.__mfsRippleHandler=a,t.addEventListener("pointerdown",a)},updated(t,r){const l=Sl(r.value);t.__mfsRippleDisabled=l.disabled,t.__mfsRippleColor=l.color},unmounted(t){t.__mfsRippleHandler&&(t.removeEventListener("pointerdown",t.__mfsRippleHandler),delete t.__mfsRippleHandler)}};function gh(t){return t.right?"right":t.bottom?"bottom":t.left?"left":"top"}function Dl(t){const r=gh(t.modifiers),l=t.value;return typeof l=="string"?{text:l,disabled:!1,placement:r}:l&&typeof l=="object"?{text:l.value??"",disabled:!!l.disabled,placement:r,customClass:l.class}:{text:"",disabled:!0,placement:r}}function zl(t,r,l){const o=t.getBoundingClientRect(),a=r.getBoundingClientRect(),s=8;let i=0,c=0;switch(l){case"bottom":i=o.bottom+s,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-s;break;case"right":i=o.top+o.height/2-a.height/2,c=o.right+s;break;case"top":default:i=o.top-a.height-s,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);r.style.top=`${Math.min(Math.max(8,i),n)}px`,r.style.left=`${Math.min(Math.max(8,c),d)}px`}function xe(t){t.tipEl&&(t.tipEl.remove(),t.tipEl=void 0)}const Re={mounted(t,r){const o={...Dl(r),show:()=>{if(o.disabled||!o.text)return;xe(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),zl(t,a,o.placement),o.tipEl=a},hide:()=>xe(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,r){const l=t.__mfsTooltipState;if(!l)return;const o=Dl(r);l.text=o.text,l.disabled=o.disabled,l.placement=o.placement,l.customClass=o.customClass,l.disabled||!l.text?xe(l):l.tipEl&&(l.tipEl.textContent=l.text,zl(t,l.tipEl,l.placement))},unmounted(t){const r=t.__mfsTooltipState;r&&(t.removeEventListener("mouseenter",r.show),t.removeEventListener("mouseleave",r.hide),t.removeEventListener("focusin",r.show),t.removeEventListener("focusout",r.hide),xe(r),delete t.__mfsTooltipState)}},yh=["a[href]","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])'].join(",");function Ll(t){return Array.from(t.querySelectorAll(yh)).filter(r=>r.offsetParent!==null||r===document.activeElement)}function Tl(t){if(t.__mfsTrapActive)return;t.__mfsTrapActive=!0,t.__mfsPrevFocus=document.activeElement;const r=Ll(t);r.length>0&&r[0].focus();const l=o=>{if(o.key!=="Tab")return;const a=Ll(t);if(a.length===0){o.preventDefault();return}const s=a[0],i=a[a.length-1];o.shiftKey&&document.activeElement===s?(o.preventDefault(),i.focus()):!o.shiftKey&&document.activeElement===i&&(o.preventDefault(),s.focus())};t.__mfsFocusTrapHandler=l,t.addEventListener("keydown",l)}function Il(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 Pl={mounted(t,r){r.value!==!1&&Tl(t)},updated(t,r){r.value===!1?Il(t):Tl(t)},unmounted(t){Il(t)}},Rl={mounted(t,r){if(typeof IntersectionObserver>"u")return;const l=typeof r.value=="string"?{enterClass:r.value}:r.value??{},o=l.enterClass??"mfs-aos-enter",a=l.leaveClass??"",s=l.threshold??.1,i=l.once??!0,c=new IntersectionObserver(d=>{for(const n of d)n.isIntersecting?(a&&t.classList.remove(a),o&&t.classList.add(o),i&&c.unobserve(t)):i||(o&&t.classList.remove(o),a&&t.classList.add(a))},{threshold:s});t.__mfsAosObserver=c,c.observe(t)},unmounted(t){t.__mfsAosObserver&&(t.__mfsAosObserver.disconnect(),delete t.__mfsAosObserver)}};function bh(t,r){var l;return!r||r==="@self"?t:r==="@next"?t.nextElementSibling:r==="@prev"?t.previousElementSibling:r==="@parent"?t.parentElement:r==="@grandparent"?((l=t.parentElement)==null?void 0:l.parentElement)??null:document.querySelector(r)}function Fl(t){return typeof t=="string"?{toggleClass:t}:t}const Al={mounted(t,r){t.__mfsStyleClassOpts=Fl(r.value);const l=()=>{const o=t.__mfsStyleClassOpts;if(!o)return;const a=bh(t,o.selector);a&&(o.toggleClass?o.toggleClass.split(/\s+/).filter(Boolean).forEach(s=>a.classList.toggle(s)):(o.leaveClass&&o.leaveClass.split(/\s+/).filter(Boolean).forEach(s=>a.classList.remove(s)),o.enterClass&&o.enterClass.split(/\s+/).filter(Boolean).forEach(s=>a.classList.add(s))))};t.__mfsStyleClassHandler=l,t.addEventListener("click",l)},updated(t,r){t.__mfsStyleClassOpts=Fl(r.value)},unmounted(t){t.__mfsStyleClassHandler&&(t.removeEventListener("click",t.__mfsStyleClassHandler),delete t.__mfsStyleClassHandler)}},jl={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 Bh(t){const r=t.value;return r==null||r===""?null:typeof r=="string"||typeof r=="number"?{text:String(r),severity:"primary"}:typeof r=="object"?r.value===null||r.value===void 0||r.value===""?null:{text:String(r.value),severity:r.severity??"primary"}:null}function _h(t,r){if(typeof window>"u")return;getComputedStyle(t).position==="static"&&(r.hadStaticPosition=!0,r.previousPosition=t.style.position,t.style.position="relative")}function wh(){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 Kl(t,r,l){const o=Bh(r);if(!o){l.badgeEl&&(l.badgeEl.remove(),l.badgeEl=void 0);return}_h(t,l),l.badgeEl||(l.badgeEl=wh(),t.appendChild(l.badgeEl));const a=jl[o.severity]??jl.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 Fe={mounted(t,r){const l={hadStaticPosition:!1,previousPosition:""};t.__mfsBadgeState=l,Kl(t,r,l)},updated(t,r){const l=t.__mfsBadgeState;l&&Kl(t,r,l)},unmounted(t){const r=t.__mfsBadgeState;r&&(r.badgeEl&&(r.badgeEl.remove(),r.badgeEl=void 0),r.hadStaticPosition&&(t.style.position=r.previousPosition),delete t.__mfsBadgeState)}},Eh=Fe,Ol={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 Ae(t,r){return(t.global||t.sticky)&&(t.lastIndex=0),t.test(r)}function $h(t,r){if(!r)return!0;if(r instanceof RegExp)return Ae(r,t);const l=Ol[r];return l?l.charPattern.test(t):!0}function Vh(t,r){if(!r||t==="")return!0;if(r instanceof RegExp)return r.source.startsWith("^")||r.source.endsWith("$")?Ae(r,t):[...t].every(o=>Ae(r,o));const l=Ol[r];return l?l.pastePattern.test(t):!0}const je={mounted(t,r){const l={filter:r.value,onKeyPress(o){o.ctrlKey||o.metaKey||o.altKey||o.key.length!==1||$h(o.key,l.filter)||o.preventDefault()},onPaste(o){var s;const a=((s=o.clipboardData)==null?void 0:s.getData("text"))??"";Vh(a,l.filter)||o.preventDefault()}};t.__mfsKeyFilterState=l,t.addEventListener("keypress",l.onKeyPress),t.addEventListener("paste",l.onPaste)},updated(t,r){t.__mfsKeyFilterState&&(t.__mfsKeyFilterState.filter=r.value)},unmounted(t){const r=t.__mfsKeyFilterState;r&&(t.removeEventListener("keypress",r.onKeyPress),t.removeEventListener("paste",r.onPaste),delete t.__mfsKeyFilterState)}},Ch=je,xh={Button:ne,ButtonGroup:He,Card:We,Input:fe,InputText:fe,Badge:Se,Switch:Q,ToggleSwitch:Q,InputSwitch:Q,Modal:v,Dialog:v,Textarea:Ge,InputNumber:qe,Password:Ye,Checkbox:ee,RadioButton:Me,Select:pe,Dropdown:pe,MultiSelect:Xe,Slider:Ze,Rating:Je,ColorPicker:Qe,DatePicker:ue,Calendar:ue,Avatar:ke,Chip:ae,Tag:ae,Divider:ve,Accordion:et,Timeline:tt,Carousel:lt,Image:ot,Toast:st,Alert:he,Message:he,Tooltip:rt,Drawer:ge,Sidebar:ge,Popover:ye,OverlayPanel:ye,Skeleton:it,ProgressBar:dt,ProgressSpinner:ct,ConfirmDialog:pt,Navbar:Be,Menubar:Be,Tabs:_e,TabView:_e,Breadcrumb:ut,Pagination:se,Paginator:se,Steps:we,Stepper:we,ContextMenu:kt,ScrollTop:ht,DataTable:gt,Column:yt,DataView:bt,Tree:Bt,AutoComplete:_t,Cascader:Ee,CascadeSelect:Ee,TreeSelect:wt,Knob:Et,SelectButton:$t,ToggleButton:Vt,InputOtp:Ct,InputMask:xt,InputGroup:Nt,InputGroupAddon:St,IconField:Mt,InputIcon:Dt,Listbox:zt,FloatLabel:Lt,IftaLabel:Tt,Editor:It,SplitButton:Pt,SpeedDial:Rt,Panel:Ft,Fieldset:At,Splitter:jt,Toolbar:Kt,ScrollPanel:Ot,Fluid:Ut,Deferred:$e,DeferredContent:$e,Menu:Ht,TieredMenu:Wt,SlideMenu:Gt,PanelMenu:qt,MegaMenu:Yt,Dock:Xt,TabMenu:Zt,OrderList:Jt,PickList:Qt,TreeTable:vt,OrganizationChart:el,VirtualScroller:tl,MeterGroup:ll,Inplace:ol,ConfirmPopup:nl,InlineMessage:al,BlockUI:sl,Galleria:rl,FileUpload:il,Terminal:dl,Chart:cl,ImageCropper:Le,AvatarGroup:ml,OverlayBadge:fl,ImageCompare:pl,Portal:ul,Chips:Ve,InputChips:Ve,CheckboxGroup:kl,RadioButtonGroup:hl,DynamicDialog:yl,CommandPalette:bl,InfiniteScroll:Bl,Mentions:_l,SignaturePad:wl,Form:El,FormField:$l},Nh={ripple:Ml,tooltip:Re,focustrap:Pl,animateonscroll:Rl,styleclass:Al,badge:Fe,keyfilter:je},Sh={install(t,r={}){for(const[l,o]of Object.entries(xh))t.component(l,o);for(const[l,o]of Object.entries(Nh))t.directive(l,o);if(typeof window<"u"){const{initTheme:l}=Nl();l(r.defaultTheme||"clay")}}};x.Accordion=et,x.Alert=he,x.AutoComplete=_t,x.Avatar=ke,x.AvatarGroup=ml,x.Badge=Se,x.BadgeDirective=Eh,x.BlockUI=sl,x.Breadcrumb=ut,x.Button=ne,x.ButtonGroup=He,x.Calendar=ue,x.Card=We,x.Carousel=lt,x.CascadeSelect=Ee,x.Cascader=Ee,x.Chart=cl,x.Checkbox=ee,x.CheckboxGroup=kl,x.Chip=ae,x.Chips=Ve,x.ColorPicker=Qe,x.Column=yt,x.CommandPalette=bl,x.ConfirmDialog=pt,x.ConfirmPopup=nl,x.ContextMenu=kt,x.DataTable=gt,x.DataView=bt,x.DatePicker=ue,x.Deferred=$e,x.DeferredContent=$e,x.Dialog=v,x.Divider=ve,x.Dock=Xt,x.Drawer=ge,x.Dropdown=pe,x.DynamicDialog=yl,x.Editor=It,x.Fieldset=At,x.FileUpload=il,x.FloatLabel=Lt,x.Fluid=Ut,x.Form=El,x.FormField=$l,x.Galleria=rl,x.IconField=Mt,x.IftaLabel=Tt,x.Image=ot,x.ImageCompare=pl,x.ImageCropper=Le,x.InfiniteScroll=Bl,x.InlineMessage=al,x.Inplace=ol,x.Input=fe,x.InputChips=Ve,x.InputGroup=Nt,x.InputGroupAddon=St,x.InputIcon=Dt,x.InputMask=xt,x.InputNumber=qe,x.InputOtp=Ct,x.InputSwitch=Q,x.InputText=fe,x.KeyFilter=Ch,x.Knob=Et,x.Listbox=zt,x.MegaMenu=Yt,x.Mentions=_l,x.Menu=Ht,x.Menubar=Be,x.Message=he,x.MeterGroup=ll,x.Modal=v,x.MultiSelect=Xe,x.Navbar=Be,x.OrderList=Jt,x.OrganizationChart=el,x.OverlayBadge=fl,x.OverlayPanel=ye,x.Pagination=se,x.Paginator=se,x.Panel=Ft,x.PanelMenu=qt,x.Password=Ye,x.PickList=Qt,x.Popover=ye,x.Portal=ul,x.ProgressBar=dt,x.ProgressSpinner=ct,x.RadioButton=Me,x.RadioButtonGroup=hl,x.Rating=Je,x.ScrollPanel=Ot,x.ScrollTop=ht,x.Select=pe,x.SelectButton=$t,x.Sidebar=ge,x.SignaturePad=wl,x.Skeleton=it,x.SlideMenu=Gt,x.Slider=Ze,x.SpeedDial=Rt,x.SplitButton=Pt,x.Splitter=jt,x.Stepper=we,x.Steps=we,x.Switch=Q,x.THEME_OPTIONS=Ie,x.TabMenu=Zt,x.TabView=_e,x.Tabs=_e,x.Tag=ae,x.Terminal=dl,x.Textarea=Ge,x.TieredMenu=Wt,x.Timeline=tt,x.Toast=st,x.ToggleButton=Vt,x.ToggleSwitch=Q,x.Toolbar=Kt,x.Tooltip=rt,x.TooltipDirective=Re,x.Tree=Bt,x.TreeSelect=wt,x.TreeTable=vt,x.VirtualScroller=tl,x.default=Sh,x.useConfirm=ft,x.useDialog=gl,x.useStyle=hh,x.useTheme=Nl,x.useToast=at,x.vAnimateOnScroll=Rl,x.vBadge=Fe,x.vFocusTrap=Pl,x.vKeyFilter=je,x.vRipple=Ml,x.vStyleClass=Al,x.vTooltip=Re,Object.defineProperties(x,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})}));