diff --git a/frontend/build.mjs b/frontend/build.mjs index 75a21d6..86504a8 100644 --- a/frontend/build.mjs +++ b/frontend/build.mjs @@ -71,6 +71,10 @@ for (const f of fs.readdirSync('js')) { fs.copyFileSync(`js/${f}`, `${dist}/js/${f}`) } } +// Service Worker doit être servi depuis la racine pour avoir le bon scope +if (fs.existsSync('js/ws.sw.js')) { + fs.copyFileSync('js/ws.sw.js', `${dist}/ws.sw.js`) +} // 5. Copy CSS for (const f of fs.readdirSync('css')) { diff --git a/frontend/css/neu.css b/frontend/css/neu.css index c4e950a..620d7e3 100644 --- a/frontend/css/neu.css +++ b/frontend/css/neu.css @@ -78,7 +78,7 @@ input, select, textarea { font-family: inherit; font-size: inherit; } /* Sidebar */ --sidebar-width: 240px; - --sidebar-width-collapsed: 64px; + --sidebar-width-collapsed: 52px; /* Z-index */ --z-sidebar: 100; @@ -215,6 +215,14 @@ input, select, textarea { font-family: inherit; font-size: inherit; } border-radius: var(--neu-radius-md); } +/* Bouton icône carré taille sm — se déclenche automatiquement si le bouton + ne contient qu'un (ex: theme, logout, edit mode) */ +.neu-btn--sm:has(> i:only-child) { + width: 2rem; + height: 2rem; + padding: 0; +} + .neu-btn--ghost { background: transparent; box-shadow: none; @@ -423,6 +431,12 @@ input, select, textarea { font-family: inherit; font-size: inherit; } width: var(--sidebar-width-collapsed); } +.sidebar.collapsed .sidebar-link { + justify-content: center; + padding-left: 0; + padding-right: 0; +} + .sidebar-header { display: flex; align-items: center; @@ -619,3 +633,13 @@ html.is-animating .transition-fade { margin-right: var(--sidebar-width-collapsed); } } + +/* ── Couleurs icônes contextuelles ─────────────────────────────────────────── */ + +/* Navbar : logout, thème, édition */ +.navbar .lnid-power-button { color: var(--neu-danger); } +.navbar .lnid-sun-1 { color: #f59e0b; } +.navbar .lnid-moon-half-left-1 { color: #60a5fa; } + +/* Sidebar footer : utilisateur */ +.sidebar-footer .sidebar-icon { color: var(--neu-primary); } diff --git a/frontend/css/pages.css b/frontend/css/pages.css index 424d76a..1fb9cde 100644 --- a/frontend/css/pages.css +++ b/frontend/css/pages.css @@ -621,6 +621,7 @@ transition: color .15s; } .widget-panel-toggle:hover { color: var(--neu-primary); } +.widget-panel-item.is-visible .widget-panel-toggle { color: var(--neu-success); } /* Resize handle (coin bas-droit de la tuile, edit mode) */ .widget-resize-handle { diff --git a/frontend/dashboard.html b/frontend/dashboard.html index 7d98c9b..76b29b7 100644 --- a/frontend/dashboard.html +++ b/frontend/dashboard.html @@ -25,7 +25,7 @@