import{D as e,E as t,L as n,M as r,P as i,R as a,T as o,V as s,W as c,_ as l,b as u,f as d,ft as f,it as p,l as m,n as h,nt as g,ot as _,q as v,r as y,st as b,t as x,v as S}from"../../client.js";import{c as C}from"../../components.js";import"../builtinmenu/BuiltInMenu.js";import"../builtinmenuitem/BuiltInMenuItem.js";var w=i(`<span slot="icon"><!></span>`),T=i(`<m-built-in-menu-item><!></m-built-in-menu-item>`,2),E=i(`<m-built-in-menu></m-built-in-menu>`,2),D={hash:`svelte-1k60ooz`,code:`/**
 * Do not edit directly, this file was auto-generated.
 */.mc-check-list-menu__icon.svelte-1k60ooz {fill:var(--built-in-menu-color-text-default, #404040);}.mc-check-list-menu__icon--selected.svelte-1k60ooz {fill:var(--built-in-menu-color-text-selected, #006902);}`};function O(n,i){b(i,!0),u(n,D);let x=h(i,`selected`,15),O=h(i,`items`,7),k=h(i,`outlined`,7),A=h(i,`class`,7),j=y(i,[`$$slots`,`$$events`,`$$legacy`,`$$host`,`selected`,`items`,`outlined`,`class`]);var M={get selected(){return x()},set selected(e){x(e),p()},get items(){return O()},set items(e){O(e),p()},get outlined(){return k()},set outlined(e){k(e),p()},get class(){return A()},set class(e){A(e),p()}},N=E();return m(N,()=>({selected:x(),outlined:k(),class:A(),...j}),void 0,void 0,void 0,`svelte-1k60ooz`),o(N,21,O,t,(t,n,i)=>{let o=g(()=>s(n).href?`a`:`button`);var u=T();d(u,`slot`,`item`),c(()=>d(u,`label`,s(n).label)),c(()=>d(u,`href`,s(n).href)),c(()=>d(u,`target`,s(n).target)),c(()=>d(u,`selected`,x()===i)),c(()=>d(u,`role`,s(o)===`button`?`menuitem`:void 0));var p=v(u),m=e=>{var t=w();C(v(t),{}),f(t),c(()=>l(t,1,S({"mc-check-list-menu__icon":!0,"mc-check-list-menu__icon--selected":x()===i}),`svelte-1k60ooz`)),r(e,t)};e(p,e=>{s(n).checked&&e(m)}),f(u),a(`click`,u,()=>x(i)),r(t,u)}),f(N),r(n,N),_(M)}n([`click`]),customElements.define(`m-check-list-menu`,x(O,{selected:{attribute:`selected`,reflect:!0,type:`Number`},outlined:{attribute:`outlined`,reflect:!0,type:`Boolean`},items:{},class:{}},[],[],{mode:`open`}));
//# sourceMappingURL=CheckListMenu.js.map