1
0

feat(ui): wire WebSocket live feed into HTMX dashboard

- Fix swarm_live.html WebSocket URL from /swarm/ws to /swarm/live
  (matching the actual endpoint in swarm_ws.py)
- Update handleMessage() to process individual swarm events
  (agent_joined, task_posted, bid_submitted, task_assigned, etc.)
  in addition to bulk state snapshots
- Add refreshStats() helper that fetches /swarm REST endpoint to
  update stat counters after each event
- Add GET /swarm/live page route to render the swarm_live.html template
- Add SWARM and MOBILE navigation links to base.html header
  (fixes UX-01: /mobile route not in desktop nav)
This commit is contained in:
Manus AI
2026-02-21 13:43:42 -05:00
parent ee45a16267
commit ccfe2717ed
3 changed files with 46 additions and 7 deletions

View File

@@ -21,6 +21,8 @@
<span class="mc-subtitle">MISSION CONTROL</span>
</div>
<div class="mc-header-right">
<a href="/swarm/live" class="mc-test-link">SWARM</a>
<a href="/mobile" class="mc-test-link">MOBILE</a>
<a href="/mobile-test" class="mc-test-link">TEST</a>
<span class="mc-time" id="clock"></span>
</div>