Spaces:
Configuration error
Configuration error
| class CustomHeader extends HTMLElement { | |
| connectedCallback() { | |
| this.attachShadow({ mode: 'open' }); | |
| this.shadowRoot.innerHTML = ` | |
| <style> | |
| :host { | |
| display: block; | |
| background: #ffffff; | |
| padding: 1rem 2rem; | |
| border-bottom: 1px solid #e2e8f0; | |
| box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); | |
| } | |
| .header-content { | |
| display: flex; | |
| justify-content: space-between; | |
| align-items: center; | |
| max-width: 1200px; | |
| margin: 0 auto; | |
| } | |
| .logo { | |
| font-weight: 700; | |
| font-size: 1.25rem; | |
| color: #1e40af; | |
| } | |
| .nav-links { | |
| display: flex; | |
| gap: 1.5rem; | |
| } | |
| .nav-link { | |
| color: #4b5563; | |
| text-decoration: none; | |
| font-weight: 500; | |
| } | |
| .nav-link:hover { | |
| color: #1e40af; | |
| } | |
| </style> | |
| <div class="header-content"> | |
| <div class="logo">Rosalinda IA</div> | |
| <div class="nav-links"> | |
| <a href="#" class="nav-link">Accueil</a> | |
| <a href="#" class="nav-link" data-target="code-editor">Éditeur</a> | |
| <a href="#" class="nav-link" data-target="rosalinda-chat">Chat</a> | |
| <a href="#" class="nav-link">Contact</a> | |
| </div> | |
| </div> | |
| `; | |
| } | |
| } | |
| customElements.define('custom-header', CustomHeader); |