Initial scaffold: FastAPI server, responsive UI shell

This commit is contained in:
2026-06-01 23:44:10 -04:00
commit 049edc0238
8 changed files with 204 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
// Command Center SPA Router
const sections = document.querySelectorAll('.panel');
const links = document.querySelectorAll('.nav-links a');
function navigate(hash) {
const target = hash.replace('#', '') || 'agents';
sections.forEach(s => s.hidden = s.id !== target);
links.forEach(l => l.classList.toggle('active', l.getAttribute('href') === '#' + target));
}
links.forEach(l => l.addEventListener('click', e => {
e.preventDefault();
window.location.hash = l.getAttribute('href');
}));
window.addEventListener('hashchange', () => navigate(window.location.hash));
navigate(window.location.hash || '#agents');