class ModuleCard extends HTMLElement { static get observedAttributes() { return ['title', 'icon', 'description', 'status', 'action']; } connectedCallback() { this.attachShadow({ mode: 'open' }); this.render(); } attributeChangedCallback(name, oldValue, newValue) { if (oldValue !== newValue) { this.render(); } } render() { const title = this.getAttribute('title') || 'Module'; const icon = this.getAttribute('icon') || 'box'; const description = this.getAttribute('description') || 'No description provided'; const status = this.getAttribute('status') || 'inactive'; const action = this.getAttribute('action') || 'configure'; const statusColors = { active: 'bg-green-500', inactive: 'bg-gray-500', ready: 'bg-blue-500', error: 'bg-red-500' }; const actionTexts = { configure: 'Configure', launch: 'Launch', monitor: 'Monitor', execute: 'Execute' }; this.shadowRoot.innerHTML = `

${title}

${description}

`; feather.replace(); } } customElements.define('module-card', ModuleCard);