geneseed 3.16.0 → 3.18.0
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 +45 -0
- package/README.md +17 -3
- package/SHIPPED.md +3 -3
- package/adapters/claude-code/skills/geneseed/SKILL.md +1 -1
- package/adapters/opencode/README.md +2 -2
- package/adapters/opencode/plugins/geneseed-context.js +31 -21
- package/adapters/opencode/plugins/geneseed-guard.js +35 -7
- package/bin/geneseed-cli.mjs +5 -0
- package/bin/geneseed.mjs +17 -0
- package/docs/concepts/exclusions.md +1 -1
- package/docs/concepts/hooks.md +1 -0
- package/docs/concepts/loop-notes.md +3 -0
- package/docs/concepts/loops.md +11 -0
- package/docs/concepts/skills.md +4 -0
- package/docs/extending.md +33 -0
- package/docs/guides/headless.md +1 -1
- package/docs/guides/project-context.md +2 -2
- package/docs/guides/read-non-markdown.md +2 -2
- package/docs/guides/uninstall.md +1 -1
- package/docs/guides/upgrade.md +1 -1
- package/docs/guides/wiki.md +4 -4
- package/docs/opencode-plugin-setup.md +1 -1
- package/docs/reference/env-context.md +2 -2
- package/docs/reference/plugin-context.md +4 -4
- package/docs/reference/plugin-guard.md +1 -1
- package/docs/token-footprint.md +18 -15
- package/docs/understand/take-it-out.md +1 -1
- package/harness.config.json +1 -1
- package/js/README.md +4 -1
- package/js/build/args.mjs +22 -20
- package/js/build/bundle.mjs +1 -3
- package/js/build/emit-claude.mjs +5 -4
- package/js/build/emit-opencode.mjs +9 -2
- package/js/build/generate.mjs +6 -6
- package/js/build/render.mjs +19 -12
- package/js/build/source.mjs +82 -7
- package/js/build/stubs.mjs +35 -6
- package/js/build/themes.mjs +1 -3
- package/js/cli-table.json +53 -0
- package/js/hosts/hooks-context.mjs +40 -27
- package/js/hosts/hooks.mjs +34 -1
- package/js/hosts/hosts.mjs +1 -3
- package/js/hosts/installs.mjs +13 -7
- package/js/hosts/mcp.mjs +1 -1
- package/js/hosts/native.mjs +60 -5
- package/js/hosts/opencode.mjs +37 -6
- package/js/hosts/settings.mjs +3 -1
- package/js/hosts/shim.mjs +1 -0
- package/js/inspect/checks-authoring.mjs +4 -1
- package/js/inspect/checks-constitution.mjs +2 -2
- package/js/inspect/checks-repo.mjs +164 -2
- package/js/inspect/diff.mjs +5 -1
- package/js/inspect/doctor.mjs +2 -1
- package/js/inspect/inventory.mjs +7 -9
- package/js/inspect/scorecard-checks.mjs +571 -0
- package/js/inspect/scorecard-svg.mjs +85 -0
- package/js/inspect/scorecard.mjs +839 -0
- package/js/lib/json.mjs +1 -1
- package/js/loop/graph.mjs +2 -1
- package/js/loop/state.mjs +30 -1
- package/js/maintain/migrate.mjs +2 -1
- package/js/maintain/uninstall.mjs +2 -3
- package/js/maintain/update.mjs +10 -3
- package/js/ui/menu.mjs +2 -2
- package/js/ui/tui.mjs +1 -0
- package/js/web/api.mjs +2 -0
- package/js/web/catalog.mjs +24 -7
- package/js/web/daemon.mjs +2 -1
- package/js/web/routes.mjs +2 -0
- package/js/web/server.mjs +1 -1
- package/js/web/user-files.mjs +1 -0
- package/package.json +11 -3
- package/registry.json +12 -75
- package/src/AGENT.md.tmpl +13 -22
- package/src/agents/docs.md +5 -0
- package/src/agents/researcher.md +1 -1
- package/src/bricks/apply.md +3 -0
- package/src/bricks/bruno-test.md +2 -2
- package/src/bricks/ci-fix.md +3 -3
- package/src/bricks/deps-audit.md +3 -3
- package/src/bricks/docs-update.md +2 -0
- package/src/bricks/migration-plan.md +2 -2
- package/src/bricks/test.md +17 -7
- package/src/doctrines/process.md +11 -7
- package/src/laws/universal.md +2 -2
- package/src/loops/api-endpoint.json +1 -1
- package/src/loops/bugfix.json +1 -1
- package/src/loops/ci-repair.json +1 -1
- package/src/loops/deps-upgrade.json +1 -1
- package/src/loops/enforce-architecture-rule.json +1 -1
- package/src/loops/feature.json +1 -1
- package/src/loops/fix-flaky-tests.json +1 -1
- package/src/loops/legacy-refactor.json +1 -1
- package/src/loops/legacy-tests.json +1 -1
- package/src/loops/refactor.json +1 -1
- package/src/loops/remove-dead-code.json +1 -1
- package/src/loops/spec-first-feature.json +1 -1
- package/src/loops/tdd.json +1 -1
- package/src/loops/update-contract.json +1 -1
- package/src/skills/brainstorm.md +14 -10
- package/src/skills/bruno.md +84 -0
- package/src/skills/codebase-design.md +41 -23
- package/src/skills/daydream/SKILL.md +3 -3
- package/src/skills/daydream/VENDOR.md +2 -2
- package/src/skills/daydream/instructions.md +1 -1
- package/src/skills/debug/ci.md +11 -0
- package/src/skills/debug.md +11 -8
- package/src/skills/dependencies.md +65 -0
- package/src/skills/develop.md +9 -4
- package/src/skills/document-project.md +106 -32
- package/src/skills/geneseed-code-review.md +13 -8
- package/src/skills/geneseed.md +4 -1
- package/src/skills/git-history.md +78 -0
- package/src/skills/handoff.md +4 -3
- package/src/skills/parallel-agents.md +1 -0
- package/src/skills/plan.md +5 -1
- package/src/skills/prototype.md +10 -7
- package/src/skills/research.md +6 -1
- package/src/skills/rule/consolidate.md +32 -0
- package/src/skills/rule.md +14 -4
- package/src/skills/security-audit.md +1 -1
- package/src/skills/ship.md +8 -5
- package/src/skills/teach.md +5 -3
- package/src/skills/wayfinder.md +19 -16
- package/src/skills/wiki.md +2 -2
- package/themes/_TEMPLATE.json +7 -16
- package/themes/biker.json +7 -16
- package/themes/commentator.json +7 -16
- package/themes/cyberpunk.json +7 -16
- package/themes/gamer.json +7 -16
- package/themes/imperial.json +7 -16
- package/themes/joker.json +7 -16
- package/themes/marvin.json +7 -16
- package/themes/mean.json +7 -16
- package/themes/military.json +7 -16
- package/themes/neutral.json +7 -16
- package/themes/pirate.json +7 -16
- package/themes/sports.json +7 -16
- package/themes/verstappen.json +7 -16
- package/themes/wizard.json +7 -16
- package/web/dist/assets/{Activity-kpWxd70F.js → Activity-4M4VQJOh.js} +1 -1
- package/web/dist/assets/{ActivityDetail-Ccr942VL.js → ActivityDetail-CnmDs43F.js} +1 -1
- package/web/dist/assets/{Dashboard-D1lE7jcg.js → Dashboard-lTaH58R9.js} +2 -2
- package/web/dist/assets/{Docs-BHyaggFy.js → Docs-DU5znu5f.js} +1 -1
- package/web/dist/assets/FilterInput-BSfpStOZ.js +1 -0
- package/web/dist/assets/{GreenhouseView-Sc_UDMOE.js → GreenhouseView-BxO84bKX.js} +1 -1
- package/web/dist/assets/{Installs-Gw-pJ3Zi.js → Installs-B1WcObxK.js} +1 -1
- package/web/dist/assets/{JournalView-_gxpsxXi.js → JournalView-0YNKcaaD.js} +1 -1
- package/web/dist/assets/{Laws-S9fq1r9T.js → Laws-DnDpRwpE.js} +1 -1
- package/web/dist/assets/Library-DBkKsBMe.js +1 -0
- package/web/dist/assets/{Loops-Da_JhlzM.js → Loops-P-6RCdzS.js} +1 -1
- package/web/dist/assets/Markdown-C6fRd4A4.js +67 -0
- package/web/dist/assets/{OperatorHudView--TkvDybH.js → OperatorHudView-BZZ3uJPH.js} +1 -1
- package/web/dist/assets/{Personal-CTXKHVbV.js → Personal-BoVw6OCW.js} +1 -1
- package/web/dist/assets/{Tabs-B0cdf8k6.js → Tabs-VYLhUTiX.js} +1 -1
- package/web/dist/assets/{activity-Dr7ZMBI3.js → activity-dcg5vF9j.js} +1 -1
- package/web/dist/assets/{drawable-BbWQxe82.js → drawable-CdNARIKC.js} +1 -1
- package/web/dist/assets/{index-ujKG1ZNf.js → index-hsabpYzv.js} +2 -2
- package/web/dist/assets/react-DRhoX0kS.js +9 -0
- package/web/dist/assets/{usePoll-DD8VjtSg.js → usePoll-BmR631BB.js} +1 -1
- package/web/dist/index.html +2 -2
- package/src/skills/bruno-collection-generator.md +0 -52
- package/src/skills/bruno-test-writer.md +0 -51
- package/src/skills/ci-fix.md +0 -49
- package/src/skills/consolidate-memory.md +0 -50
- package/src/skills/deps-audit.md +0 -46
- package/src/skills/domain-modeling.md +0 -27
- package/src/skills/git-archaeology.md +0 -36
- package/src/skills/git-rescue.md +0 -58
- package/src/skills/migrate.md +0 -34
- package/src/skills/opencode-theme.md +0 -42
- package/src/skills/repo-map.md +0 -25
- package/src/skills/tickets.md +0 -33
- package/web/dist/assets/FilterInput-CVyqmYWM.js +0 -1
- package/web/dist/assets/Library-MBxadRzn.js +0 -1
- package/web/dist/assets/Markdown-X2a3qvOh.js +0 -38
- package/web/dist/assets/react-B9Z_tXRV.js +0 -8
package/themes/sports.json
CHANGED
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
"DESC_REVIEWER": "Runs the pre-game review — correctness first, then form, before it ships.",
|
|
18
18
|
"DESC_TESTER": "Sets up the drills, runs them, and breaks down the tape when they fail.",
|
|
19
19
|
"DESC_DEVELOPER": "Builds the scoped play in its own practice field, runs it once, then hands it to the tester.",
|
|
20
|
-
"DESC_THEME": "Train up your own OpenCode colour theme — pick or tweak a palette, get solid and transparent kits, they stay through every rebuild.",
|
|
21
20
|
"DESC_ARCHITECT": "Draws up the game plan before the first snap.",
|
|
22
21
|
"DESC_DOCS": "Files the post-game report and the playbook once the work lands.",
|
|
23
22
|
"DESC_SECURITY": "Runs the integrity check on anything touching the security surface.",
|
|
@@ -34,24 +33,20 @@
|
|
|
34
33
|
"DESC_OPERATOR": "Speaks for game day — how it holds under pressure, the upkeep, and the load on the crew that runs it.",
|
|
35
34
|
"DESC_HISTORIAN": "Calls up the archive — what was tried before, how it played, and the lesson for this call.",
|
|
36
35
|
"DESC_PLAN": "Draw the game plan before a non-trivial task; track the score as it goes.",
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"DESC_GIT_RESCUE": "Recover a blown or messy repo, or rewrite history clean — reflog, undo, rebase, every move backed up first.",
|
|
40
|
-
"DESC_REPO_MAP": "Chart the field — a single-read map of the repository, kept current.",
|
|
36
|
+
"DESC_DEPENDENCIES": "Audit the roster — outdated, injured and reachable, retired, dead weight — into a risk-ordered upgrade plan, then move up one change at a time, tests green between each.",
|
|
37
|
+
"DESC_GIT_HISTORY": "Go to the tape, look but don't touch, to find when the regression landed or why the code's there — bisect, blame, pickaxe — or recover a blown or messy repo and rewrite history clean, every move backed up first.",
|
|
41
38
|
"DESC_DOCUMENT_PROJECT": "Draw up the PRD, design system, architecture and AGENTS.md from the current code, fix the playbook, and re-cut the offline HTML overview.",
|
|
42
39
|
"DESC_COMMIT": "Stage only what this drive touched and log a focused commit.",
|
|
43
40
|
"DESC_CODE_REVIEW": "Review a diff or PR — correctness first, form second.",
|
|
44
41
|
"DESC_BRAINSTORM": "Turn a raw idea into an agreed game plan before any code is run.",
|
|
45
|
-
"DESC_CODEBASE_DESIGN": "Design deep modules — a lot
|
|
46
|
-
"DESC_DOMAIN_MODELING": "Keep the glossary in CONTEXT.md current, and log every structural call as an ADR.",
|
|
42
|
+
"DESC_CODEBASE_DESIGN": "Design deep modules and the team's own language — a lot behind a small interface, seam placed by the game plan, a living GLOSSARY.md, an ADR for every call too costly to reverse.",
|
|
47
43
|
"DESC_WAYFINDER": "Chart work too big for one game as a shared map of decision tickets, resolved one at a time until the field's clear.",
|
|
48
|
-
"DESC_TICKETS": "Split a spec into tracer-bullet tickets with explicit blocking edges, each sized for one fresh drive.",
|
|
49
44
|
"DESC_PROTOTYPE": "Answer a design question with throwaway code — built to learn the play, never to keep.",
|
|
50
45
|
"DESC_ROAST_ME": "Hard post-game breakdown of any work — blunt, exact, always actionable.",
|
|
51
46
|
"DESC_FRESH_EYES": "Bring on a fresh official who saw none of the training — just the original game plan and the finished play; they set the scoring line blind, then rule whether it counts, with none of the player's own hype.",
|
|
52
47
|
"ROAST_PERSONA": "a veteran color commentator who has called this exact blunder cost a championship",
|
|
53
48
|
"DESC_COUNCIL": "Bring a panel of opposing voices to debate the call, then deliver the verdict with the dissent on the tape.",
|
|
54
|
-
"DESC_DEBUG": "Break down the fault on tape — reproduce, isolate, root-cause, confirm the fix.",
|
|
49
|
+
"DESC_DEBUG": "Break down the fault on tape — a play that fails on it first, reproduce, isolate, root-cause, confirm the fix — a red CI run included, reproduced under CI's own conditions.",
|
|
55
50
|
"DESC_REFACTOR": "Rework the formation without changing the result — one named move, tests green throughout.",
|
|
56
51
|
"DESC_PONYTAIL": "The laziest play that scores — least code, shortest path; standard kit before custom plays, one line before fifty. lite/full/ultra.",
|
|
57
52
|
"DESC_PARALLEL_AGENTS": "Send several players on independent plays at once, then regroup the results.",
|
|
@@ -65,18 +60,15 @@
|
|
|
65
60
|
"DESC_SECURITY_AUDIT": "Scout the change like the opposing team would — where it can be attacked, what it leaks, what it pulls in from outside — and call it: play it, fix it, or bench it.",
|
|
66
61
|
"DESC_SKILL_FORGE": "Draw up, sharpen, merge, or retire a play — reuse the playbook first, trigger before the steps, tested against neighbouring plays, every satellite registered, doctor green.",
|
|
67
62
|
"DESC_WORKTREE": "Run a task on its own practice field — a fresh worktree off a clean base, nothing shared with the game in progress, back through the normal gate, field cleared once merged.",
|
|
68
|
-
"DESC_CI_FIX": "Turn a red CI run green at the cause — read the tape, classify the failure, reproduce under CI's own conditions, fix, and watch the re-run.",
|
|
69
|
-
"DESC_DEPS_AUDIT": "Audit the roster — outdated, injured and reachable, retired, dead weight — into a risk-ordered upgrade plan for migrate to execute, signing nothing yet.",
|
|
70
|
-
"DESC_CONSOLIDATE_MEMORY": "Tend the film room — verify each note against the live season, merge duplicates, cut stale ones, promote recurring lessons to team rules, rebuild the index.",
|
|
71
63
|
"DESC_HANDOFF": "Hand off cleanly — snapshot the state so a fresh player picks up in one read.",
|
|
72
64
|
"DESC_SHIP": "Make the call: open a PR with a clear recap, or merge the branch, once it's verified.",
|
|
73
65
|
"DESC_RELEASE": "Ship the release — bump the version, write the recap, tag it, all in sync.",
|
|
74
66
|
"DESC_INGEST": "Bring a PDF, Office, or web document into clean markdown before reading it.",
|
|
75
67
|
"DESC_RESEARCH": "Work the scouting report — search wide, then confirm every claim against independent sources before you call it.",
|
|
76
68
|
"DESC_HERDR": "Drive herdr from inside it — split panes, spawn sibling agents, wait on output, read other panes.",
|
|
77
|
-
"DESC_RULE": "Ask first — standing house rule, or just one for the notes? Then log the memory, or run the rule against the play that breaks it before it goes on the board in user-rules.md.",
|
|
69
|
+
"DESC_RULE": "Ask first — standing house rule, or just one for the notes? Then log the memory, or run the rule against the play that breaks it before it goes on the board in user-rules.md — and keep tending the film room: merge, cut, promote.",
|
|
78
70
|
"DESC_PROFILE": "Write the scouting report in PROFILE.md — position, playing style, how they want the play called; identity only, team rules go on the board in user-rules.md.",
|
|
79
|
-
"DESC_GENESEED": "Operate the deployed Geneseed harness — find each install and its settings, read its files, run status, doctor and diff, and rebuild it with one setting changed when the user asks.",
|
|
71
|
+
"DESC_GENESEED": "Operate the deployed Geneseed harness — find each install and its settings, read its files, run status, doctor and diff, and rebuild it with one setting changed when the user asks — and train up the user's own OpenCode colour theme.",
|
|
80
72
|
"DESC_REVIEW_RESPONSE": "Take the review like game tape — verify each note, then adjust or push back with reasons.",
|
|
81
73
|
"LEX_SEALED_SECRETS": "Guard the Signs · Sealed Secrets",
|
|
82
74
|
"LEX_ONE_INTENT_ONE_ACT": "One Play at a Time · One Intent, One Act",
|
|
@@ -145,8 +137,7 @@
|
|
|
145
137
|
"INTRO_WIKI": "The club may keep a playbook on this machine — a vault of cross-referenced plays and scouting that outlasts any single season.",
|
|
146
138
|
"DESC_WIKI": "Work the franchise playbook — study the relevant play before the snap, draw up new ones cross-referenced, and file them in the right chapter.",
|
|
147
139
|
"DESC_MCP": "Build or harden an MCP server — study the spec, design task-ready tools, test with the Inspector, and prove it on the evals.",
|
|
148
|
-
"
|
|
149
|
-
"DESC_BRUNO_TEST_WRITER": "Write Bruno tests for a request or the full collection — status, shape, chaining — no secret leaks, no call the tape does not back.",
|
|
140
|
+
"DESC_BRUNO": "Build, reorganise or test a Bruno collection — requests, environments, assertions, chaining — secrets kept as placeholders, no leaks, no call the tape doesn't back.",
|
|
150
141
|
"DESC_PROSE": "Write like a human, not a machine — cut the filler, keep it active, vary the tempo, trust the reader.",
|
|
151
142
|
"DESC_FRONTEND_DESIGN": "Design a UI with a point of view — palette, type, and layout built for this brief, not the stock defaults, then cut to one bold move.",
|
|
152
143
|
"DESC_WORKFLOW": "Run a saved set play that drives your squad on script — parallel runs, staged phases, and a verified result, all in one deterministic drive.",
|
package/themes/verstappen.json
CHANGED
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
"DESC_REVIEWER": "Checks the car over before it goes out — correctness first, polish second.",
|
|
18
18
|
"DESC_TESTER": "Builds the test runs, sends them, and reads the data when they go wrong.",
|
|
19
19
|
"DESC_DEVELOPER": "Builds the scoped fix in its own garage, checks it once, then hands it to the tester for the real run.",
|
|
20
|
-
"DESC_THEME": "Build your own OpenCode colour theme — pick or fine-tune a palette, get solid and transparent setups, they survive every rebuild.",
|
|
21
20
|
"DESC_ARCHITECT": "Sorts the strategy before a single line is committed.",
|
|
22
21
|
"DESC_DOCS": "Writes up the debrief and the notes once the work is done.",
|
|
23
22
|
"DESC_SECURITY": "Goes over anything touching the security surface with a fine comb.",
|
|
@@ -34,24 +33,20 @@
|
|
|
34
33
|
"DESC_OPERATOR": "Speaks for the car under load — reliability, the watch, and the on-call burden of running it.",
|
|
35
34
|
"DESC_HISTORIAN": "Brings the history — what was tried before, how it went, and the lesson for this call.",
|
|
36
35
|
"DESC_PLAN": "Set the strategy before a non-trivial stint; call your progress as you go.",
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"DESC_GIT_RESCUE": "Recover a wrecked or tangled session, or rewrite the history safely — reflog, undo, rebase behind a backup.",
|
|
40
|
-
"DESC_REPO_MAP": "Draw the track map — a single-read map of the repository, kept current.",
|
|
36
|
+
"DESC_DEPENDENCIES": "Survey every component — outdated, on recall and reachable, discontinued, dead weight — into a risk-ordered upgrade plan, then fit each change one at a time, trials green between each.",
|
|
37
|
+
"DESC_GIT_HISTORY": "Go through the data, hands off the car, to find when it broke or why a line was driven — bisect, blame, pickaxe — or recover a wrecked or tangled session and rewrite the history safely, every move behind a backup.",
|
|
41
38
|
"DESC_DOCUMENT_PROJECT": "Write the team's PRD, design system, architecture and AGENTS.md off the living code, mend the doc tree, and re-render the offline HTML overview.",
|
|
42
39
|
"DESC_COMMIT": "Stage only what this stint touched and seal a focused commit.",
|
|
43
40
|
"DESC_CODE_REVIEW": "Go over a diff or PR — correctness first, polish after.",
|
|
44
41
|
"DESC_BRAINSTORM": "Turn a raw idea into an agreed strategy before a single tyre hits the track.",
|
|
45
|
-
"DESC_CODEBASE_DESIGN": "Design deep modules — a lot
|
|
46
|
-
"DESC_DOMAIN_MODELING": "Keep the glossary in CONTEXT.md current, and log every structural call as an ADR, box by box.",
|
|
42
|
+
"DESC_CODEBASE_DESIGN": "Design deep modules and the team's own language — a lot behind a small interface, the seam placed like a racing line, a living GLOSSARY.md, an ADR for every call too costly to reverse.",
|
|
47
43
|
"DESC_WAYFINDER": "Chart work too big for one stint as a shared map of decision tickets, resolved one at a time until the track's clear.",
|
|
48
|
-
"DESC_TICKETS": "Split a spec into tracer-bullet tickets with explicit blocking edges, each sized for one fresh stint.",
|
|
49
44
|
"DESC_PROTOTYPE": "Answer a design question with throwaway code — built to learn the lap, never to keep.",
|
|
50
45
|
"DESC_ROAST_ME": "Tear into any work — blunt, exact, always actionable.",
|
|
51
46
|
"DESC_FRESH_EYES": "Bring in a fresh pair of eyes who's seen neither the briefing nor the laps — only the original orders and the finished car — to set the bar blind, then call whether it meets the orders, no excuses from the driver.",
|
|
52
47
|
"ROAST_PERSONA": "a championship driver with zero patience who has watched this exact mistake throw away a win",
|
|
53
48
|
"DESC_COUNCIL": "Get a panel of opposed voices to argue a call out, then hand down a verdict with the dissent kept on record.",
|
|
54
|
-
"DESC_DEBUG": "Hunt the fault by evidence — reproduce it, isolate it, kill the root cause, prove it fixed.",
|
|
49
|
+
"DESC_DEBUG": "Hunt the fault by evidence — a lap that fails on it first, reproduce it, isolate it, kill the root cause, prove it fixed — a red CI run included, reproduced under CI's own conditions. No retry-until-green.",
|
|
55
50
|
"DESC_REFACTOR": "Rebuild the car without changing how it drives — one named move, trials green throughout.",
|
|
56
51
|
"DESC_PONYTAIL": "The laziest line that wins — least code, shortest path; standard parts before custom builds, one line before fifty. lite/full/ultra.",
|
|
57
52
|
"DESC_PARALLEL_AGENTS": "Send several engineers on independent jobs at once, then bring in what they get.",
|
|
@@ -65,18 +60,15 @@
|
|
|
65
60
|
"DESC_SECURITY_AUDIT": "Attack the change the way a rival would — where it can be forced, what it leaks, what it brings in from outside — and call it: ship, fix, or block.",
|
|
66
61
|
"DESC_SKILL_FORGE": "Build, tune, merge, or retire a setup — reuse first, trigger before procedure, tested against its neighbours, every satellite registered, doctor green.",
|
|
67
62
|
"DESC_WORKTREE": "Run a task in its own garage — a fresh worktree off a clean base, nothing shared with the car already on the stand, back through the normal gate, garage cleared once merged.",
|
|
68
|
-
"DESC_CI_FIX": "Turn a red CI run green at the cause — read the data, classify the failure, reproduce under CI's own conditions, fix, watch the re-run. No retry-until-green.",
|
|
69
|
-
"DESC_DEPS_AUDIT": "Survey every component — outdated, on recall and reachable, discontinued, dead weight — into a risk-ordered upgrade plan for migrate to execute, fitting nothing yet.",
|
|
70
|
-
"DESC_CONSOLIDATE_MEMORY": "Tend the memory — verify each note against the live car, merge duplicates, retire stale ones, promote recurring lessons to rules, rebuild the index.",
|
|
71
63
|
"DESC_HANDOFF": "Hand over the car — snapshot the state so a fresh driver takes the wheel in one read.",
|
|
72
64
|
"DESC_SHIP": "Take the flag: open a PR with a clear write-up, or merge the branch, once it's verified.",
|
|
73
65
|
"DESC_RELEASE": "Cut a release — raise the version, write the debrief, tag it, all three in sync.",
|
|
74
66
|
"DESC_INGEST": "Bring a PDF, Office, or web document into clean markdown before reading it.",
|
|
75
67
|
"DESC_RESEARCH": "Find the answer out on the open circuit — search wide, then prove every claim against independent sources before you call it.",
|
|
76
68
|
"DESC_HERDR": "Drive herdr from inside it — split panes, spawn sibling agents, wait on output, read other panes.",
|
|
77
|
-
"DESC_RULE": "Ask first — standing rule, or just something to remember? Then note it, or run the rule through the lap that breaks it before locking it into user-rules.md.",
|
|
69
|
+
"DESC_RULE": "Ask first — standing rule, or just something to remember? Then note it, or run the rule through the lap that breaks it before locking it into user-rules.md — and keep tending the memory: merge, retire, promote.",
|
|
78
70
|
"DESC_PROFILE": "Set up the driver profile in PROFILE.md — seat, driving style, how they want the pit wall to talk; identity only, team orders go in user-rules.md.",
|
|
79
|
-
"DESC_GENESEED": "Operate the deployed Geneseed harness — find each install and its settings, read its files, run status, doctor and diff, and rebuild it with one setting changed when the user asks.",
|
|
71
|
+
"DESC_GENESEED": "Operate the deployed Geneseed harness — find each install and its settings, read its files, run status, doctor and diff, and rebuild it with one setting changed when the user asks — and build the user's own OpenCode colour theme.",
|
|
80
72
|
"DESC_REVIEW_RESPONSE": "Take the notes straight — weigh each call, then act on it or push back with reasons.",
|
|
81
73
|
"LEX_SEALED_SECRETS": "Keep It in the Garage · Sealed Secrets",
|
|
82
74
|
"LEX_ONE_INTENT_ONE_ACT": "One Move per Corner · One Intent, One Act",
|
|
@@ -145,8 +137,7 @@
|
|
|
145
137
|
"INTRO_WIKI": "The team may keep a data room on this machine — a vault of linked engineering notes that carries over every race weekend.",
|
|
146
138
|
"DESC_WIKI": "Use the team's data room — check the data before you push, log new findings properly linked, and file them with the right weekend.",
|
|
147
139
|
"DESC_MCP": "Build or harden an MCP server — study the spec, design task-shaped tools, test with the Inspector, and prove it with evals.",
|
|
148
|
-
"
|
|
149
|
-
"DESC_BRUNO_TEST_WRITER": "Write Bruno tests for a request or the whole collection — status, shape, chaining — no secret leaks, no assertion the data does not back.",
|
|
140
|
+
"DESC_BRUNO": "Build, reorganise or test a Bruno collection — requests, environments, assertions, chaining — every secret a placeholder, no leaks, no assertion the data doesn't back.",
|
|
150
141
|
"DESC_PROSE": "Write like a human, not a bot — bin the filler, keep it active, vary the rhythm, and trust the reader.",
|
|
151
142
|
"DESC_FRONTEND_DESIGN": "Design a UI with a point of view — palette, type, and layout dialled in for this brief, not the default setup, then trim to one bold move.",
|
|
152
143
|
"DESC_WORKFLOW": "Run a saved race plan that drives your engineers by script — many sent out at once, their results gathered and checked in one clean grand prix.",
|
package/themes/wizard.json
CHANGED
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
"DESC_REVIEWER": "Scryes a change for soundness and craft before it is sealed.",
|
|
18
18
|
"DESC_TESTER": "Conjures the trials, casts them, and reads the omens when they fail.",
|
|
19
19
|
"DESC_DEVELOPER": "Conjures the scoped fix in its own warded circle, tests it once, then hands it to the examiner.",
|
|
20
|
-
"DESC_THEME": "Conjure your own OpenCode colour theme — choose or transmute a palette, gain solid and translucent forms, warded against every rebuild.",
|
|
21
20
|
"DESC_ARCHITECT": "Designs the ritual before a single rune is inscribed.",
|
|
22
21
|
"DESC_DOCS": "Transcribes the tomes for those who follow, once the work is done.",
|
|
23
22
|
"DESC_SECURITY": "Wards the circle — audits any working that touches the warded surface.",
|
|
@@ -34,24 +33,20 @@
|
|
|
34
33
|
"DESC_OPERATOR": "Speaks for the working once loosed — how it holds in the wild, its upkeep, and the watch it demands.",
|
|
35
34
|
"DESC_HISTORIAN": "Reads the old grimoires — what was tried before, how it fared, and the lesson for this casting.",
|
|
36
35
|
"DESC_PLAN": "Inscribe the ritual before a non-trivial working; track progress as it unfolds.",
|
|
37
|
-
"
|
|
38
|
-
"
|
|
39
|
-
"DESC_GIT_RESCUE": "Mend a broken or tangled grimoire, or rewrite its history without a backfire — reflog and undo, every working warded by a backup.",
|
|
40
|
-
"DESC_REPO_MAP": "Chart the sanctum — a single-read map of the repository, kept current.",
|
|
36
|
+
"DESC_DEPENDENCIES": "Survey every reagent — outdated, tainted and reachable, abandoned, dead weight — into a risk-ordered upgrade plan, then transmute one rune at a time, trials green between each.",
|
|
37
|
+
"DESC_GIT_HISTORY": "Scry the chronicle, disturbing nothing, for when the curse took hold or why a rune was set — bisect, blame, the pickaxe — or mend a broken or tangled grimoire and rewrite its history without a backfire, every working warded by a backup.",
|
|
41
38
|
"DESC_DOCUMENT_PROJECT": "Inscribe the PRD, design system, architecture and AGENTS.md from the living code, mend the tomes, and re-conjure the offline HTML overview.",
|
|
42
39
|
"DESC_COMMIT": "Gather only the reagents this working touched and seal a focused commit.",
|
|
43
40
|
"DESC_CODE_REVIEW": "Scry a diff or petition — soundness first, craft after.",
|
|
44
41
|
"DESC_BRAINSTORM": "Turn a raw notion into an agreed design before any rune is cut.",
|
|
45
|
-
"DESC_CODEBASE_DESIGN": "Design deep modules — great
|
|
46
|
-
"DESC_DOMAIN_MODELING": "Keep the glossary alive in CONTEXT.md, and inscribe each structural decision as an ADR.",
|
|
42
|
+
"DESC_CODEBASE_DESIGN": "Design deep modules and the tongue of the domain — great power behind one small interface, the seam placed by design, a living GLOSSARY.md, an ADR inscribed for each irreversible call.",
|
|
47
43
|
"DESC_WAYFINDER": "Chart a working too vast for one session as a shared map of decision runes, resolved one at a time until the way is clear.",
|
|
48
|
-
"DESC_TICKETS": "Split a working into tracer-bullet tickets with explicit blocking edges, each sized for one fresh session.",
|
|
49
44
|
"DESC_PROTOTYPE": "Answer a design question with throwaway code — built to learn, never to keep in the grimoire.",
|
|
50
45
|
"DESC_ROAST_ME": "Put any work to the trial by fire — blunt, exact, always actionable.",
|
|
51
46
|
"DESC_FRESH_EYES": "Conjure an unscried adept who has glimpsed neither your deliberations nor your toil — only the original charge and the wrought work — to divine the measure blind, then pronounce whether the work answers the charge.",
|
|
52
47
|
"ROAST_PERSONA": "an exacting archmagus who has watched this exact folly unmake apprentices",
|
|
53
48
|
"DESC_COUNCIL": "Convene a circle of opposed counsels to debate a decision, then render a verdict with the dissent preserved.",
|
|
54
|
-
"DESC_DEBUG": "Hunt the curse by evidence — reproduce, isolate, find its root, banish it.",
|
|
49
|
+
"DESC_DEBUG": "Hunt the curse by evidence — a working that fails on it first, reproduce, isolate, find its root, banish it — a red CI run included, reproduced under CI's own conditions.",
|
|
55
50
|
"DESC_REFACTOR": "Reshape the working without changing its effect — one named pass, trials green throughout.",
|
|
56
51
|
"DESC_PONYTAIL": "The laziest working spell — least incantation, shortest path; the standard grimoire before bespoke runes, one line before fifty. lite/full/ultra.",
|
|
57
52
|
"DESC_PARALLEL_AGENTS": "Loose several familiars on independent tasks at once, then gather what they bring.",
|
|
@@ -65,18 +60,15 @@
|
|
|
65
60
|
"DESC_SECURITY_AUDIT": "Scry a change as a hostile caster would — where the wards can be breached, what it leaks, what it summons from beyond the circle — and pronounce: ship, mend, or bind.",
|
|
66
61
|
"DESC_SKILL_FORGE": "Inscribe, sharpen, merge, or retire a spell — reuse the spellbook first, the trigger before the incantation, tested against neighbouring spells, every satellite recorded, doctor green.",
|
|
67
62
|
"DESC_WORKTREE": "Work a task in its own warded circle — a fresh worktree off a clean base, nothing shared with the ritual in progress, back through the normal gate, circle dispelled once merged.",
|
|
68
|
-
"DESC_CI_FIX": "Turn a red CI run green at the cause — read the omens, classify the failure, reproduce under CI's own conditions, mend, and watch the re-run.",
|
|
69
|
-
"DESC_DEPS_AUDIT": "Survey every reagent — outdated, tainted and reachable, abandoned, dead weight — into a risk-ordered upgrade plan for migrate to execute, acquiring nothing yet.",
|
|
70
|
-
"DESC_CONSOLIDATE_MEMORY": "Tend the grimoire of memory — verify each entry against the living tower, merge duplicates, strike stale ones, promote recurring lessons to law, rebuild the index.",
|
|
71
63
|
"DESC_HANDOFF": "Pass the working — inscribe its state so a fresh mind resumes in one read.",
|
|
72
64
|
"DESC_SHIP": "Send the working forth: open a PR with a clear account, or merge the branch, once proven.",
|
|
73
65
|
"DESC_RELEASE": "Cut a release — raise the version, inscribe the chronicle, seal it with a tag, all in accord.",
|
|
74
66
|
"DESC_INGEST": "Transmute a PDF, Office, or web document into clean markdown before reading it.",
|
|
75
67
|
"DESC_RESEARCH": "Seek the answer through the wider lore — scry many sources, then prove each claim against independent tomes before you trust it.",
|
|
76
68
|
"DESC_HERDR": "Drive herdr from inside it — split panes, spawn sibling agents, wait on output, read other panes.",
|
|
77
|
-
"DESC_RULE": "Ask first — a standing rule, or a thing merely to be remembered? Then inscribe the memory, or prove the rule against the case that would unmake it before it enters user-rules.md.",
|
|
69
|
+
"DESC_RULE": "Ask first — a standing rule, or a thing merely to be remembered? Then inscribe the memory, or prove the rule against the case that would unmake it before it enters user-rules.md — and keep tending the grimoire: merge, strike, promote.",
|
|
78
70
|
"DESC_PROFILE": "Divine the user's nature into PROFILE.md — who they are, how they work, the register they favour; identity only, binding runes belong in user-rules.md.",
|
|
79
|
-
"DESC_GENESEED": "Operate the deployed Geneseed harness — find each install and its settings, read its files, run status, doctor and diff, and rebuild it with one setting changed when the user asks.",
|
|
71
|
+
"DESC_GENESEED": "Operate the deployed Geneseed harness — find each install and its settings, read its files, run status, doctor and diff, and rebuild it with one setting changed when the user asks — and conjure the user's own OpenCode colour theme.",
|
|
80
72
|
"DESC_REVIEW_RESPONSE": "Answer the scrying with rigour — weigh each finding, then heed it or refute it with cause.",
|
|
81
73
|
"LEX_SEALED_SECRETS": "Sealed Sigils · Sealed Secrets",
|
|
82
74
|
"LEX_ONE_INTENT_ONE_ACT": "One Intent, One Casting · One Intent, One Act",
|
|
@@ -145,8 +137,7 @@
|
|
|
145
137
|
"INTRO_WIKI": "The archmage may keep an athenaeum upon this machine — a vault of interlinked tomes whose knowledge outlives any single working.",
|
|
146
138
|
"DESC_WIKI": "Consult and enrich the athenaeum — find the governing tome before casting, inscribe new pages well-linked, and shelve each where the catalogue ordains.",
|
|
147
139
|
"DESC_MCP": "Conjure or fortify an MCP server — study the grimoire, shape tools to real workings, test with the Inspector, and prove it with trials.",
|
|
148
|
-
"
|
|
149
|
-
"DESC_BRUNO_TEST_WRITER": "Bind Bruno tests to a request or the whole collection — status, shape, chaining — and let no secret escape the circle.",
|
|
140
|
+
"DESC_BRUNO": "Conjure, reorganise or bind tests to a Bruno collection — requests, environments, assertions, chaining — every secret a placeholder, none let escape the circle.",
|
|
150
141
|
"DESC_PROSE": "Pen prose for mortal eyes, not machine-cant — banish the filler, speak plainly, vary the cadence, and trust the reader.",
|
|
151
142
|
"DESC_FRONTEND_DESIGN": "Design a UI with intent — palette, type, and layout woven for this brief, not the common defaults; plan, scrutinise, and keep one bold flourish.",
|
|
152
143
|
"DESC_WORKFLOW": "Invoke a saved ritual that binds your familiars by inscribed rite — many sent at once, their auguries gathered and proven in one deterministic casting.",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-
|
|
1
|
+
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-DRhoX0kS.js";import{t as r}from"./api-CxgfYu18.js";import{N as i,k as a,l as o,q as s,y as c}from"./index-hsabpYzv.js";import{a as l,i as u,n as d,o as f,r as p,t as m}from"./activity-dcg5vF9j.js";import{t as h}from"./usePoll-BmR631BB.js";var g=e(t(),1),_=n();function v({s:e}){let t=p[e.status]||p.idle,n=e.files,r=e.todos,o=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]})]})]}),o&&(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 `,i(e.updated_at),` ago`]})]})}function y(){let[e,t]=(0,g.useState)(null),[n,i]=(0,g.useState)(``);h(e=>r.activity().then(n=>{e()&&(t(n),i(``))},t=>{e()&&i(t.message)}),2e3,[]);let a=!e||e.enabled!==!1,l=e?.activity||[],u=s(),d=async()=>{let e=!a;try{let n=await r.activityToggle(e);t(e=>({...e||{},enabled:n.enabled,activity:n.enabled&&e?.activity||[]})),i(``)}catch(e){i(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:a?`tracking on`:`tracking off`}),(0,_.jsx)(`div`,{className:`sw-toggle${a?` on`:``}`,role:`switch`,"aria-checked":a,"aria-label":`Toggle activity tracking`,tabIndex:0,onClick:d,onKeyDown:e=>{(e.key===`Enter`||e.key===` `)&&(e.key===` `&&e.preventDefault(),d())}})]})]}),(0,_.jsx)(o,{error:n,style:{marginBottom:12}}),e?a?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)(c,{label:`Reading live sessions…`})]})}export{y as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-
|
|
1
|
+
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-DRhoX0kS.js";import{t as r}from"./api-CxgfYu18.js";import{N as i,k as a,y as o}from"./index-hsabpYzv.js";import{a as s,n as c,o as l,r as u,t as d}from"./activity-dcg5vF9j.js";import{t as f}from"./usePoll-BmR631BB.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)(o,{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 `,i(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};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/GreenhouseView-
|
|
2
|
-
import{n as e,o as t,r as n,s as r}from"./sections-GalMS0Zv.js";import{i,t as a}from"./react-B9Z_tXRV.js";import{t as o}from"./api-CxgfYu18.js";import{A as s,F as c,H as l,I as u,K as d,M as f,N as p,U as m,c as h,j as g,k as _,l as v,t as y,x as b,y as x}from"./index-ujKG1ZNf.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=d(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=s(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:`Invariants`,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)(m,{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:()=>l(`#/diff`),title:`Open changes`,children:[(0,T.jsx)(`span`,{className:`kseg-n`+(t===0?` zero`:``),children:(0,T.jsx)(m,{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:()=>l(`#/section/`+n),children:[(0,T.jsxs)(`div`,{className:`gtop`,children:[(0,T.jsx)(`span`,{className:`gname`,children:i.label}),(0,T.jsx)(_,{name:i.icon,className:`gicon`})]}),(0,T.jsx)(`div`,{className:`gcount`+(a===0?` zero`:``),children:a==null?`—`:(0,T.jsx)(m,{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:[p(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)(_,{name:`refresh`}),`Update`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`build-all`),children:[(0,T.jsx)(_,{name:`build`}),`Rebuild`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`doctor`),children:[(0,T.jsx)(_,{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=g(e.counts),o=r?.version_verdict||``,c=o.includes(`up to date`),l=s(e.diff),u=[[`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`}),u.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 ${c?`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`}),l,` 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=g(t.counts),c=t.doctor?.ok,l=t.doctor?.problems?.length??0,u=s(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:c?(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`}),l,` issue`,l===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:u})]})]})})}),(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 u()}catch(e){r(e.message),t(!1)}},disabled:e,children:e?`Restarting…`:`Restart`})]})}var F=t({default:()=>z}),I=(0,S.lazy)(()=>y(()=>import(`./GreenhouseView-Sc_UDMOE.js`),__vite__mapDeps([0,1,2,3,4,5,6,7]))),L=(0,S.lazy)(()=>y(()=>import(`./OperatorHudView--TkvDybH.js`),__vite__mapDeps([8,1,2,4,5,6,7]))),R=(0,S.lazy)(()=>y(()=>import(`./JournalView-_gxpsxXi.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:s,layout:l=`cultivar`,dataRev:u}){let d=l,[f,p]=(0,S.useState)(`status`),m=e&&r.find(t=>t.name===e.theme)?.sigil||``,{data:g}=c(()=>d===`greenhouse`||d===`operator`?o.doctor().catch(()=>null):Promise.resolve(null),[d,u]),{data:_}=c(()=>d===`journal`?o.recent().catch(()=>null):Promise.resolve(null),[d,u]);if(!e)return t?(0,T.jsxs)(`div`,{children:[(0,T.jsx)(v,{error:`Could not load the harness overview: ${t}`}),(0,T.jsx)(`button`,{className:`btn`,onClick:n,children:`Retry`})]}):(0,T.jsx)(x,{});let y=e.daemon_stale?(0,T.jsx)(P,{}):null;return e.deployed?f===`status`&&d===`journal`?(0,T.jsxs)(S.Suspense,{fallback:(0,T.jsx)(x,{}),children:[y,(0,T.jsx)(R,{overview:e,recent:_,onAction:s,onDirection:p,dataRev:u})]}):(0,T.jsxs)(T.Fragment,{children:[y,(0,T.jsx)(`div`,{className:`head-row`,children:(0,T.jsx)(b,{"aria-label":`Dashboard view`,children:[[`status`,`Status`],[`lineage`,`Lineage`],[`operator`,`Operator`]].map(([e,t])=>(0,T.jsx)(`button`,{className:f===e?`on`:``,onClick:()=>p(e),"aria-pressed":f===e,children:t},e))})}),(0,T.jsxs)(`div`,{className:`view-in`,children:[f===`status`&&d===`cultivar`&&(0,T.jsx)(A,{overview:e,sigil:m,setup:i,jobs:a,onAction:s}),f===`status`&&d===`greenhouse`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(x,{}),children:(0,T.jsx)(I,{overview:e,sigil:m,jobs:a,doctor:g,onAction:s})}),f===`status`&&d===`operator`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(x,{}),children:(0,T.jsx)(L,{overview:e,jobs:a,doctor:g,onAction:s})}),f===`lineage`&&(0,T.jsx)(M,{overview:e,sigil:m,setup:i,jobs:a}),f===`operator`&&(0,T.jsx)(N,{overview:e,setup:i,jobs:a})]},f)]}):(0,T.jsxs)(T.Fragment,{children:[y,(0,T.jsx)(h,{onAction:s})]})}export{z as default,w as n,F as t};
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/GreenhouseView-BxO84bKX.js","assets/sections-GalMS0Zv.js","assets/react-DRhoX0kS.js","assets/drawable-CdNARIKC.js","assets/index-hsabpYzv.js","assets/api-CxgfYu18.js","assets/index-Ctp-4poP.css","assets/jobBuckets-Dbq8ZlWW.js","assets/OperatorHudView-BZZ3uJPH.js","assets/JournalView-0YNKcaaD.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
import{n as e,o as t,r as n,s as r}from"./sections-GalMS0Zv.js";import{i,t as a}from"./react-DRhoX0kS.js";import{t as o}from"./api-CxgfYu18.js";import{A as s,F as c,H as l,I as u,K as d,M as f,N as p,U as m,c as h,j as g,k as _,l as v,t as y,x as b,y as x}from"./index-hsabpYzv.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=d(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=s(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:`Invariants`,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)(m,{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:()=>l(`#/diff`),title:`Open changes`,children:[(0,T.jsx)(`span`,{className:`kseg-n`+(t===0?` zero`:``),children:(0,T.jsx)(m,{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:()=>l(`#/section/`+n),children:[(0,T.jsxs)(`div`,{className:`gtop`,children:[(0,T.jsx)(`span`,{className:`gname`,children:i.label}),(0,T.jsx)(_,{name:i.icon,className:`gicon`})]}),(0,T.jsx)(`div`,{className:`gcount`+(a===0?` zero`:``),children:a==null?`—`:(0,T.jsx)(m,{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:[p(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)(_,{name:`refresh`}),`Update`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`build-all`),children:[(0,T.jsx)(_,{name:`build`}),`Rebuild`]}),(0,T.jsxs)(`button`,{className:`btn ghost`,onClick:()=>a(`doctor`),children:[(0,T.jsx)(_,{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=g(e.counts),o=r?.version_verdict||``,c=o.includes(`up to date`),l=s(e.diff),u=[[`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`}),u.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 ${c?`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`}),l,` 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=g(t.counts),c=t.doctor?.ok,l=t.doctor?.problems?.length??0,u=s(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:c?(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`}),l,` issue`,l===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:u})]})]})})}),(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 u()}catch(e){r(e.message),t(!1)}},disabled:e,children:e?`Restarting…`:`Restart`})]})}var F=t({default:()=>z}),I=(0,S.lazy)(()=>y(()=>import(`./GreenhouseView-BxO84bKX.js`),__vite__mapDeps([0,1,2,3,4,5,6,7]))),L=(0,S.lazy)(()=>y(()=>import(`./OperatorHudView-BZZ3uJPH.js`),__vite__mapDeps([8,1,2,4,5,6,7]))),R=(0,S.lazy)(()=>y(()=>import(`./JournalView-0YNKcaaD.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:s,layout:l=`cultivar`,dataRev:u}){let d=l,[f,p]=(0,S.useState)(`status`),m=e&&r.find(t=>t.name===e.theme)?.sigil||``,{data:g}=c(()=>d===`greenhouse`||d===`operator`?o.doctor().catch(()=>null):Promise.resolve(null),[d,u]),{data:_}=c(()=>d===`journal`?o.recent().catch(()=>null):Promise.resolve(null),[d,u]);if(!e)return t?(0,T.jsxs)(`div`,{children:[(0,T.jsx)(v,{error:`Could not load the harness overview: ${t}`}),(0,T.jsx)(`button`,{className:`btn`,onClick:n,children:`Retry`})]}):(0,T.jsx)(x,{});let y=e.daemon_stale?(0,T.jsx)(P,{}):null;return e.deployed?f===`status`&&d===`journal`?(0,T.jsxs)(S.Suspense,{fallback:(0,T.jsx)(x,{}),children:[y,(0,T.jsx)(R,{overview:e,recent:_,onAction:s,onDirection:p,dataRev:u})]}):(0,T.jsxs)(T.Fragment,{children:[y,(0,T.jsx)(`div`,{className:`head-row`,children:(0,T.jsx)(b,{"aria-label":`Dashboard view`,children:[[`status`,`Status`],[`lineage`,`Lineage`],[`operator`,`Operator`]].map(([e,t])=>(0,T.jsx)(`button`,{className:f===e?`on`:``,onClick:()=>p(e),"aria-pressed":f===e,children:t},e))})}),(0,T.jsxs)(`div`,{className:`view-in`,children:[f===`status`&&d===`cultivar`&&(0,T.jsx)(A,{overview:e,sigil:m,setup:i,jobs:a,onAction:s}),f===`status`&&d===`greenhouse`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(x,{}),children:(0,T.jsx)(I,{overview:e,sigil:m,jobs:a,doctor:g,onAction:s})}),f===`status`&&d===`operator`&&(0,T.jsx)(S.Suspense,{fallback:(0,T.jsx)(x,{}),children:(0,T.jsx)(L,{overview:e,jobs:a,doctor:g,onAction:s})}),f===`lineage`&&(0,T.jsx)(M,{overview:e,sigil:m,setup:i,jobs:a}),f===`operator`&&(0,T.jsx)(N,{overview:e,setup:i,jobs:a})]},f)]}):(0,T.jsxs)(T.Fragment,{children:[y,(0,T.jsx)(h,{onAction:s})]})}export{z as default,w as n,F as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-
|
|
1
|
+
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-DRhoX0kS.js";import{t as r}from"./api-CxgfYu18.js";import{C as i,F as a,H as o,S as s,a as c,i as l,k as u,l as d,n as f,o as p,r as m,s as h,w as ee,x as te,y as g}from"./index-hsabpYzv.js";import{a as _,c as v,i as y,l as b,n as x,o as S,r as C,s as ne,t as w}from"./Markdown-C6fRd4A4.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
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)(()=>x(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(),o(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)(u,{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(`
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import"./sections-GalMS0Zv.js";import{i as e,t}from"./react-DRhoX0kS.js";e();var n=t();function r({value:e,onChange:t,label:r,placeholder:i,className:a}){return(0,n.jsx)(`input`,{className:a||`lib-filter`,type:`text`,value:e,onChange:e=>t(e.target.value),placeholder:i,"aria-label":r||i})}export{r as t};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{n as e,r as t,s as n}from"./sections-GalMS0Zv.js";import{i as r,t as i}from"./react-
|
|
1
|
+
import{n as e,r as t,s as n}from"./sections-GalMS0Zv.js";import{i as r,t as i}from"./react-DRhoX0kS.js";import{t as a}from"./drawable-CdNARIKC.js";import{A as o,G as s,Q as c,U as l,W as u,Y as d,k as f}from"./index-hsabpYzv.js";import{t as p}from"./jobBuckets-Dbq8ZlWW.js";import{n as m}from"./Dashboard-lTaH58R9.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),f=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)),l=a(t);d(l,{draw:`0 0`});let f=c(l,{draw:[`0 0`,`0 1`],duration:(e,t)=>Math.max(b*n[t],60),delay:(e,t)=>b*r[t],ease:`linear`});return s(f,b)},[f]);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)(l,{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)(f,{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:s}){let c=n.counts||{},u=a?.groups||[],d=u.length>0,h=u.filter(e=>e.problems.length===0).length,b=u.length||1,S=m(n),T=o(n.diff),E=t.filter(e=>(c[e]||0)>0).map((t,n)=>({label:e[t].label,value:c[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:()=>s(`update`),children:[(0,g.jsx)(f,{name:`refresh`}),`Update`]}),(0,g.jsxs)(`button`,{className:`btn ghost`,onClick:()=>s(`build-all`),children:[(0,g.jsx)(f,{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:d?`${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.`]}),d&&(0,g.jsx)(`ul`,{className:`b-hero-checks`,children:u.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:c.agents??`—`,sub:`specialists`,color:y[0],icon:`layers`}),(0,g.jsx)(w,{label:`Skills`,value:c.skills??`—`,sub:`workflows`,color:y[1],icon:`skill`}),(0,g.jsx)(w,{label:`Invariants`,value:c.laws??`—`,sub:c.doctrines?`${c.doctrines.active}/${c.doctrines.total} packs · ${c.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)(l,{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
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};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-B9Z_tXRV.js";import{t as r}from"./api-CxgfYu18.js";import{A as i,D as a,E as o,F as s,I as c,L as l,O as u,R as d,T as f,b as p,k as m,l as h,v as g,x as _,y as v,z as y}from"./index-ujKG1ZNf.js";import{t as b}from"./Tabs-B0cdf8k6.js";var x=e(t(),1),S=n();function C({label:e,value:t,options:n,onChange:r}){return n.length?(0,S.jsx)(`select`,{className:`sel`,"aria-label":e,value:t,onChange:e=>r(e.target.value),children:n.map(e=>(0,S.jsx)(`option`,{value:e,children:e},e))}):null}var w=[`full`,`lean`];function T({on:e,disabled:t,label:n,onToggle:r}){return(0,S.jsx)(`input`,{type:`checkbox`,role:`switch`,className:`sw-toggle${e?` on`:``}`,checked:e,"aria-checked":e,disabled:t,"aria-label":n,onChange:r,onKeyDown:e=>{e.key===`Enter`&&!t&&r()}})}var E=[{key:`theme`,name:`voice`,title:`Voice`},{key:`footprint`,name:`footprint`,title:`Footprint`},{key:`posture`,name:`posture`,title:`Posture`},{key:`mode`,name:`mode`,title:`Mode`},{key:`trust`,name:`trust`,title:`Loop trust`}];function D({value:e,options:t,onChange:n,who:r}){return E.map(i=>(0,S.jsxs)(`label`,{className:`dp-field`,children:[(0,S.jsx)(`span`,{children:i.title}),(0,S.jsx)(C,{label:`${i.name} for ${r}`,value:e[i.key],options:t[i.key],onChange:e=>n(i.key,e)})]},i.key))}function O({host:e,theme:t,options:n,onAction:i,onClose:a,onNote:s}){let[c,l]=(0,x.useState)({path:``,host:e,theme:t,footprint:`full`,posture:`peer`,mode:`direct`,trust:`balanced`}),[u,d]=(0,x.useState)(!1),p=(e,t)=>l(n=>({...n,[e]:t})),m=async()=>{d(!0),s(``);try{let e=await r.pickFolder();e.path?p(`path`,e.path):e.error&&s(e.error)}catch(e){s(e.message)}finally{d(!1)}},h=async()=>{let e=c.path.trim();if(!e){s(`Choose or type a folder to deploy into.`);return}s(``),await i?.(`deploy`,{host:c.host,path:e,theme:c.theme,footprint:c.footprint,posture:c.posture,mode:c.mode,trust:c.trust})&&a()};return(0,S.jsxs)(`div`,{className:`deploy-pop`,children:[(0,S.jsxs)(`div`,{className:`dp-row`,children:[(0,S.jsx)(`input`,{className:`inp dp-path`,type:`text`,placeholder:`/path/to/project, or click Browse…`,value:c.path,onChange:e=>p(`path`,e.target.value),onKeyDown:e=>e.key===`Enter`&&h(),"aria-label":`Folder to deploy into`}),(0,S.jsx)(`button`,{className:`btn ghost sm`,disabled:u,onClick:m,children:u?`Choosing…`:`Browse…`})]}),(0,S.jsxs)(`div`,{className:`dp-row`,children:[(0,S.jsxs)(`label`,{className:`dp-field`,children:[(0,S.jsx)(`span`,{children:`Deploy as`}),(0,S.jsx)(`select`,{className:`sel`,"aria-label":`host for the new harness`,value:c.host,onChange:e=>p(`host`,e.target.value),children:f.map(e=>(0,S.jsx)(`option`,{value:e.id,children:e.label},e.id))})]}),(0,S.jsx)(D,{value:c,options:n,onChange:p,who:`the new harness`}),(0,S.jsx)(`button`,{className:`btn sm`,onClick:h,children:`Deploy`}),(0,S.jsx)(`button`,{className:`btn ghost sm`,onClick:a,children:`Cancel`})]}),(0,S.jsxs)(`p`,{className:`sub dp-note`,children:[`Adds a per-repo harness (`,(0,S.jsx)(`code`,{children:o(c.host).deployAdds}),`) into the folder, non-destructively. It’s then tracked here even after you leave its directory.`]})]})}function k(){let{data:e,error:t,reload:n}=s(()=>r.excludes(),[]),[i,a]=(0,x.useState)(!1),[o,c]=(0,x.useState)([]),l=async(e,t)=>{a(!0);try{let n=await r.excludeMutate(e,t);c(n.messages||[])}catch(e){c(e.body?.messages||[e.message])}finally{a(!1),n()}};return t||!e?.installs?.length?null:(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Excluded folders`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`Sovereign repos: inside these folders every global harness goes dormant — hooks stay silent and the global preamble is not loaded.`}),(e.excludes||[]).map(e=>(0,S.jsxs)(`div`,{className:`row wrap between gap-12`,children:[(0,S.jsx)(`code`,{children:e.path}),(0,S.jsxs)(`span`,{className:`mono muted`,children:[`[`,e.hosts.join(`, `),`]`]}),(0,S.jsx)(`button`,{className:`btn ghost sm`,disabled:i,onClick:()=>l(`remove`,e.path),children:`Remove`})]},e.path)),(0,S.jsxs)(`button`,{className:`btn ghost sm`,disabled:i,onClick:async()=>{a(!0);try{let e=await r.pickFolder();e.path?await l(`add`,e.path):e.error&&c([e.error])}catch(e){c([e.message])}finally{a(!1)}},children:[(0,S.jsx)(m,{name:`folder`}),` Exclude a folder…`]}),o.map((e,t)=>(0,S.jsx)(`p`,{className:`sub`,children:e},t))]})}function A({inst:e,memory:t,busy:n,onMemory:r,onRemove:i,onCancel:a}){return(0,S.jsxs)(`div`,{className:`h-remove`,children:[(0,S.jsxs)(`p`,{className:`hr-msg`,children:[(0,S.jsx)(`strong`,{children:e.scope===`project`?`Remove this harness from the folder?`:`Remove the global ${e.host} install?`}),` `,(0,S.jsxs)(`span`,{className:`sub`,children:[`Deletes `,(0,S.jsx)(`code`,{children:u(e.host,e.scope)}),e.scope===`project`?` and de-lists it.`:`; the row stays, marked “not installed.”`,` `,`This can’t be undone.`]})]}),(0,S.jsxs)(`label`,{className:`field`,children:[(0,S.jsx)(`span`,{children:`Memory and notebook`}),(0,S.jsxs)(`select`,{className:`sel`,"aria-label":`memory disposition`,value:t,onChange:e=>r(e.target.value),children:[(0,S.jsx)(`option`,{value:`keep`,children:`keep in place`}),(0,S.jsx)(`option`,{value:`archive`,children:`archive aside`}),(0,S.jsx)(`option`,{value:`delete`,children:`delete too`})]})]}),(0,S.jsxs)(`div`,{className:`row gap-8`,children:[(0,S.jsx)(`button`,{type:`button`,className:`btn danger`,disabled:n,onClick:i,children:n?`Removing…`:`Remove`}),(0,S.jsx)(`button`,{type:`button`,className:`btn ghost`,onClick:a,children:`Cancel`})]})]})}function j({targets:e,mcpBusy:t,onReveal:n,onToggle:r}){let i=e.flatMap(e=>e.servers),a=i.filter(e=>e.state===`enabled`).length;return(0,S.jsxs)(`div`,{className:`ip-block`,children:[(0,S.jsxs)(`span`,{className:`ip-label`,children:[`MCP servers`,` `,(0,S.jsxs)(`span`,{className:`mono dim`,children:[a,` of `,i.length]})]}),e.map(e=>(0,S.jsxs)(`div`,{className:`mcp-target`,children:[(0,S.jsxs)(`div`,{className:`mt-head`,children:[(0,S.jsx)(`code`,{title:e.path,children:e.label}),(0,S.jsx)(`button`,{type:`button`,className:`btn ghost sm`,onClick:()=>n(e),title:`Open the folder holding ${e.path}: tokens and URLs go in this file`,children:`Open folder`}),e.commented?(0,S.jsx)(`span`,{className:`dim`,children:`has comments; edit by hand`}):null]}),e.servers.map(n=>{let i=e.path+n.name,a=!!(e.commented||t===i);return(0,S.jsxs)(`div`,{className:`mcp-row`,title:n.desc,children:[(0,S.jsx)(`span`,{children:n.label}),n.state===`absent`?n.preset?(0,S.jsx)(`button`,{type:`button`,className:`btn ghost sm`,disabled:a,onClick:()=>r(e,n),children:`Add`}):null:(0,S.jsx)(T,{on:n.state===`enabled`,disabled:a,label:`${n.label} server`,onToggle:()=>r(e,n)})]},n.name)})]},e.path))]})}var M={active:[`Active`,`ok`],disabled:[`Disabled`,`warn`],absent:[`Not installed`,``]};function N({inst:e,targets:t,choice:n,unchanged:r,options:i,onPick:s,canAct:c,busy:l,mcpBusy:u,removing:d,onRemoving:f,onApply:p,onToggleInstall:m,onRemove:h,onRevealMcp:g,onToggleMcp:_}){let v=`${e.host} · ${e.scope}`,[y,b]=M[e.state]||M.absent,x=e.state===`active`,C=e.state===`absent`;return(0,S.jsxs)(`aside`,{className:`install-panel`,"aria-label":`${v} install`,children:[(0,S.jsx)(`span`,{className:`ip-eyebrow`,children:`Selected install`}),(0,S.jsxs)(`div`,{className:`ip-head`,children:[(0,S.jsx)(`h2`,{children:a(e)}),(0,S.jsx)(`span`,{className:`tag ${b}`,children:y})]}),(0,S.jsx)(`span`,{className:`ip-kind`,children:e.scope===`global`?`Global install`:`Per-project install · ${o(e.host).label}`}),(0,S.jsx)(`code`,{className:`ip-path`,children:e.path}),C?(0,S.jsxs)(`p`,{className:`sub`,children:[`Install Geneseed here as `,(0,S.jsx)(`strong`,{children:e.host}),`. Files are added non-destructively; deactivate or uninstall later.`]}):null,(x||C)&&c?(0,S.jsx)(`div`,{className:`ip-picks`,children:(0,S.jsx)(D,{value:n,options:i,onChange:s,who:v})}):null,x&&t.length?(0,S.jsx)(j,{targets:t,mcpBusy:u,onReveal:g,onToggle:_}):null,x&&e.scope===`global`?(0,S.jsx)(k,{}):null,C?null:(0,S.jsxs)(`label`,{className:`ip-switch`,children:[(0,S.jsx)(T,{on:x,disabled:l,label:`activate ${v}`,onToggle:m}),(0,S.jsx)(`span`,{children:x?`Active: loads in every session`:`Disabled: files moved aside`})]}),(0,S.jsx)(`div`,{className:`ip-spacer`}),c?(0,S.jsxs)(`div`,{className:`ip-actions`,children:[C?(0,S.jsx)(`button`,{type:`button`,className:`btn`,onClick:p,children:`Install`}):x?(0,S.jsx)(`button`,{type:`button`,className:`btn`,disabled:r,onClick:p,children:`Apply and rebuild`}):null,C?null:(0,S.jsx)(`button`,{type:`button`,className:`btn ghost danger-line`,"aria-label":`remove ${v} from ${e.path}`,"aria-expanded":!!d,disabled:l,onClick:()=>f(d?null:{memory:`keep`}),children:`Uninstall…`})]}):null,d?(0,S.jsx)(A,{inst:e,memory:d.memory,busy:l,onMemory:e=>f({memory:e}),onRemove:h,onCancel:()=>f(null)}):null]})}var P=(e,t)=>`${e} ${t}`,F={active:[`Active`,`ok`],disabled:[`Disabled`,`warn`]};function I({rows:e,project:t,currentId:n,onPick:r,label:i}){return(0,S.jsx)(`div`,{className:`tbl-scroll`,children:(0,S.jsxs)(`table`,{className:`tbl hosts-tbl`,"aria-label":i,children:[(0,S.jsx)(`thead`,{children:(0,S.jsxs)(`tr`,{children:[(0,S.jsx)(`th`,{children:t?`Project`:`Host`}),(0,S.jsx)(`th`,{children:t?`Host`:`Path`}),(0,S.jsx)(`th`,{children:`Voice`}),(0,S.jsx)(`th`,{children:`Footprint`}),(0,S.jsx)(`th`,{children:`State`}),(0,S.jsx)(`th`,{children:(0,S.jsx)(`span`,{className:`sr-only`,children:`Selected`})})]})}),(0,S.jsx)(`tbody`,{children:e.map(e=>{let[i,s]=F[e.state]||[`Not installed`,``],c=n===e.id,l=e.state===`absent`;return(0,S.jsxs)(`tr`,{className:`pickable${c?` on`:``}${l?` quiet`:``}`,onClick:()=>r(e.id),children:[(0,S.jsx)(`td`,{children:(0,S.jsx)(`button`,{type:`button`,className:`row-pick`,"aria-pressed":c,title:e.path,onClick:()=>r(e.id),children:a(e)})}),t?(0,S.jsx)(`td`,{children:o(e.host).label}):(0,S.jsx)(`td`,{className:`mono path-cell`,title:e.path,children:e.path}),(0,S.jsx)(`td`,{children:l?``:e.theme||``}),(0,S.jsx)(`td`,{children:l?``:e.footprint||``}),(0,S.jsx)(`td`,{children:(0,S.jsx)(`span`,{className:`tag ${s}`,children:i})}),(0,S.jsx)(`td`,{className:`pick-mark`,children:c?`Editing ›`:``})]},e.id)})})]})})}function L({themes:e,current:t}){if(!e.length||!t)return null;let n=[...e].sort((e,n)=>e.name===t?-1:+(n.name===t));return(0,S.jsxs)(`details`,{className:`panel voice-ref`,children:[(0,S.jsxs)(`summary`,{children:[(0,S.jsx)(`span`,{className:`vr-title`,children:`Voices`}),(0,S.jsxs)(`span`,{className:`mono dim`,children:[e.length,` to choose from, set per install`]})]}),(0,S.jsx)(`div`,{className:`vr-list`,children:n.map(e=>(0,S.jsxs)(`div`,{className:`voice-row${e.name===t?` current`:``}`,children:[(0,S.jsx)(`span`,{className:`vr-name`,children:e.name}),(0,S.jsx)(`span`,{className:`vr-desc`,children:e.tagline?`“${e.tagline}”`:e.blurb})]},e.name))})]})}function R({setup:e,overview:t}){if(!e)return null;let n=e.installed_fp&&e.installed_fp===e.source_fp;return(0,S.jsxs)(`section`,{className:`panel`,"aria-labelledby":`checkout-h`,children:[(0,S.jsxs)(`div`,{className:`panel-head`,children:[(0,S.jsx)(`h2`,{id:`checkout-h`,children:`This checkout`}),(0,S.jsx)(`span`,{className:`mono ${n?`t-good`:`t-warn`}`,children:e.version_verdict})]}),(0,S.jsxs)(`dl`,{className:`kv-grid`,children:[(0,S.jsx)(`dt`,{children:`Source`}),(0,S.jsx)(`dd`,{className:`mono`,children:e.root}),(0,S.jsx)(`dt`,{children:`Version`}),(0,S.jsx)(`dd`,{className:`mono`,children:t?.version||`unknown`}),(0,S.jsx)(`dt`,{children:`Fingerprint`}),(0,S.jsx)(`dd`,{className:`mono`,children:e.source_fp})]})]})}function z({onAction:e,themes:t=[],currentTheme:n,overview:i,setup:a,dataRev:o,onMutated:c}){let l=g(),{data:u,error:d}=s(()=>r.installs(),[o]),{data:f,error:p}=s(()=>r.mcp(),[o]),[_,y]=(0,x.useState)(``),[b,C]=(0,x.useState)(``),[T,E]=(0,x.useState)(``),[D,k]=(0,x.useState)({}),[A,j]=(0,x.useState)(!1),[M,F]=(0,x.useState)(null),[z,B]=(0,x.useState)(``),V=(0,x.useMemo)(()=>{let e={};for(let t of f?.targets||[]){let n=P(t.host||`opencode`,t.root);(e[n]||(e[n]=[])).push(t)}return e},[f]);if(d||p)return(0,S.jsx)(h,{error:d||p});if(!u||!f)return(0,S.jsx)(v,{});let H={active:0,disabled:1,absent:2},U=[...u.installs].sort((e,t)=>(e.scope===`global`?0:1)-(t.scope===`global`?0:1)||(H[e.state]??3)-(H[t.state]??3)),W=U.find(e=>e.id===z)||U.find(e=>e.selected)||U.find(e=>e.state===`active`)||U[0],G=e=>{let t=D[e.id]||{};return{theme:t.theme||e.theme||n||`neutral`,footprint:t.footprint||e.footprint||`full`,posture:t.posture||e.posture||`peer`,mode:t.mode||e.mode||`direct`,trust:t.trust||e.trust||`balanced`}},K=(e,t,n)=>k(r=>({...r,[e.id]:{...r[e.id],[t]:n}})),q=e=>{let t=G(e);return t.theme===e.theme&&t.footprint===(e.footprint||`full`)&&t.posture===(e.posture||`peer`)&&t.mode===(e.mode||`direct`)&&t.trust===(e.trust||`balanced`)},J={theme:t.map(e=>e.name),footprint:w,posture:u.postures||[],mode:u.modes||[],trust:u.trusts||[]},Y=async t=>{let{theme:n,footprint:r,posture:i,mode:a,trust:o}=G(t),s=t.state===`absent`?`Install Geneseed into ${t.path} with the “${n}” voice (${r} footprint, ${i} posture, ${a} mode)? Files are added non-destructively (your own config is left untouched); deactivate or uninstall later.`:`Rebuild this install (voice “${n}”, ${r} footprint, ${i} posture, ${a} mode)? It rebuilds in place, non-destructive.`;await l(s,{title:t.state===`absent`?`Install Geneseed?`:`Rebuild this install?`,confirmLabel:t.state===`absent`?`Install`:`Rebuild`})&&e?.(`install`,{host:t.host,scope:t.scope,path:t.path,theme:n,footprint:r,posture:i,mode:a,trust:o})},X=async e=>{if(e.state!==`active`||await l(`Deactivate this install? Files are moved aside, not deleted; reactivate any time.`,{title:`Deactivate this install?`,confirmLabel:`Deactivate`})){C(e.id),y(``);try{let t=await r.installToggle(e.host,e.path,e.state===`active`?`deactivate`:`activate`);if(!t.ok){let e=Array.isArray(t.failed)?t.failed.join(`, `):``;y(t.error||e&&`unrestored: ${e}`||`action failed`);return}c?.()}catch(e){y(e.message)}finally{C(``)}}},Z=async()=>{let e=M;if(e){C(e.id),y(``);try{let t=await r.installRemove(e.host,e.path,e.memory);if(!t.ok){y(t.error||`remove failed`);return}F(null),c?.()}catch(e){y(e.message)}finally{C(``)}}},ee=async e=>{y(``);try{let t=await r.mcpReveal(e.path);y(`Opening ${t.dir}. If no window appeared, open that folder by hand.`)}catch(e){y(e.message)}},te=async(e,t)=>{let n=e.path+t.name;E(n),y(``);try{await r.mcpToggle(e.path,t.name,t.state!==`enabled`),c?.()}catch(e){y(e.message)}finally{E(``)}},ne=U.find(e=>e.selected)?.host||U.find(e=>e.state===`active`)?.host||U[0]?.host||`opencode`,re=U.filter(e=>e.scope===`global`),Q=U.filter(e=>e.scope!==`global`),$=e=>{B(e),F(null)};return(0,S.jsxs)(`div`,{className:`hosts`,children:[(0,S.jsxs)(`div`,{className:`hosts-main`,children:[(0,S.jsxs)(`div`,{className:`toolbar`,children:[(0,S.jsxs)(`span`,{className:`dim`,children:[U.filter(e=>e.state===`active`).length,` active of `,U.length,` `,`detected.`]}),e?(0,S.jsx)(`div`,{className:`row gap-8`,children:(0,S.jsxs)(`button`,{type:`button`,className:`btn ghost`,onClick:()=>e(`build-all`),children:[(0,S.jsx)(m,{name:`refresh`}),` Rebuild all`]})}):null]}),_?(0,S.jsx)(`p`,{className:`tag bad note`,role:`status`,children:_}):null,(0,S.jsxs)(`section`,{className:`panel flush`,"aria-labelledby":`inst-global`,children:[(0,S.jsx)(`div`,{className:`inst-head`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{id:`inst-global`,children:`Global installs`}),(0,S.jsx)(`p`,{className:`dim`,children:`One per tool. Loaded in every folder, except excluded ones.`})]})}),(0,S.jsx)(I,{rows:re,currentId:W?.id,onPick:$,label:`Global installs`})]}),(0,S.jsxs)(`section`,{className:`panel flush`,"aria-labelledby":`inst-project`,children:[(0,S.jsxs)(`div`,{className:`inst-head`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{id:`inst-project`,children:`Per-project installs`}),(0,S.jsx)(`p`,{className:`dim`,children:`A repo with its own harness. Inside it, only that harness loads.`})]}),e?(0,S.jsxs)(`button`,{type:`button`,className:`btn ghost`,onClick:()=>j(e=>!e),children:[(0,S.jsx)(m,{name:`folder`}),` Deploy to a repo…`]}):null]}),A?(0,S.jsx)(`div`,{className:`inst-deploy`,children:(0,S.jsx)(O,{host:ne,theme:n||`neutral`,options:J,onAction:e,onClose:()=>j(!1),onNote:y})}):null,Q.length?(0,S.jsx)(I,{rows:Q,project:!0,currentId:W?.id,onPick:$,label:`Per-project installs`}):(0,S.jsx)(`div`,{className:`empty inst-empty`,children:`No repo has its own harness yet. Deploy one to give a project its own rules and voice.`})]}),(0,S.jsx)(R,{setup:a,overview:i}),(0,S.jsx)(L,{themes:t,current:i?.theme})]}),W?(0,S.jsx)(N,{inst:W,targets:V[P(W.host,W.path)]||[],choice:G(W),unchanged:q(W),options:J,onPick:(e,t)=>K(W,e,t),canAct:!!e,busy:b===W.id,mcpBusy:T,removing:M?.id===W.id?M:null,onRemoving:e=>F(e&&{id:W.id,host:W.host,path:W.path,memory:e.memory}),onApply:()=>Y(W),onToggleInstall:()=>X(W),onRemove:Z,onRevealMcp:ee,onToggleMcp:te},W.id):null]})}function B(e){return e.startsWith(`@@`)||e.startsWith(`+++`)||e.startsWith(`---`)?`hunk`:e.startsWith(`+`)?`add`:e.startsWith(`-`)?`del`:`ctx`}function V({onMutated:e,onAction:t,dataRev:n}){let i=g(),{data:a,error:o,reload:c}=s(()=>r.diff(),[n]),[l,u]=(0,x.useState)(!1),[d,f]=(0,x.useState)(``),[p,_]=(0,x.useState)(()=>new Set),[y,b]=(0,x.useState)(()=>new Set),[C,w]=(0,x.useState)(null);a&&a!==C&&(w(a),_(new Set),b(new Set(a.files.map(e=>e.rel))));let T=e=>_(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n}),E=()=>_(e=>e.size===a.files.length?new Set:new Set(a.files.map(e=>e.rel))),D=()=>t?.(`export`),O=async()=>{let t=[...p],n=t.filter(e=>a.files.find(t=>t.rel===e)?.status===`added`),o=n.length?`Restoring will DELETE ${n.length} deployed-only file(s):\n${n.join(`
|
|
1
|
+
import{s as e}from"./sections-GalMS0Zv.js";import{i as t,t as n}from"./react-DRhoX0kS.js";import{t as r}from"./api-CxgfYu18.js";import{A as i,D as a,E as o,F as s,I as c,L as l,O as u,R as d,T as f,b as p,k as m,l as h,v as g,x as _,y as v,z as y}from"./index-hsabpYzv.js";import{t as b}from"./Tabs-VYLhUTiX.js";var x=e(t(),1),S=n();function C({label:e,value:t,options:n,onChange:r}){return n.length?(0,S.jsx)(`select`,{className:`sel`,"aria-label":e,value:t,onChange:e=>r(e.target.value),children:n.map(e=>(0,S.jsx)(`option`,{value:e,children:e},e))}):null}var w=[`full`,`lean`];function T({on:e,disabled:t,label:n,onToggle:r}){return(0,S.jsx)(`input`,{type:`checkbox`,role:`switch`,className:`sw-toggle${e?` on`:``}`,checked:e,"aria-checked":e,disabled:t,"aria-label":n,onChange:r,onKeyDown:e=>{e.key===`Enter`&&!t&&r()}})}var E=[{key:`theme`,name:`voice`,title:`Voice`},{key:`footprint`,name:`footprint`,title:`Footprint`},{key:`posture`,name:`posture`,title:`Posture`},{key:`mode`,name:`mode`,title:`Mode`},{key:`trust`,name:`trust`,title:`Loop trust`}];function D({value:e,options:t,onChange:n,who:r}){return E.map(i=>(0,S.jsxs)(`label`,{className:`dp-field`,children:[(0,S.jsx)(`span`,{children:i.title}),(0,S.jsx)(C,{label:`${i.name} for ${r}`,value:e[i.key],options:t[i.key],onChange:e=>n(i.key,e)})]},i.key))}function O({host:e,theme:t,options:n,onAction:i,onClose:a,onNote:s}){let[c,l]=(0,x.useState)({path:``,host:e,theme:t,footprint:`full`,posture:`peer`,mode:`direct`,trust:`balanced`}),[u,d]=(0,x.useState)(!1),p=(e,t)=>l(n=>({...n,[e]:t})),m=async()=>{d(!0),s(``);try{let e=await r.pickFolder();e.path?p(`path`,e.path):e.error&&s(e.error)}catch(e){s(e.message)}finally{d(!1)}},h=async()=>{let e=c.path.trim();if(!e){s(`Choose or type a folder to deploy into.`);return}s(``),await i?.(`deploy`,{host:c.host,path:e,theme:c.theme,footprint:c.footprint,posture:c.posture,mode:c.mode,trust:c.trust})&&a()};return(0,S.jsxs)(`div`,{className:`deploy-pop`,children:[(0,S.jsxs)(`div`,{className:`dp-row`,children:[(0,S.jsx)(`input`,{className:`inp dp-path`,type:`text`,placeholder:`/path/to/project, or click Browse…`,value:c.path,onChange:e=>p(`path`,e.target.value),onKeyDown:e=>e.key===`Enter`&&h(),"aria-label":`Folder to deploy into`}),(0,S.jsx)(`button`,{className:`btn ghost sm`,disabled:u,onClick:m,children:u?`Choosing…`:`Browse…`})]}),(0,S.jsxs)(`div`,{className:`dp-row`,children:[(0,S.jsxs)(`label`,{className:`dp-field`,children:[(0,S.jsx)(`span`,{children:`Deploy as`}),(0,S.jsx)(`select`,{className:`sel`,"aria-label":`host for the new harness`,value:c.host,onChange:e=>p(`host`,e.target.value),children:f.map(e=>(0,S.jsx)(`option`,{value:e.id,children:e.label},e.id))})]}),(0,S.jsx)(D,{value:c,options:n,onChange:p,who:`the new harness`}),(0,S.jsx)(`button`,{className:`btn sm`,onClick:h,children:`Deploy`}),(0,S.jsx)(`button`,{className:`btn ghost sm`,onClick:a,children:`Cancel`})]}),(0,S.jsxs)(`p`,{className:`sub dp-note`,children:[`Adds a per-repo harness (`,(0,S.jsx)(`code`,{children:o(c.host).deployAdds}),`) into the folder, non-destructively. It’s then tracked here even after you leave its directory.`]})]})}function k(){let{data:e,error:t,reload:n}=s(()=>r.excludes(),[]),[i,a]=(0,x.useState)(!1),[o,c]=(0,x.useState)([]),l=async(e,t)=>{a(!0);try{let n=await r.excludeMutate(e,t);c(n.messages||[])}catch(e){c(e.body?.messages||[e.message])}finally{a(!1),n()}};return t||!e?.installs?.length?null:(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Excluded folders`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`Sovereign repos: inside these folders every global harness goes dormant — hooks stay silent and the global preamble is not loaded.`}),(e.excludes||[]).map(e=>(0,S.jsxs)(`div`,{className:`row wrap between gap-12`,children:[(0,S.jsx)(`code`,{children:e.path}),(0,S.jsxs)(`span`,{className:`mono muted`,children:[`[`,e.hosts.join(`, `),`]`]}),(0,S.jsx)(`button`,{className:`btn ghost sm`,disabled:i,onClick:()=>l(`remove`,e.path),children:`Remove`})]},e.path)),(0,S.jsxs)(`button`,{className:`btn ghost sm`,disabled:i,onClick:async()=>{a(!0);try{let e=await r.pickFolder();e.path?await l(`add`,e.path):e.error&&c([e.error])}catch(e){c([e.message])}finally{a(!1)}},children:[(0,S.jsx)(m,{name:`folder`}),` Exclude a folder…`]}),o.map((e,t)=>(0,S.jsx)(`p`,{className:`sub`,children:e},t))]})}function A({inst:e,memory:t,busy:n,onMemory:r,onRemove:i,onCancel:a}){return(0,S.jsxs)(`div`,{className:`h-remove`,children:[(0,S.jsxs)(`p`,{className:`hr-msg`,children:[(0,S.jsx)(`strong`,{children:e.scope===`project`?`Remove this harness from the folder?`:`Remove the global ${e.host} install?`}),` `,(0,S.jsxs)(`span`,{className:`sub`,children:[`Deletes `,(0,S.jsx)(`code`,{children:u(e.host,e.scope)}),e.scope===`project`?` and de-lists it.`:`; the row stays, marked “not installed.”`,` `,`This can’t be undone.`]})]}),(0,S.jsxs)(`label`,{className:`field`,children:[(0,S.jsx)(`span`,{children:`Memory and notebook`}),(0,S.jsxs)(`select`,{className:`sel`,"aria-label":`memory disposition`,value:t,onChange:e=>r(e.target.value),children:[(0,S.jsx)(`option`,{value:`keep`,children:`keep in place`}),(0,S.jsx)(`option`,{value:`archive`,children:`archive aside`}),(0,S.jsx)(`option`,{value:`delete`,children:`delete too`})]})]}),(0,S.jsxs)(`div`,{className:`row gap-8`,children:[(0,S.jsx)(`button`,{type:`button`,className:`btn danger`,disabled:n,onClick:i,children:n?`Removing…`:`Remove`}),(0,S.jsx)(`button`,{type:`button`,className:`btn ghost`,onClick:a,children:`Cancel`})]})]})}function j({targets:e,mcpBusy:t,onReveal:n,onToggle:r}){let i=e.flatMap(e=>e.servers),a=i.filter(e=>e.state===`enabled`).length;return(0,S.jsxs)(`div`,{className:`ip-block`,children:[(0,S.jsxs)(`span`,{className:`ip-label`,children:[`MCP servers`,` `,(0,S.jsxs)(`span`,{className:`mono dim`,children:[a,` of `,i.length]})]}),e.map(e=>(0,S.jsxs)(`div`,{className:`mcp-target`,children:[(0,S.jsxs)(`div`,{className:`mt-head`,children:[(0,S.jsx)(`code`,{title:e.path,children:e.label}),(0,S.jsx)(`button`,{type:`button`,className:`btn ghost sm`,onClick:()=>n(e),title:`Open the folder holding ${e.path}: tokens and URLs go in this file`,children:`Open folder`}),e.commented?(0,S.jsx)(`span`,{className:`dim`,children:`has comments; edit by hand`}):null]}),e.servers.map(n=>{let i=e.path+n.name,a=!!(e.commented||t===i);return(0,S.jsxs)(`div`,{className:`mcp-row`,title:n.desc,children:[(0,S.jsx)(`span`,{children:n.label}),n.state===`absent`?n.preset?(0,S.jsx)(`button`,{type:`button`,className:`btn ghost sm`,disabled:a,onClick:()=>r(e,n),children:`Add`}):null:(0,S.jsx)(T,{on:n.state===`enabled`,disabled:a,label:`${n.label} server`,onToggle:()=>r(e,n)})]},n.name)})]},e.path))]})}var M={active:[`Active`,`ok`],disabled:[`Disabled`,`warn`],absent:[`Not installed`,``]};function N({inst:e,targets:t,choice:n,unchanged:r,options:i,onPick:s,canAct:c,busy:l,mcpBusy:u,removing:d,onRemoving:f,onApply:p,onToggleInstall:m,onRemove:h,onRevealMcp:g,onToggleMcp:_}){let v=`${e.host} · ${e.scope}`,[y,b]=M[e.state]||M.absent,x=e.state===`active`,C=e.state===`absent`;return(0,S.jsxs)(`aside`,{className:`install-panel`,"aria-label":`${v} install`,children:[(0,S.jsx)(`span`,{className:`ip-eyebrow`,children:`Selected install`}),(0,S.jsxs)(`div`,{className:`ip-head`,children:[(0,S.jsx)(`h2`,{children:a(e)}),(0,S.jsx)(`span`,{className:`tag ${b}`,children:y})]}),(0,S.jsx)(`span`,{className:`ip-kind`,children:e.scope===`global`?`Global install`:`Per-project install · ${o(e.host).label}`}),(0,S.jsx)(`code`,{className:`ip-path`,children:e.path}),C?(0,S.jsxs)(`p`,{className:`sub`,children:[`Install Geneseed here as `,(0,S.jsx)(`strong`,{children:e.host}),`. Files are added non-destructively; deactivate or uninstall later.`]}):null,(x||C)&&c?(0,S.jsx)(`div`,{className:`ip-picks`,children:(0,S.jsx)(D,{value:n,options:i,onChange:s,who:v})}):null,x&&t.length?(0,S.jsx)(j,{targets:t,mcpBusy:u,onReveal:g,onToggle:_}):null,x&&e.scope===`global`?(0,S.jsx)(k,{}):null,C?null:(0,S.jsxs)(`label`,{className:`ip-switch`,children:[(0,S.jsx)(T,{on:x,disabled:l,label:`activate ${v}`,onToggle:m}),(0,S.jsx)(`span`,{children:x?`Active: loads in every session`:`Disabled: files moved aside`})]}),(0,S.jsx)(`div`,{className:`ip-spacer`}),c?(0,S.jsxs)(`div`,{className:`ip-actions`,children:[C?(0,S.jsx)(`button`,{type:`button`,className:`btn`,onClick:p,children:`Install`}):x?(0,S.jsx)(`button`,{type:`button`,className:`btn`,disabled:r,onClick:p,children:`Apply and rebuild`}):null,C?null:(0,S.jsx)(`button`,{type:`button`,className:`btn ghost danger-line`,"aria-label":`remove ${v} from ${e.path}`,"aria-expanded":!!d,disabled:l,onClick:()=>f(d?null:{memory:`keep`}),children:`Uninstall…`})]}):null,d?(0,S.jsx)(A,{inst:e,memory:d.memory,busy:l,onMemory:e=>f({memory:e}),onRemove:h,onCancel:()=>f(null)}):null]})}var P=(e,t)=>`${e} ${t}`,F={active:[`Active`,`ok`],disabled:[`Disabled`,`warn`]};function I({rows:e,project:t,currentId:n,onPick:r,label:i}){return(0,S.jsx)(`div`,{className:`tbl-scroll`,children:(0,S.jsxs)(`table`,{className:`tbl hosts-tbl`,"aria-label":i,children:[(0,S.jsx)(`thead`,{children:(0,S.jsxs)(`tr`,{children:[(0,S.jsx)(`th`,{children:t?`Project`:`Host`}),(0,S.jsx)(`th`,{children:t?`Host`:`Path`}),(0,S.jsx)(`th`,{children:`Voice`}),(0,S.jsx)(`th`,{children:`Footprint`}),(0,S.jsx)(`th`,{children:`State`}),(0,S.jsx)(`th`,{children:(0,S.jsx)(`span`,{className:`sr-only`,children:`Selected`})})]})}),(0,S.jsx)(`tbody`,{children:e.map(e=>{let[i,s]=F[e.state]||[`Not installed`,``],c=n===e.id,l=e.state===`absent`;return(0,S.jsxs)(`tr`,{className:`pickable${c?` on`:``}${l?` quiet`:``}`,onClick:()=>r(e.id),children:[(0,S.jsx)(`td`,{children:(0,S.jsx)(`button`,{type:`button`,className:`row-pick`,"aria-pressed":c,title:e.path,onClick:()=>r(e.id),children:a(e)})}),t?(0,S.jsx)(`td`,{children:o(e.host).label}):(0,S.jsx)(`td`,{className:`mono path-cell`,title:e.path,children:e.path}),(0,S.jsx)(`td`,{children:l?``:e.theme||``}),(0,S.jsx)(`td`,{children:l?``:e.footprint||``}),(0,S.jsx)(`td`,{children:(0,S.jsx)(`span`,{className:`tag ${s}`,children:i})}),(0,S.jsx)(`td`,{className:`pick-mark`,children:c?`Editing ›`:``})]},e.id)})})]})})}function L({themes:e,current:t}){if(!e.length||!t)return null;let n=[...e].sort((e,n)=>e.name===t?-1:+(n.name===t));return(0,S.jsxs)(`details`,{className:`panel voice-ref`,children:[(0,S.jsxs)(`summary`,{children:[(0,S.jsx)(`span`,{className:`vr-title`,children:`Voices`}),(0,S.jsxs)(`span`,{className:`mono dim`,children:[e.length,` to choose from, set per install`]})]}),(0,S.jsx)(`div`,{className:`vr-list`,children:n.map(e=>(0,S.jsxs)(`div`,{className:`voice-row${e.name===t?` current`:``}`,children:[(0,S.jsx)(`span`,{className:`vr-name`,children:e.name}),(0,S.jsx)(`span`,{className:`vr-desc`,children:e.tagline?`“${e.tagline}”`:e.blurb})]},e.name))})]})}function R({setup:e,overview:t}){if(!e)return null;let n=e.installed_fp&&e.installed_fp===e.source_fp;return(0,S.jsxs)(`section`,{className:`panel`,"aria-labelledby":`checkout-h`,children:[(0,S.jsxs)(`div`,{className:`panel-head`,children:[(0,S.jsx)(`h2`,{id:`checkout-h`,children:`This checkout`}),(0,S.jsx)(`span`,{className:`mono ${n?`t-good`:`t-warn`}`,children:e.version_verdict})]}),(0,S.jsxs)(`dl`,{className:`kv-grid`,children:[(0,S.jsx)(`dt`,{children:`Source`}),(0,S.jsx)(`dd`,{className:`mono`,children:e.root}),(0,S.jsx)(`dt`,{children:`Version`}),(0,S.jsx)(`dd`,{className:`mono`,children:t?.version||`unknown`}),(0,S.jsx)(`dt`,{children:`Fingerprint`}),(0,S.jsx)(`dd`,{className:`mono`,children:e.source_fp})]})]})}function z({onAction:e,themes:t=[],currentTheme:n,overview:i,setup:a,dataRev:o,onMutated:c}){let l=g(),{data:u,error:d}=s(()=>r.installs(),[o]),{data:f,error:p}=s(()=>r.mcp(),[o]),[_,y]=(0,x.useState)(``),[b,C]=(0,x.useState)(``),[T,E]=(0,x.useState)(``),[D,k]=(0,x.useState)({}),[A,j]=(0,x.useState)(!1),[M,F]=(0,x.useState)(null),[z,B]=(0,x.useState)(``),V=(0,x.useMemo)(()=>{let e={};for(let t of f?.targets||[]){let n=P(t.host||`opencode`,t.root);(e[n]||(e[n]=[])).push(t)}return e},[f]);if(d||p)return(0,S.jsx)(h,{error:d||p});if(!u||!f)return(0,S.jsx)(v,{});let H={active:0,disabled:1,absent:2},U=[...u.installs].sort((e,t)=>(e.scope===`global`?0:1)-(t.scope===`global`?0:1)||(H[e.state]??3)-(H[t.state]??3)),W=U.find(e=>e.id===z)||U.find(e=>e.selected)||U.find(e=>e.state===`active`)||U[0],G=e=>{let t=D[e.id]||{};return{theme:t.theme||e.theme||n||`neutral`,footprint:t.footprint||e.footprint||`full`,posture:t.posture||e.posture||`peer`,mode:t.mode||e.mode||`direct`,trust:t.trust||e.trust||`balanced`}},K=(e,t,n)=>k(r=>({...r,[e.id]:{...r[e.id],[t]:n}})),q=e=>{let t=G(e);return t.theme===e.theme&&t.footprint===(e.footprint||`full`)&&t.posture===(e.posture||`peer`)&&t.mode===(e.mode||`direct`)&&t.trust===(e.trust||`balanced`)},J={theme:t.map(e=>e.name),footprint:w,posture:u.postures||[],mode:u.modes||[],trust:u.trusts||[]},Y=async t=>{let{theme:n,footprint:r,posture:i,mode:a,trust:o}=G(t),s=t.state===`absent`?`Install Geneseed into ${t.path} with the “${n}” voice (${r} footprint, ${i} posture, ${a} mode)? Files are added non-destructively (your own config is left untouched); deactivate or uninstall later.`:`Rebuild this install (voice “${n}”, ${r} footprint, ${i} posture, ${a} mode)? It rebuilds in place, non-destructive.`;await l(s,{title:t.state===`absent`?`Install Geneseed?`:`Rebuild this install?`,confirmLabel:t.state===`absent`?`Install`:`Rebuild`})&&e?.(`install`,{host:t.host,scope:t.scope,path:t.path,theme:n,footprint:r,posture:i,mode:a,trust:o})},X=async e=>{if(e.state!==`active`||await l(`Deactivate this install? Files are moved aside, not deleted; reactivate any time.`,{title:`Deactivate this install?`,confirmLabel:`Deactivate`})){C(e.id),y(``);try{let t=await r.installToggle(e.host,e.path,e.state===`active`?`deactivate`:`activate`);if(!t.ok){let e=Array.isArray(t.failed)?t.failed.join(`, `):``;y(t.error||e&&`unrestored: ${e}`||`action failed`);return}c?.()}catch(e){y(e.message)}finally{C(``)}}},Z=async()=>{let e=M;if(e){C(e.id),y(``);try{let t=await r.installRemove(e.host,e.path,e.memory);if(!t.ok){y(t.error||`remove failed`);return}F(null),c?.()}catch(e){y(e.message)}finally{C(``)}}},ee=async e=>{y(``);try{let t=await r.mcpReveal(e.path);y(`Opening ${t.dir}. If no window appeared, open that folder by hand.`)}catch(e){y(e.message)}},te=async(e,t)=>{let n=e.path+t.name;E(n),y(``);try{await r.mcpToggle(e.path,t.name,t.state!==`enabled`),c?.()}catch(e){y(e.message)}finally{E(``)}},ne=U.find(e=>e.selected)?.host||U.find(e=>e.state===`active`)?.host||U[0]?.host||`opencode`,re=U.filter(e=>e.scope===`global`),Q=U.filter(e=>e.scope!==`global`),$=e=>{B(e),F(null)};return(0,S.jsxs)(`div`,{className:`hosts`,children:[(0,S.jsxs)(`div`,{className:`hosts-main`,children:[(0,S.jsxs)(`div`,{className:`toolbar`,children:[(0,S.jsxs)(`span`,{className:`dim`,children:[U.filter(e=>e.state===`active`).length,` active of `,U.length,` `,`detected.`]}),e?(0,S.jsx)(`div`,{className:`row gap-8`,children:(0,S.jsxs)(`button`,{type:`button`,className:`btn ghost`,onClick:()=>e(`build-all`),children:[(0,S.jsx)(m,{name:`refresh`}),` Rebuild all`]})}):null]}),_?(0,S.jsx)(`p`,{className:`tag bad note`,role:`status`,children:_}):null,(0,S.jsxs)(`section`,{className:`panel flush`,"aria-labelledby":`inst-global`,children:[(0,S.jsx)(`div`,{className:`inst-head`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{id:`inst-global`,children:`Global installs`}),(0,S.jsx)(`p`,{className:`dim`,children:`One per tool. Loaded in every folder, except excluded ones.`})]})}),(0,S.jsx)(I,{rows:re,currentId:W?.id,onPick:$,label:`Global installs`})]}),(0,S.jsxs)(`section`,{className:`panel flush`,"aria-labelledby":`inst-project`,children:[(0,S.jsxs)(`div`,{className:`inst-head`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{id:`inst-project`,children:`Per-project installs`}),(0,S.jsx)(`p`,{className:`dim`,children:`A repo with its own harness. Inside it, only that harness loads.`})]}),e?(0,S.jsxs)(`button`,{type:`button`,className:`btn ghost`,onClick:()=>j(e=>!e),children:[(0,S.jsx)(m,{name:`folder`}),` Deploy to a repo…`]}):null]}),A?(0,S.jsx)(`div`,{className:`inst-deploy`,children:(0,S.jsx)(O,{host:ne,theme:n||`neutral`,options:J,onAction:e,onClose:()=>j(!1),onNote:y})}):null,Q.length?(0,S.jsx)(I,{rows:Q,project:!0,currentId:W?.id,onPick:$,label:`Per-project installs`}):(0,S.jsx)(`div`,{className:`empty inst-empty`,children:`No repo has its own harness yet. Deploy one to give a project its own rules and voice.`})]}),(0,S.jsx)(R,{setup:a,overview:i}),(0,S.jsx)(L,{themes:t,current:i?.theme})]}),W?(0,S.jsx)(N,{inst:W,targets:V[P(W.host,W.path)]||[],choice:G(W),unchanged:q(W),options:J,onPick:(e,t)=>K(W,e,t),canAct:!!e,busy:b===W.id,mcpBusy:T,removing:M?.id===W.id?M:null,onRemoving:e=>F(e&&{id:W.id,host:W.host,path:W.path,memory:e.memory}),onApply:()=>Y(W),onToggleInstall:()=>X(W),onRemove:Z,onRevealMcp:ee,onToggleMcp:te},W.id):null]})}function B(e){return e.startsWith(`@@`)||e.startsWith(`+++`)||e.startsWith(`---`)?`hunk`:e.startsWith(`+`)?`add`:e.startsWith(`-`)?`del`:`ctx`}function V({onMutated:e,onAction:t,dataRev:n}){let i=g(),{data:a,error:o,reload:c}=s(()=>r.diff(),[n]),[l,u]=(0,x.useState)(!1),[d,f]=(0,x.useState)(``),[p,_]=(0,x.useState)(()=>new Set),[y,b]=(0,x.useState)(()=>new Set),[C,w]=(0,x.useState)(null);a&&a!==C&&(w(a),_(new Set),b(new Set(a.files.map(e=>e.rel))));let T=e=>_(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n}),E=()=>_(e=>e.size===a.files.length?new Set:new Set(a.files.map(e=>e.rel))),D=()=>t?.(`export`),O=async()=>{let t=[...p],n=t.filter(e=>a.files.find(t=>t.rel===e)?.status===`added`),o=n.length?`Restoring will DELETE ${n.length} deployed-only file(s):\n${n.join(`
|
|
2
2
|
`)}\n\n`:``;if(await i(`${o}Discard local edits and restore ${t.length} file(s) from source?`,{title:`Restore from source?`,confirmLabel:`Restore`})){u(!0);try{let n=await r.restore(t),i=n.errors.length?` · ${n.errors.length} error(s): ${n.errors.join(`; `)}`:``;f(`Restored ${n.restored.length}, deleted ${n.deleted.length}${i}`),await c(),e?.()}catch(e){f(e.message)}finally{u(!1)}}};if(o)return(0,S.jsx)(h,{error:o});if(!a)return(0,S.jsx)(v,{});if(!a.deployed)return(0,S.jsxs)(`div`,{className:`empty`,children:[(0,S.jsx)(`div`,{className:`big`,children:`No deployed harness`}),`Nothing to diff against.`]});if(!a.diffable)return(0,S.jsxs)(`div`,{className:`empty`,children:[(0,S.jsx)(`div`,{className:`big`,children:`No drift check for this install`}),`The drift check covers global installs only.`]});let k=a.files,A=k.filter(e=>e.status===`edited`).length,j=k.filter(e=>e.status===`added`).length,M=k.filter(e=>e.status===`missing`).length,N=e=>b(t=>{let n=new Set(t);return n.has(e)?n.delete(e):n.add(e),n});return(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{className:`h`,children:`Local edits`}),(0,S.jsx)(`p`,{className:`sub`,children:`The agent refines its own deployed files in place. Export them as improvements before any rebuild overwrites them.`})]}),(0,S.jsxs)(`div`,{className:`row gap-10`,children:[(0,S.jsxs)(`button`,{className:`btn ghost`,disabled:l||p.size===0,onClick:O,children:[`Restore`,p.size?` (${p.size})`:``]}),(0,S.jsxs)(`button`,{className:`btn`,disabled:l,onClick:D,children:[(0,S.jsx)(m,{name:`download`}),`Export improvements`]})]})]}),d?(0,S.jsx)(`p`,{className:`sub mb-14`,children:d}):null,k.length===0?(0,S.jsxs)(`div`,{className:`empty`,children:[(0,S.jsx)(`div`,{className:`big`,children:`In sync`}),`Deployed harness matches source.`]}):(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`div`,{className:`row between mb-14`,children:[(0,S.jsxs)(`div`,{className:`row gap-10`,children:[(0,S.jsxs)(`span`,{className:`badge`,children:[(0,S.jsx)(`span`,{className:`dot`,style:{background:`var(--warn)`}}),A,` edited`]}),(0,S.jsxs)(`span`,{className:`badge`,children:[(0,S.jsx)(`span`,{className:`dot`,style:{background:`var(--good)`}}),j,` added`]}),M>0&&(0,S.jsxs)(`span`,{className:`badge`,children:[(0,S.jsx)(`span`,{className:`dot`,style:{background:`var(--bad)`}}),M,` missing`]})]}),(0,S.jsxs)(`label`,{className:`row dim`,style:{gap:8,fontSize:12.5,cursor:`pointer`},children:[(0,S.jsx)(`input`,{type:`checkbox`,style:{accentColor:`var(--accent)`},checked:p.size===k.length,onChange:E}),`Select all`]})]}),(0,S.jsx)(`div`,{className:`stack gap-12`,children:k.map(e=>{let t=y.has(e.rel),n=e.status===`added`?`ok`:e.status===`missing`?`bad`:`warn`;return(0,S.jsxs)(`div`,{className:`card diff-file${t?` open`:``}`,children:[(0,S.jsxs)(`div`,{className:`diff-head`,children:[(0,S.jsx)(`input`,{type:`checkbox`,className:`chk`,checked:p.has(e.rel),onChange:()=>T(e.rel),onClick:e=>e.stopPropagation(),"aria-label":`Select ${e.rel}`}),(0,S.jsx)(`span`,{className:`fname`,children:e.rel}),(0,S.jsxs)(`span`,{className:`badge ${n}`,children:[(0,S.jsx)(`span`,{className:`dot`}),e.status]}),(0,S.jsxs)(`span`,{className:`dim mono`,style:{marginLeft:`auto`,fontSize:11},children:[e.diff.length,` lines`]}),(0,S.jsx)(`button`,{className:`iconbtn`,onClick:()=>N(e.rel),style:{transform:t?`rotate(90deg)`:`none`},"aria-label":t?`Collapse ${e.rel}`:`Expand ${e.rel}`,"aria-expanded":t,children:(0,S.jsx)(m,{name:`chevron`})})]}),t&&(0,S.jsx)(`div`,{className:`diff-body`,children:e.diff.map((e,t)=>(0,S.jsx)(`div`,{className:`diff-line ${B(e)}`,children:e},t))})]},e.rel)})})]})]})}function H({group:e,i:t}){let n=e.problems.length===0,[r,i]=(0,x.useState)(!n);return(0,S.jsxs)(`div`,{className:`card check rise ${n?``:`bad`} ${r?`open`:``}`,style:{"--i":t*.6},children:[(0,S.jsxs)(`button`,{className:`check-head`,onClick:()=>i(e=>!e),disabled:n,style:{cursor:n?`default`:`pointer`},"aria-expanded":n?void 0:r,children:[(0,S.jsx)(`span`,{className:`feed-dot ${n?`ok`:`bad`}`,style:{width:9,height:9}}),(0,S.jsx)(`h3`,{children:e.label}),(0,S.jsxs)(`span`,{className:`badge ${n?`ok`:`bad`}`,children:[(0,S.jsx)(`span`,{className:`dot`}),n?`clean`:`${e.problems.length} problem${e.problems.length===1?``:`s`}`]}),!n&&(0,S.jsx)(m,{name:`chevron`,className:`chev glyph`})]}),!n&&r&&(0,S.jsx)(`div`,{className:`check-body`,children:e.problems.map(e=>(0,S.jsxs)(`div`,{className:`problem`,children:[(0,S.jsx)(`span`,{className:`x`,children:`✕`}),(0,S.jsx)(`span`,{children:e})]},e))})]})}function U(){let{data:e,error:t,reload:n,setData:i}=s(()=>r.doctor(),[]);return t?(0,S.jsx)(h,{error:t}):(0,S.jsxs)(`div`,{className:`narrow`,children:[(0,S.jsxs)(`div`,{className:`head-row mb-16`,children:[(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{className:`h`,children:`Doctor`}),(0,S.jsx)(`p`,{className:`sub`,children:`Every check builds each theme in a sandbox and validates the result: token resolution, link integrity, parity, and drift.`})]}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:()=>{i(null),n()},disabled:!e,children:[(0,S.jsx)(m,{name:`refresh`}),e?`Re-run checks`:`Running…`]})]}),e?(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(`div`,{className:`card pad-md mb-16`,children:(0,S.jsxs)(`div`,{className:`row wrap between gap-12`,children:[(0,S.jsxs)(`div`,{className:`row`,style:{gap:10,flexWrap:`wrap`},children:[(0,S.jsxs)(`span`,{className:`dim mono`,style:{fontSize:12},children:[`validated `,e.themes.length,` theme`,e.themes.length===1?``:`s`]}),e.themes.map(e=>(0,S.jsx)(`span`,{className:`badge`,style:{textTransform:`capitalize`},children:e},e))]}),e.ok?(0,S.jsxs)(`span`,{className:`badge ok`,children:[(0,S.jsx)(`span`,{className:`dot`}),`all clean`]}):(0,S.jsxs)(`span`,{className:`badge bad`,children:[(0,S.jsx)(`span`,{className:`dot`}),e.problems.length,` problem`,e.problems.length===1?``:`s`]})]})}),(0,S.jsx)(`div`,{className:`stack gap-12`,children:e.groups.map((e,t)=>(0,S.jsx)(H,{group:e,i:t},e.label))})]}):(0,S.jsx)(v,{label:`Running every check (builds each theme in a sandbox)…`})]})}function W(){let e=g(),[t,n]=(0,x.useState)(!1),[i,a]=(0,x.useState)(!1),[o,s]=(0,x.useState)(null);return t?(0,S.jsxs)(`p`,{className:`sub`,children:[`Server stopped. You can close this tab and reopen any time with `,(0,S.jsx)(`code`,{children:`geneseed web`}),`.`]}):(0,S.jsxs)(S.Fragment,{children:[o&&(0,S.jsx)(`p`,{className:`sub`,role:`alert`,children:o}),(0,S.jsxs)(`div`,{className:`row`,children:[(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:async()=>{if(await e(`Restart the local Geneseed server? The console reconnects in a moment.`,{title:`Restart the server?`,confirmLabel:`Restart`})){a(!0),s(null);try{await c()}catch(e){s(e.message),a(!1)}}},disabled:i,children:[(0,S.jsx)(m,{name:`refresh`}),i?`Restarting…`:`Restart server`]}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:async()=>{if(await e(`Stop the local Geneseed server? The console goes offline until you start it again.`,{title:`Stop the server?`,confirmLabel:`Stop server`})){s(null);try{await r.shutdown()}catch(e){if(e.status)return s(e.message)}n(!0)}},disabled:i,children:[(0,S.jsx)(m,{name:`x`}),`Stop server`]})]})]})}var G=`https://github.com/Arylmera/Geneseed`,K=`https://github.com/Arylmera`;function q(){let[e,t]=(0,x.useState)(G),[n,i]=(0,x.useState)(!0);return(0,x.useEffect)(()=>{Promise.resolve(r.docsPage?.(`about`)).then(e=>{e?.repo&&(t(e.repo),i(!!e.repo_is_github))}).catch(()=>{})},[]),(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`About`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`Geneseed is a portable, theme-able harness you implant once and use everywhere to grow a disciplined AI coding agent. One canonical source, many voices, MIT-licensed.`}),(0,S.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,S.jsxs)(`a`,{className:`btn ghost`,href:e,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(m,{name:`github`}),n?`Source on GitHub`:`Source repo`]}),n&&(0,S.jsxs)(S.Fragment,{children:[(0,S.jsxs)(`a`,{className:`btn ghost`,href:e+`/issues`,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(m,{name:`external`}),`Issues`]}),(0,S.jsxs)(`a`,{className:`btn ghost`,href:e+`/blob/main/LICENSE`,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(m,{name:`external`}),`MIT License`]})]})]})]}),(0,S.jsxs)(`div`,{className:`card pad-lg`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Creator`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[`Geneseed is built by `,(0,S.jsx)(`strong`,{children:`Guillaume Lemer`}),`. It started as a personal, Obsidian-vault-grown agent operating system and was distilled into the repo you are running. Implant it once, and a disciplined agent grows around the same inherited rules, skills, and memory in every repo it follows you into.`]}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`If you find this useful, a star on the repo or an issue with feedback is the best way to help shape what comes next.`}),(0,S.jsx)(`div`,{className:`row wrap gap-10`,children:(0,S.jsxs)(`a`,{className:`btn ghost`,href:K,target:`_blank`,rel:`noreferrer`,children:[(0,S.jsx)(m,{name:`github`}),`@Arylmera on GitHub`]})})]})]})}function J({overview:e,onAction:t,flavour:n,onFlavour:r,accentMode:i,onAccentMode:a,layout:o,onLayout:s}){let c=g(),u=e?.install,f=e?.footprint,h=async e=>{u&&e!==f&&await c(`Rebuild ${u.host} · ${u.scope} with the “${e}” footprint? It rebuilds in place, non-destructive.`,{title:`Change the footprint?`,confirmLabel:`Rebuild`})&&t?.(`install`,{...u,footprint:e})};return(0,S.jsxs)(`div`,{className:`narrow-lg`,children:[(0,S.jsx)(`div`,{className:`head-row mb-18`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h2`,{className:`h`,children:`Settings`}),(0,S.jsx)(`p`,{className:`sub`,children:`Console appearance, the footprint of the install you are viewing, machine maintenance (including the update), server control, and about. Each install is managed on the Hosts tab.`})]})}),n&&r&&(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Console direction`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[y.length,` takes on the same data. Pick a direction; it applies instantly and persists across reloads.`]}),i&&a&&(0,S.jsxs)(`div`,{className:`dir-layout`,children:[(0,S.jsx)(`span`,{className:`tick`,id:`dir-accent-label`,children:`Accent`}),(0,S.jsx)(p,{value:i,onChange:a,labelledBy:`dir-accent-label`}),(0,S.jsx)(`span`,{className:`dir-layout-note sub`,role:`status`,"aria-live":`polite`,children:d(i)})]}),o&&s&&(0,S.jsxs)(`div`,{className:`dir-layout`,children:[(0,S.jsx)(`span`,{className:`tick`,id:`dir-layout-label`,children:`Overview view`}),(0,S.jsx)(_,{"aria-labelledby":`dir-layout-label`,children:l.map(e=>(0,S.jsx)(`button`,{className:o===e.id?`on`:``,onClick:()=>s(e.id),"aria-pressed":o===e.id,title:e.tagline,children:e.short},e.id))}),(0,S.jsx)(`span`,{className:`dir-layout-note sub`,role:`status`,"aria-live":`polite`,children:l.find(e=>e.id===o)?.tagline??``})]}),(0,S.jsx)(`div`,{className:`dir-grid`,children:y.map(e=>(0,S.jsxs)(`button`,{className:`dir-tile dir-${e.id} ${n===e.id?`on`:``}`,onClick:()=>r(e.id),"aria-pressed":n===e.id,children:[(0,S.jsxs)(`span`,{className:`dir-thumb`,"aria-hidden":`true`,children:[(0,S.jsx)(`span`,{className:`dir-thumb-rail`}),(0,S.jsx)(`span`,{className:`dir-thumb-bar`}),(0,S.jsx)(`span`,{className:`dir-thumb-bar`,style:{width:`70%`}}),(0,S.jsx)(`span`,{className:`dir-thumb-bar`,style:{width:`52%`}}),(0,S.jsx)(`span`,{className:`dir-thumb-dot`})]}),(0,S.jsxs)(`span`,{className:`dir-meta`,children:[(0,S.jsxs)(`span`,{className:`dir-name`,children:[e.short,n===e.id&&(0,S.jsx)(`span`,{className:`dir-check`,children:`● active`})]}),(0,S.jsx)(`span`,{className:`dir-tag`,children:e.tagline})]})]},e.id))})]}),u&&f&&(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Harness footprint`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[`How much of the Rules `,(0,S.jsx)(`code`,{children:`AGENT.md`}),` carries inline each turn, for the current install (`,(0,S.jsxs)(`code`,{children:[u.host,` · `,u.scope]}),`). A token-cost dial; every Rule stays in force either way. Changing it rebuilds the install in place. `,(0,S.jsx)(`a`,{href:`#/docs/footprint`,children:`Learn more →`})]}),(0,S.jsxs)(`div`,{className:`dir-layout`,children:[(0,S.jsx)(`span`,{className:`tick`,id:`footprint-label`,children:`Footprint`}),(0,S.jsx)(_,{"aria-labelledby":`footprint-label`,children:[`full`,`lean`].map(e=>(0,S.jsx)(`button`,{className:f===e?`on`:``,onClick:()=>h(e),"aria-pressed":f===e,children:e},e))}),(0,S.jsx)(`span`,{className:`dir-layout-note sub`,role:`status`,"aria-live":`polite`,children:f===`lean`?`Lean: terse rule lines + a pointer to the full law file (~40% smaller, lighter context per turn).`:`Full: every Rule’s complete text and rationale inlined (maximum guidance, largest context).`})]})]}),(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Maintenance`})}),(0,S.jsxs)(`p`,{className:`sub mb-16`,children:[`Put `,(0,S.jsx)(`code`,{children:`geneseed`}),` on your PATH so it runs from any directory, or remove a global install. Your memory store is always kept. Each runs live in the console.`]}),(0,S.jsxs)(`div`,{className:`row wrap gap-10`,children:[(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:()=>t(`update`),children:[(0,S.jsx)(m,{name:`download`}),`Update (git pull + rebuild)`]}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:()=>t(`link`),children:[(0,S.jsx)(m,{name:`external`}),`Add to PATH`]}),(0,S.jsx)(`button`,{className:`btn ghost`,onClick:()=>t(`unlink`),children:`Remove from PATH`}),(0,S.jsxs)(`button`,{className:`btn ghost`,onClick:async()=>{await c(`Uninstall the global Geneseed harness? Your memory store is kept; everything else this install added is removed.`,{title:`Uninstall Geneseed?`,confirmLabel:`Uninstall`})&&t(`uninstall`)},children:[(0,S.jsx)(m,{name:`clear`}),`Uninstall`]})]})]}),(0,S.jsxs)(`div`,{className:`card pad-lg mb-16`,children:[(0,S.jsx)(`div`,{className:`card-head`,children:(0,S.jsx)(`h3`,{children:`Server`})}),(0,S.jsx)(`p`,{className:`sub mb-16`,children:`The console runs a small local server. Leave it running in the background and reopen any time, or stop it when you are done.`}),(0,S.jsx)(W,{})]}),(0,S.jsx)(q,{})]})}function Y({tab:e=`hosts`,overview:t,setup:n,themes:r,onAction:a,onMutated:o,dataRev:s,appearance:c={}}){let l=t?.doctor,u=t?.diff,d={edits:u?i(u)+(u.missing??0):null,doctor:l?l.ok?`clean`:l.problems.length:null};return(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(`div`,{className:`page-head`,children:(0,S.jsxs)(`div`,{children:[(0,S.jsx)(`h1`,{className:`h`,children:`Installs`}),(0,S.jsx)(`p`,{className:`sub`,children:`Where the harness lives on this machine, and how each copy is built.`})]})}),(0,S.jsx)(b,{page:`installs`,current:e,badges:d,label:`Installs`}),e===`hosts`&&(0,S.jsx)(z,{onAction:a,themes:r,currentTheme:t?.theme,overview:t,setup:n,dataRev:s,onMutated:o}),e===`edits`&&(0,S.jsx)(V,{onMutated:o,onAction:a,dataRev:s}),e===`doctor`&&(0,S.jsx)(U,{}),e===`server`&&(0,S.jsx)(J,{overview:t,onAction:a,...c})]})}export{Y as default};
|