class MonthAccordion extends HTMLElement { constructor() { super(); this.isOpen = false; } connectedCallback() { this.attachShadow({ mode: 'open' }); this.render(); this.addEventListener('click', this.toggle.bind(this)); } toggle() { this.isOpen = !this.isOpen; this.render(); } render() { const month = this.getAttribute('month') || 'Monat'; this.shadowRoot.innerHTML = `