Spaces:
Running
Running
l'horloge est legerement décalée. le 1 a la place du 12 etc... remplacer les formules par des equations tres simples
30d8d56
verified
| class CustomNavbar extends HTMLElement { | |
| connectedCallback() { | |
| this.attachShadow({ mode: 'open' }); | |
| this.shadowRoot.innerHTML = ` | |
| <style> | |
| nav { | |
| background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%); | |
| padding: 1rem 2rem; | |
| display: flex; | |
| justify-content: space-between; | |
| align-items: center; | |
| box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); | |
| } | |
| .logo { | |
| color: white; | |
| font-weight: bold; | |
| font-size: 1.25rem; | |
| display: flex; | |
| align-items: center; | |
| gap: 0.5rem; | |
| } | |
| ul { | |
| display: flex; | |
| gap: 1.5rem; | |
| list-style: none; | |
| margin: 0; | |
| padding: 0; | |
| } | |
| a { | |
| color: white; | |
| text-decoration: none; | |
| transition: opacity 0.2s; | |
| font-weight: 500; | |
| display: flex; | |
| align-items: center; | |
| gap: 0.25rem; | |
| } | |
| a:hover { | |
| opacity: 0.8; | |
| text-decoration: underline; | |
| } | |
| </style> | |
| <nav> | |
| <div class="logo"> | |
| <i data-feather="clock"></i> | |
| <span>MathClock</span> | |
| </div> | |
| <ul> | |
| <li><a href="/"><i data-feather="home"></i> Home</a></li> | |
| <li><a href="#"><i data-feather="info"></i> About</a></li> | |
| </ul> | |
| </nav> | |
| `; | |
| } | |
| } | |
| customElements.define('custom-navbar', CustomNavbar); |