feat: add version footer to dashboard UI (v1.2.1)

- /health endpoint now includes version field
- Footer displays 'sofarr vX.Y.Z' fetched on page load
- Subtle .app-version styling (smaller, dimmed)
- Bump version to 1.2.1, update CHANGELOG
This commit is contained in:
2026-05-17 20:34:59 +01:00
parent ad024ab87b
commit 6a8ca90fd3
6 changed files with 30 additions and 3 deletions

View File

@@ -27,13 +27,25 @@ document.addEventListener('DOMContentLoaded', () => {
initThemeSwitcher();
initTabs();
initHistoryControls();
loadAppVersion();
document.getElementById('login-form').addEventListener('submit', handleLogin);
document.getElementById('logout-btn').addEventListener('click', handleLogout);
document.getElementById('show-all-toggle').addEventListener('change', handleShowAllToggle);
document.getElementById('status-btn').addEventListener('click', toggleStatusPanel);
});
function loadAppVersion() {
fetch('/health')
.then(r => r.json())
.then(data => {
if (data.version) {
document.getElementById('app-version').textContent = `sofarr v${data.version}`;
}
})
.catch(() => {});
}
function initThemeSwitcher() {
const saved = localStorage.getItem('sofarr-theme') || 'light';
document.querySelectorAll('.theme-btn').forEach(btn => {