geneseed 4.9.1 → 4.9.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +30 -0
- package/SHIPPED.md +1 -1
- package/adapters/opencode/plugins/geneseed-context.js +7 -1
- package/adapters/opencode/plugins/geneseed-guard.js +123 -12
- package/adapters/opencode/plugins/geneseed-learn.js +7 -1
- package/docs/concepts/enforcement-table.md +1 -1
- package/docs/concepts/exclusions.md +1 -2
- package/docs/concepts/hooks.md +3 -2
- package/docs/guides/upgrade.md +1 -1
- package/harness.config.json +1 -1
- package/js/README.md +30 -9
- package/js/build/args.mjs +9 -8
- package/js/build/driver.mjs +21 -21
- package/js/build/emit-claude.mjs +3 -3
- package/js/build/generate.mjs +4 -5
- package/js/build/source.mjs +18 -22
- package/js/hosts/gitref.mjs +5 -3
- package/js/hosts/hooks-done.mjs +21 -9
- package/js/hosts/hooks-learn.mjs +23 -10
- package/js/hosts/hooks-prims.mjs +25 -0
- package/js/hosts/hooks.mjs +19 -4
- package/js/hosts/installs.mjs +5 -4
- package/js/hosts/loss.mjs +98 -0
- package/js/hosts/native.mjs +3 -1
- package/js/hosts/owned.mjs +34 -6
- package/js/hosts/settings.mjs +6 -5
- package/js/inspect/checks-probe.mjs +1 -1
- package/js/inspect/cost.mjs +37 -5
- package/js/inspect/diff.mjs +154 -64
- package/js/inspect/validate.mjs +2 -2
- package/js/lib/fs.mjs +73 -2
- package/js/maintain/setup.mjs +31 -7
- package/js/maintain/uninstall.mjs +1 -1
- package/js/maintain/update.mjs +1 -1
- package/js/web/actions.mjs +36 -3
- package/js/web/api.mjs +17 -6
- package/js/web/handler.mjs +4 -16
- package/js/web/jobs.mjs +5 -3
- package/js/web/state.mjs +3 -0
- package/package.json +1 -1
- package/web/dist/assets/{Activity-GQGAZHIE.js → Activity-C8sZVIUU.js} +1 -1
- package/web/dist/assets/{ActivityDetail-DktWyxim.js → ActivityDetail-Cc6vWUS4.js} +1 -1
- package/web/dist/assets/Dashboard-C5ATa3ow.js +2 -0
- package/web/dist/assets/{Docs-CsWYLnN1.js → Docs-tDW7i7mo.js} +3 -3
- package/web/dist/assets/GreenhouseView-zk2Uzc3A.js +2 -0
- package/web/dist/assets/Installs-CB_rvbBP.js +3 -0
- package/web/dist/assets/JournalView-Bfj27XHC.js +1 -0
- package/web/dist/assets/Laws-BA3CzUf5.js +3 -0
- package/web/dist/assets/Library-BWwiy9Vb.js +1 -0
- package/web/dist/assets/{Loops-BUBOeM0C.js → Loops-DaPk-ckL.js} +2 -2
- package/web/dist/assets/{OperatorHudView-BJuCYsjf.js → OperatorHudView-CyiGhiHk.js} +1 -1
- package/web/dist/assets/Personal-Bwd27CmT.js +1 -0
- package/web/dist/assets/{Tabs-GPQlocTw.js → Tabs-BOD7Kaz1.js} +1 -1
- package/web/dist/assets/drawable-CyLe1gtW.js +1 -0
- package/web/dist/assets/index-DQXG_mqo.js +2 -0
- package/web/dist/index.html +1 -1
- package/web/src/pages/Laws.jsx +60 -353
- package/web/dist/assets/Dashboard-CmSn6JfK.js +0 -2
- package/web/dist/assets/GreenhouseView-Dt_cIxAY.js +0 -2
- package/web/dist/assets/Installs-CWuUU4I3.js +0 -2
- package/web/dist/assets/JournalView-ClbZj_YF.js +0 -1
- package/web/dist/assets/Laws-R5zZCmya.js +0 -3
- package/web/dist/assets/Library-u36V7oSD.js +0 -1
- package/web/dist/assets/Personal-DWQuSAUz.js +0 -1
- package/web/dist/assets/drawable-CE-arUnF.js +0 -1
- package/web/dist/assets/index-3lnPT_1J.js +0 -2
package/js/maintain/setup.mjs
CHANGED
|
@@ -46,13 +46,13 @@ import path from 'node:path';
|
|
|
46
46
|
|
|
47
47
|
import { main as driverMain, resolveOut } from '../build/driver.mjs';
|
|
48
48
|
import { playLine } from '../ui/anim.mjs';
|
|
49
|
-
import { discoverNames, PACK_ORDER } from '../build/source.mjs';
|
|
49
|
+
import { discoverNames, GATE_SWITCHES, PACK_ORDER } from '../build/source.mjs';
|
|
50
50
|
import { exportImprovements } from '../inspect/diff.mjs';
|
|
51
51
|
import { cmdDoctor } from '../inspect/doctor.mjs';
|
|
52
52
|
import { setupBuildArgs } from '../build/generate.mjs';
|
|
53
53
|
import { GLOBAL_MANIFEST, HOSTS, opencodeConfigDir } from '../hosts/hosts.mjs';
|
|
54
54
|
import {
|
|
55
|
-
claudeCfg, defaultMode, defaultPosture, defaultTheme, EMIT_HOST_SCOPE, installedDefaults,
|
|
55
|
+
claudeCfg, defaultMode, defaultPosture, defaultTheme, EMIT_HOST_SCOPE, gatesOfDir, installedDefaults,
|
|
56
56
|
readJsonMaybe, themeFiles,
|
|
57
57
|
} from '../hosts/installs.mjs';
|
|
58
58
|
import { printOut, printErr } from '../lib/fs.mjs';
|
|
@@ -242,6 +242,24 @@ function askDoctrines(deployed = null) {
|
|
|
242
242
|
* whole, `null` included, because `askDoctrines` distinguishes "no carrier said" from "a
|
|
243
243
|
* carrier said none" and the two open the question differently.
|
|
244
244
|
*/
|
|
245
|
+
/**
|
|
246
|
+
* The gate switches of the one install a setup answer re-runs: the chosen emit's global config
|
|
247
|
+
* dir, or the project/bundle root it names. Never another host's install — carrying its `off`
|
|
248
|
+
* across would disarm a gate nobody switched off here. FAILS CLOSED: no install there, or a dir
|
|
249
|
+
* that cannot be resolved, reads as all armed (`gatesOfDir` already fails closed per line).
|
|
250
|
+
*/
|
|
251
|
+
function targetGates(emit, out) {
|
|
252
|
+
const [host, scope] = EMIT_HOST_SCOPE.get(emit) ?? [];
|
|
253
|
+
try {
|
|
254
|
+
if (!host) return gatesOfDir(resolveOut(out || 'Harness'));
|
|
255
|
+
const dir = scope === 'global'
|
|
256
|
+
? HOSTS.find((h) => h.host === host).configDir() : resolveOut(out || '.');
|
|
257
|
+
return gatesOfDir(dir, host);
|
|
258
|
+
} catch {
|
|
259
|
+
return Object.fromEntries(GATE_SWITCHES.map((g) => [g.key, true]));
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
|
|
245
263
|
export function collectSetupLines() {
|
|
246
264
|
printOut('Geneseed setup — answer a few questions; nothing is written until you confirm.\n');
|
|
247
265
|
const inst = installedDefaults();
|
|
@@ -279,14 +297,20 @@ export function collectSetupLines() {
|
|
|
279
297
|
const excludeRules = inst.excludeRules?.length ? inst.excludeRules : null;
|
|
280
298
|
// Skills left out are preserved the same way, and elide when there are none.
|
|
281
299
|
const excludeSkills = inst.excludeSkills?.length ? inst.excludeSkills : null;
|
|
300
|
+
// The gate switches too: a re-run that dropped them would re-arm every gate its owner switched
|
|
301
|
+
// off. Read off the install THIS answer targets, never the machine walk above (`targetGates`).
|
|
302
|
+
// `setupBuildArgs` elides an armed gate, so an all-armed install prints what it always did.
|
|
303
|
+
const gates = targetGates(emit, out);
|
|
304
|
+
const gated = Object.values(gates).some((on) => on === false);
|
|
282
305
|
printOut(`\nAbout to run: geneseed build ${
|
|
283
306
|
setupBuildArgs(theme, emit, out, root, footprint, posture, mode, doctrines, allPacks,
|
|
284
|
-
excludeRules, undefined, excludeSkills).join(' ')}\n`);
|
|
307
|
+
excludeRules, undefined, excludeSkills, gates).join(' ')}\n`);
|
|
285
308
|
if (!confirm('Proceed?', true)) return null;
|
|
286
|
-
// The key only when there is something to carry, so a selection that excludes no skill
|
|
287
|
-
// the same object it was before
|
|
309
|
+
// The key only when there is something to carry, so a selection that excludes no skill and
|
|
310
|
+
// switches off no gate is the same object it was before either existed.
|
|
288
311
|
return {
|
|
289
312
|
theme, posture, mode, doctrines, excludeRules, ...(excludeSkills ? { excludeSkills } : {}),
|
|
313
|
+
...(gated ? { gates } : {}),
|
|
290
314
|
emit, out, root, footprint,
|
|
291
315
|
};
|
|
292
316
|
}
|
|
@@ -470,7 +494,7 @@ export function setupLines() {
|
|
|
470
494
|
}
|
|
471
495
|
const {
|
|
472
496
|
theme, emit, out, root, footprint = 'lean', posture = 'peer', mode = 'direct',
|
|
473
|
-
doctrines = null, excludeRules = null, excludeSkills = null,
|
|
497
|
+
doctrines = null, excludeRules = null, excludeSkills = null, gates = {},
|
|
474
498
|
} = sel;
|
|
475
499
|
if (emit === 'opencode-global') {
|
|
476
500
|
// The build below overwrites the deployed global harness, and the self-improvement loops
|
|
@@ -489,7 +513,7 @@ export function setupLines() {
|
|
|
489
513
|
// runs must carry the pack selection the plan line just previewed, or the wizard would print
|
|
490
514
|
// one command and run another.
|
|
491
515
|
const argv = setupBuildArgs(theme, emit, out, root, footprint, posture, mode, doctrines,
|
|
492
|
-
doctrineOptions().map(([n]) => n), excludeRules, undefined, excludeSkills);
|
|
516
|
+
doctrineOptions().map(([n]) => n), excludeRules, undefined, excludeSkills, gates);
|
|
493
517
|
printOut(`Running: geneseed build ${argv.join(' ')}\n`);
|
|
494
518
|
const rc = driverMain(argv);
|
|
495
519
|
if (rc !== 0) {
|
|
@@ -1179,7 +1179,7 @@ function remergeClaudeHooks(cfg, root = cfg, host = 'claude') {
|
|
|
1179
1179
|
const gates = Object.fromEntries(Object.keys(atRoot).map((k) => [k, atRoot[k] && atCfg[k]]));
|
|
1180
1180
|
const [, claims] = mergeClaudeSettings(settingsFile(cfg, managed),
|
|
1181
1181
|
managed.settings_hooks ?? null, hookRunnerEntry(), doctrines, excluded, host, cfg,
|
|
1182
|
-
gates
|
|
1182
|
+
gates);
|
|
1183
1183
|
// `and data` — a manifest that did not parse is not one to write back.
|
|
1184
1184
|
if (!deepEquals(claims, managed.settings_hooks ?? null) && Object.keys(data).length > 0) {
|
|
1185
1185
|
managed.settings_hooks = claims;
|
package/js/maintain/update.mjs
CHANGED
|
@@ -632,7 +632,7 @@ export async function installAxes(dir, { installProfile, setupBuildArgs }, notif
|
|
|
632
632
|
if (legacyProcessCarrierOfDir(String(dir), 'opencode')) return null;
|
|
633
633
|
const p = installProfile('opencode', 'global', String(dir), notify);
|
|
634
634
|
return setupBuildArgs('', 'files', null, null, p.footprint, p.posture, p.mode, p.doctrines,
|
|
635
|
-
undefined, p.excludeRules, p.trust, p.excludeSkills, p
|
|
635
|
+
undefined, p.excludeRules, p.trust, p.excludeSkills, p).slice(4);
|
|
636
636
|
}
|
|
637
637
|
|
|
638
638
|
/**
|
package/js/web/actions.mjs
CHANGED
|
@@ -38,7 +38,7 @@ import {
|
|
|
38
38
|
} from '../build/source.mjs';
|
|
39
39
|
import { withStdoutSwallowed } from '../inspect/diff.mjs';
|
|
40
40
|
import { excludeAdd, excludeRemove } from '../inspect/excludes.mjs';
|
|
41
|
-
import { setupBuildArgs } from '../build/generate.mjs';
|
|
41
|
+
import { installProfile, setupBuildArgs } from '../build/generate.mjs';
|
|
42
42
|
import { DEFAULT_PRESET, PRESETS } from '../loop/score.mjs';
|
|
43
43
|
import { activeLoops, setLoopPreset } from '../loop/registry.mjs';
|
|
44
44
|
import {
|
|
@@ -61,6 +61,7 @@ import { stripWhitespace } from '../lib/text.mjs';
|
|
|
61
61
|
import { memoryDelete } from '../maintain/memory.mjs';
|
|
62
62
|
import { installDeactivate, installReactivate, installUninstall } from '../maintain/uninstall.mjs';
|
|
63
63
|
import { emitChoices, themeChoices, viewCfg } from './api.mjs';
|
|
64
|
+
import { actionCommands } from './jobs.mjs';
|
|
64
65
|
import { NotFound, deployed, memoryDir } from './catalog.mjs';
|
|
65
66
|
|
|
66
67
|
/** One body field, `dflt` when the body is not an object or does not carry the key. */
|
|
@@ -439,6 +440,38 @@ export function buildOverride(state, body) {
|
|
|
439
440
|
return [themes.has(t) ? t : state.theme, emits.has(e) ? e : state.emit];
|
|
440
441
|
}
|
|
441
442
|
|
|
443
|
+
/**
|
|
444
|
+
* The job steps for a Build POST.
|
|
445
|
+
*
|
|
446
|
+
* A DEPLOYED INSTALL REBUILT IN ITS OWN EMIT TAKES THE ARGV ITS PROFILE OWNS (`installProfile`,
|
|
447
|
+
* the one reader `rebuild-all`, `status` and `upgrade` share), with only the theme the picker
|
|
448
|
+
* chose swapped in. This path used to re-assemble the axes it happened to carry — no gate
|
|
449
|
+
* switches, `--exclude-rules none`, no excluded skills — so a console Build silently re-armed
|
|
450
|
+
* every switched-off gate and handed back every rule and skill its owner had left out.
|
|
451
|
+
*
|
|
452
|
+
* Nothing deployed (the first-deploy Onboarding form) or a re-target to another emit has no
|
|
453
|
+
* install of that emit to honour — a re-target is a FRESH target, by decision (2026-10-18), so it
|
|
454
|
+
* deliberately carries none of this install's switches or exclusions — and keeps the defaults it
|
|
455
|
+
* always had: footprint, posture
|
|
456
|
+
* and mode off the viewed dir, and ALL packs when unknown — never `harness.config.json`, which
|
|
457
|
+
* would drop the consent gate.
|
|
458
|
+
*/
|
|
459
|
+
export function buildActionCmds(state, body) {
|
|
460
|
+
const [theme, emit] = buildOverride(state, body);
|
|
461
|
+
const [host, scope] = EMIT_HOST_SCOPE.get(state.emit || '') ?? [];
|
|
462
|
+
if (host && deployed(state) && emit === state.emit) {
|
|
463
|
+
// `setupBuildArgs` always leads with `--theme <theme>`, so the swap is the head alone.
|
|
464
|
+
// `state.root`, not `target`: a project install's markers live at the repo root.
|
|
465
|
+
const [, , ...rest] = installProfile(host, scope, state.root).argv;
|
|
466
|
+
return actionCommands('build', { buildArgv: ['--theme', theme, ...rest] });
|
|
467
|
+
}
|
|
468
|
+
return actionCommands('build', {
|
|
469
|
+
theme, emit, footprint: state.footprint, posture: state.posture, mode: state.mode,
|
|
470
|
+
trust: state.trust,
|
|
471
|
+
doctrines: doctrinesForBuild(state.target),
|
|
472
|
+
});
|
|
473
|
+
}
|
|
474
|
+
|
|
442
475
|
/**
|
|
443
476
|
* The global emit matching a deployed install's `.geneseed-emit`, so the EXPECTED render
|
|
444
477
|
* uses the install's own host dialect.
|
|
@@ -595,7 +628,7 @@ export function apiInstallCmd(state, body) {
|
|
|
595
628
|
const gates = bodyGates(body, root, host);
|
|
596
629
|
const out = scope === 'global' ? null : String(root);
|
|
597
630
|
const argv = setupBuildArgs(theme || 'neutral', emit, out, out, fp, pos, mode, doctrines,
|
|
598
|
-
PACK_ORDER, excludeRules, trust, excludedSkillsOfDir(root, host), gates
|
|
631
|
+
PACK_ORDER, excludeRules, trust, excludedSkillsOfDir(root, host), gates);
|
|
599
632
|
return { cmd: [process.execPath, path.join(ROOT, 'bin', 'build-driver.mjs'), ...argv] };
|
|
600
633
|
}
|
|
601
634
|
|
|
@@ -697,6 +730,6 @@ export function apiDeployCmd(state, body) {
|
|
|
697
730
|
const gates = bodyGates(body, root, host);
|
|
698
731
|
// project-scope emit name == host name (opencode / claude / bob / openclaude)
|
|
699
732
|
const argv = setupBuildArgs(theme || 'neutral', host, root, root, fp, pos, mode, doctrines,
|
|
700
|
-
PACK_ORDER, excludeRules, trust, excludedSkillsOfDir(root, host), gates
|
|
733
|
+
PACK_ORDER, excludeRules, trust, excludedSkillsOfDir(root, host), gates);
|
|
701
734
|
return { cmd: [process.execPath, path.join(ROOT, 'bin', 'build-driver.mjs'), ...argv] };
|
|
702
735
|
}
|
package/js/web/api.mjs
CHANGED
|
@@ -15,7 +15,7 @@ import { CONFIG, ROOT, THEMES, discoverNames, makeCfg } from '../build/source.mj
|
|
|
15
15
|
import { readVersion, sourceFingerprint } from '../build/version.mjs';
|
|
16
16
|
import { sourceReleaseVersion } from '../hosts/opencode.mjs';
|
|
17
17
|
import { alwaysOnCost } from '../inspect/cost.mjs';
|
|
18
|
-
import { diffCollect } from '../inspect/diff.mjs';
|
|
18
|
+
import { diffCollect, renderMemo } from '../inspect/diff.mjs';
|
|
19
19
|
import { excludesSnapshot } from '../inspect/excludes.mjs';
|
|
20
20
|
import { CLAUDE_STYLE, HOSTS, VERSION_MARKER, resolvePath } from '../hosts/hosts.mjs';
|
|
21
21
|
import {
|
|
@@ -130,11 +130,21 @@ export function* activeInstalls(targets) {
|
|
|
130
130
|
}
|
|
131
131
|
}
|
|
132
132
|
|
|
133
|
-
/**
|
|
133
|
+
/**
|
|
134
|
+
* The state's memo of `expected` renders, made on first use: overview and fleet diff the same
|
|
135
|
+
* install on every refresh, and only the compare has to run again (see `renderMemo`).
|
|
136
|
+
*/
|
|
137
|
+
const memoOf = (state) => (state.renderMemo ??= renderMemo());
|
|
138
|
+
|
|
139
|
+
/**
|
|
140
|
+
* The edited/added/missing tally of a `diffCollect` file list, and apart from it the `linked`
|
|
141
|
+
* paths — the user's own links, which the console never adds into a drift total.
|
|
142
|
+
*/
|
|
134
143
|
const driftCounts = (files) => ({
|
|
135
144
|
edited: files.filter((f) => f.status === 'edited').length,
|
|
136
145
|
added: files.filter((f) => f.status === 'added').length,
|
|
137
146
|
missing: files.filter((f) => f.status === 'missing').length,
|
|
147
|
+
linked: files.filter((f) => f.status === 'linked').length,
|
|
138
148
|
});
|
|
139
149
|
|
|
140
150
|
/**
|
|
@@ -179,8 +189,9 @@ export function apiInstalls(state) {
|
|
|
179
189
|
*
|
|
180
190
|
* Its own route, not more fields on `/api/installs`: the sidebar refetches that list on every
|
|
181
191
|
* data revision, and the drift check below re-renders a whole emit per global install.
|
|
182
|
-
*
|
|
183
|
-
*
|
|
192
|
+
* Each global install's `expected` render is memoised on the state (`renderMemo`, keyed on the
|
|
193
|
+
* source fingerprint computed once per request and every axis), so a refresh re-runs only the
|
|
194
|
+
* compare; the memo holds a handful of installs, enough for any machine seen so far.
|
|
184
195
|
*
|
|
185
196
|
* Each row reads ITS OWN `.geneseed-version`. `statusData().installed_fp` is the first carrier
|
|
186
197
|
* a fixed walk finds, which describes the wrong install as soon as two hosts are deployed.
|
|
@@ -197,7 +208,7 @@ export function apiFleet(state) {
|
|
|
197
208
|
let drift = null;
|
|
198
209
|
if (st === 'active') {
|
|
199
210
|
try {
|
|
200
|
-
const { files } = diffCollect({ target: dir });
|
|
211
|
+
const { files } = diffCollect({ target: dir, memo: memoOf(state), sourceFp });
|
|
201
212
|
if (files !== null) drift = driftCounts(files);
|
|
202
213
|
} catch { /* an install that cannot be re-rendered reports no drift figure, not zero */ }
|
|
203
214
|
}
|
|
@@ -226,7 +237,7 @@ export function apiOverview(state) {
|
|
|
226
237
|
let diff = null;
|
|
227
238
|
if (deployed(state)) {
|
|
228
239
|
const { files } = diffCollect({
|
|
229
|
-
target: state.target, theme: state.theme, emit: state.emit });
|
|
240
|
+
target: state.target, theme: state.theme, emit: state.emit, memo: memoOf(state) });
|
|
230
241
|
if (files !== null) diff = driftCounts(files);
|
|
231
242
|
}
|
|
232
243
|
let buildTime = null;
|
package/js/web/handler.mjs
CHANGED
|
@@ -11,11 +11,10 @@
|
|
|
11
11
|
* declared next door in `routes.mjs`; the daemon that starts it is in `daemon.mjs`.
|
|
12
12
|
*/
|
|
13
13
|
import { resolvePath } from '../hosts/hosts.mjs';
|
|
14
|
-
import { doctrinesForBuild } from '../hosts/installs.mjs';
|
|
15
14
|
import { isTruthy, jsonDumpsCompact } from '../lib/json.mjs';
|
|
16
15
|
import { parseIntStrict, percentDecode } from '../lib/text.mjs';
|
|
17
16
|
import { preflight } from '../maintain/update.mjs';
|
|
18
|
-
import { apiDeployCmd, apiInstallCmd, apiPickFolder, apiRestore,
|
|
17
|
+
import { apiDeployCmd, apiInstallCmd, apiPickFolder, apiRestore, buildActionCmds, mcpTargetPaths } from './actions.mjs';
|
|
19
18
|
import { NotFound } from './catalog.mjs';
|
|
20
19
|
import { openUrl, requestRestart } from './daemon.mjs';
|
|
21
20
|
import { apiDocs, apiDocsPage } from './docs.mjs';
|
|
@@ -301,20 +300,9 @@ export function makeHandler(state, jm, token, dist, holder = null) {
|
|
|
301
300
|
if (jid === null) return sendJson(res, { error: 'busy' }, 409, ae);
|
|
302
301
|
return sendJson(res, { job_id: jid }, 202, ae);
|
|
303
302
|
}
|
|
304
|
-
// Build
|
|
305
|
-
// the deployed theme downstream.
|
|
306
|
-
|
|
307
|
-
const [theme, emit] = action === 'build'
|
|
308
|
-
? buildOverride(state, body) : [state.theme, state.emit];
|
|
309
|
-
// The pack selection follows the install like footprint/posture/mode, and is read here
|
|
310
|
-
// rather than left to the table's default: a console Build must re-emit the constitution
|
|
311
|
-
// the deployment already carries. Unknown (no `Active packs:` marker) resolves to ALL
|
|
312
|
-
// packs — never to `harness.config.json`, which would drop the consent gate.
|
|
313
|
-
const cmds = actionCommands(action, {
|
|
314
|
-
theme, emit, footprint: state.footprint, posture: state.posture, mode: state.mode,
|
|
315
|
-
trust: state.trust,
|
|
316
|
-
doctrines: doctrinesForBuild(state.target),
|
|
317
|
-
});
|
|
303
|
+
// Build resolves its argv off the install (`buildActionCmds`); the other actions take no
|
|
304
|
+
// axes and self-resolve the deployed theme downstream.
|
|
305
|
+
const cmds = action === 'build' ? buildActionCmds(state, body) : actionCommands(action);
|
|
318
306
|
if (!isTruthy(cmds)) {
|
|
319
307
|
return sendJson(res, { error: `unknown action ${action}` }, 404, ae);
|
|
320
308
|
}
|
package/js/web/jobs.mjs
CHANGED
|
@@ -421,14 +421,16 @@ export const INLINE_ACTIONS = ['restore', 'install', 'deploy'];
|
|
|
421
421
|
* `harness.config.json` exactly as the pack list does, so `{"excludeRules":["process.5"]}`
|
|
422
422
|
* there would take the consent gate out of a console Build that never asked for it. `[]` is
|
|
423
423
|
* spelled `--exclude-rules none` and says "exclude nothing" out loud.
|
|
424
|
+
*
|
|
425
|
+
* `buildArgv`, when given, is used whole and the axes above are ignored: it is the argv a
|
|
426
|
+
* deployed install's profile owns (`buildActionCmds`), switches and exclusions included.
|
|
424
427
|
*/
|
|
425
428
|
function actionTable({
|
|
426
429
|
theme = 'neutral', emit = 'opencode-global', footprint = 'full',
|
|
427
430
|
posture = 'peer', mode = 'direct', doctrines = [...PACK_ORDER], excludeRules = [],
|
|
428
|
-
trust = DEFAULT_PRESET,
|
|
431
|
+
trust = DEFAULT_PRESET, buildArgv = setupBuildArgs(theme, emit, null, null, footprint, posture,
|
|
432
|
+
mode, doctrines, PACK_ORDER, excludeRules, trust),
|
|
429
433
|
} = {}) {
|
|
430
|
-
const buildArgv = setupBuildArgs(theme, emit, null, null, footprint, posture, mode,
|
|
431
|
-
doctrines, PACK_ORDER, excludeRules, trust);
|
|
432
434
|
return {
|
|
433
435
|
doctor: [[NODE(), CLI(), 'doctor']],
|
|
434
436
|
build: [[NODE(), GEN(), ...buildArgv]],
|
package/js/web/state.mjs
CHANGED
|
@@ -63,6 +63,9 @@ export function webState(theme = null, target = null) {
|
|
|
63
63
|
// beside it rather than inside so `/api/overview` (fetched after every mutation) does not
|
|
64
64
|
// carry every group.
|
|
65
65
|
_doctorRun: null,
|
|
66
|
+
// `diffCollect`'s memo of `expected` renders, made on first use by `api.mjs` (`memoOf`);
|
|
67
|
+
// it re-renders on its own key change, so `refresh()` leaves it alone.
|
|
68
|
+
renderMemo: null,
|
|
66
69
|
};
|
|
67
70
|
// The INSTALL ROOT (== build --out). For globals it IS the data dir; a claude/bob/openclaude
|
|
68
71
|
// PROJECT install keeps its data under <repo>/.claude|.bob|.openclaude while the markers
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"//": "Every field here is argued and gated in tests/unit/package_manifest.test.mjs. `files`, `bin` and `engines` each have a test that fails when reality drifts from this file; `version` mirrors harness.config.json and is gated too. Read that docblock before editing this one.",
|
|
3
3
|
"name": "geneseed",
|
|
4
|
-
"version": "4.9.
|
|
4
|
+
"version": "4.9.3",
|
|
5
5
|
"description": "A portable, theme-able harness you implant once and use everywhere to grow a disciplined AI coding agent.",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"ai",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{
|
|
1
|
+
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{C as i,N as a,Q as o,R as s,x as c}from"./index-DQXG_mqo.js";import{a as l,i as u,n as d,o as f,r as p,t as m}from"./activity-DvPxoS4Y.js";import{t as h}from"./usePoll-NSTzLOF4.js";var g=e(t(),1),_=n();function v({s:e}){let t=p[e.status]||p.idle,n=e.files,r=e.todos,i=r&&r.total>0||e.error||e.blocked_on;return(0,_.jsxs)(`a`,{className:`card pad-md act-card`,href:`#/activity/${encodeURIComponent(e.session_id)}`,children:[(0,_.jsxs)(`div`,{className:`row between wrap gap-12`,children:[(0,_.jsxs)(`div`,{className:`row gap-10`,style:{minWidth:0},children:[(0,_.jsx)(`span`,{className:`feed-dot ${t.cls||`acc`}`,style:{width:9,height:9}}),(0,_.jsxs)(`div`,{style:{minWidth:0},children:[(0,_.jsx)(`h3`,{style:{margin:0},children:e.title||l(e.cwd)||e.session_id}),e.cwd&&(0,_.jsx)(`div`,{className:`dim mono`,style:{fontSize:12,...m},title:e.cwd,children:e.cwd})]})]}),(0,_.jsxs)(`div`,{className:`row gap-8`,style:{flexShrink:0},children:[e.model&&(0,_.jsx)(`span`,{className:`badge mono`,title:`model`,children:e.model}),e.agent&&(0,_.jsx)(`span`,{className:`badge`,children:e.agent}),(0,_.jsxs)(`span`,{className:`badge ${t.cls}`,children:[(0,_.jsx)(`span`,{className:`dot`}),t.label]}),(0,_.jsx)(a,{name:`chevron`,className:`glyph act-chev`})]})]}),e.phase&&(0,_.jsxs)(`div`,{className:`row gap-8`,style:{marginTop:10,fontSize:14},children:[(0,_.jsx)(a,{name:`activity`}),(0,_.jsx)(`span`,{style:m,children:e.phase})]}),(e.tokens>0||e.cost>0||e.turn_started_at||n&&n.count>0)&&(0,_.jsxs)(`div`,{className:`row wrap`,style:{gap:16,marginTop:12,fontSize:13,color:`var(--text-2)`},children:[e.tokens>0&&(0,_.jsxs)(`span`,{children:[f(e.tokens),` tok`]}),e.cost>0&&(0,_.jsxs)(`span`,{children:[`$`,e.cost.toFixed(2)]}),e.turn_started_at?(0,_.jsx)(`span`,{children:(0,_.jsx)(d,{startedAt:e.turn_started_at})}):null,n&&n.count>0&&(0,_.jsxs)(`span`,{children:[n.count,` file`,n.count===1?``:`s`,` `,(0,_.jsxs)(`span`,{style:{color:`var(--good)`},children:[`+`,n.additions]}),` `,(0,_.jsxs)(`span`,{style:{color:`var(--bad)`},children:[`−`,n.deletions]})]})]}),i&&(0,_.jsxs)(`div`,{className:`row between wrap gap-12`,style:{marginTop:12,paddingTop:10,borderTop:`1px solid var(--line)`},children:[r&&r.total>0?(0,_.jsxs)(`span`,{className:`row gap-8 dim`,style:{fontSize:13},children:[(0,_.jsx)(u,{done:r.done,total:r.total}),`plan `,r.done,`/`,r.total]}):(0,_.jsx)(`span`,{}),e.error?(0,_.jsx)(`span`,{className:`badge bad`,title:e.error,style:{maxWidth:300,...m},children:e.error}):e.blocked_on?(0,_.jsx)(`span`,{className:`badge bad`,title:e.blocked_on,style:{maxWidth:300,...m},children:e.blocked_on}):null]}),(0,_.jsxs)(`div`,{className:`dim mono`,style:{fontSize:11,marginTop:8},children:[`updated `,s(e.updated_at),` ago`]})]})}function y(){let[e,t]=(0,g.useState)(null),[n,a]=(0,g.useState)(``);h(e=>r.activity().then(n=>{e()&&(t(n),a(``))},t=>{e()&&a(t.message)}),2e3,[]);let s=!e||e.enabled!==!1,l=e?.activity||[],u=o(),d=async()=>{let e=!s;try{let n=await r.activityToggle(e);t(e=>({...e||{},enabled:n.enabled,activity:n.enabled&&e?.activity||[]})),a(``)}catch(e){a(e.message)}};return(0,_.jsxs)(`div`,{className:`narrow`,children:[(0,_.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,_.jsxs)(`div`,{children:[(0,_.jsx)(`h1`,{className:`h`,children:`Activity`}),(0,_.jsx)(`p`,{className:`sub`,children:`Live OpenCode sessions this harness is running: what each one is doing right now. Refreshes every couple of seconds; sessions drop off when their process exits.`})]}),(0,_.jsxs)(`div`,{className:`row gap-10`,style:{alignItems:`center`,flexShrink:0},children:[(0,_.jsx)(`span`,{className:`dim mono`,style:{fontSize:12},children:s?`tracking on`:`tracking off`}),(0,_.jsx)(`div`,{className:`sw-toggle${s?` on`:``}`,role:`switch`,"aria-checked":s,"aria-label":`Toggle activity tracking`,tabIndex:0,onClick:d,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.key===` `&&e.preventDefault(),d())}})]})]}),(0,_.jsx)(c,{error:n,style:{marginBottom:12}}),e?s?l.length===0?(0,_.jsxs)(`div`,{className:`empty`,children:[(0,_.jsx)(`div`,{className:`big`,children:`No active sessions`}),`Run `,(0,_.jsx)(`code`,{children:`opencode`}),` and the sessions it spins up appear here.`]}):(0,_.jsx)(`div`,{className:`stack gap-12`,ref:u,children:l.map(e=>(0,_.jsx)(`div`,{"data-flip":e.session_id,children:(0,_.jsx)(v,{s:e})},e.session_id))}):(0,_.jsxs)(`div`,{className:`empty`,children:[(0,_.jsx)(`div`,{className:`big`,children:`Activity tracking is off`}),`The plugin isn't recording sessions. Flip the switch to turn it back on.`]}):(0,_.jsx)(i,{label:`Reading live sessions…`})]})}export{y as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{
|
|
1
|
+
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{C as i,N as a,R as o}from"./index-DQXG_mqo.js";import{a as s,n as c,o as l,r as u,t as d}from"./activity-DvPxoS4Y.js";import{t as f}from"./usePoll-NSTzLOF4.js";var p=e(t(),1),m=n();function h(e){return e.kind===`tool`?e.status===`error`?`bad`:e.status===`completed`?`ok`:`acc`:{retry:`warn`,error:`bad`,subtask:`acc`,text:`acc`}[e.kind]||``}function g({rec:e}){let t=e.who===`you`,n=[];t||(e.kind===`tool`&&e.ms!=null&&n.push(`${(e.ms/1e3).toFixed(1)}s`),e.kind===`step`&&(e.tokens&&n.push(`${l(e.tokens)} tok`),e.cost&&n.push(`$${e.cost.toFixed(2)}`)),e.kind===`subtask`&&e.agent&&n.unshift(e.agent));let r=!t&&(e.kind===`text`||e.kind===`thinking`||e.kind===`step`),i=t?e.text:e.label||e.snippet||e.kind;return(0,m.jsxs)(`div`,{className:`row gap-10`,style:{alignItems:`baseline`},children:[(0,m.jsx)(`span`,{className:`badge ${t?``:`acc`}`,style:{flexShrink:0,minWidth:52,justifyContent:`center`},children:t?`you`:`agent`}),(0,m.jsxs)(`div`,{style:{minWidth:0,flex:1,fontSize:13},children:[!t&&(0,m.jsx)(`span`,{className:`feed-dot ${h(e)||`acc`}`,style:{display:`inline-block`,marginRight:8,verticalAlign:`middle`}}),e.kind===`thinking`&&(0,m.jsx)(`span`,{className:`dim`,children:`thinking: `}),r?(0,m.jsx)(`span`,{className:`dim`,children:i}):t?i:(0,m.jsx)(`b`,{children:i}),e.error&&(0,m.jsxs)(`span`,{className:`dim`,children:[`: `,e.error]})]}),n.length>0&&(0,m.jsx)(`span`,{className:`dim mono`,style:{flexShrink:0,fontSize:12},children:n.join(` · `)})]})}function _({turns:e}){return!e||e.length===0?(0,m.jsx)(`div`,{className:`dim`,style:{fontSize:13},children:`No conversation captured yet.`}):(0,m.jsx)(`div`,{className:`stack gap-12`,children:e.map((e,t)=>{let n=e.role===`user`;return(0,m.jsxs)(`div`,{className:`row gap-10`,style:{alignItems:`baseline`},children:[(0,m.jsx)(`span`,{className:`badge ${n?``:`acc`}`,style:{flexShrink:0,minWidth:52,justifyContent:`center`},children:n?`you`:`agent`}),(0,m.jsx)(`div`,{style:{minWidth:0,fontSize:13,color:n?`inherit`:`var(--text-2)`},children:e.text})]},t)})})}function v({sid:e}){let[t,n]=(0,p.useState)(null),[h,v]=(0,p.useState)(``),[y,b]=(0,p.useState)(!1),[x,S]=(0,p.useState)(!1);f(t=>r.activityDetail(e).then(e=>{t()&&(n(e),v(``),b(!1))},e=>{t()&&(e.status===404?b(!0):v(e.message))}),2e3,[e]);let C=(0,m.jsxs)(`a`,{className:`btn ghost sm`,href:`#/activity`,style:{marginBottom:12,display:`inline-flex`,gap:6},children:[(0,m.jsx)(a,{name:`arrow`,style:{transform:`rotate(180deg)`}}),` Activity`]});if(y)return(0,m.jsxs)(`div`,{className:`narrow`,children:[C,(0,m.jsxs)(`div`,{className:`empty`,children:[(0,m.jsx)(`div`,{className:`big`,children:`Session ended`}),`It's no longer live. `,(0,m.jsx)(`a`,{href:`#/activity`,children:`Back to Activity`}),`.`]})]});if(!t)return(0,m.jsxs)(`div`,{className:`narrow`,children:[C,(0,m.jsx)(i,{label:`Loading session…`})]});let w=t.session,T=u[w.status]||u.idle,E=w.files,D=w.todos,O=!!(E&&E.items&&E.items.length>0),k=!!(D&&D.items&&D.items.length>0),A=t.conversation||[],j=t.timeline||[],M=[...A.filter(e=>e.role===`user`).map(e=>({who:`you`,text:e.text,t:e.t||0})),...j.map(e=>({...e,who:`agent`}))].sort((e,t)=>(e.t||0)-(t.t||0));return(0,m.jsxs)(`div`,{className:`narrow`,children:[C,h&&(0,m.jsx)(`p`,{className:`badge bad`,style:{marginBottom:12},children:h}),(0,m.jsxs)(`div`,{className:`card pad-md`,children:[(0,m.jsxs)(`div`,{className:`row between wrap gap-12`,children:[(0,m.jsxs)(`div`,{style:{minWidth:0},children:[(0,m.jsx)(`h1`,{className:`h`,style:{margin:0},children:w.title||s(w.cwd)||w.session_id}),w.cwd&&(0,m.jsx)(`div`,{className:`dim mono`,style:{fontSize:12,...d},title:w.cwd,children:w.cwd})]}),(0,m.jsxs)(`div`,{className:`row gap-8`,style:{flexShrink:0},children:[w.model&&(0,m.jsx)(`span`,{className:`badge mono`,children:w.model}),w.agent&&(0,m.jsx)(`span`,{className:`badge`,children:w.agent}),(0,m.jsxs)(`span`,{className:`badge ${T.cls}`,children:[(0,m.jsx)(`span`,{className:`dot`}),T.label]})]})]}),w.phase&&(0,m.jsxs)(`div`,{className:`row gap-8`,style:{marginTop:10,fontSize:14},children:[(0,m.jsx)(a,{name:`activity`}),(0,m.jsx)(`span`,{style:d,children:w.phase})]}),(0,m.jsxs)(`div`,{className:`row wrap`,style:{gap:16,marginTop:12,fontSize:13,color:`var(--text-2)`},children:[w.tokens>0&&(0,m.jsxs)(`span`,{children:[l(w.tokens),` tok`]}),w.cost>0&&(0,m.jsxs)(`span`,{children:[`$`,w.cost.toFixed(2)]}),w.turn_started_at?(0,m.jsx)(`span`,{children:(0,m.jsx)(c,{startedAt:w.turn_started_at})}):null,(0,m.jsxs)(`span`,{className:`dim`,children:[`updated `,o(w.updated_at),` ago`]})]}),(w.error||w.blocked_on)&&(0,m.jsx)(`div`,{style:{marginTop:10},children:(0,m.jsx)(`span`,{className:`badge bad`,style:{maxWidth:`100%`,...d},children:w.error||w.blocked_on})})]}),(O||k)&&(0,m.jsxs)(`div`,{className:`grid gap-12`,style:{marginTop:12,gridTemplateColumns:O&&k?`minmax(0, 1fr) minmax(0, 1fr)`:`1fr`},children:[O&&(0,m.jsxs)(`div`,{className:`card pad-md`,children:[(0,m.jsx)(`div`,{className:`card-head`,children:(0,m.jsxs)(`h3`,{children:[`Files touched `,(0,m.jsxs)(`span`,{className:`dim`,children:[`(`,E.count,`)`]})]})}),(0,m.jsx)(`div`,{className:`stack`,style:{gap:6,marginTop:8},children:E.items.map(e=>(0,m.jsxs)(`div`,{className:`row between gap-12`,style:{fontSize:13},children:[(0,m.jsx)(`span`,{className:`mono`,style:{...d,minWidth:0,flex:1},title:e.file,children:e.file}),(0,m.jsxs)(`span`,{style:{flexShrink:0},children:[(0,m.jsxs)(`span`,{style:{color:`var(--good)`},children:[`+`,e.additions]}),` `,(0,m.jsxs)(`span`,{style:{color:`var(--bad)`},children:[`−`,e.deletions]})]})]},e.file))})]}),k&&(0,m.jsxs)(`div`,{className:`card pad-md`,children:[(0,m.jsx)(`div`,{className:`card-head`,children:(0,m.jsxs)(`h3`,{children:[`Plan`,` `,(0,m.jsxs)(`span`,{className:`dim`,children:[`(`,D.done,`/`,D.total,`)`]})]})}),(0,m.jsx)(`div`,{className:`stack`,style:{gap:6,marginTop:8},children:D.items.map((e,t)=>(0,m.jsxs)(`div`,{className:`row gap-8`,style:{fontSize:13},children:[(0,m.jsx)(`span`,{className:`feed-dot ${e.status===`completed`?`ok`:e.status===`in_progress`?`acc`:``}`}),(0,m.jsx)(`span`,{style:{textDecoration:e.status===`completed`?`line-through`:`none`,color:e.status===`completed`?`var(--text-3)`:`inherit`},children:e.content})]},t))})]})]}),(0,m.jsxs)(`div`,{className:`card pad-md`,style:{marginTop:12},children:[(0,m.jsxs)(`div`,{className:`card-head`,style:{justifyContent:`space-between`,marginBottom:12},children:[(0,m.jsx)(`h3`,{children:`Timeline`}),j.length>0&&(0,m.jsx)(`button`,{className:`btn ghost sm`,onClick:()=>S(e=>!e),children:x?`Show conversation`:`Show all ${j.length} steps`})]}),x?(0,m.jsx)(`div`,{className:`stack gap-12`,children:M.map((e,t)=>(0,m.jsx)(g,{rec:e},t))}):(0,m.jsx)(_,{turns:A})]})]})}export{v as default};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/GreenhouseView-zk2Uzc3A.js","assets/sections-BET3c1WT.js","assets/react-BOF6yL40.js","assets/drawable-CyLe1gtW.js","assets/index-DQXG_mqo.js","assets/api-CiXlkbe0.js","assets/index-BCJz4_8C.css","assets/jobBuckets-Dbq8ZlWW.js","assets/OperatorHudView-CyiGhiHk.js","assets/JournalView-Bfj27XHC.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{n as e,o as t,r as n,s as r}from"./sections-BET3c1WT.js";import{i,t as a}from"./react-BOF6yL40.js";import{t as o}from"./api-CiXlkbe0.js";import{B as s,C as c,F as l,I as u,J as d,L as f,N as p,R as m,T as h,V as g,Z as _,b as v,q as y,t as b,x}from"./index-DQXG_mqo.js";var S=r(i(),1),C={neutral:`Loaded & ready`,imperial:`The Codex in force`,military:`The unit stands ready`,cyberpunk:`Jacked in`,wizard:`Wards in place`,pirate:`The crew stands ready`,gamer:`Game loaded`,sports:`The squad takes the field`,biker:`The crew rolls out`,commentator:`Lights out, away we go`,verstappen:`Setup's in`,joker:`Mic check`,mean:`Rules are up`,marvin:`Online. Reluctantly.`},w=e=>e.deployed?C[e.theme]||`Loaded & ready`:`Not deployed`,T=a();function E({value:e,size:t=232}){let n=_(e,1100)??0,r=t/2-14,i=2*Math.PI*r,a=i*(1-n);return(0,T.jsxs)(`div`,{className:`ring-wrap`,style:{width:t,height:t},children:[(0,T.jsxs)(`svg`,{viewBox:`0 0 ${t} ${t}`,children:[(0,T.jsx)(`circle`,{cx:t/2,cy:t/2,r,fill:`none`,stroke:`var(--surface-3)`,strokeWidth:`10`}),(0,T.jsx)(`circle`,{cx:t/2,cy:t/2,r,fill:`none`,stroke:`var(--accent)`,strokeWidth:`10`,strokeLinecap:`round`,strokeDasharray:i,strokeDashoffset:a}),Array.from({length:48}).map((e,i)=>{let a=i/48*2*Math.PI,o=r-18,s=r-24,c=t/2+Math.cos(a)*o,l=t/2+Math.sin(a)*o,u=t/2+Math.cos(a)*s,d=t/2+Math.sin(a)*s;return(0,T.jsx)(`line`,{x1:c,y1:l,x2:u,y2:d,stroke:`var(--line-2)`,strokeWidth:`1`,opacity:i/48<n?.9:.25},i)})]}),(0,T.jsxs)(`div`,{className:`ring-center`,children:[(0,T.jsxs)(`div`,{className:`pct`,children:[Math.round(n*100),(0,T.jsx)(`span`,{style:{fontSize:20,color:`var(--text-3)`},children:`%`})]}),(0,T.jsx)(`div`,{className:`lbl`,children:`germination`})]})]})}function D({overview:e}){let t=l(e.diff),n=e.counts||{};return(0,T.jsxs)(`div`,{className:`card kpiband rise mb-16`,children:[[{key:`agents`,label:`Agents`,hash:`#/agents`},{key:`skills`,label:`Skills`,hash:`#/skills`},{key:`laws`,label:`Dictates`,hash:`#/laws`}].map(e=>{let t=n[e.key];return(0,T.jsxs)(`a`,{className:`kseg`,href:e.hash,title:`Open ${e.label}`,children:[(0,T.jsx)(`span`,{className:`kseg-n`+(t===0?` zero`:``),children:t==null?`—`:(0,T.jsx)(d,{value:t})}),(0,T.jsx)(`span`,{className:`kseg-l`,children:e.label})]},e.key)}),(0,T.jsx)(`div`,{className:`kseg-spacer`}),(0,T.jsxs)(`button`,{className:`kseg`+(t>0?` hot`:``),onClick:()=>y(`#/diff`),title:`Open changes`,children:[(0,T.jsx)(`span`,{className:`kseg-n`+(t===0?` zero`:``),children:(0,T.jsx)(d,{value:t})}),(0,T.jsx)(`span`,{className:`kseg-l`,children:`Local edits`}),t>0&&(0,T.jsx)(`span`,{className:`delta up`,children:`▲`})]})]})}function O({overview:t}){return(0,T.jsx)(`div`,{className:`genome`,children:n.map((n,r)=>{let i=e[n],a=t.counts?.[n];return(0,T.jsxs)(`div`,{className:`card gcell rise`,style:{"--i":r},onClick:()=>y(`#/section/`+n),children:[(0,T.jsxs)(`div`,{className:`gtop`,children:[(0,T.jsx)(`span`,{className:`gname`,children:i.label}),(0,T.jsx)(p,{name:i.icon,className:`gicon`})]}),(0,T.jsx)(`div`,{className:`gcount`+(a===0?` zero`:``),children:a==null?`—`:(0,T.jsx)(d,{value:a})}),(0,T.jsx)(`div`,{className:`gdesc`,children:i.desc})]},n)})})}function k({jobs:e}){if(!e||e.length===0)return(0,T.jsx)(`div`,{className:`feed`,children:(0,T.jsxs)(`div`,{className:`empty`,children:[(0,T.jsx)(`div`,{className:`big`,children:`No activity yet`}),`Actions you run appear here.`]})});let t={done:`ok`,running:`acc`,failed:`bad`},n=[...e].sort((e,t)=>t.started-e.started).slice(0,8);return(0,T.jsx)(`div`,{className:`feed`,children:n.map(e=>(0,T.jsxs)(`div`,{className:`feed-row`,children:[(0,T.jsx)(`span`,{className:`feed-dot ${t[e.status]||`ok`}`}),(0,T.jsx)(`span`,{className:`feed-txt`,children:(0,T.jsx)(`b`,{children:e.action})}),(0,T.jsxs)(`span`,{className:`feed-when`,children:[m(e.started),` ago`]})]},e.id))})}function A({overview:e,sigil:t,setup:r,jobs:i,onAction:a}){let o=w(e),s=f(e,r);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`card pad-lg rise mb-16`,children:(0,T.jsxs)(`div`,{className:`hero`,children:[(0,T.jsx)(E,{value:s}),(0,T.jsxs)(`div`,{className:`hero-facts`,children:[(0,T.jsx)(`div`,{className:`ttl`,children:o}),t&&(0,T.jsxs)(`div`,{className:`voice-readout`,children:[(0,T.jsx)(`span`,{className:`vr-cur`,children:`▕`}),(0,T.jsx)(`span`,{className:`vr-txt`,children:t})]},e.theme),(0,T.jsxs)(`p`,{className:`sub`,children:[`One source rendered into `,(0,T.jsx)(`code`,{children:e.target}),`. Every repo on this machine inherits it.`]}),(0,T.jsxs)(`div`,{className:`hero-chips`,children:[(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`voice`}),(0,T.jsx)(`span`,{className:`cv`,style:{textTransform:`capitalize`},children:e.theme})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`mode`}),(0,T.jsx)(`span`,{className:`cv`,children:e.emit})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`footprint`}),(0,T.jsx)(`span`,{className:`cv`,children:e.footprint})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`built`}),(0,T.jsx)(`span`,{className:`cv`,children:e.build_time||`unknown`})]}),(0,T.jsxs)(`span`,{className:`chip`,children:[(0,T.jsx)(`span`,{className:`ck`,children:`fp`}),(0,T.jsx)(`span`,{className:`cv`,children:r?.installed_fp||`—`})]})]}),(0,T.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,T.jsxs)(`button`,{className:`btn`,onClick:()=>a(`update`),children:[(0,T.jsx)(p,{name:`refresh`}),`Update`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`build-all`),children:[(0,T.jsx)(p,{name:`build`}),`Rebuild`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`doctor`),children:[(0,T.jsx)(p,{name:`doctor`}),`Run doctor`]})]})]})]})}),(0,T.jsx)(D,{overview:e}),(0,T.jsxs)(`div`,{className:`grid split-status`,children:[(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsxs)(`div`,{className:`card-head`,children:[(0,T.jsx)(`h3`,{children:`Capability genome`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsxs)(`span`,{className:`tick`,children:[n.length,` sections`]})})]}),(0,T.jsx)(O,{overview:e})]}),(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsxs)(`div`,{className:`card-head`,children:[(0,T.jsx)(`h3`,{children:`Recent activity`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsxs)(`span`,{className:`badge acc`,children:[(0,T.jsx)(`span`,{className:`dot`}),`live`]})})]}),(0,T.jsx)(k,{jobs:i})]})]})]})}function j({k:t,overview:n,max:r}){let i=e[t],a=n.counts?.[t]??0;return(0,T.jsxs)(`div`,{className:`strand`,children:[(0,T.jsxs)(`span`,{className:`strand-name`,children:[(0,T.jsx)(`span`,{className:`strand-dot`}),(0,T.jsx)(`a`,{href:`#/section/`+t,className:`strand-link stretch-link`,children:i.label})]}),(0,T.jsx)(`div`,{className:`hbar`,children:(0,T.jsx)(`i`,{style:{width:`${a/r*100}%`}})}),(0,T.jsx)(`span`,{className:`strand-val`,children:a})]})}function M({overview:e,sigil:t,setup:r,jobs:i}){let a=u(e.counts),o=r?.version_verdict||``,s=o.includes(`up to date`),c=l(e.diff),d=[[`Source`,`src/, the canonical genetic material`,r?.source_fp||`—`,!0],[`Render`,`geneseed build → ${e.emit}`,e.theme+` voice`,!0],[`Deployed`,e.target,`inherited by every repo`,!1]];return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`mb-16`,children:(0,T.jsxs)(`div`,{className:`card pad-lg rise`,style:{position:`relative`,overflow:`hidden`},children:[(0,T.jsx)(`h2`,{className:`h`,style:{fontSize:22,margin:`0 0 18px`},children:`Gene-seed lineage`}),(0,T.jsxs)(`div`,{className:`lineage-track`,children:[(0,T.jsx)(`div`,{className:`spine`}),d.map(([e,t,n,r],i)=>(0,T.jsxs)(`div`,{className:`lineage-step`,children:[(0,T.jsx)(`span`,{className:`node ${r?`on`:``}`}),(0,T.jsx)(`div`,{className:`lt`,children:e}),(0,T.jsx)(`div`,{className:`ld`,children:t}),(0,T.jsx)(`div`,{className:`ltag`,children:n})]},i))]}),(0,T.jsx)(`hr`,{className:`hr`}),t&&(0,T.jsxs)(`div`,{className:`voice-readout`,style:{marginBottom:14},children:[(0,T.jsx)(`span`,{className:`vr-cur`,children:`▕`}),(0,T.jsx)(`span`,{className:`vr-txt`,children:t})]},e.theme),(0,T.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,T.jsxs)(`span`,{className:`badge ${s?`ok`:`warn`}`,children:[(0,T.jsx)(`span`,{className:`dot`}),`in sync · `,o]}),(0,T.jsxs)(`span`,{className:`badge`,children:[(0,T.jsx)(`span`,{className:`dot`}),c,` local edits`]})]})]})}),(0,T.jsxs)(`div`,{className:`grid split-even`,children:[(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsxs)(`div`,{className:`card-head`,children:[(0,T.jsx)(`h3`,{children:`Genome strand`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsx)(`span`,{className:`tick`,children:`by volume`})})]}),n.map(t=>(0,T.jsx)(j,{k:t,overview:e,max:a},t))]}),(0,T.jsxs)(`div`,{className:`card pad-lg`,children:[(0,T.jsx)(`div`,{className:`card-head`,children:(0,T.jsx)(`h3`,{children:`Recent activity`})}),(0,T.jsx)(k,{jobs:i})]})]})]})}function N({overview:t,setup:r,jobs:i}){let a=n.reduce((e,n)=>e+(t.counts?.[n]??0),0),o=u(t.counts),s=t.doctor?.ok,c=t.doctor?.problems?.length??0,d=l(t.diff);return(0,T.jsxs)(T.Fragment,{children:[(0,T.jsx)(`div`,{className:`card pad-md rise mb-16`,children:(0,T.jsx)(`div`,{className:`row wrap between gap-16`,children:(0,T.jsxs)(`div`,{className:`row`,style:{gap:20,flexWrap:`wrap`},children:[(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`status`}),(0,T.jsx)(`div`,{className:`row`,style:{gap:8,marginTop:4},children:(0,T.jsxs)(`span`,{className:`badge ${t.deployed?`ok`:`warn`}`,children:[(0,T.jsx)(`span`,{className:`dot`}),t.deployed?`deployed`:`not deployed`]})})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`voice`}),(0,T.jsx)(`div`,{className:`metric`,style:{fontSize:18,marginTop:6,textTransform:`capitalize`},children:t.theme})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`mode`}),(0,T.jsx)(`div`,{className:`mono`,style:{fontSize:14,marginTop:6},children:t.emit})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`fingerprint`}),(0,T.jsx)(`div`,{className:`mono`,style:{fontSize:14,marginTop:6,color:`var(--accent)`},children:r?.installed_fp||`—`})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`doctor`}),(0,T.jsx)(`div`,{className:`row`,style:{gap:8,marginTop:4},children:s?(0,T.jsxs)(`span`,{className:`badge ok`,children:[(0,T.jsx)(`span`,{className:`dot`}),`clean`]}):(0,T.jsxs)(`span`,{className:`badge warn`,children:[(0,T.jsx)(`span`,{className:`dot`}),c,` issue`,c===1?``:`s`]})})]}),(0,T.jsxs)(`div`,{children:[(0,T.jsx)(`div`,{className:`tick`,children:`edits`}),(0,T.jsx)(`div`,{className:`metric`,style:{fontSize:18,marginTop:6},children:d})]})]})})}),(0,T.jsxs)(`div`,{className:`grid split-operator`,children:[(0,T.jsxs)(`div`,{className:`card rise`,style:{"--i":1},children:[(0,T.jsxs)(`div`,{className:`card-head pad-lg`,style:{padding:`18px 20px 0`,marginBottom:14},children:[(0,T.jsx)(`h3`,{children:`Sections`}),(0,T.jsx)(`div`,{className:`right`,children:(0,T.jsxs)(`span`,{className:`tick`,children:[a,` entries total`]})})]}),(0,T.jsxs)(`table`,{className:`tbl`,children:[(0,T.jsx)(`thead`,{children:(0,T.jsxs)(`tr`,{children:[(0,T.jsx)(`th`,{children:`Section`}),(0,T.jsx)(`th`,{children:`Detail`}),(0,T.jsx)(`th`,{style:{width:130},children:`Share`}),(0,T.jsx)(`th`,{className:`num`,children:`Count`})]})}),(0,T.jsx)(`tbody`,{children:n.map(n=>{let r=e[n],i=t.counts?.[n]??0;return(0,T.jsxs)(`tr`,{className:`clickable`,children:[(0,T.jsx)(`td`,{className:`name`,children:(0,T.jsx)(`a`,{href:`#/section/`+n,className:`stretch-link`,children:r.label})}),(0,T.jsx)(`td`,{className:`muted`,children:r.desc}),(0,T.jsx)(`td`,{children:(0,T.jsx)(`div`,{className:`hbar`,children:(0,T.jsx)(`i`,{style:{width:`${i/o*100}%`}})})}),(0,T.jsx)(`td`,{className:`num`,children:i})]},n)})})]})]}),(0,T.jsxs)(`div`,{className:`card pad-lg rise`,style:{"--i":2},children:[(0,T.jsx)(`div`,{className:`card-head`,children:(0,T.jsx)(`h3`,{children:`Run log`})}),(0,T.jsx)(k,{jobs:i})]})]})]})}function P(){let[e,t]=(0,S.useState)(!1),[n,r]=(0,S.useState)(null);return(0,T.jsxs)(`div`,{className:`stale-banner`,role:`alert`,children:[(0,T.jsx)(`span`,{children:n||`This console is running code from before your last upgrade.`}),(0,T.jsx)(`button`,{className:`btn sm`,onClick:async()=>{t(!0),r(null);try{await g()}catch(e){r(e.message),t(!1)}},disabled:e,children:e?`Restarting…`:`Restart`})]})}var F=t({default:()=>z}),I=(0,S.lazy)(()=>b(()=>import(`./GreenhouseView-zk2Uzc3A.js`),__vite__mapDeps([0,1,2,3,4,5,6,7]))),L=(0,S.lazy)(()=>b(()=>import(`./OperatorHudView-CyiGhiHk.js`),__vite__mapDeps([8,1,2,4,5,6,7]))),R=(0,S.lazy)(()=>b(()=>import(`./JournalView-Bfj27XHC.js`),__vite__mapDeps([9,1,2,5,3,4,6])));function z({overview:e,overviewError:t,onRetry:n,themes:r,setup:i,runs:a,onAction:l,layout:u=`cultivar`,dataRev:d}){let f=u,[p,m]=(0,S.useState)(`status`),g=e&&r.find(t=>t.name===e.theme)?.sigil||``,{data:_}=s(()=>f===`greenhouse`||f===`operator`?o.doctor().catch(()=>null):Promise.resolve(null),[f,d]),{data:y}=s(()=>f===`journal`?o.recent().catch(()=>null):Promise.resolve(null),[f,d]);if(!e)return t?(0,T.jsxs)(`div`,{children:[(0,T.jsx)(x,{error:`Could not load the harness overview: ${t}`}),(0,T.jsx)(`button`,{className:`btn`,onClick:n,children:`Retry`})]}):(0,T.jsx)(c,{});let b=e.daemon_stale?(0,T.jsx)(P,{}):null;return e.deployed?p===`status`&&f===`journal`?(0,T.jsxs)(S.Suspense,{fallback:(0,T.jsx)(c,{}),children:[b,(0,T.jsx)(R,{overview:e,recent:y,onAction:l,onDirection:m,dataRev:d})]}):(0,T.jsxs)(T.Fragment,{children:[b,(0,T.jsx)(`div`,{className:`head-row`,children:(0,T.jsx)(h,{"aria-label":`Dashboard view`,children:[[`status`,`Status`],[`lineage`,`Lineage`],[`operator`,`Operator`]].map(([e,t])=>(0,T.jsx)(`button`,{className:p===e?`on`:``,onClick:()=>m(e),"aria-pressed":p===e,children:t},e))})}),(0,T.jsxs)(`div`,{className:`view-in`,children:[p===`status`&&f===`cultivar`&&(0,T.jsx)(A,{overview:e,sigil:g,setup:i,jobs:a,onAction:l}),p===`status`&&f===`greenhouse`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(c,{}),children:(0,T.jsx)(I,{overview:e,sigil:g,jobs:a,doctor:_,onAction:l})}),p===`status`&&f===`operator`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(c,{}),children:(0,T.jsx)(L,{overview:e,jobs:a,doctor:_,onAction:l})}),p===`lineage`&&(0,T.jsx)(M,{overview:e,sigil:g,setup:i,jobs:a}),p===`operator`&&(0,T.jsx)(N,{overview:e,setup:i,jobs:a})]},p)]}):(0,T.jsxs)(T.Fragment,{children:[b,(0,T.jsx)(v,{onAction:l})]})}export{z as default,w as n,F as t};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{
|
|
2
|
-
`)){if(i.startsWith("```")){n=!n;continue}if(n)continue;let e=i.match(/^(##|###)\s+(.+?)\s*$/);e&&(r+=1,t.push({level:e[1].length,title:O(e[2]),id:D(e[2],r)}))}return t}var A={"opencode-global":[`install-opencode`,`Global (recommended)`],opencode:[`install-opencode`,`Per repo`],"claude-global":[`install-claude-code`],claude:[`install-claude-code`],"openclaude-global":[`install-openclaude`],openclaude:[`install-openclaude`],"bob-global":[`install-bob`],bob:[`install-bob`],files:[`install-agent-md`]},j=`you already know this`;function M({page:e,overview:t,onAction:n}){let r=(0,T.useRef)(null),i=(0,T.useMemo)(()=>
|
|
1
|
+
import{s as e}from"./sections-BET3c1WT.js";import{i as t,t as n}from"./react-BOF6yL40.js";import{t as r}from"./api-CiXlkbe0.js";import{B as i,C as a,D as o,E as s,N as c,O as ee,T as te,a as l,i as ne,n as u,o as d,q as f,r as p,s as m,x as h}from"./index-DQXG_mqo.js";import{a as g,c as _,i as v,l as y,n as b,o as x,r as S,s as C,t as w}from"./Markdown-iHvBrpRN.js";var T=e(t(),1),E=n();function D(e,t=0){let n=String(e).toLowerCase().trim().replace(/[^a-z0-9\s-]/g,``).replace(/\s+/g,`-`).replace(/-+/g,`-`).replace(/^-+|-+$/g,``);return n&&/^[a-z]/.test(n)?n:`h-${t}-${n||`section`}`}function O(e){return e.replace(/!?\[([^\]]*)\]\([^)]*\)/g,`$1`).replace(/\[\[([^\]]+)\]\]/g,`$1`).replace(/`([^`]*)`/g,`$1`).replace(/\*\*|__/g,``).replace(/\*([^*\s][^*]*)\*/g,`$1`)}function k(e){let t=[],n=!1,r=0;for(let i of(e||``).split(`
|
|
2
|
+
`)){if(i.startsWith("```")){n=!n;continue}if(n)continue;let e=i.match(/^(##|###)\s+(.+?)\s*$/);e&&(r+=1,t.push({level:e[1].length,title:O(e[2]),id:D(e[2],r)}))}return t}var A={"opencode-global":[`install-opencode`,`Global (recommended)`],opencode:[`install-opencode`,`Per repo`],"claude-global":[`install-claude-code`],claude:[`install-claude-code`],"openclaude-global":[`install-openclaude`],openclaude:[`install-openclaude`],"bob-global":[`install-bob`],bob:[`install-bob`],files:[`install-agent-md`]},j=`you already know this`;function M({page:e,overview:t,onAction:n}){let r=(0,T.useRef)(null),i=(0,T.useMemo)(()=>b(e.body,e.links),[e.body,e.links]);(0,T.useEffect)(()=>{let e=r.current;if(!e)return;let t=0;e.querySelectorAll(`h1, h2, h3`).forEach(e=>{if(e.tagName!==`H1`&&(t+=1),!e.id){let n=D(e.textContent||``,t);n&&(e.id=n)}}),e.querySelectorAll(`blockquote`).forEach(e=>{(e.querySelector(`strong`)?.textContent||``).toLowerCase().startsWith(j)&&e.classList.add(`analogy`)})},[i]),(0,T.useEffect)(()=>{let e=r.current;if(!e)return;let t=e=>{let t=e.target.closest(`a[href]`);if(!t)return;let n=t.getAttribute(`href`);n&&n.startsWith(`#/`)&&(e.preventDefault(),f(n))};return e.addEventListener(`click`,t),()=>e.removeEventListener(`click`,t)},[i]),(0,T.useEffect)(()=>{let n=r.current;if(!n)return;n.querySelectorAll(`.docs-here`).forEach(e=>e.classList.remove(`docs-here`));let[i,a]=A[t?.emit]||[];if(!i)return;let o=null;e.id===`install`?o=n.querySelector(`a[href="#/docs/${i}"]`)?.closest(`li`):e.id===i&&a&&(o=[...n.querySelectorAll(`h2`)].find(e=>D(e.textContent||``)===D(a))),o?.classList.add(`docs-here`)},[i,e.id,t?.emit]);let a=[];return e.id===`install`&&(a.push({label:`Run doctor`,action:`doctor`}),a.push({label:`Rebuild`,action:`build`})),e.id===`verify`&&a.push({label:`Run doctor`,action:`doctor`}),e.id===`upgrade`&&a.push({label:`Update`,action:`update`}),(0,E.jsxs)(`div`,{className:`detail-doc`,children:[(0,E.jsx)(`h1`,{style:{marginTop:0},children:e.title}),e.source&&(0,E.jsx)(`div`,{className:`doc-meta`,children:(0,E.jsxs)(`span`,{className:`badge`,children:[(0,E.jsx)(`span`,{className:`dot`}),e.source]})}),a.length>0&&(0,E.jsx)(`div`,{className:`row wrap gap-10`,style:{margin:`10px 0 14px`},children:a.map(e=>e.hash?(0,E.jsx)(`a`,{className:`btn ghost sm`,href:e.hash,children:e.label},e.label):(0,E.jsx)(`button`,{className:`btn ghost sm`,onClick:()=>n&&n(e.action),children:e.label},e.label))}),(0,E.jsx)(`div`,{className:`markdown`,ref:r,dangerouslySetInnerHTML:{__html:i}}),e.link&&(0,E.jsx)(`div`,{style:{marginTop:24},children:(0,E.jsx)(`a`,{className:`btn soft sm`,href:e.link.hash,children:e.link.label})})]})}var N=1200;function P({a:e,kind:t}){let n=t===`positional`?e.dest:e.names.join(`, `),r=[];return e.metavar&&r.push(e.metavar),e.choices&&r.push(`{${e.choices.join(`|`)}}`),e.default!==null&&e.default!==void 0&&e.default!==``&&!e.is_flag&&r.push(`default: ${e.default}`),e.required&&r.push(`required`),(0,E.jsxs)(`div`,{className:`cli-arg`,children:[(0,E.jsx)(`code`,{className:`cli-arg-name`,children:n}),r.length>0&&(0,E.jsxs)(`code`,{className:`cli-arg-meta`,children:[` `,r.join(` · `)]}),e.help&&(0,E.jsx)(`div`,{className:`cli-arg-help`,children:e.help})]})}function F({text:e}){let[t,n]=(0,T.useState)(!1);return(0,E.jsxs)(`button`,{className:`btn ghost sm`,onClick:async()=>{try{await navigator.clipboard.writeText(e),n(!0),setTimeout(()=>n(!1),N)}catch{}},title:`Copy command`,children:[(0,E.jsx)(c,{name:t?`spark`:`copy`}),t?`Copied`:`Copy`]})}function I({cmd:e,prog:t}){let n=[t,e.name];for(let t of e.positionals||[]){let e=(t.metavar||t.dest||``).toUpperCase();n.push(t.required?e:`[${e}]`)}(e.options||[]).length&&n.push(`[OPTIONS]`);let r=n.join(` `);return(0,E.jsxs)(`div`,{className:`card pad-md mb-12 cli-card`,children:[(0,E.jsxs)(`div`,{className:`row wrap between`,style:{alignItems:`flex-start`},children:[(0,E.jsxs)(`div`,{className:`stack`,style:{gap:4},children:[(0,E.jsx)(`h3`,{style:{margin:0},children:(0,E.jsx)(`code`,{children:e.name})}),e.help&&(0,E.jsx)(`p`,{className:`sub`,style:{margin:0},children:e.help})]}),(0,E.jsx)(F,{text:`${t} ${e.name}`})]}),(0,E.jsx)(`pre`,{className:`cli-syn`,children:r}),(e.positionals||[]).length>0&&(0,E.jsxs)(`div`,{className:`cli-block`,children:[(0,E.jsx)(`div`,{className:`cli-block-head`,children:`Arguments`}),e.positionals.map(e=>(0,E.jsx)(P,{a:e,kind:`positional`},e.dest))]}),(e.options||[]).length>0&&(0,E.jsxs)(`div`,{className:`cli-block`,children:[(0,E.jsx)(`div`,{className:`cli-block-head`,children:`Options`}),e.options.map(e=>(0,E.jsx)(P,{a:e,kind:`option`},e.names.join(`,`)))]})]})}function L({page:e}){let t=e.prog||`geneseed`,n=e.commands||[];return(0,E.jsxs)(`div`,{className:`detail-doc`,children:[(0,E.jsx)(`h1`,{style:{marginTop:0},children:e.title}),(0,E.jsxs)(`p`,{className:`sub`,style:{marginTop:4},children:[`Every subcommand of `,(0,E.jsx)(`code`,{children:t}),`. Generated from the parser at request time (the same one `,(0,E.jsx)(`code`,{children:`geneseed`}),` actually parses), so this page cannot drift.`]}),(0,E.jsx)(`div`,{style:{marginTop:18},children:n.map(e=>(0,E.jsx)(I,{cmd:e,prog:t},e.name))})]})}function R({page:e}){let t=e.rows||[],n=e.theme||`neutral`;return(0,E.jsxs)(`div`,{className:`detail-doc`,children:[(0,E.jsx)(`h1`,{style:{marginTop:0},children:e.title}),(0,E.jsxs)(`p`,{className:`sub`,style:{marginTop:4},children:[`Geneseed's invented vocabulary, decoded. Left: the neutral, plain-English term. Right: the word your `,(0,E.jsx)(`code`,{style:{textTransform:`capitalize`},children:n}),` theme actually uses in the agent's voice. Last: the developer idea it maps to.`]}),(0,E.jsx)(`div`,{className:`card pad-md`,style:{marginTop:18},children:(0,E.jsxs)(`table`,{className:`glossary-table`,children:[(0,E.jsx)(`thead`,{children:(0,E.jsxs)(`tr`,{children:[(0,E.jsx)(`th`,{children:`Concept`}),(0,E.jsx)(`th`,{children:`Neutral term`}),(0,E.jsxs)(`th`,{children:[`In `,n]}),(0,E.jsx)(`th`,{children:`Meaning`}),(0,E.jsx)(`th`,{children:`In dev terms`})]})}),(0,E.jsx)(`tbody`,{children:t.map(e=>(0,E.jsxs)(`tr`,{children:[(0,E.jsx)(`td`,{children:(0,E.jsx)(`strong`,{children:e.label})}),(0,E.jsx)(`td`,{children:(0,E.jsx)(`code`,{children:e.neutral||`—`})}),(0,E.jsx)(`td`,{children:(0,E.jsx)(`code`,{children:e.themed||e.neutral||`—`})}),(0,E.jsx)(`td`,{className:`dim`,children:e.desc}),(0,E.jsx)(`td`,{className:`dim`,children:e.analogy||`—`})]},e.label))})]})})]})}var z={enforced:`ok`,automatic:`ok`,asked:`warn`,"on demand":`warn`};function B(e){let t=[],n=[],r=`before`;for(let i of(e||``).split(`
|
|
3
3
|
`))r===`before`&&/^\|\s*piece\s*\|/i.test(i)?r=`map`:r===`map`&&!i.trimStart().startsWith(`|`)&&(r=`after`),r===`before`?t.push(i):r===`after`&&n.push(i);return[t.join(`
|
|
4
4
|
`),n.join(`
|
|
5
|
-
`)]}var V=({text:e})=>(0,E.jsx)(`span`,{dangerouslySetInnerHTML:{__html:
|
|
5
|
+
`)]}var V=({text:e})=>(0,E.jsx)(`span`,{dangerouslySetInnerHTML:{__html:S(v.parseInline(e||``))}}),H=({kind:e})=>(0,E.jsx)(`span`,{className:`tag ${z[e]||``}`,children:e});function U({page:e,overview:t,onAction:n}){let[r,i]=(0,T.useState)(0);if(!e.rows)return(0,E.jsx)(M,{page:e,overview:t,onAction:n});let a=e.rows[r]||e.rows[0],[o,s]=B(e.body);return(0,E.jsxs)(`div`,{className:`detail-doc`,children:[(0,E.jsx)(`h1`,{style:{marginTop:0},children:e.title}),(0,E.jsx)(w,{body:o,links:e.links}),(0,E.jsxs)(`div`,{className:`docs-map`,children:[(0,E.jsx)(`ul`,{className:`map-tree`,"aria-label":`Pieces`,children:e.rows.map((e,t)=>(0,E.jsx)(`li`,{children:(0,E.jsxs)(`button`,{className:`map-node ${t===r?`on`:``}`,"aria-pressed":t===r,onClick:()=>i(t),children:[(0,E.jsx)(`span`,{className:`map-piece`,children:(0,E.jsx)(V,{text:e.piece})}),(0,E.jsx)(H,{kind:e.kind}),(0,E.jsx)(`span`,{className:`mono dim map-cost`,children:(0,E.jsx)(V,{text:e.cost})})]})},t))}),a&&(0,E.jsxs)(`div`,{className:`card pad-md map-detail`,"aria-live":`polite`,children:[(0,E.jsx)(`h3`,{style:{margin:`0 0 8px`},children:(0,E.jsx)(V,{text:a.piece})}),(0,E.jsx)(H,{kind:a.kind}),(0,E.jsxs)(`dl`,{children:[(0,E.jsx)(`dt`,{children:`Does`}),(0,E.jsx)(`dd`,{children:(0,E.jsx)(V,{text:a.does})}),(0,E.jsx)(`dt`,{children:`Costs`}),(0,E.jsx)(`dd`,{children:(0,E.jsx)(V,{text:a.cost})}),(0,E.jsx)(`dt`,{children:`Turn it off`}),(0,E.jsx)(`dd`,{children:(0,E.jsx)(V,{text:a.off})})]})]})]}),s.trim()&&(0,E.jsx)(w,{body:s,links:e.links})]})}var W=5,G=e=>e.replace(/[.*+?^${}()|[\]\\]/g,`\\$&`);function K(e,t){let n=e||``,r=[];for(let e of t||[])if([...new Set([e.themed,e.neutral,e.label].filter(Boolean))].some(e=>RegExp(`(?<![\\w-])${G(e)}s?(?![\\w-])`,`i`).test(n))&&r.push(e),r.length===W)break;return r}var q=e=>document.getElementById(e)?.scrollIntoView({behavior:`smooth`});function J({body:e,glossaryRows:t}){let n=(0,T.useMemo)(()=>k(e),[e]),r=(0,T.useMemo)(()=>K(e,t),[e,t]);return!n.length&&!r.length?null:(0,E.jsxs)(`aside`,{className:`docs-margin`,children:[n.length>0&&(0,E.jsxs)(`nav`,{className:`docs-toc`,"aria-label":`On this page`,children:[(0,E.jsx)(`div`,{className:`docs-toc-head`,children:`On this page`}),(0,E.jsx)(`ul`,{children:n.map(e=>(0,E.jsx)(`li`,{className:`lvl-${e.level}`,children:(0,E.jsx)(`a`,{href:`#${e.id}`,onClick:t=>{t.preventDefault(),q(e.id)},children:e.title})},e.id))})]}),r.length>0&&(0,E.jsxs)(`div`,{className:`docs-gloss`,children:[(0,E.jsx)(`div`,{className:`docs-toc-head`,children:`Terms on this page`}),r.map(e=>(0,E.jsxs)(`div`,{className:`docs-gloss-card`,children:[(0,E.jsx)(`b`,{children:e.themed||e.neutral||e.label}),(0,E.jsx)(`p`,{children:e.desc})]},e.label))]})]})}function Y({page:e}){let t=e.version||{},n=[[`Theme`,e.theme],[`Install mode`,e.emit],[`Deployed`,e.deployed?`yes`:`no`],[`Target`,(0,E.jsx)(`code`,{children:e.target},`t`)],[`Source root`,(0,E.jsx)(`code`,{children:e.root},`r`)],[`Installed build`,(0,E.jsx)(`code`,{children:t.installed_fp||`(none)`},`i`)],[`Source build`,(0,E.jsx)(`code`,{children:t.source_fp||`—`},`s`)],[`Match?`,t.verdict||`—`],[`License`,e.license]];return(0,E.jsxs)(`div`,{className:`detail-doc`,children:[(0,E.jsx)(`h1`,{style:{marginTop:0},children:e.title}),(0,E.jsx)(`p`,{className:`sub`,style:{marginTop:4},children:`Live snapshot of the install behind this UI, plus where to go next.`}),(0,E.jsx)(`div`,{className:`card pad-md`,style:{marginTop:18},children:n.map(([e,t])=>(0,E.jsxs)(`div`,{className:`kv`,children:[(0,E.jsx)(`span`,{className:`k`,children:e}),(0,E.jsx)(`span`,{className:`v`,children:t??`—`})]},e))}),(0,E.jsxs)(`div`,{className:`row wrap gap-10`,style:{marginTop:18},children:[(0,E.jsxs)(`a`,{className:`btn ghost`,href:e.repo,target:`_blank`,rel:`noreferrer`,children:[(0,E.jsx)(c,{name:`external`}),e.repo_is_github?`GitHub repo`:`Source repo`]}),e.repo_is_github&&(0,E.jsxs)(E.Fragment,{children:[(0,E.jsxs)(`a`,{className:`btn ghost`,href:`${e.repo}/issues`,target:`_blank`,rel:`noreferrer`,children:[(0,E.jsx)(c,{name:`external`}),`File an issue`]}),(0,E.jsxs)(`a`,{className:`btn ghost`,href:`${e.repo}/blob/main/LICENSE`,target:`_blank`,rel:`noreferrer`,children:[(0,E.jsx)(c,{name:`external`}),`License`]})]})]})]})}var X=encodeURIComponent,Z=e=>`#/docs/${X(e)}`;function Q(e){return e?.groups?.[0]?.pages?.[0]?.id||``}function re({data:e,error:t,overview:n,onAction:r}){if(t)return(0,E.jsx)(h,{error:t,style:{margin:18}});if(!e)return(0,E.jsx)(a,{label:`Loading page…`});switch(e.kind){case`markdown`:case`concept`:return(0,E.jsx)(M,{page:e,overview:n,onAction:r});case`map`:return(0,E.jsx)(U,{page:e,overview:n,onAction:r});case`cli`:return(0,E.jsx)(L,{page:e});case`glossary`:return(0,E.jsx)(R,{page:e});case`about`:return(0,E.jsx)(Y,{page:e});default:return(0,E.jsxs)(`div`,{className:`empty`,children:[(0,E.jsx)(`div`,{className:`big`,children:`Unknown page kind`}),e.kind]})}}function $(e){return(e?.pages||[]).map(e=>({name:e.id,title:e.title,desc:e.description||``,group:e.section||`General`,groupC:`var(--accent)`}))}function ie({page:e,overview:t,onAction:n}){let[c,v]=ee(o(t?.emit)),{data:b,error:S}=i(()=>r.docs(c),[c]),w=e||Q(b),{data:D,error:O,loading:k}=i(()=>w?r.docsPage(w,c):Promise.resolve(null),[w,c]),{data:A}=i(()=>r.docsPage(`glossary`,c).catch(()=>null),[c],`docs:glossary`);(0,T.useEffect)(()=>{if(b&&w&&!b.groups.some(e=>e.pages.some(e=>e.id===w))){let e=Q(b);e&&e!==w&&f(Z(e))}},[b,w]),(0,T.useEffect)(()=>{let e=document.scrollingElement||document.documentElement;for(let t of[document.getElementById(`main`),e])t&&(t.scrollTop=0)},[w]);let j=d(b,w),M=j.part||b?.groups?.[0]||null,N=M?.id===p;(0,T.useEffect)(()=>{N&&D?.id===w&&l(w)},[N,D,w]);let P=N?[...m(),w]:[],[F,I]=(0,T.useState)(``),[L,R]=(0,T.useState)(`all`),[z,B]=(0,T.useState)(M?.id);M?.id!==z&&(B(M?.id),I(``),R(`all`));let V=$(M),H=x(V),U=L===`all`?V:V.filter(e=>e.group===L),W=y(U,F);return S?(0,E.jsx)(h,{error:S}):(0,E.jsx)(`div`,{className:`docs-wrap`,children:(0,E.jsxs)(`div`,{className:`library docs-lib`,children:[(0,E.jsxs)(`aside`,{className:`lib-kinds`,"aria-label":`Docs parts`,children:[(0,E.jsxs)(`div`,{className:`lib-title`,children:[(0,E.jsx)(`h1`,{className:`h`,children:`Docs`}),(0,E.jsx)(`span`,{className:`dim`,children:`How it works, and how to use it`})]}),(0,E.jsx)(te,{"aria-label":`Harness`,children:s.map(e=>(0,E.jsx)(`button`,{className:c===e.id?`on`:``,onClick:()=>v(e.id),"aria-pressed":c===e.id,children:e.label},e.id))}),(0,E.jsx)(`nav`,{className:`kind-list`,"aria-label":`Parts`,children:(b?.groups||[]).map(e=>(0,E.jsxs)(T.Fragment,{children:[(0,E.jsxs)(`a`,{href:e.pages[0]?Z(e.pages[0].id):`#/docs`,className:M?.id===e.id?`on`:``,"aria-current":M?.id===e.id?`page`:void 0,children:[e.label,(0,E.jsx)(`span`,{className:`mono dim`,children:e.pages.length})]}),M?.id===e.id&&(0,E.jsx)(g,{label:`Sections`,total:V.length,cats:H,cat:L,onChange:R})]},e.id))})]}),(0,E.jsx)(_,{label:M?.label||`Docs`,count:F.trim()?`${W.length} of ${U.length}`:U.length||``,extra:N&&(0,E.jsx)(ne,{pages:M.pages,seen:P}),q:F,onQ:I,matched:W.length,inView:[M?.id,w],children:b?(0,E.jsx)(C,{rows:W,activeName:w,hrefOf:e=>Z(e.name),pills:N?e=>P.includes(e.name)&&e.name!==w?(0,E.jsxs)(`span`,{className:`docs-read-mark`,children:[(0,E.jsx)(`span`,{"aria-hidden":`true`,children:`✓`}),(0,E.jsx)(`span`,{className:`sr-only`,children:`read`})]}):null:void 0}):(0,E.jsx)(a,{label:`Loading docs…`})}),(0,E.jsxs)(`article`,{className:`lib-reader docs-reader`,"aria-label":`Page`,children:[j.page&&(0,E.jsxs)(`nav`,{className:`docs-crumbs mono`,"aria-label":`Breadcrumb`,children:[(0,E.jsx)(`a`,{href:Z(j.part.pages[0].id),children:j.part.label}),(0,E.jsx)(`span`,{"aria-hidden":`true`,children:`›`}),(0,E.jsx)(`a`,{href:Z(j.part.pages.find(e=>(e.section||`General`)===j.section).id),children:j.section}),(0,E.jsx)(`span`,{"aria-hidden":`true`,children:`›`}),(0,E.jsx)(`span`,{"aria-current":`page`,children:j.page.title})]}),(0,E.jsxs)(`div`,{className:`docs-read`,children:[(0,E.jsxs)(`div`,{className:`docs-article`,children:[(0,E.jsx)(re,{data:k?null:D,error:O,overview:t,onAction:n},`${w}|${c}`),!k&&(0,E.jsx)(u,{menu:b,pageId:w})]}),!k&&(0,E.jsx)(J,{body:D?.body,glossaryRows:A?.rows})]})]})]})})}export{ie as default,$ as docRows};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{n as e,r as t,s as n}from"./sections-BET3c1WT.js";import{i as r,t as i}from"./react-BOF6yL40.js";import{t as a}from"./drawable-CyLe1gtW.js";import{F as o,J as s,N as c,X as l,Y as u,et as d,rt as f}from"./index-DQXG_mqo.js";import{t as p}from"./jobBuckets-Dbq8ZlWW.js";import{n as m}from"./Dashboard-C5ATa3ow.js";var h=n(r(),1),g=i(),_=12,v=120,y=[`#2BB673`,`#16A6A6`,`#E8A23B`,`#E07A5F`,`#8E7DBE`,`#5BD08A`,`#79856E`],b=650;function x({segments:e,size:t=186,stroke:n=26,caption:r=`capabilities`}){let i=e.reduce((e,t)=>e+t.value,0)||1,o=(0,h.useRef)(null),c=e.map(e=>e.value).join(`,`);(0,h.useLayoutEffect)(()=>{let t=o.current?.querySelectorAll(`path`);if(!t?.length||!u())return;let n=e.filter(e=>e.value>0).map(e=>e.value/i),r=n.map((e,t)=>n.slice(0,t).reduce((e,t)=>e+t,0)),s=a(t);d(s,{draw:`0 0`});let c=f(s,{draw:[`0 0`,`0 1`],duration:(e,t)=>Math.max(b*n[t],60),delay:(e,t)=>b*r[t],ease:`linear`});return l(c,b)},[c]);let p=t/2-n/2,m=t/2,_=t/2,v=[],y=0;for(let t of e)v.push(y),y+=t.value;return(0,g.jsxs)(`svg`,{width:t,height:t,viewBox:`0 0 ${t} ${t}`,children:[(0,g.jsx)(`circle`,{cx:m,cy:_,r:p,fill:`none`,stroke:`var(--surface-3)`,strokeWidth:n}),(0,g.jsx)(`g`,{ref:o,children:e.map((e,t)=>{if(e.value/i<=0)return null;let r=v[t]/i*2*Math.PI-Math.PI/2,a=(v[t]+e.value)/i*2*Math.PI-Math.PI/2,o=m+p*Math.cos(r),s=_+p*Math.sin(r),c=m+p*Math.cos(a),l=_+p*Math.sin(a),u=+(a-r>Math.PI);return(0,g.jsx)(`path`,{d:`M ${o} ${s} A ${p} ${p} 0 ${u} 1 ${c} ${l}`,fill:`none`,stroke:e.color,strokeWidth:n,strokeLinecap:`butt`,children:(0,g.jsxs)(`title`,{children:[e.label,`: `,e.value]})},t)})}),(0,g.jsx)(`text`,{x:m,y:_-4,textAnchor:`middle`,className:`donut-c-num`,children:(0,g.jsx)(s,{value:i,duration:b})}),(0,g.jsx)(`text`,{x:m,y:_+16,textAnchor:`middle`,className:`donut-c-cap`,children:r})]})}function S(e){if(e.length<2)return e.length?`M${e[0][0]},${e[0][1]}`:``;let t=`M${e[0][0]},${e[0][1]}`;for(let n=0;n<e.length-1;n++){let r=e[n-1]||e[n],i=e[n],a=e[n+1],o=e[n+2]||a,s=i[0]+(a[0]-r[0])/6,c=i[1]+(a[1]-r[1])/6,l=a[0]-(o[0]-i[0])/6,u=a[1]-(o[1]-i[1])/6;t+=` C${s},${c} ${l},${u} ${a[0]},${a[1]}`}return t}function C({data:e,height:t=156,accent:n}){if(!e.length)return null;let r=t,i=Math.max(...e.map(e=>e.v),1)+1,a=e.length>1?588/(e.length-1):588,o=e.map((e,t)=>[6+t*a,r-6-e.v/i*(r-14-6)]),s=S(o),c=o[o.length-1],l=o[0],u=`${s} L${c[0]},${r} L${l[0]},${r} Z`;return(0,g.jsxs)(`svg`,{viewBox:`0 0 600 ${r}`,preserveAspectRatio:`none`,style:{width:`100%`,height:t,display:`block`,overflow:`visible`},children:[(0,g.jsx)(`defs`,{children:(0,g.jsxs)(`linearGradient`,{id:`b-grad`,x1:`0`,y1:`0`,x2:`0`,y2:`1`,children:[(0,g.jsx)(`stop`,{offset:`0`,stopColor:n,stopOpacity:`.28`}),(0,g.jsx)(`stop`,{offset:`1`,stopColor:n,stopOpacity:`0`})]})}),(0,g.jsx)(`path`,{d:u,fill:`url(#b-grad)`}),(0,g.jsx)(`path`,{d:s,fill:`none`,stroke:n,strokeWidth:`2`,strokeLinejoin:`round`,strokeLinecap:`round`,vectorEffect:`non-scaling-stroke`}),(0,g.jsx)(`circle`,{cx:c[0],cy:c[1],r:`3.5`,fill:n,vectorEffect:`non-scaling-stroke`})]})}function w({label:e,value:t,sub:n,color:r,icon:i}){return(0,g.jsxs)(`div`,{className:`b-tile`,children:[(0,g.jsx)(`span`,{className:`b-tile-ic`,style:{background:`color-mix(in srgb, ${r} 18%, transparent)`,color:r},children:(0,g.jsx)(c,{name:i})}),(0,g.jsxs)(`div`,{className:`b-tile-body`,children:[(0,g.jsx)(`div`,{className:`b-tile-val`+(t===0?` zero`:``),children:t}),(0,g.jsx)(`div`,{className:`b-tile-label`,children:e})]}),(0,g.jsx)(`div`,{className:`b-tile-sub`,children:n})]})}function T({overview:n,sigil:r,jobs:i,doctor:a,onAction:l}){let u=n.counts||{},d=a?.groups||[],f=d.length>0,h=d.filter(e=>e.problems.length===0).length,b=d.length||1,S=m(n),T=o(n.diff),E=t.filter(e=>(u[e]||0)>0).map((t,n)=>({label:e[t].label,value:u[t]||0,color:y[n%y.length]})),D=E.reduce((e,t)=>e+t.value,0),O=p(i||[],10),k=O.reduce((e,t)=>e+t.v,0);return(0,g.jsxs)(g.Fragment,{children:[(0,g.jsxs)(`div`,{className:`b-greet`,children:[(0,g.jsxs)(`div`,{children:[(0,g.jsx)(`div`,{className:`eyebrow`,children:`your harness`}),(0,g.jsx)(`h1`,{className:`h b-h`,children:S}),(0,g.jsx)(`p`,{className:`sub`,children:r||`A friendly read of every layer growing in your harness.`})]}),(0,g.jsxs)(`div`,{className:`row gap-8`,children:[(0,g.jsxs)(`button`,{className:`btn`,onClick:()=>l(`update`),children:[(0,g.jsx)(c,{name:`refresh`}),`Update`]}),(0,g.jsxs)(`button`,{className:`btn ghost`,onClick:()=>l(`build-all`),children:[(0,g.jsx)(c,{name:`build`}),`Rebuild`]})]})]}),(0,g.jsxs)(`div`,{className:`grid b-hero-grid mb-16`,children:[(0,g.jsxs)(`div`,{className:`card b-hero`,children:[(0,g.jsx)(`div`,{className:`b-hero-ring`,children:(0,g.jsx)(x,{segments:[{label:`pass`,value:h,color:y[0]},{label:`attention`,value:Math.max(b-h,0),color:y[2]}],size:168,stroke:20,caption:`checks`})}),(0,g.jsxs)(`div`,{className:`b-hero-side`,children:[(0,g.jsx)(`h3`,{className:`b-hero-title`,children:f?`${h} of ${b} checks pass`:`Running checks…`}),(0,g.jsxs)(`p`,{className:`sub`,children:[`One source, rendered into `,(0,g.jsx)(`code`,{children:n.target}),` and inherited by every repo on this machine.`]}),f&&(0,g.jsx)(`ul`,{className:`b-hero-checks`,children:d.map(e=>{let t=e.problems.length===0;return(0,g.jsxs)(`li`,{className:`b-hcheck ${t?`ok`:`bad`}`,title:t?`clean`:e.problems.join(`; `),children:[(0,g.jsx)(`span`,{className:`b-hcheck-mark`,children:t?`✓`:`!`}),(0,g.jsx)(`span`,{className:`b-hcheck-label`,children:e.label})]},e.label)})}),(0,g.jsxs)(`div`,{className:`b-chips`,children:[(0,g.jsxs)(`span`,{className:`b-chip`,children:[(0,g.jsx)(`b`,{style:{textTransform:`capitalize`},children:n.theme}),` voice`]}),(0,g.jsx)(`span`,{className:`b-chip`,children:(0,g.jsx)(`b`,{children:n.emit})}),(0,g.jsxs)(`span`,{className:`b-chip`,children:[`built `,(0,g.jsx)(`b`,{children:n.build_time||`unknown`})]})]})]})]}),(0,g.jsxs)(`div`,{className:`b-tiles`,children:[(0,g.jsx)(w,{label:`Agents`,value:u.agents??`—`,sub:`specialists`,color:y[0],icon:`layers`}),(0,g.jsx)(w,{label:`Skills`,value:u.skills??`—`,sub:`workflows`,color:y[1],icon:`skill`}),(0,g.jsx)(w,{label:`Dictates`,value:u.laws??`—`,sub:u.doctrines?`${u.doctrines.active}/${u.doctrines.total} packs · ${u.doctrines.rules} rules`:`all upheld`,color:y[2],icon:`law`}),(0,g.jsx)(w,{label:`Edits`,value:T,sub:`to graft`,color:y[3],icon:`changes`})]})]}),(0,g.jsxs)(`div`,{className:`grid split-even mb-16`,children:[(0,g.jsxs)(`div`,{className:`card pad-lg b-mix-card`,children:[(0,g.jsxs)(`div`,{className:`card-head`,children:[(0,g.jsx)(`h3`,{children:`Capability mix`}),(0,g.jsx)(`div`,{className:`right`,children:(0,g.jsxs)(`span`,{className:`tick`,children:[D,` total`]})})]}),(0,g.jsxs)(`div`,{className:`b-mix`,children:[(0,g.jsx)(x,{segments:E,size:186,stroke:26}),(0,g.jsx)(`div`,{className:`b-legend`,children:E.map(e=>(0,g.jsxs)(`div`,{className:`b-leg-row`,children:[(0,g.jsx)(`span`,{className:`b-leg-dot`,style:{background:e.color}}),(0,g.jsx)(`span`,{className:`b-leg-name`,children:e.label}),(0,g.jsx)(`span`,{className:`b-leg-bar`,children:(0,g.jsx)(`i`,{style:{width:`${e.value/D*100}%`,background:e.color}})}),(0,g.jsx)(`span`,{className:`b-leg-val`,children:e.value})]},e.label))})]})]}),(0,g.jsxs)(`div`,{className:`card pad-lg`,children:[(0,g.jsxs)(`div`,{className:`card-head`,children:[(0,g.jsx)(`h3`,{children:`Recent runs`}),(0,g.jsx)(`div`,{className:`right`,children:(0,g.jsxs)(`span`,{className:`badge ok`,children:[(0,g.jsx)(`span`,{className:`dot`}),`job log`]})})]}),(0,g.jsxs)(`div`,{className:`b-stat-lead`,children:[(0,g.jsx)(`span`,{className:`b-stat-big`,children:(0,g.jsx)(s,{value:k})}),(0,g.jsxs)(`span`,{className:`b-stat-cap`,children:[`runs in the last 10 days · `,h,`/`,b,` checks pass now`]})]}),(0,g.jsx)(C,{data:O,accent:y[0],height:156})]})]}),(0,g.jsxs)(`div`,{className:`card pad-lg`,children:[(0,g.jsxs)(`div`,{className:`card-head`,children:[(0,g.jsx)(`h3`,{children:`Recent activity`}),(0,g.jsx)(`div`,{className:`right`,children:(0,g.jsxs)(`span`,{className:`tick`,children:[`last `,Math.min(i?.length||0,12),` runs`]})})]}),(0,g.jsxs)(`div`,{className:`b-timeline`,children:[(i||[]).slice(0,_).map(e=>{let t=e.status===`done`,n=e.status===`failed`?`warn`:t?`ok`:`acc`;return(0,g.jsxs)(`div`,{className:`b-tl-row`,children:[(0,g.jsx)(`span`,{className:`b-tl-node ${n}`}),(0,g.jsxs)(`div`,{className:`b-tl-body`,children:[(0,g.jsx)(`b`,{children:e.action}),e.output?`: ${e.output.split(`
|
|
2
|
+
`)[0].slice(0,v)}`:``]}),(0,g.jsx)(`span`,{className:`b-tl-when`,children:e.duration?`${e.duration}s`:e.status})]},e.id)}),(!i||i.length===0)&&(0,g.jsxs)(`div`,{className:`b-tl-row`,children:[(0,g.jsx)(`span`,{className:`b-tl-node`}),(0,g.jsx)(`div`,{className:`b-tl-body sub`,children:`No runs yet. Trigger an action to populate this.`}),(0,g.jsx)(`span`,{className:`b-tl-when`,children:`—`})]})]})]})]})}export{T as default};
|