feat: badge version dans le header + tag v2.0.0-dev
CI / lint (push) Failing after 9s
CI / test (push) Has been skipped
CI / build (push) Has been skipped
CI / e2e (push) Has been skipped
CI / security (push) Successful in 13s
Desktop Build / build-windows (push) Has been cancelled
Desktop Build / build-linux (push) Has been cancelled

- index.html: <div class="version-badge"> dans header-right
- app.js: fetch /api/health → affiche version dans le badge
- style.css: .version-badge discret (10px, mono, muted)
- Tag: v2.0.0-dev créé → git describe retourne v2.0.0-dev
This commit is contained in:
2026-07-27 18:02:01 -04:00
parent efb59230e7
commit 0cea78b3b1
3 changed files with 27 additions and 0 deletions
+1
View File
@@ -432,6 +432,7 @@
</div>
<!-- User menu (visible when logged in) -->
<div class="user-menu" id="user-menu"></div>
<div class="version-badge" id="version-badge" title="Version ObsiGate"></div>
<div class="header-menu">
<button
class="header-menu-btn"
+11
View File
@@ -104,4 +104,15 @@ async function init() {
document.addEventListener("DOMContentLoaded", () => {
init();
Sync.init();
// Show version in header
fetch('/api/health')
.then(r => r.json())
.then(d => {
const badge = document.getElementById('version-badge');
if (badge && d.version) {
badge.textContent = d.version;
badge.style.display = 'inline-block';
}
})
.catch(() => {});
});
+15
View File
@@ -522,6 +522,21 @@ a:hover {
background: color-mix(in srgb, var(--accent) 10%, transparent);
}
/* Version badge in header */
.version-badge {
display: none;
font-size: 10px;
color: var(--text-muted);
padding: 2px 8px;
border-radius: 10px;
background: color-mix(in srgb, var(--text-muted) 8%, transparent);
border: 1px solid color-mix(in srgb, var(--text-muted) 15%, transparent);
font-family: var(--font-mono, monospace);
white-space: nowrap;
cursor: default;
user-select: none;
}
.header-menu-dropdown {
display: none;
position: absolute;