Watch
0
0
Fork
You've already forked hyperhive
0
hyperhive/frontend
Repository files (latest commit first)
Filename Latest commit message Latest commit date
iris 7707a257e9 hive ui: the dashboard wears the swarm UI's chrome, and its own header, tab strip and menu mounts go
The dashboard mounts @hive/shared's AppShell, the header, nav and settings menu the swarm UI has, from a new shell.js: the hive's name for the brand, the tabs agents, rebuild queue and kept state routed by the URL hash, the theme, motion and solid-background settings in this page's own browser storage, and the shared links and user menus. The three tab panes stay plain DOM, kept hidden in index.html and moved into the shell's content column by shell.js. The tabs, the hash-to-tab parse and the menu entries sit in shell-routes.js, which npm test covers (the dashboard package gets a test script). The old header, the createTabStrip tabbar, the leet tab names, the identity headline and title code, the sticky-top wrapper, the links-menu.js and user-menu.js mounts and their CSS are removed. The docs say the plain tab names and the new chrome.
2026-11-21 10:47:37 +01:00
..
packages hive ui: the dashboard wears the swarm UI's chrome, and its own header, tab strip and menu mounts go 2026-11-21 10:47:37 +01:00
.gitignore frontend: add npm workspace scaffold under frontend/ 2026-05-23 14:51:01 +02:00
npm-deps-hash remove the agent's stats page and its endpoint 2026-11-16 19:00:52 +01:00
package-lock.json remove the agent's stats page and its endpoint 2026-11-16 19:00:52 +01:00
package.json frontend: root test and typecheck scripts, and tests for the review runs wording and the terminal drag 2026-11-20 00:28:04 +01:00
README.md frontend: the swarm UI's page chrome moves to @hive/shared as AppShell 2026-11-21 10:46:53 +01:00

hyperhive frontend

npm workspaces project for the hyperhive browser-facing assets:

  • packages/shared/ — shared modules used by every surface (terminal pane, Catppuccin palette + body typography, the AppShell page chrome the swarm UI mounts).
  • packages/dashboard/ — the hive-c0re dashboard SPA.
  • packages/agent/ — the per-container web pages (stats, screen).
  • packages/swarm-ui/ — the swarm-level operator UI shell (hives, agents, jobs, issue-report pages).

Build

npm install            # one-off; uses the checked-in package-lock.json
npm run build          # builds every workspace into packages/*/dist/

The Rust binaries serve packages/dashboard/dist/ and packages/agent/dist/ via tower_http::ServeDir at runtime; nix/packages/frontend.nix wires up the build derivation. The services.hyperhive.agent.frontend.extraFiles option in agent.nix layers per-agent additions on top of the default agent dist.

Why npm + esbuild

  • Hermetic: dependencies vendored via the checked-in lockfile; buildNpmPackage in nix uses it as the source-of-truth so the output is reproducible without network access at build time.
  • esbuild: agent and swarm-ui are Preact apps; dashboard is a vanilla-JS + custom-element MPA with a few Preact-rendered pages (builds.js, agents.js, imported by the dashboard entry); shared holds both kinds of module. No framework runtime beyond Preact where it's used. Each workspace's build.mjs is a short esbuild script.
  • Single-PR migration: see the tracked design proposal and the four-commit shape (npm scaffold → nix derivations → container plumbing → Rust cutover).