import{r as s,h as l,e,H as t}from"./p-9babd345.js";import{D as a}from"./p-7c38a70b.js";const i=class{constructor(l){s(this,l),this.isOpen=!0}hostData(){return{class:"sparkle-menu-collapsible--status-open",role:"button",tabindex:"0","aria-label":"Collapsible Menu"}}toggle(){this.isOpen=!this.isOpen,r(this.el,"sparkle-menu-collapsible--status-"),this.el.classList.add("sparkle-menu-collapsible--status-"+(this.isOpen?"open":"closed"))}__stencil_render(){return[l("a",{onClick:()=>this.toggle(),class:"sparkle-menu-collapsible__title"},this.heading,l(a,null)),l("div",{class:"sparkle-menu-collapsible__contents"},l("slot",null))]}get el(){return e(this)}render(){return l(t,this.hostData(),this.__stencil_render())}},r=(s,l)=>{s.classList.forEach((e=>{e.startsWith(l)&&s.classList.remove(e)}))};i.style="collapsible{}";export{i as sparkle_menu_collapsible}