Phase 1 of stylix integration (#1457): extract the Catppuccin palette into a dedicated, separately-linked stylesheet so a theme swap can replace just that file without rebuilding the rest of the frontend. - shared/src/theme.css (new): the `:root` palette, moved out of base.css (which now holds only the body typography it references). - shared/package.json: export `./theme.css`. - dashboard/src/theme.css + agent/src/theme.css (new): one-line re-exports of @hive/shared/theme.css so each package's esbuild emits its own standalone `dist/static/theme.css` (palette is NOT inlined into the page bundles). - both build.mjs: add theme.css to the CSS build list. - every page (dashboard index/flow/logs, agent index/stats/screen): link `theme.css` first, ahead of the page CSS, so the `:root` vars resolve for everything. - docs/web-ui/css-vars.md: document the split + the no-rebuild rationale. Behaviour-neutral — same colours, just relocated. Verified both `npm run build` outputs: theme.css emits standalone (383b) with the palette; no `--*` palette defs duplicated into common.css/agent.css. Phase 2 (nix derivation that swaps theme.css from stylix colours) is a follow-up; touches nix/frontend.nix, coordinating with damocles. Part of #1457.
83 lines
3.5 KiB
HTML
83 lines
3.5 KiB
HTML
<!doctype html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="utf-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<title>hyperhive // LOGS</title>
|
|
<link rel="icon" type="image/svg+xml" href="/favicon.svg">
|
|
<link rel="stylesheet" href="/static/theme.css">
|
|
<link rel="stylesheet" href="/static/common.css">
|
|
<link rel="stylesheet" href="/static/logs.css">
|
|
</head>
|
|
<body class="logs-shell">
|
|
|
|
<!-- Minimal chrome: back link + sub-tab strip.
|
|
Same pattern as flow.html — no full dashboard tabbar. -->
|
|
<header class="logs-header">
|
|
<a class="logs-back" href="/">← dashboard</a>
|
|
<nav class="logs-tabbar" id="logs-tabbar" role="tablist">
|
|
<a class="logs-tab" id="logs-tab-build" href="#build" role="tab"
|
|
aria-controls="logs-pane-build" data-logs-tab="build">
|
|
<span class="logs-tab-label">BUILD</span>
|
|
</a>
|
|
<a class="logs-tab" id="logs-tab-agent" href="#agent" role="tab"
|
|
aria-controls="logs-pane-agent" data-logs-tab="agent">
|
|
<span class="logs-tab-label">AGENT</span>
|
|
</a>
|
|
<a class="logs-tab" id="logs-tab-system" href="#system" role="tab"
|
|
aria-controls="logs-pane-system" data-logs-tab="system">
|
|
<span class="logs-tab-label">SYSTEM</span>
|
|
</a>
|
|
</nav>
|
|
</header>
|
|
|
|
<main class="logs-main">
|
|
|
|
<!-- BUILD: all-agents build log history. Lists recent nix build /
|
|
nixos-container invocations across all agents, with
|
|
click-to-expand full stdout+stderr. Backed by
|
|
GET /api/build-logs?limit=30. -->
|
|
<section class="logs-pane" id="logs-pane-build"
|
|
role="tabpanel" aria-labelledby="logs-tab-build">
|
|
<div class="logs-toolbar">
|
|
<button type="button" class="btn btn-restart" id="build-refresh">↻ refresh</button>
|
|
</div>
|
|
<div id="build-list"><p class="meta">loading…</p></div>
|
|
</section>
|
|
|
|
<!-- AGENT: journald viewer for a specific agent container.
|
|
Agent selector + unit filter + line count. Backed by
|
|
GET /api/journal/{agent}?unit=<unit>&lines=N. -->
|
|
<section class="logs-pane" id="logs-pane-agent"
|
|
role="tabpanel" aria-labelledby="logs-tab-agent">
|
|
<div class="logs-toolbar">
|
|
<select id="agent-select" class="journal-unit"></select>
|
|
<select id="agent-unit-select" class="journal-unit">
|
|
<option value="hive-ag3nt.service">hive-ag3nt.service</option>
|
|
<option value="">(full machine journal)</option>
|
|
</select>
|
|
<button type="button" class="btn btn-restart" id="agent-refresh">↻ refresh</button>
|
|
<span id="agent-fetch-ts" class="meta logs-fetch-ts" hidden></span>
|
|
</div>
|
|
<pre id="agent-output" class="journal-output">select an agent above</pre>
|
|
</section>
|
|
|
|
<!-- SYSTEM: host-side service logs. Shows the hive-c0re daemon
|
|
journal via GET /api/journal-host?unit=hive-c0re.service. -->
|
|
<section class="logs-pane" id="logs-pane-system"
|
|
role="tabpanel" aria-labelledby="logs-tab-system">
|
|
<div class="logs-toolbar">
|
|
<select id="system-unit-select" class="journal-unit">
|
|
<option value="hive-c0re.service">hive-c0re.service</option>
|
|
</select>
|
|
<button type="button" class="btn btn-restart" id="system-refresh">↻ refresh</button>
|
|
<span id="system-fetch-ts" class="meta logs-fetch-ts" hidden></span>
|
|
</div>
|
|
<pre id="system-output" class="journal-output">loading…</pre>
|
|
</section>
|
|
|
|
</main>
|
|
|
|
<script type="module" src="/static/logs.js" defer></script>
|
|
</body>
|
|
</html>
|