@selvakumaresra/specship 0.6.0 → 0.9.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/dist/bin/specship.js +59 -0
- package/dist/bin/specship.js.map +1 -1
- package/dist/db/migrations.d.ts +1 -1
- package/dist/db/migrations.d.ts.map +1 -1
- package/dist/db/migrations.js +28 -1
- package/dist/db/migrations.js.map +1 -1
- package/dist/db/schema.sql +25 -1
- package/dist/index.d.ts +20 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +71 -1
- package/dist/index.js.map +1 -1
- package/dist/reflect/apply.d.ts +31 -0
- package/dist/reflect/apply.d.ts.map +1 -0
- package/dist/reflect/apply.js +286 -0
- package/dist/reflect/apply.js.map +1 -0
- package/dist/reflect/hash.d.ts +20 -0
- package/dist/reflect/hash.d.ts.map +1 -0
- package/dist/reflect/hash.js +36 -0
- package/dist/reflect/hash.js.map +1 -0
- package/dist/reflect/index.d.ts +16 -0
- package/dist/reflect/index.d.ts.map +1 -0
- package/dist/reflect/index.js +43 -0
- package/dist/reflect/index.js.map +1 -0
- package/dist/reflect/miner.d.ts +21 -0
- package/dist/reflect/miner.d.ts.map +1 -0
- package/dist/reflect/miner.js +463 -0
- package/dist/reflect/miner.js.map +1 -0
- package/dist/reflect/store.d.ts +31 -0
- package/dist/reflect/store.d.ts.map +1 -0
- package/dist/reflect/store.js +101 -0
- package/dist/reflect/store.js.map +1 -0
- package/dist/reflect/sweep.d.ts +26 -0
- package/dist/reflect/sweep.d.ts.map +1 -0
- package/dist/reflect/sweep.js +42 -0
- package/dist/reflect/sweep.js.map +1 -0
- package/dist/reflect/targets.d.ts +52 -0
- package/dist/reflect/targets.d.ts.map +1 -0
- package/dist/reflect/targets.js +192 -0
- package/dist/reflect/targets.js.map +1 -0
- package/dist/reflect/types.d.ts +96 -0
- package/dist/reflect/types.d.ts.map +1 -0
- package/dist/reflect/types.js +13 -0
- package/dist/reflect/types.js.map +1 -0
- package/dist/server/routes/events.js +134 -0
- package/dist/server/routes/projects.js +1 -1
- package/dist/server/routes/reflect.js +93 -0
- package/dist/server/server.js +4 -0
- package/dist/types.d.ts +1 -1
- package/dist/types.d.ts.map +1 -1
- package/dist/web/chunk-ITHLF4GI.js +1 -0
- package/dist/web/chunk-JBO7ZIPO.js +1 -0
- package/dist/web/chunk-RJLLYZEQ.js +6 -0
- package/dist/web/chunk-TPDB5GJN.js +1 -0
- package/dist/web/chunk-Y6WWDS4R.js +1 -0
- package/dist/web/chunk-Z5L3T5EO.js +1 -0
- package/dist/web/icon-192.png +0 -0
- package/dist/web/icon-512.png +0 -0
- package/dist/web/index.html +2 -1
- package/dist/web/main-P33TUYUP.js +1 -0
- package/dist/web/manifest.webmanifest +15 -0
- package/dist/workflows/executor.d.ts.map +1 -1
- package/dist/workflows/executor.js +3 -0
- package/dist/workflows/executor.js.map +1 -1
- package/dist/workflows/runners/prompt.d.ts +31 -8
- package/dist/workflows/runners/prompt.d.ts.map +1 -1
- package/dist/workflows/runners/prompt.js +117 -23
- package/dist/workflows/runners/prompt.js.map +1 -1
- package/dist/workflows/runners/types.d.ts +7 -1
- package/dist/workflows/runners/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/dist/web/chunk-BYZFQSM6.js +0 -1
- package/dist/web/chunk-JQ534IB6.js +0 -6
- package/dist/web/chunk-MVOMVPYB.js +0 -1
- package/dist/web/chunk-NZEZCT65.js +0 -1
- package/dist/web/chunk-SBWU7JFC.js +0 -1
- package/dist/web/main-QAP4FTDP.js +0 -1
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* GET /api/events — cross-project alert stream (REQ-PWA-002).
|
|
3
|
+
*
|
|
4
|
+
* A single SSE stream that watches EVERY initialized project (not just the
|
|
5
|
+
* selected one) and emits an event when an alert-worthy transition happens:
|
|
6
|
+
* - `approval` — a workflow run entered `paused` (an approval gate)
|
|
7
|
+
* - `runDone` — a run entered `completed` or `failed`
|
|
8
|
+
* - `drift` — a spec→code link newly entered drifted/broken/orphaned
|
|
9
|
+
*
|
|
10
|
+
* Polls the same SQLite the executor/resolver write to (mirrors the workflow
|
|
11
|
+
* SSE's 500ms-poll approach), diffing against per-connection seen-state so only
|
|
12
|
+
* NEW transitions are emitted — never a backlog burst on connect, never a repeat
|
|
13
|
+
* for the same transition. The client (NotificationsService) turns these into
|
|
14
|
+
* desktop notifications, gated on permission + per-type toggles.
|
|
15
|
+
*/
|
|
16
|
+
import os from 'node:os';
|
|
17
|
+
import path from 'node:path';
|
|
18
|
+
import { enumerate } from './projects.js';
|
|
19
|
+
const POLL_MS = 3000;
|
|
20
|
+
const KEEPALIVE_MS = 15000;
|
|
21
|
+
// Reflection sweep cadence — high-severity-only, roughly daily (REQ-REFLECT-006).
|
|
22
|
+
// The persisted reflect_proposals store dedupes across sweeps/connections, so a
|
|
23
|
+
// proposal is only ever notified once regardless of how often the sweep runs.
|
|
24
|
+
const SWEEP_MS = 24 * 60 * 60 * 1000;
|
|
25
|
+
export async function registerEventsRoutes(app) {
|
|
26
|
+
const claudeRoot = path.join(os.homedir(), '.claude', 'projects');
|
|
27
|
+
app.get('/api/events', async (req, reply) => {
|
|
28
|
+
reply.raw.setHeader('Content-Type', 'text/event-stream');
|
|
29
|
+
reply.raw.setHeader('Cache-Control', 'no-cache');
|
|
30
|
+
reply.raw.setHeader('Connection', 'keep-alive');
|
|
31
|
+
reply.raw.write(': connected\n\n');
|
|
32
|
+
// Per-connection seen-state — emit only NEW transitions.
|
|
33
|
+
const lastStatus = new Map(); // `${slug}:${runId}` -> status
|
|
34
|
+
const seenDrift = new Set(); // `${slug}:${linkId}`
|
|
35
|
+
const lastSweep = new Map(); // slug -> last reflection sweep ms
|
|
36
|
+
let primed = false; // first pass seeds state silently (no burst on connect)
|
|
37
|
+
let closed = false;
|
|
38
|
+
const send = (ev) => {
|
|
39
|
+
if (closed)
|
|
40
|
+
return;
|
|
41
|
+
try {
|
|
42
|
+
reply.raw.write(`data: ${JSON.stringify(ev)}\n\n`);
|
|
43
|
+
}
|
|
44
|
+
catch { /* peer gone */ }
|
|
45
|
+
};
|
|
46
|
+
const poll = async () => {
|
|
47
|
+
let projects;
|
|
48
|
+
try {
|
|
49
|
+
projects = await enumerate(claudeRoot);
|
|
50
|
+
}
|
|
51
|
+
catch {
|
|
52
|
+
return;
|
|
53
|
+
}
|
|
54
|
+
for (const p of projects) {
|
|
55
|
+
if (!p.initialized || closed)
|
|
56
|
+
continue;
|
|
57
|
+
let cg;
|
|
58
|
+
try {
|
|
59
|
+
cg = await app.projects.getBySlug(p.slug);
|
|
60
|
+
}
|
|
61
|
+
catch {
|
|
62
|
+
cg = null;
|
|
63
|
+
}
|
|
64
|
+
if (!cg)
|
|
65
|
+
continue;
|
|
66
|
+
const sq = cg.getSpecQueries();
|
|
67
|
+
// Workflow run transitions.
|
|
68
|
+
let runs = [];
|
|
69
|
+
try {
|
|
70
|
+
runs = sq.getAllWorkflowRuns(50);
|
|
71
|
+
}
|
|
72
|
+
catch { /* ignore */ }
|
|
73
|
+
for (const r of runs) {
|
|
74
|
+
const key = `${p.slug}:${r.id}`;
|
|
75
|
+
if (lastStatus.get(key) === r.status)
|
|
76
|
+
continue;
|
|
77
|
+
lastStatus.set(key, r.status);
|
|
78
|
+
if (!primed)
|
|
79
|
+
continue;
|
|
80
|
+
if (r.status === 'paused') {
|
|
81
|
+
send({ kind: 'approval', project: p.slug, projectPath: p.path, id: r.id, title: 'Run needs approval', detail: r.workflowName });
|
|
82
|
+
}
|
|
83
|
+
else if (r.status === 'completed' || r.status === 'failed') {
|
|
84
|
+
send({ kind: 'runDone', project: p.slug, projectPath: p.path, id: r.id, title: `Run ${r.status}`, detail: r.workflowName, status: r.status });
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
// Newly-drifted links.
|
|
88
|
+
let links = [];
|
|
89
|
+
try {
|
|
90
|
+
links = sq.getLinksByState(['drifted', 'broken', 'orphaned']);
|
|
91
|
+
}
|
|
92
|
+
catch { /* ignore */ }
|
|
93
|
+
for (const l of links) {
|
|
94
|
+
const key = `${p.slug}:${l.id}`;
|
|
95
|
+
if (seenDrift.has(key))
|
|
96
|
+
continue;
|
|
97
|
+
seenDrift.add(key);
|
|
98
|
+
if (!primed)
|
|
99
|
+
continue;
|
|
100
|
+
send({ kind: 'drift', project: p.slug, projectPath: p.path, id: String(l.id), title: 'Drift detected', detail: `${l.specId} → ${l.targetQualifiedName}` });
|
|
101
|
+
}
|
|
102
|
+
// Reflection sweep — throttled to ~daily. Notifies only on NEW
|
|
103
|
+
// high-severity proposals; the persisted store dedupes, so this is NOT
|
|
104
|
+
// gated on `primed` (a brand-new finding should alert even on connect,
|
|
105
|
+
// while an already-seen one never re-fires regardless of connection).
|
|
106
|
+
const now = Date.now();
|
|
107
|
+
if (now - (lastSweep.get(p.slug) ?? 0) >= SWEEP_MS) {
|
|
108
|
+
lastSweep.set(p.slug, now);
|
|
109
|
+
try {
|
|
110
|
+
const res = cg.reflectSweep();
|
|
111
|
+
for (const prop of res.notify) {
|
|
112
|
+
send({ kind: 'reflect', project: p.slug, projectPath: p.path, id: prop.contentHash, title: prop.title, detail: prop.evidence.detail });
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
catch { /* ignore — a sweep failure must not break the stream */ }
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
primed = true;
|
|
119
|
+
};
|
|
120
|
+
await poll(); // prime: seed seen-state without emitting
|
|
121
|
+
const pollTimer = setInterval(() => { void poll(); }, POLL_MS);
|
|
122
|
+
const kaTimer = setInterval(() => { if (!closed) {
|
|
123
|
+
try {
|
|
124
|
+
reply.raw.write(': ka\n\n');
|
|
125
|
+
}
|
|
126
|
+
catch { /* noop */ }
|
|
127
|
+
} }, KEEPALIVE_MS);
|
|
128
|
+
req.raw.on('close', () => {
|
|
129
|
+
closed = true;
|
|
130
|
+
clearInterval(pollTimer);
|
|
131
|
+
clearInterval(kaTimer);
|
|
132
|
+
});
|
|
133
|
+
});
|
|
134
|
+
}
|
|
@@ -18,7 +18,7 @@ import path from 'node:path';
|
|
|
18
18
|
import { decodeProjectSlug } from '../ingest/ingestor.js';
|
|
19
19
|
const projectsBus = new EventEmitter();
|
|
20
20
|
projectsBus.setMaxListeners(0); // many SSE subscribers + internal
|
|
21
|
-
async function enumerate(claudeRoot) {
|
|
21
|
+
export async function enumerate(claudeRoot) {
|
|
22
22
|
let entries;
|
|
23
23
|
try {
|
|
24
24
|
entries = await fs.readdir(claudeRoot, { withFileTypes: true });
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Reflection engine HTTP surface (REFLECT-DOC).
|
|
3
|
+
*
|
|
4
|
+
* GET /api/reflect — list persisted proposals (?state=open|applied|undone|dismissed)
|
|
5
|
+
* POST /api/reflect/analyze — run a reflection pass, persist, return open proposals
|
|
6
|
+
* GET /api/reflect/:hash/preview — non-mutating diff of the change a proposal would make
|
|
7
|
+
* POST /api/reflect/:hash/apply — preview-confirmed write (idempotent + reversible)
|
|
8
|
+
* POST /api/reflect/:hash/undo — reverse a previously applied proposal
|
|
9
|
+
* POST /api/reflect/:hash/dismiss — hide a proposal from future sweeps
|
|
10
|
+
*
|
|
11
|
+
* Like the tips engine, reflection reads the cross-project claude_* tables that
|
|
12
|
+
* live in the boot-time "primary" project's DB, so every handler resolves the
|
|
13
|
+
* primary instance and drives it through its `reflect*` methods. These are
|
|
14
|
+
* instance methods on the dynamically-loaded SpecShip — NOT a runtime package
|
|
15
|
+
* import — so the route never trips the stale-build hazard.
|
|
16
|
+
*/
|
|
17
|
+
export async function registerReflectRoutes(app) {
|
|
18
|
+
function requirePrimary(reply) {
|
|
19
|
+
if (!app.primaryCg) {
|
|
20
|
+
reply.code(409).send({ error: 'reflection unavailable: no primary project configured', code: 'no_primary' });
|
|
21
|
+
return null;
|
|
22
|
+
}
|
|
23
|
+
return app.primaryCg;
|
|
24
|
+
}
|
|
25
|
+
// List persisted proposals, optionally filtered by state.
|
|
26
|
+
app.get('/api/reflect', async (req, reply) => {
|
|
27
|
+
const cg = requirePrimary(reply);
|
|
28
|
+
if (!cg)
|
|
29
|
+
return;
|
|
30
|
+
const state = req.query.state;
|
|
31
|
+
return { proposals: cg.reflectList(state) };
|
|
32
|
+
});
|
|
33
|
+
// Run a reflection pass: mine + persist + return the current open proposals.
|
|
34
|
+
app.post('/api/reflect/analyze', async (_req, reply) => {
|
|
35
|
+
const cg = requirePrimary(reply);
|
|
36
|
+
if (!cg)
|
|
37
|
+
return;
|
|
38
|
+
const result = cg.reflectAnalyze();
|
|
39
|
+
return { open: result.open, empty: result.empty };
|
|
40
|
+
});
|
|
41
|
+
// Non-mutating preview of a proposal's change (REQ-REFLECT-003).
|
|
42
|
+
app.get('/api/reflect/:hash/preview', async (req, reply) => {
|
|
43
|
+
const cg = requirePrimary(reply);
|
|
44
|
+
if (!cg)
|
|
45
|
+
return;
|
|
46
|
+
const preview = cg.reflectPreview(req.params.hash);
|
|
47
|
+
if (!preview) {
|
|
48
|
+
reply.code(404).send({ error: 'proposal not found', code: 'not_found' });
|
|
49
|
+
return;
|
|
50
|
+
}
|
|
51
|
+
return preview;
|
|
52
|
+
});
|
|
53
|
+
// Apply a proposal — preview-confirmed write (REQ-REFLECT-004).
|
|
54
|
+
app.post('/api/reflect/:hash/apply', async (req, reply) => {
|
|
55
|
+
const cg = requirePrimary(reply);
|
|
56
|
+
if (!cg)
|
|
57
|
+
return;
|
|
58
|
+
const outcome = cg.reflectApply(req.params.hash);
|
|
59
|
+
if (outcome === null) {
|
|
60
|
+
reply.code(404).send({ error: 'proposal not found', code: 'not_found' });
|
|
61
|
+
return;
|
|
62
|
+
}
|
|
63
|
+
if (outcome === 'conflict') {
|
|
64
|
+
reply.code(409).send({ error: 'a non-SpecShip file already occupies the target path', code: 'conflict' });
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
return { outcome, proposal: cg.reflectGet(req.params.hash) };
|
|
68
|
+
});
|
|
69
|
+
// Undo a previously applied proposal (REQ-REFLECT-004.A3).
|
|
70
|
+
app.post('/api/reflect/:hash/undo', async (req, reply) => {
|
|
71
|
+
const cg = requirePrimary(reply);
|
|
72
|
+
if (!cg)
|
|
73
|
+
return;
|
|
74
|
+
const outcome = cg.reflectUndo(req.params.hash);
|
|
75
|
+
if (outcome === null) {
|
|
76
|
+
reply.code(404).send({ error: 'proposal not found', code: 'not_found' });
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
return { outcome, proposal: cg.reflectGet(req.params.hash) };
|
|
80
|
+
});
|
|
81
|
+
// Dismiss a proposal so it does not resurface on later sweeps (REQ-REFLECT-007.A2).
|
|
82
|
+
app.post('/api/reflect/:hash/dismiss', async (req, reply) => {
|
|
83
|
+
const cg = requirePrimary(reply);
|
|
84
|
+
if (!cg)
|
|
85
|
+
return;
|
|
86
|
+
const ok = cg.reflectDismiss(req.params.hash);
|
|
87
|
+
if (!ok) {
|
|
88
|
+
reply.code(404).send({ error: 'proposal not found', code: 'not_found' });
|
|
89
|
+
return;
|
|
90
|
+
}
|
|
91
|
+
return { ok: true, proposal: cg.reflectGet(req.params.hash) };
|
|
92
|
+
});
|
|
93
|
+
}
|
package/dist/server/server.js
CHANGED
|
@@ -27,6 +27,8 @@ import { registerClaudeRoutes } from './routes/claude.js';
|
|
|
27
27
|
import { registerStatusRoutes } from './routes/status.js';
|
|
28
28
|
import { registerMemoryRoutes } from './routes/memory.js';
|
|
29
29
|
import { registerProjectsRoutes } from './routes/projects.js';
|
|
30
|
+
import { registerEventsRoutes } from './routes/events.js';
|
|
31
|
+
import { registerReflectRoutes } from './routes/reflect.js';
|
|
30
32
|
/**
|
|
31
33
|
* Lazy-import the specship core. Two delivery shapes are supported:
|
|
32
34
|
*
|
|
@@ -164,6 +166,8 @@ export async function createServer(options) {
|
|
|
164
166
|
await registerClaudeRoutes(app);
|
|
165
167
|
await registerMemoryRoutes(app);
|
|
166
168
|
await registerProjectsRoutes(app);
|
|
169
|
+
await registerEventsRoutes(app);
|
|
170
|
+
await registerReflectRoutes(app);
|
|
167
171
|
// Optional: serve the built Angular UI from `webDir` and fall back to
|
|
168
172
|
// index.html for client-side routes. Must register AFTER the /api/*
|
|
169
173
|
// routes so they take precedence over the SPA wildcard.
|
package/dist/types.d.ts
CHANGED
|
@@ -540,7 +540,7 @@ export type WorkflowNodeState = 'pending' | 'running' | 'completed' | 'failed' |
|
|
|
540
540
|
/**
|
|
541
541
|
* Event types emitted by the workflow executor.
|
|
542
542
|
*/
|
|
543
|
-
export type WorkflowEventType = 'step_started' | 'step_completed' | 'step_failed' | 'step_skipped' | 'tool_called' | 'artifact_created' | 'approval_requested' | 'approval_granted' | 'approval_rejected' | 'run_started' | 'run_completed' | 'run_failed' | 'run_cancelled' | 'run_paused';
|
|
543
|
+
export type WorkflowEventType = 'step_started' | 'step_completed' | 'step_failed' | 'step_skipped' | 'tool_called' | 'agent_message' | 'artifact_created' | 'approval_requested' | 'approval_granted' | 'approval_rejected' | 'run_started' | 'run_completed' | 'run_failed' | 'run_cancelled' | 'run_paused';
|
|
544
544
|
/**
|
|
545
545
|
* A workflow run record (one invocation of a workflow definition).
|
|
546
546
|
*/
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAMH;;;;;;GAMG;AACH,eAAO,MAAM,UAAU,sQA4Bb,CAAC;AAEX,MAAM,MAAM,QAAQ,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC;AAEnD;;GAEG;AACH,MAAM,MAAM,QAAQ,GAChB,UAAU,GACV,OAAO,GACP,SAAS,GACT,SAAS,GACT,SAAS,GACT,YAAY,GACZ,YAAY,GACZ,SAAS,GACT,SAAS,GACT,cAAc,GACd,WAAW,GACX,WAAW,GACX,WAAW,GACX,WAAW,CAAC;AAEhB;;;GAGG;AACH,eAAO,MAAM,SAAS,0QA8BZ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;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,QAAQ,GAAG,WAAW,CAAC;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CACpC;AAED;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,UAAU,GAAG,kBAAkB,CAAC;IACtC,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,QAAQ,CAAC,EAAE;QAAE,MAAM,EAAE,MAAM,CAAC;QAAC,WAAW,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACpD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{b as B}from"./chunk-HZA6NEAB.js";import{a as A,c as j}from"./chunk-SHPTC4RL.js";import{a as W}from"./chunk-7RNS77UP.js";import{a as V}from"./chunk-E44X4RH2.js";import{Aa as p,Ga as P,I as w,Ia as b,Ka as c,M as y,N as C,O,P as I,R as z,Ta as R,Ua as E,Va as l,W as _,Wa as x,Xa as T,ea as o,ka as $,lb as h,qa as D,ra as u,sa as m,va as M,wa as S,xa as g,ya as s,za as a,zb as F}from"./chunk-PDN6QYGJ.js";import"./chunk-Q7L6LLAK.js";var H=(i,t)=>t.from+t.to,N=(i,t)=>t.id;function q(i,t){if(i&1){let e=P();s(0,"button",24),b("click",function(){y(e);let r=c(2);return C(r.cancel())}),p(1,"app-icon",25),l(2," Cancel "),a()}if(i&2){let e=c(2);g("disabled",e.actionPending()!==null),o(),g("size",12)}}function Q(i,t){if(i&1&&(s(0,"span",17),l(1),a(),s(2,"span",18),l(3),a(),p(4,"app-state-pill",19)(5,"span",20),s(6,"span",21),p(7,"app-icon",22),l(8),a(),u(9,q,3,2,"button",23)),i&2){let e=t,n=c();o(),x(e.workflowName),o(2),x(e.id.slice(0,8)),o(),g("state",e.status)("pulse",e.status==="running"),o(3),g("size",11),o(),T(" ",n.fmtDuration(e.startedAt,e.completedAt)," "),o(),m(e.status==="running"||e.status==="paused"?9:-1)}}function U(i,t){i&1&&(s(0,"span",26),l(1,"Loading\u2026"),a(),p(2,"span",20))}function J(i,t){if(i&1&&(s(0,"span",27),l(1),a(),p(2,"span",20)),i&2){let e=c();o(),x(e.error())}}function K(i,t){if(i&1&&(s(0,"div",4),l(1),a()),i&2){let e=c();o(),T("Action failed: ",e.actionError())}}function X(i,t){i&1&&(s(0,"div",4),l(1),a()),i&2&&(o(),x(t))}function Y(i,t){if(i&1){let e=P();s(0,"div",5)(1,"span",28),p(2,"app-icon",29),a(),s(3,"div",20)(4,"div",30),l(5,"Approval required \u2014 review diff before merge"),a(),s(6,"div",31),l(7," Review the artifacts carefully before approving. "),a()(),s(8,"button",32),b("click",function(){y(e);let r=c();return C(r.activeTab.set("artifacts"))}),l(9," Inspect artifacts "),a(),s(10,"button",24),b("click",function(){y(e);let r=c();return C(r.reject())}),l(11," Reject "),a(),s(12,"button",33),b("click",function(){y(e);let r=c();return C(r.approve())}),p(13,"app-icon",34),l(14," Approve "),a()()}if(i&2){let e=c();o(2),g("size",18),o(8),g("disabled",e.actionPending()!==null),o(2),g("disabled",e.actionPending()!==null),o(),g("size",13)}}function Z(i,t){if(i&1&&(O(),p(0,"path",35)),i&2){let e=c(),n=c(2);D("d",n.edgePath(e,t))("stroke",e.status==="completed"?"var(--success)":"rgba(150,160,180,0.4)")("opacity",e.status==="completed"?"0.7":"0.5")}}function ee(i,t){if(i&1&&u(0,Z,1,3,":svg:path",35),i&2){let e,n=c().$implicit,r=c();m((e=r.nodeMap()[n.to])?0:-1,e)}}function te(i,t){if(i&1&&u(0,ee,1,1),i&2){let e,n=t.$implicit,r=c();m((e=r.nodeMap()[n.from])?0:-1,e)}}function ne(i,t){i&1&&p(0,"app-icon",38),i&2&&g("size",11)}function ie(i,t){i&1&&p(0,"app-icon",39),i&2&&g("size",11)}function re(i,t){i&1&&p(0,"app-icon",40),i&2&&g("size",10)}function oe(i,t){if(i&1){let e=P();s(0,"div",36),b("click",function(){let r=y(e).$implicit,d=c();return C(d.selectedNode.set(r.id))}),s(1,"span",37),u(2,ne,1,1,"app-icon",38)(3,ie,1,1,"app-icon",39)(4,re,1,1,"app-icon",40),a(),s(5,"div",41)(6,"div",42),l(7),a(),s(8,"div",43),l(9),a()()()}if(i&2){let e=t.$implicit,n=c();R("left",e.x/n.DAG_W*100,"%")("top",e.y,"px")("border-color",n.nodeBorderColor(e))("box-shadow",n.nodeBoxShadow(e)),E("rd-node-running",e.status==="running")("rd-node-selected",n.selectedNode()===e.id)("rd-node-pending",e.status==="pending")("rd-node-skipped",e.status==="skipped"),D("aria-label",e.id),o(),R("background",n.nodeDotBg(e))("border",n.nodeDotBorder(e)),E("rd-dot-spin",e.status==="running"),o(),m(e.status==="completed"?2:e.status==="failed"?3:e.status==="paused"?4:-1),o(5),x(e.label),o(2),x(e.kind)}}function ae(i,t){i&1&&(s(0,"span",45),l(1,"live"),a())}function se(i,t){if(i&1){let e=P();s(0,"button",44),b("click",function(){let r=y(e).$implicit,d=c();return C(d.activeTab.set(r.id))}),l(1),u(2,ae,2,0,"span",45),a()}if(i&2){let e=t.$implicit,n=c();E("rd-tab-active",n.activeTab()===e.id),o(),T(" ",e.label," "),o(),m(e.id==="events"&&n.streamStatus()==="live"?2:-1)}}function de(i,t){if(i&1&&(s(0,"div",46)(1,"span",48),l(2),a(),s(3,"span",49),l(4),a(),s(5,"span",50),l(6),a(),s(7,"span",51),l(8),a()()),i&2){let e=t.$implicit,n=c(2);D("data-event-type",e.eventType),o(2),x(n.fmtTime(e.createdAt)),o(),R("color",n.evColor(e.eventType)),o(),x(e.eventType),o(2),x(n.stepIdOf(e)),o(2),x(n.eventDetail(e))}}function le(i,t){i&1&&(s(0,"div",47),p(1,"span",52),l(2," streaming\u2026 "),a())}function ce(i,t){if(i&1&&(s(0,"div",14),M(1,de,9,7,"div",46,N),u(3,le,3,0,"div",47),a()),i&2){let e=c();o(),S(e.events()),o(2),m(e.streamStatus()==="live"||e.streamStatus()==="connecting"?3:-1)}}function pe(i,t){i&1&&(s(0,"div",15)(1,"div",53),l(2," No artifacts available from the API. "),a()())}function ue(i,t){i&1&&(s(0,"div",16)(1,"div",54),l(2,"Cost data is not available from the API."),a()())}var me={step_started:"var(--info)",step_completed:"var(--success)",tool_called:"var(--node-code)",agent_message:"var(--node-spec)",artifact_created:"var(--node-route)",approval_requested:"var(--warn)",run_started:"var(--info)",run_completed:"var(--success)",run_failed:"var(--error)",run_cancelled:"var(--text-muted)",run_paused:"var(--warn)"},G=class i{api=w(V);projects=w(W);route=w(A);router=w(j);destroyRef=w(z);runId=_("");run=_(null);events=_([]);loading=_(!0);error=_(null);streamStatus=_("connecting");actionPending=_(null);actionError=_(null);closeStream=null;status=h(()=>this.run()?.status??null);isTerminal=h(()=>{let t=this.status();return t==="completed"||t==="failed"||t==="cancelled"});approvalPending=h(()=>[...this.events()].reverse().find(e=>e.eventType==="approval_requested"||e.eventType==="approval_granted"||e.eventType==="approval_rejected")?.eventType==="approval_requested");TABS=[{id:"events",label:"Events"},{id:"artifacts",label:"Artifacts"},{id:"cost",label:"Cost"}];activeTab=_("events");DAG_W=920;DAG_H=180;dagNodes=h(()=>{let t=this.run(),e=this.stepStatusMap(),n=t?.metadata?.nodes;if(n?.length){let f=this.layoutCols(n.map(v=>v.id));return n.map((v,k)=>{let L=f[k]??k;return{id:v.id,label:v.id,kind:v.kind??"agent",status:e[v.id]??"pending",x:L*160+20,y:72}})}let r=[...new Set(this.events().map(f=>f.data?.stepId??f.stepId??"").filter(Boolean))];if(!r.length)return[];let d=Math.min(160,(this.DAG_W-40)/Math.max(r.length,1));return r.map((f,v)=>({id:f,label:f,kind:this.events().find(k=>(k.data?.stepId??k.stepId)===f)?.stepKind??"step",status:e[f]??"pending",x:v*d+20,y:72}))});dagEdges=h(()=>{let e=this.run()?.metadata?.edges;if(e?.length)return e;let n=this.dagNodes();return n.slice(0,-1).map((r,d)=>({from:r.id,to:n[d+1].id}))});nodeMap=h(()=>{let t={};for(let e of this.dagNodes())t[e.id]=e;return t});selectedNode=_("");stepStatusMap=h(()=>{let t={};for(let e of this.events()){let n=e.data?.stepId??e.stepId??"";if(n)switch(e.eventType){case"step_started":t[n]="running";break;case"step_completed":t[n]="completed";break;case"step_failed":t[n]="failed";break;case"step_skipped":t[n]="skipped";break}}if(this.status()==="paused")for(let e of Object.keys(t))t[e]==="running"&&(t[e]="paused");return t});ngOnInit(){let t=this.route.snapshot.paramMap.get("id")??"";if(!t){this.error.set("No run id"),this.loading.set(!1);return}this.runId.set(t),this.bootstrap(t)}ngOnDestroy(){this.closeStream?.(),this.closeStream=null}async bootstrap(t){try{let e=await this.api.get(`/api/workflows/runs/${encodeURIComponent(t)}${this.projects.projectQuery()}`);this.run.set(e.run),this.events.set(e.events??[]),this.loading.set(!1),this.isTerminal()?this.streamStatus.set("closed"):this.openStream(t)}catch(e){this.error.set(e instanceof Error?e.message:String(e)),this.loading.set(!1)}}openStream(t){this.streamStatus.set("connecting");let e=this.api.openEventStream(`/api/workflows/runs/${encodeURIComponent(t)}/events${this.projects.projectQuery()}`,(n,r)=>{if(n==="done"){this.streamStatus.set("closed"),this.refreshRun();return}let d=r;!d||typeof d!="object"||d.id==null||(this.streamStatus.set("live"),this.appendEvent(d),n.startsWith("run_")&&this.refreshRun())},()=>{this.streamStatus.set("error")});this.closeStream=e,this.destroyRef.onDestroy(()=>e())}appendEvent(t){this.events.update(e=>{if(e.some(r=>r.id===t.id))return e;let n=[...e,t];return n.sort((r,d)=>r.id-d.id),n})}async refreshRun(){try{let t=this.runId();if(!t)return;let e=await this.api.get(`/api/workflows/runs/${encodeURIComponent(t)}${this.projects.projectQuery()}`);this.run.set(e.run)}catch{}}async approve(){await this.action("approve")}async reject(){let t=prompt("Reason for rejecting?")??void 0;await this.action("reject",t?{reason:t}:void 0)}async cancel(){confirm("Cancel this run?")&&await this.action("cancel")}async resume(){await this.action("resume")}async action(t,e){this.actionPending.set(t),this.actionError.set(null);try{await this.api.post(`/api/workflows/runs/${encodeURIComponent(this.runId())}/${t}${this.projects.projectQuery()}`,e??{}),await this.refreshRun(),(t==="resume"||t==="approve")&&!this.isTerminal()&&!this.closeStream&&this.openStream(this.runId())}catch(n){this.actionError.set(n instanceof Error?n.message:String(n))}finally{this.actionPending.set(null)}}fmtTime(t){return t?new Date(t).toLocaleTimeString():"\u2014"}fmtDuration(t,e){if(!t)return"\u2014";let r=(e??Date.now())-t;return r>=6e4?Math.round(r/6e4)+"m "+Math.round(r%6e4/1e3)+"s":r>=1e3?(r/1e3).toFixed(1)+"s":r+"ms"}eventDetail(t){let e=t.data;if(!e)return"";let n=d=>d.length>200?d.slice(0,200)+"\u2026":d;if(typeof e.error=="string")return e.error;if(typeof e.text=="string")return n(e.text);if(typeof e.name=="string"){let d=typeof e.input=="string"?e.input:"";return n(d?`${e.name} ${d}`:e.name)}let r=e.output;if(typeof r=="string")return n(r);if(r!=null)try{return n(JSON.stringify(r))}catch{return""}return""}stepIdOf(t){return t.data?.stepId??t.stepId??""}evColor(t){return me[t]??"var(--text-secondary)"}back(){this.router.navigate(["/runs"])}edgePath(t,e){let n=t.x+150,r=t.y+18,d=e.x,f=e.y+18,v=(n+d)/2;return`M ${n} ${r} C ${v} ${r}, ${v} ${f}, ${d} ${f}`}nodeBorderColor(t){return this.selectedNode()===t.id?"var(--accent)":t.status==="pending"||t.status==="skipped"?"var(--border-subtle)":{running:"var(--info)",completed:"var(--success)",failed:"var(--error)",paused:"var(--warn)"}[t.status]??"var(--border-subtle)"}nodeBoxShadow(t){return t.status==="running"?"0 0 0 3px var(--info-soft)":this.selectedNode()===t.id?"0 4px 14px rgba(0,0,0,0.4)":"none"}nodeDotBg(t){return t.status==="completed"?"var(--success)":t.status==="failed"?"var(--error)":t.status==="paused"?"var(--warn)":"transparent"}nodeDotBorder(t){return t.status==="pending"||t.status==="running"||t.status==="skipped"?`1.5px solid ${{pending:"var(--text-muted)",running:"var(--info)",skipped:"var(--text-muted)"}[t.status]}`:"none"}layoutCols(t){return t.map((e,n)=>n)}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=$({type:i,selectors:[["app-run-detail"]],decls:27,vars:10,consts:[[1,"col","rd-root"],[1,"row","gap-10","rd-head"],["type","button",1,"btn","btn-ghost","btn-sm",3,"click"],["name","chevronLeft",3,"size"],[1,"rd-banner","rd-banner-error"],[1,"row","gap-12","rd-approval"],[1,"rd-dag"],["width","100%",1,"rd-dag-svg"],["id","rarrow","viewBox","0 0 10 10","refX","8","refY","5","markerWidth","6","markerHeight","6","orient","auto-start-reverse"],["d","M0 0 L10 5 L0 10 z","fill","rgba(160,170,190,0.6)"],["role","button",1,"rd-node",3,"rd-node-running","rd-node-selected","rd-node-pending","rd-node-skipped","left","top","border-color","box-shadow"],[1,"col","rd-panel"],[1,"row","gap-2","rd-tabs"],["type","button",1,"rd-tab",3,"rd-tab-active"],["aria-live","polite",1,"scroll-y","rd-events"],[1,"rd-artifacts","row"],[1,"rd-cost-wrap",2,"padding","16px"],[1,"mono","rd-wf-name"],[1,"mono","muted",2,"font-size","11.5px"],[3,"state","pulse"],[1,"grow"],[1,"mono","muted","row","gap-4",2,"font-size","11.5px"],["name","clock",3,"size"],["type","button",1,"btn","btn-destructive","btn-sm",3,"disabled"],["type","button",1,"btn","btn-destructive","btn-sm",3,"click","disabled"],["name","cancel",3,"size"],[1,"muted",2,"font-size","12px"],[1,"rd-error"],[2,"color","var(--warn)","flex-shrink","0"],["name","pause",3,"size"],[2,"font-weight","600","font-size","13px"],[1,"secondary",2,"font-size","12px","margin-top","1px"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click"],["type","button",1,"btn","btn-primary","btn-sm",3,"click","disabled"],["name","check",3,"size"],["fill","none","stroke-width","1.6","marker-end","url(#rarrow)"],["role","button",1,"rd-node",3,"click"],[1,"rd-node-dot"],["name","check",2,"color","#fff",3,"size"],["name","x",2,"color","#fff",3,"size"],["name","pause",2,"color","#fff",3,"size"],[1,"grow",2,"min-width","0"],[1,"rd-node-label"],[1,"mono","muted","rd-node-type"],["type","button",1,"rd-tab",3,"click"],[1,"pill","rd-live-pill"],[1,"row","gap-10","rd-event-row"],[1,"row","gap-6","muted",2,"padding","6px 0"],[1,"muted","tabular","rd-event-time"],[1,"rd-event-kind"],[1,"muted","rd-event-node"],[1,"secondary","rd-event-text"],[1,"rd-stream-dot"],[1,"muted","rd-no-artifacts",2,"margin","auto","font-size","12.5px"],[1,"muted",2,"font-size","12.5px"]],template:function(e,n){if(e&1&&(s(0,"div",0)(1,"div",1)(2,"button",2),b("click",function(){return n.back()}),p(3,"app-icon",3),l(4," Runs "),a(),u(5,Q,10,7)(6,U,3,0)(7,J,3,1),a(),u(8,K,2,1,"div",4),u(9,X,2,1,"div",4),u(10,Y,15,4,"div",5),s(11,"div",6),O(),s(12,"svg",7)(13,"defs")(14,"marker",8),p(15,"path",9),a()(),M(16,te,1,1,null,null,H),a(),M(18,oe,10,26,"div",10,N),a(),I(),s(20,"div",11)(21,"div",12),M(22,se,3,4,"button",13,N),a(),u(24,ce,4,1,"div",14),u(25,pe,3,0,"div",15),u(26,ue,3,0,"div",16),a()()),e&2){let r,d;o(3),g("size",14),o(2),m((r=n.run())?5:n.loading()?6:n.error()?7:-1,r),o(3),m(n.actionError()?8:-1),o(),m((d=(d=n.run())==null?null:d.errorMessage)?9:-1,d),o(),m(n.approvalPending()?10:-1),o(2),D("height",n.DAG_H)("viewBox","0 0 "+n.DAG_W+" "+n.DAG_H),o(4),S(n.dagEdges()),o(2),S(n.dagNodes()),o(4),S(n.TABS),o(2),m(n.activeTab()==="events"?24:-1),o(),m(n.activeTab()==="artifacts"?25:-1),o(),m(n.activeTab()==="cost"?26:-1)}},dependencies:[B,F],styles:["[_nghost-%COMP%]{display:contents}.rd-root[_ngcontent-%COMP%]{flex:1;min-height:0}.rd-head[_ngcontent-%COMP%]{padding:12px 16px;border-bottom:1px solid var(--border-subtle);flex-shrink:0}.rd-wf-name[_ngcontent-%COMP%]{font-weight:600;font-size:14px}.rd-error[_ngcontent-%COMP%]{color:var(--error);font-size:12px}.rd-banner[_ngcontent-%COMP%]{padding:10px 16px;font-size:12.5px;flex-shrink:0}.rd-banner-error[_ngcontent-%COMP%]{background:var(--error-soft);color:var(--error);border-bottom:1px solid color-mix(in srgb,var(--error) 30%,transparent)}.rd-approval[_ngcontent-%COMP%]{padding:12px 16px;background:var(--warn-soft);border-bottom:1px solid rgba(229,165,10,.3);flex-shrink:0}.rd-dag[_ngcontent-%COMP%]{position:relative;height:180px;background:var(--bg-canvas-2, var(--bg-canvas));background-image:radial-gradient(circle,var(--dot-grid, rgba(255, 255, 255, .07)) 1px,transparent 1px);background-size:20px 20px;border-bottom:1px solid var(--border-subtle);overflow:hidden;flex-shrink:0}.rd-dag-svg[_ngcontent-%COMP%]{position:absolute;inset:0;pointer-events:none}.rd-node[_ngcontent-%COMP%]{position:absolute;width:150px;height:36px;display:flex;align-items:center;gap:8px;padding:0 11px;border-radius:8px;background:var(--bg-panel);border:1.5px solid var(--border-subtle);cursor:pointer;transition:border-color .12s,box-shadow .12s}.rd-node[_ngcontent-%COMP%]:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.rd-node-running[_ngcontent-%COMP%]{background:var(--info-soft)}.rd-node-pending[_ngcontent-%COMP%]{opacity:.6}.rd-node-skipped[_ngcontent-%COMP%]{border-style:dotted}.rd-node-dot[_ngcontent-%COMP%]{width:18px;height:18px;border-radius:50%;display:grid;place-items:center;flex-shrink:0}.rd-dot-spin[_ngcontent-%COMP%]{animation:_ngcontent-%COMP%_rd-spin 1.4s linear infinite;border-top-color:transparent!important}@keyframes _ngcontent-%COMP%_rd-spin{to{transform:rotate(360deg)}}.rd-node-label[_ngcontent-%COMP%]{font-size:12px;font-weight:500;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rd-node-type[_ngcontent-%COMP%]{font-size:9px}.rd-panel[_ngcontent-%COMP%]{flex:1;min-height:0}.rd-tabs[_ngcontent-%COMP%]{padding:8px 14px 0;border-bottom:1px solid var(--border-subtle);flex-shrink:0}.rd-tab[_ngcontent-%COMP%]{padding:7px 13px;border:none;background:transparent;cursor:pointer;font-size:12.5px;font-weight:500;font-family:var(--font-ui);text-transform:capitalize;color:var(--text-muted);border-bottom:2px solid transparent;margin-bottom:-1px;display:inline-flex;align-items:center;gap:6px;transition:color .1s}.rd-tab[_ngcontent-%COMP%]:hover{color:var(--text-secondary)}.rd-tab-active[_ngcontent-%COMP%]{color:var(--text-primary);border-bottom-color:var(--accent)}.rd-live-pill[_ngcontent-%COMP%]{font-size:9px;background:var(--info-soft);color:var(--info)}.rd-events[_ngcontent-%COMP%]{flex:1;padding:8px 14px;font-family:var(--font-mono);font-size:11.5px;min-height:0}.rd-event-row[_ngcontent-%COMP%]{padding:4px 0;border-bottom:1px solid rgba(255,255,255,.03)}.rd-event-time[_ngcontent-%COMP%]{flex-shrink:0;width:80px;font-size:11px}.rd-event-kind[_ngcontent-%COMP%]{width:132px;flex-shrink:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.rd-event-node[_ngcontent-%COMP%]{flex-shrink:0;width:80px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:11px}.rd-event-text[_ngcontent-%COMP%]{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1}.rd-stream-dot[_ngcontent-%COMP%]{width:6px;height:6px;border-radius:50%;background:var(--info);animation:_ngcontent-%COMP%_rd-pulse 1s infinite}@keyframes _ngcontent-%COMP%_rd-pulse{0%,to{opacity:1}50%{opacity:.3}}.rd-artifacts[_ngcontent-%COMP%]{flex:1;min-height:0}.rd-no-artifacts[_ngcontent-%COMP%]{padding:40px;text-align:center}"],changeDetection:0})};export{G as RunDetail};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as V}from"./chunk-X2HTISHL.js";import{a as A}from"./chunk-UYC52MBC.js";import{c as F}from"./chunk-GR72OOCN.js";import"./chunk-7RNS77UP.js";import{a as $}from"./chunk-E44X4RH2.js";import{Aa as f,Ea as z,Fa as R,Ga as w,I as S,Ia as y,Ka as p,M as b,N as C,Ta as T,Va as l,W as x,Wa as m,Xa as _,bb as H,ea as o,ka as O,lb as I,qa as k,ra as v,sa as u,ua as E,va as P,wa as M,xa as d,ya as a,za as r,zb as D}from"./chunk-PDN6QYGJ.js";import{a as g,b as h}from"./chunk-Q7L6LLAK.js";var B=()=>[0,1,2],L=(i,e)=>e.contentHash;function j(i,e){if(i&1&&(a(0,"div",6),l(1),r()),i&2){let t=p();o(),m(t.errorMsg())}}function U(i,e){i&1&&f(0,"div",9)}function W(i,e){i&1&&P(0,U,1,0,"div",9,E),i&2&&M(H(0,B))}function q(i,e){i&1&&(a(0,"div",7),f(1,"app-icon",5),a(2,"div",10),l(3,"No proposals yet"),r(),a(4,"div",11),l(5,"Run "),a(6,"strong"),l(7,"Analyze"),r(),l(8," to mine your ingested transcripts for recurring patterns worth turning into a durable rule, skill, or hook."),r()()),i&2&&(o(),d("size",28))}function G(i,e){if(i&1&&(a(0,"span",19),l(1),r()),i&2){let t=p().$implicit,n=p(2);o(),m(n.outcomeOf(t.contentHash))}}function J(i,e){i&1&&(a(0,"div",30),l(1,"Loading preview\u2026"),r())}function K(i,e){i&1&&(a(0,"div",31),l(1,"A non-SpecShip file already exists at this path \u2014 apply is blocked to avoid clobbering it."),r())}function Q(i,e){if(i&1&&(v(0,K,2,0,"div",31),a(1,"div",24),l(2,"Preview diff"),r(),a(3,"pre",32),l(4),r()),i&2){let t,n,s=p(2).$implicit,c=p(2);u((t=c.previewOf(s.contentHash))!=null&&t.conflict?0:-1),o(4),m((n=c.previewOf(s.contentHash))==null?null:n.diff)}}function X(i,e){if(i&1&&(a(0,"div",26),v(1,J,2,0,"div",30)(2,Q,5,2),r()),i&2){let t=p().$implicit,n=p(2);o(),u(n.previewOf(t.contentHash)===null?1:2)}}function Y(i,e){if(i&1){let t=w();a(0,"span",33),l(1,"applied"),r(),a(2,"button",34),y("click",function(){b(t);let s=p().$implicit,c=p(2);return C(c.undoProposal(s.contentHash))}),l(3,"Undo"),r()}if(i&2){let t=p().$implicit,n=p(2);o(2),d("disabled",n.isBusy(t.contentHash))}}function Z(i,e){if(i&1){let t=w();a(0,"button",34),y("click",function(){b(t);let s=p().$implicit,c=p(2);return C(c.dismissProposal(s.contentHash))}),l(1,"Dismiss"),r(),a(2,"button",4),y("click",function(){b(t);let s=p().$implicit,c=p(2);return C(c.applyProposal(s.contentHash))}),l(3),r()}if(i&2){let t,n=p().$implicit,s=p(2);d("disabled",s.isBusy(n.contentHash)),o(2),d("disabled",s.isBusy(n.contentHash)||((t=s.previewOf(n.contentHash))==null?null:t.conflict)),o(),_(" ",s.isBusy(n.contentHash)?"Applying\u2026":"Apply"," ")}}function ee(i,e){if(i&1){let t=w();a(0,"div",12),f(1,"div",13),a(2,"div",14)(3,"div",15)(4,"div",16)(5,"div",17)(6,"span",18),l(7),r(),a(8,"app-pill",3),l(9),r(),v(10,G,2,1,"span",19),r(),a(11,"div",20),l(12),r()()(),a(13,"div",21),l(14),r(),a(15,"div",22)(16,"div",23)(17,"div",24),l(18,"Evidence"),r(),a(19,"div",25),l(20),r()(),a(21,"div",23)(22,"div",24),l(23,"Writes to"),r(),a(24,"div",25),l(25),r()()(),v(26,X,3,1,"div",26),a(27,"div",27)(28,"button",28),y("click",function(){let s=b(t).$implicit,c=p(2);return C(c.togglePreview(s.contentHash))}),l(29),r(),f(30,"div",29),v(31,Y,4,1)(32,Z,4,3),r()()()}if(i&2){let t=e.$implicit,n=p(2);k("data-sev",t.severity),o(),T("background",n.sevColor(t.severity)),o(6),m(n.typeLabel(t.type)),o(),d("color",n.sevColor(t.severity))("bg","color-mix(in srgb, "+n.sevColor(t.severity)+" 16%, transparent)"),o(),m(t.severity),o(),u(n.outcomeOf(t.contentHash)?10:-1),o(2),m(t.title),o(2),m(t.body),o(6),m(t.evidence.detail),o(5),m(t.targetPath),o(),u(n.previewOf(t.contentHash)!==void 0?26:-1),o(3),_(" ",n.previewOf(t.contentHash)!==void 0?"Hide preview":"Preview"," "),o(2),u(t.state==="applied"?31:32)}}function te(i,e){if(i&1&&(a(0,"div",8),P(1,ee,33,15,"div",12,L),r()),i&2){let t=p();o(),M(t.proposals())}}var N=class i{api=S($);resource=F(this.api,()=>"/api/reflect?state=open");analyzing=x(!1);previews=x({});busy=x(new Set);outcomes=x({});errorMsg=x(null);proposals=I(()=>{let e=this.resource.state().data?.proposals??[],t={high:0,warn:1,info:2};return[...e].sort((n,s)=>(t[n.severity]??9)-(t[s.severity]??9))});counts=I(()=>{let e=this.resource.state().data?.proposals??[];return{high:e.filter(t=>t.severity==="high").length,warn:e.filter(t=>t.severity==="warn").length,info:e.filter(t=>t.severity==="info").length}});typeLabel(e){return e==="memory_rule"?"memory / rule":e==="skill"?"skill":"hook"}sevColor(e){return e==="high"?"var(--error)":e==="warn"?"var(--warn)":"var(--info)"}isBusy(e){return this.busy().has(e)}previewOf(e){return this.previews()[e]}outcomeOf(e){return this.outcomes()[e]}async analyze(){this.analyzing.set(!0),this.errorMsg.set(null);try{await this.api.post("/api/reflect/analyze",{}),this.resource.refetch()}catch(e){this.errorMsg.set(this.msg(e))}finally{this.analyzing.set(!1)}}async togglePreview(e){let t=this.previews();if(e in t){let n=g({},t);delete n[e],this.previews.set(n);return}this.previews.set(h(g({},t),{[e]:null}));try{let n=await this.api.get(`/api/reflect/${e}/preview`);this.previews.set(h(g({},this.previews()),{[e]:n}))}catch(n){this.errorMsg.set(this.msg(n));let s=g({},this.previews());delete s[e],this.previews.set(s)}}applyProposal(e){return this.mutate(e,`/api/reflect/${e}/apply`,"apply")}undoProposal(e){return this.mutate(e,`/api/reflect/${e}/undo`,"undo")}dismissProposal(e){return this.mutate(e,`/api/reflect/${e}/dismiss`,"dismiss")}async mutate(e,t,n){this.setBusy(e,!0),this.errorMsg.set(null);try{let s=await this.api.post(t,{}),c=s.outcome??(s.ok?"dismissed":"done");this.outcomes.set(h(g({},this.outcomes()),{[e]:c})),this.resource.refetch()}catch(s){this.errorMsg.set(`${n} failed: ${this.msg(s)}`)}finally{this.setBusy(e,!1)}}setBusy(e,t){this.busy.update(n=>{let s=new Set(n);return t?s.add(e):s.delete(e),s})}msg(e){return e instanceof Error?e.message:String(e)}static \u0275fac=function(t){return new(t||i)};static \u0275cmp=O({type:i,selectors:[["app-improvements"]],decls:16,vars:14,consts:[[1,"page","scroll-y"],["icon","sparkles","title","Improvements","sub","Durable fixes mined from your transcripts \u2014 preview, then apply"],["actions",""],[3,"color","bg"],["type","button",1,"btn","btn-primary","btn-sm",3,"click","disabled"],["name","sparkles",3,"size"],[1,"banner-error"],[1,"empty"],[1,"prop-list"],[1,"skel","card-skel"],[1,"empty-title"],[1,"empty-sub"],[1,"prop-card","card"],[1,"sev-bar"],[1,"prop-body"],[1,"row","gap-10","head-row"],[1,"grow",2,"min-width","0"],[1,"row","gap-6","chips"],[1,"type-chip"],[1,"outcome"],[1,"prop-title"],[1,"prop-why"],[1,"prop-meta"],[1,"kv-block"],[1,"eyebrow"],[1,"mono","secondary","detail"],[1,"preview"],[1,"actions"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click"],[1,"grow"],[1,"muted"],[1,"banner-error","small"],[1,"diff","mono"],[1,"applied-tag"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click","disabled"]],template:function(t,n){t&1&&(a(0,"div",0)(1,"app-page-head",1),z(2,2),a(3,"app-pill",3),l(4),r(),a(5,"app-pill",3),l(6),r(),a(7,"app-pill",3),l(8),r(),a(9,"button",4),y("click",function(){return n.analyze()}),f(10,"app-icon",5),l(11),r(),R(),r(),v(12,j,2,1,"div",6),v(13,W,2,1)(14,q,9,1,"div",7)(15,te,3,0,"div",8),r()),t&2&&(o(3),d("color","var(--error)")("bg","var(--error-soft)"),o(),_("",n.counts().high," high"),o(),d("color","var(--warn)")("bg","var(--warn-soft)"),o(),_("",n.counts().warn," warn"),o(),d("color","var(--info)")("bg","var(--info-soft)"),o(),_("",n.counts().info," info"),o(),d("disabled",n.analyzing()),o(),d("size",13),o(),_(" ",n.analyzing()?"Analyzing\u2026":"Analyze"," "),o(),u(n.errorMsg()?12:-1),o(),u(n.resource.state().loading?13:n.proposals().length===0?14:15))},dependencies:[A,V,D],styles:[".page[_ngcontent-%COMP%]{padding:20px 24px 48px}.banner-error[_ngcontent-%COMP%]{background:var(--error-soft);color:var(--error);border:1px solid color-mix(in srgb,var(--error) 30%,transparent);border-radius:8px;padding:10px 12px;font-size:12.5px;margin-bottom:14px}.banner-error.small[_ngcontent-%COMP%]{margin:8px 0;padding:8px 10px;font-size:11.5px}.empty[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:center;gap:8px;text-align:center;padding:64px 24px;color:var(--text-muted)}.empty[_ngcontent-%COMP%] .empty-title[_ngcontent-%COMP%]{font-size:15px;font-weight:600;color:var(--text)}.empty[_ngcontent-%COMP%] .empty-sub[_ngcontent-%COMP%]{font-size:12.5px;max-width:460px;line-height:1.5}.card-skel[_ngcontent-%COMP%]{height:132px;border-radius:12px;margin-bottom:12px}.prop-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:12px}.prop-card[_ngcontent-%COMP%]{position:relative;display:flex;overflow:hidden;padding:0}.prop-card[_ngcontent-%COMP%] .sev-bar[_ngcontent-%COMP%]{width:3px;flex:0 0 3px}.prop-card[_ngcontent-%COMP%] .prop-body[_ngcontent-%COMP%]{flex:1;min-width:0;padding:14px 16px}.head-row[_ngcontent-%COMP%]{margin-bottom:8px}.chips[_ngcontent-%COMP%]{margin-bottom:6px}.type-chip[_ngcontent-%COMP%]{font-size:10.5px;text-transform:uppercase;letter-spacing:.04em;font-weight:600;color:var(--text-muted);background:var(--surface-2, color-mix(in srgb, var(--text) 7%, transparent));border-radius:5px;padding:2px 7px}.outcome[_ngcontent-%COMP%]{font-size:10.5px;color:var(--success);font-weight:600;text-transform:lowercase}.prop-title[_ngcontent-%COMP%]{font-size:14px;font-weight:600;color:var(--text);line-height:1.35}.prop-why[_ngcontent-%COMP%]{font-size:12.5px;color:var(--text-secondary, var(--text-muted));line-height:1.5;margin-bottom:10px}.prop-meta[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-bottom:10px}.prop-meta[_ngcontent-%COMP%] .detail[_ngcontent-%COMP%]{font-size:11px;margin-top:2px;word-break:break-all}.preview[_ngcontent-%COMP%]{margin:8px 0 12px}.preview[_ngcontent-%COMP%] .diff[_ngcontent-%COMP%]{background:var(--surface-2, color-mix(in srgb, var(--text) 5%, transparent));border:1px solid var(--border, color-mix(in srgb, var(--text) 12%, transparent));border-radius:8px;padding:10px 12px;font-size:11.5px;line-height:1.5;max-height:280px;overflow:auto;white-space:pre;margin-top:4px}.actions[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;margin-top:4px}.applied-tag[_ngcontent-%COMP%]{font-size:11px;color:var(--success);font-weight:600}"],changeDetection:0})};export{N as Improvements};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import{a as j}from"./chunk-G7VZT5KB.js";import{a as ie}from"./chunk-EMGMOEVR.js";import{a as oe}from"./chunk-X2HTISHL.js";import{a as ne}from"./chunk-R5W2MDZN.js";import{a as ee}from"./chunk-WDU3WICG.js";import{a as q,b as te}from"./chunk-HZA6NEAB.js";import{a as Z,c as N}from"./chunk-GR72OOCN.js";import{c as X}from"./chunk-SHPTC4RL.js";import{a as Y}from"./chunk-7RNS77UP.js";import{a as J}from"./chunk-E44X4RH2.js";import{Aa as s,Ga as M,I as y,Ia as v,Ka as c,M as C,N as b,Oa as B,Pa as U,Qa as K,R as Q,T as P,Ta as V,Ua as $,Va as l,W as x,Wa as m,Xa as h,aa as z,ea as o,ka as k,lb as f,ra as g,sa as u,va as D,wa as I,xa as p,ya as a,yb as L,za as r,zb as E}from"./chunk-PDN6QYGJ.js";import"./chunk-Q7L6LLAK.js";var A=null,ue="self.onmessage = () => {};";function re(){return A||(typeof window<"u"&&!window.MonacoEnvironment&&(window.MonacoEnvironment={getWorker:(n,t)=>{let e=new Blob([ue],{type:"text/javascript"}),i=URL.createObjectURL(e);return new Worker(i,{name:t||"monaco-noop"})}}),A=import("./chunk-FMV5PXRC.js"),A)}var ae=!1;function de(n){ae||(ae=!0,_e(n))}function le(n,t){let e=[],i=t.getValue().split(`
|
|
2
|
+
`),d=null,_=new Map,O=/<!--\s*id\s*:\s*([^\s-][^\s]*)\s*-->/,ge=/^#{1,6}\s+/;for(let S=0;S<i.length;S++){let T=i[S]??"",R=S+1,H=T.match(O);if(H&&H[1]){d!==null&&e.push({severity:n.MarkerSeverity.Warning,message:`Stranded <!-- id: ${d.id} -->: no heading follows on line ${d.line+1}.`,startLineNumber:d.line+1,startColumn:1,endLineNumber:d.line+1,endColumn:(i[d.line]??"").length+1,code:"spec_stranded_id"});let w=H[1];d={id:w,line:S};let G=_.get(w);G!==void 0?e.push({severity:n.MarkerSeverity.Warning,message:`Duplicate spec ID "${w}" \u2014 first seen on line ${G+1}. The second occurrence will be silently lost by the parser.`,startLineNumber:R,startColumn:T.indexOf(w)+1,endLineNumber:R,endColumn:T.indexOf(w)+w.length+1,code:"spec_duplicate_id"}):_.set(w,S);continue}ge.test(T)&&(d===null?e.push({severity:n.MarkerSeverity.Error,message:"This heading has no embedded ID. Add `<!-- id: REQ-X -->` on the line above it \u2014 required by the SpecShip parser.",startLineNumber:R,startColumn:1,endLineNumber:R,endColumn:T.length+1,code:"spec_missing_id"}):d=null)}n.editor.setModelMarkers(t,"specship-spec",e)}function _e(n){n.languages.registerCompletionItemProvider("markdown",{provideCompletionItems:(t,e)=>{let i=t.getWordUntilPosition(e),d={startLineNumber:e.lineNumber,endLineNumber:e.lineNumber,startColumn:i.startColumn,endColumn:i.endColumn},_=n.languages.CompletionItemKind,O=n.languages.CompletionItemInsertTextRule;return{suggestions:[{label:"req",kind:_.Snippet,insertText:["<!-- id: REQ-${1:AREA}-${2:001} -->","## ${3:Title MUST be concrete}","","${4:Body \u2014 describe the contract, not the implementation.}","","## Acceptance","<!-- id: REQ-${1:AREA}-${2:001}.A1 -->","- ${5:First testable acceptance criterion}","$0"].join(`
|
|
3
|
+
`),insertTextRules:O.InsertAsSnippet,documentation:"Insert a full requirement (heading + acceptance) with embedded IDs.",detail:"SpecShip \xB7 requirement",range:d},{label:"doc",kind:_.Snippet,insertText:["---","id: ${1:AREA}-DOC","title: ${2:Title}","owner: ${3:team-or-person}","priority: ${4|high,medium,low|}","---","","<!-- id: ${1:AREA}-DOC -->","# ${2:Title}","","${5:One-paragraph summary of what this document covers.}","$0"].join(`
|
|
4
|
+
`),insertTextRules:O.InsertAsSnippet,documentation:"Insert a new spec document with frontmatter.",detail:"SpecShip \xB7 document",range:d},{label:"accept",kind:_.Snippet,insertText:["## Acceptance","<!-- id: ${1:REQ-X}.A1 -->","- ${2:First testable acceptance criterion}","<!-- id: ${1:REQ-X}.A2 -->","- ${3:Second testable acceptance criterion}","$0"].join(`
|
|
5
|
+
`),insertTextRules:O.InsertAsSnippet,documentation:"Insert an Acceptance section with two ID-d bullets.",detail:"SpecShip \xB7 acceptance",range:d},{label:"impl",kind:_.Snippet,insertText:["implementations:"," - ${1:src/path/to/file.ts}:${2:QualifiedSymbol}","$0"].join(`
|
|
6
|
+
`),insertTextRules:O.InsertAsSnippet,documentation:"Insert an implementations block linking the spec to code.",detail:"SpecShip \xB7 implementations",range:d}]}},triggerCharacters:["r","d","a","i"]})}var xe=["host"];function ve(n,t){if(n&1&&(a(0,"span",5),l(1),r()),n&2){let e=c();p("title",e.path),o(),m(e.path)}}function fe(n,t){n&1&&(a(0,"div",15),l(1,"Loading editor\u2026"),r())}var F=class n{sanitizer=y(L);destroyRef=y(Q);value="";path="";valueChange=new P;validationChange=new P;save=new P;cancel=new P;hostRef;loading=x(!0);currentValue=x("");errorCount=x(0);warningCount=x(0);dirty=x(!1);previewHtml=f(()=>this.sanitizer.bypassSecurityTrustHtml(j(this.currentValue()||"")));tokenCount=f(()=>Math.max(1,Math.round((this.currentValue()||"").length/4)));statusLabel=f(()=>{let t=this.errorCount(),e=this.warningCount();return t>0?`${t} error${t===1?"":"s"}`:e>0?`${e} warning${e===1?"":"s"}`:"clean"});statusKind=f(()=>this.errorCount()>0?"error":this.warningCount()>0?"warn":"ok");monaco=null;editor=null;model=null;diagnosticsTimer=null;async ngAfterViewInit(){this.currentValue.set(this.value);try{let t=await re();this.monaco=t,de(t),this.model=t.editor.createModel(this.value,"markdown"),this.editor=t.editor.create(this.hostRef.nativeElement,{model:this.model,theme:this.preferDark()?"vs-dark":"vs",automaticLayout:!0,wordWrap:"on",minimap:{enabled:!1},scrollBeyondLastLine:!1,renderWhitespace:"none",fontSize:13,lineNumbers:"on",folding:!1,tabSize:2,insertSpaces:!0,contextmenu:!1}),this.editor.onDidChangeModelContent(()=>this.handleEdit()),this.runDiagnosticsNow(),this.loading.set(!1)}catch(t){console.error("[spec-editor] failed to load Monaco",t),this.loading.set(!1)}this.destroyRef.onDestroy(()=>this.dispose())}ngOnDestroy(){this.dispose()}onSave(){this.save.emit()}onCancel(){this.cancel.emit()}handleEdit(){if(!this.model)return;let t=this.model.getValue();this.currentValue.set(t),this.dirty.set(t!==this.value),this.valueChange.emit(t),this.diagnosticsTimer!==null&&clearTimeout(this.diagnosticsTimer),this.diagnosticsTimer=setTimeout(()=>this.runDiagnosticsNow(),500)}runDiagnosticsNow(){if(!this.monaco||!this.model)return;le(this.monaco,this.model);let t=this.monaco.editor.getModelMarkers({resource:this.model.uri,owner:"specship-spec"}),e=t.filter(d=>d.severity===this.monaco.MarkerSeverity.Error).length,i=t.filter(d=>d.severity===this.monaco.MarkerSeverity.Warning).length;this.errorCount.set(e),this.warningCount.set(i),this.validationChange.emit({errors:e,warnings:i})}preferDark(){if(typeof window>"u")return!1;try{return window.matchMedia("(prefers-color-scheme: dark)").matches}catch{return!1}}dispose(){this.diagnosticsTimer!==null&&(clearTimeout(this.diagnosticsTimer),this.diagnosticsTimer=null),this.editor?.dispose(),this.editor=null,this.model?.dispose(),this.model=null}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=k({type:n,selectors:[["app-spec-editor"]],viewQuery:function(e,i){if(e&1&&B(xe,7),e&2){let d;U(d=K())&&(i.hostRef=d.first)}},inputs:{value:"value",path:"path"},outputs:{valueChange:"valueChange",validationChange:"validationChange",save:"save",cancel:"cancel"},decls:23,vars:16,consts:[["host",""],[1,"editor-shell","col"],[1,"toolbar","row","gap-8"],["name","memory",3,"size"],[1,"title"],[1,"path","mono",3,"title"],[1,"grow"],[1,"status-pill"],[1,"dot"],[1,"tokens","mono","tabular","muted",3,"title"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click"],["type","button",1,"btn","btn-primary","btn-sm",3,"click","disabled","title"],["name","check",3,"size"],[1,"panes","row"],[1,"editor-pane"],[1,"loading"],[1,"monaco-host"],[1,"preview-pane","md-content",3,"innerHTML"]],template:function(e,i){e&1&&(a(0,"div",1)(1,"div",2),s(2,"app-icon",3),a(3,"span",4),l(4,"Spec editor"),r(),g(5,ve,2,2,"span",5),s(6,"span",6),a(7,"span",7),s(8,"span",8),l(9),r(),a(10,"span",9),l(11),r(),a(12,"button",10),v("click",function(){return i.onCancel()}),l(13," Cancel "),r(),a(14,"button",11),v("click",function(){return i.onSave()}),s(15,"app-icon",12),l(16," Save "),r()(),a(17,"div",13)(18,"div",14),g(19,fe,2,0,"div",15),s(20,"div",16,0),r(),s(22,"div",17),r()()),e&2&&(o(2),p("size",14),o(3),u(i.path?5:-1),o(2),$("ok",i.statusKind()==="ok")("warn",i.statusKind()==="warn")("error",i.statusKind()==="error"),o(2),h(" ",i.statusLabel()," "),o(),p("title","~"+i.tokenCount()+" tokens (rough estimate)"),o(),h(" ~",i.tokenCount(),"t "),o(3),p("disabled",!i.dirty()||i.errorCount()>0)("title",i.errorCount()>0?"Fix errors before saving":i.dirty()?"Save changes":"No changes to save"),o(),p("size",13),o(4),u(i.loading()?19:-1),o(3),p("innerHTML",i.previewHtml(),z))},dependencies:[E],styles:['@charset "UTF-8";[_nghost-%COMP%]{display:flex;flex:1;min-height:0}.editor-shell[_ngcontent-%COMP%]{flex:1;min-height:0;border:1px solid var(--border-subtle);border-radius:10px;overflow:hidden;background:var(--bg-panel)}.toolbar[_ngcontent-%COMP%]{align-items:center;padding:8px 12px;border-bottom:1px solid var(--border-subtle);background:var(--bg-panel);flex-wrap:wrap;row-gap:6px}.toolbar[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:12.5px;font-weight:650;color:var(--text-primary)}.toolbar[_ngcontent-%COMP%] .path[_ngcontent-%COMP%]{font-size:11px;color:var(--text-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:320px}.toolbar[_ngcontent-%COMP%] .tokens[_ngcontent-%COMP%]{font-size:10.5px;color:var(--text-muted)}.status-pill[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:6px;font-size:11px;font-weight:600;padding:3px 9px;border-radius:999px;white-space:nowrap}.status-pill[_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{width:7px;height:7px;border-radius:50%}.status-pill.ok[_ngcontent-%COMP%]{color:var(--success);background:var(--success-soft)}.status-pill.ok[_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{background:var(--success)}.status-pill.warn[_ngcontent-%COMP%]{color:var(--warn);background:var(--warn-soft)}.status-pill.warn[_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{background:var(--warn)}.status-pill.error[_ngcontent-%COMP%]{color:var(--error);background:var(--error-soft)}.status-pill.error[_ngcontent-%COMP%] .dot[_ngcontent-%COMP%]{background:var(--error)}.panes[_ngcontent-%COMP%]{flex:1;min-height:0}.editor-pane[_ngcontent-%COMP%]{flex:1;min-width:0;min-height:0;position:relative;border-right:1px solid var(--border-subtle)}.loading[_ngcontent-%COMP%]{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:var(--text-muted);font-size:12px;background:var(--bg-canvas);z-index:1}.monaco-host[_ngcontent-%COMP%]{position:absolute;inset:0}.preview-pane[_ngcontent-%COMP%]{flex:1;min-width:0;min-height:0;padding:14px 18px;overflow:auto;background:var(--bg-canvas)}.preview-pane.md-content[_ngcontent-%COMP%] .md-h1[_ngcontent-%COMP%]{font-size:15px;font-weight:650;color:var(--text-primary);letter-spacing:-.01em;margin:0 0 10px}.preview-pane.md-content[_ngcontent-%COMP%] .md-h2[_ngcontent-%COMP%]{font-size:13px;font-weight:650;color:var(--text-primary);letter-spacing:-.005em;margin:18px 0 6px;padding-bottom:4px;border-bottom:1px solid var(--border-subtle)}.preview-pane.md-content[_ngcontent-%COMP%] .md-h3[_ngcontent-%COMP%]{font-size:12px;font-weight:650;color:var(--text-primary);margin:14px 0 6px}.preview-pane.md-content[_ngcontent-%COMP%] .md-h4[_ngcontent-%COMP%]{font-size:10.5px;font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:var(--text-muted);margin:12px 0 4px}.preview-pane.md-content[_ngcontent-%COMP%] .md-p[_ngcontent-%COMP%]{font-size:12.5px;line-height:1.6;color:var(--text-secondary);margin:0 0 4px;overflow-wrap:anywhere}.preview-pane.md-content[_ngcontent-%COMP%] .md-p[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--text-primary)}.preview-pane.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%], .preview-pane.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%]{padding:0;margin:4px 0 6px}.preview-pane.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%] li[_ngcontent-%COMP%], .preview-pane.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{position:relative;padding:2px 0 2px 22px;font-size:12.5px;line-height:1.6;color:var(--text-secondary);overflow-wrap:anywhere}.preview-pane.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%] li[_ngcontent-%COMP%] strong[_ngcontent-%COMP%], .preview-pane.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--text-primary)}.preview-pane.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%]{list-style:none}.preview-pane.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:before{content:"\\2022";position:absolute;left:6px;top:2px;color:var(--text-faint)}.preview-pane.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%]{list-style:none;counter-reset:md-ol}.preview-pane.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{counter-increment:md-ol}.preview-pane.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:before{content:counter(md-ol) ".";position:absolute;left:0;top:2px;color:var(--text-faint);font-family:var(--font-mono);font-size:11.5px;min-width:18px;text-align:right}.preview-pane.md-content[_ngcontent-%COMP%] .md-spacer[_ngcontent-%COMP%]{height:6px}.preview-pane.md-content[_ngcontent-%COMP%] .md-import[_ngcontent-%COMP%]{display:inline-block;font-size:11.5px;color:var(--node-route);background:var(--node-route-soft);padding:2px 8px;border-radius:5px;margin:4px 0}.preview-pane.md-content[_ngcontent-%COMP%] .md-inline-code[_ngcontent-%COMP%]{font-size:11.5px;background:var(--bg-canvas);padding:1px 6px;border-radius:4px;border:1px solid var(--border-subtle);color:var(--node-spec)}.preview-pane.md-content[_ngcontent-%COMP%] .md-blockquote[_ngcontent-%COMP%]{margin:6px 0;padding:8px 12px;border-left:3px solid var(--accent);background:var(--accent-soft);color:var(--text-secondary);font-size:12.5px;line-height:1.55;border-radius:0 6px 6px 0}.preview-pane.md-content[_ngcontent-%COMP%] .md-pre[_ngcontent-%COMP%]{position:relative;margin:8px 0 10px;padding:12px 14px;background:var(--bg-panel);border:1px solid var(--border-subtle);border-radius:8px;overflow-x:auto}.preview-pane.md-content[_ngcontent-%COMP%] .md-pre[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{display:block;font-size:11.5px;line-height:1.55;color:var(--text-primary);white-space:pre}.preview-pane.md-content[_ngcontent-%COMP%] .md-pre-lang[_ngcontent-%COMP%]{position:absolute;top:6px;right:10px;font-size:10px;font-weight:600;color:var(--text-muted);text-transform:lowercase;background:var(--bg-canvas);padding:1px 6px;border-radius:4px;border:1px solid var(--border-subtle)}.preview-pane.md-content[_ngcontent-%COMP%] .md-table-scroll[_ngcontent-%COMP%]{overflow-x:auto;margin:10px 0;border:1px solid var(--border-subtle);border-radius:8px}.preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%]{width:100%;border-collapse:collapse;font-size:11.5px}.preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] th[_ngcontent-%COMP%], .preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{padding:8px 12px;text-align:left;vertical-align:top;border-bottom:1px solid var(--border-subtle)}.preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] thead[_ngcontent-%COMP%] th[_ngcontent-%COMP%]{background:var(--bg-panel);font-weight:650;color:var(--text-primary);font-size:10.5px;text-transform:uppercase;letter-spacing:.04em;border-bottom:1px solid var(--border-strong);white-space:nowrap}.preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{color:var(--text-secondary)}.preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child td[_ngcontent-%COMP%]{border-bottom:0}.preview-pane.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.preview-pane.md-content[_ngcontent-%COMP%] > [_ngcontent-%COMP%]:first-child{margin-top:0}'],changeDetection:0})};function Ce(n,t){n&1&&(a(0,"div",14),l(1),r()),n&2&&(o(),m(t))}function be(n,t){if(n&1){let e=M();a(0,"div",0),v("click",function(){C(e);let d=c();return b(d.onBackdropClick())}),r(),a(1,"div",1)(2,"header",2)(3,"div",3)(4,"div",4),l(5,"Draft a new spec with Claude"),r(),a(6,"div",5),l(7,"Describe the feature in one sentence. Claude takes it from there."),r()(),a(8,"button",6),v("click",function(){C(e);let d=c();return b(d.onCloseClick())}),s(9,"app-icon",7),r()(),a(10,"div",8)(11,"label",9),l(12,"Feature description"),r(),a(13,"textarea",10),v("input",function(d){C(e);let _=c();return b(_.onDescriptionInput(d))}),r(),a(14,"div",11),l(15,"This will run in Claude Code:"),r(),a(16,"pre",12),l(17),r()(),a(18,"footer",13),g(19,Ce,2,1,"div",14),s(20,"span",15),a(21,"button",16),v("click",function(){C(e);let d=c();return b(d.onCopyToClipboard())}),s(22,"app-icon",17),l(23," Copy prompt "),r(),a(24,"button",18),v("click",function(){C(e);let d=c();return b(d.onOpenInClaude())}),s(25,"app-icon",19),l(26," Open in Claude Code "),r()()()}if(n&2){let e,i=c();o(9),p("size",16),o(4),p("value",i.description()),o(4),m(i.slashCommand()),o(2),u((e=i.toast())?19:-1,e),o(2),p("disabled",!i.canSubmit()),o(),p("size",13),o(2),p("disabled",!i.canSubmit()),o(),p("size",13)}}var W=class n{open=!1;close=new P;description=x("");toast=x(null);slashCommand=f(()=>{let t=this.description().trim();return t?`/ss-spec-author "${t.replace(/"/g,'\\"')}"`:"/ss-spec-author"});canSubmit=f(()=>this.description().trim().length>0);onDescriptionInput(t){let e=t.target;this.description.set(e.value)}onBackdropClick(){this.dismiss()}onCloseClick(){this.dismiss()}async onOpenInClaude(){if(!this.canSubmit())return;let t=this.slashCommand();await this.writeToClipboard(t);try{window.location.href=`claude://prompt?text=${encodeURIComponent(t)}`,this.flashToast("Opening Claude Code\u2026 (also copied to clipboard)")}catch{this.flashToast("Claude Code handler unavailable \u2014 prompt copied to clipboard.")}}async onCopyToClipboard(){if(!this.canSubmit())return;let t=this.slashCommand(),e=await this.writeToClipboard(t);this.flashToast(e?"Copied! Switch to Claude Code and paste.":"Could not access clipboard \u2014 copy the prompt manually.")}async writeToClipboard(t){if(!navigator.clipboard)return!1;try{return await navigator.clipboard.writeText(t),!0}catch{return!1}}flashToast(t){this.toast.set(t),setTimeout(()=>this.toast.set(null),2500)}dismiss(){this.description.set(""),this.toast.set(null),this.close.emit()}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=k({type:n,selectors:[["app-draft-with-claude-modal"]],inputs:{open:"open"},outputs:{close:"close"},decls:1,vars:1,consts:[["role","presentation",1,"backdrop",3,"click"],["role","dialog","aria-labelledby","draft-modal-title","aria-modal","true",1,"modal"],[1,"head"],[1,"title-block"],["id","draft-modal-title",1,"title"],[1,"sub"],["type","button","aria-label","Close",1,"close",3,"click"],["name","x",3,"size"],[1,"body"],["for","draft-description",1,"field-label"],["id","draft-description","rows","3","placeholder","e.g. Failed payment retries should back off with T+1d, T+3d, T+7d then downgrade the account.","autofocus","",1,"field",3,"input","value"],[1,"preview-label"],[1,"preview","mono"],[1,"foot"],[1,"toast"],[1,"grow"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click","disabled"],["name","copy",3,"size"],["type","button",1,"btn","btn-primary","btn-sm",3,"click","disabled"],["name","external",3,"size"]],template:function(e,i){e&1&&g(0,be,27,8),e&2&&u(i.open?0:-1)},dependencies:[E],styles:[".backdrop[_ngcontent-%COMP%]{position:fixed;inset:0;background:#00000080;z-index:100;-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px)}.modal[_ngcontent-%COMP%]{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:min(560px,100vw - 32px);max-height:calc(100vh - 64px);background:var(--bg-panel);border:1px solid var(--border-subtle);border-radius:12px;box-shadow:0 24px 48px #0006;z-index:101;display:flex;flex-direction:column;overflow:hidden}.head[_ngcontent-%COMP%]{display:flex;align-items:flex-start;gap:12px;padding:16px 18px;border-bottom:1px solid var(--border-subtle)}.head[_ngcontent-%COMP%] .title-block[_ngcontent-%COMP%]{flex:1;min-width:0}.head[_ngcontent-%COMP%] .title[_ngcontent-%COMP%]{font-size:14.5px;font-weight:650;color:var(--text-primary);letter-spacing:-.01em}.head[_ngcontent-%COMP%] .sub[_ngcontent-%COMP%]{font-size:12px;color:var(--text-secondary);margin-top:2px;line-height:1.45}.head[_ngcontent-%COMP%] .close[_ngcontent-%COMP%]{appearance:none;background:transparent;border:0;width:28px;height:28px;border-radius:6px;color:var(--text-muted);cursor:pointer;display:inline-flex;align-items:center;justify-content:center;transition:background .12s,color .12s}.head[_ngcontent-%COMP%] .close[_ngcontent-%COMP%]:hover{background:var(--bg-hover);color:var(--text-primary)}.head[_ngcontent-%COMP%] .close[_ngcontent-%COMP%]:focus-visible{outline:2px solid var(--accent);outline-offset:1px}.body[_ngcontent-%COMP%]{padding:16px 18px;display:flex;flex-direction:column;gap:10px;overflow-y:auto}.field-label[_ngcontent-%COMP%]{font-size:11px;font-weight:600;color:var(--text-muted);text-transform:uppercase;letter-spacing:.04em}.field[_ngcontent-%COMP%]{width:100%;box-sizing:border-box;padding:10px 12px;background:var(--bg-canvas);border:1px solid var(--border-subtle);border-radius:8px;color:var(--text-primary);font-family:var(--font-ui);font-size:13px;line-height:1.5;resize:vertical}.field[_ngcontent-%COMP%]:focus{outline:2px solid var(--accent);outline-offset:1px;border-color:transparent}.preview-label[_ngcontent-%COMP%]{font-size:11px;color:var(--text-muted);margin-top:4px}.preview[_ngcontent-%COMP%]{margin:0;padding:10px 12px;background:var(--bg-canvas);border:1px solid var(--border-subtle);border-radius:8px;font-size:11.5px;line-height:1.5;color:var(--node-spec);font-family:var(--font-mono);white-space:pre-wrap;word-break:break-all}.foot[_ngcontent-%COMP%]{display:flex;align-items:center;gap:8px;padding:12px 18px;border-top:1px solid var(--border-subtle);background:var(--bg-canvas);flex-wrap:wrap}.foot[_ngcontent-%COMP%] .grow[_ngcontent-%COMP%]{flex:1}.toast[_ngcontent-%COMP%]{font-size:11.5px;color:var(--success);background:var(--success-soft);padding:4px 10px;border-radius:999px;white-space:nowrap}"],changeDetection:0})};var he=(n,t)=>t.path,me=(n,t)=>t.id,ye=(n,t)=>t.briefId;function Me(n,t){n&1&&s(0,"app-pick-project-empty",0)}function we(n,t){if(n&1&&(s(0,"span",6),a(1,"span",17),l(2),r()),n&2){let e=c();o(2),h("",e.summary.conflicts," \u26A0")}}function Pe(n,t){if(n&1&&(a(0,"div",8)(1,"span")(2,"b",15),l(3),r(),l(4," ideas"),r(),a(5,"span",16),l(6,"\u2192"),r(),a(7,"span")(8,"b",15),l(9),r(),l(10," specs"),r(),a(11,"span",16),l(12,"\u2192"),r(),a(13,"span")(14,"b",15),l(15),r(),l(16," impl \xB7 "),a(17,"b",15),l(18),r(),l(19," ver"),r(),g(20,we,3,1),r()),n&2){let e=t;o(3),m(e.summary.ideas),o(6),m(e.summary.specified),o(6),m(e.summary.links.implemented),o(3),m(e.summary.links.verified),o(2),u(e.summary.conflicts>0?20:-1)}}function Oe(n,t){n&1&&s(0,"app-empty",10)}function Se(n,t){if(n&1&&(a(0,"span",22),l(1),r()),n&2){let e=c().$implicit,i=c(2);o(),h(" ",i.driftCountForGroup(e)," ")}}function ke(n,t){if(n&1){let e=M();a(0,"div",25),v("click",function(){let d=C(e).$implicit,_=c(4);return b(_.select(d.id))}),s(1,"span",26),a(2,"div",27)(3,"div",28),l(4),r(),a(5,"div",29),l(6),r()()()}if(n&2){let e=t.$implicit,i=c(4);$("selected",i.sel()===e.id),o(),V("background",i.stateColorFor(e.kind)),o(2),V("color",i.sel()===e.id?"var(--accent)":"var(--text-primary)"),o(),m(e.id),o(2),m(e.title)}}function Ee(n,t){if(n&1&&(a(0,"div",23),D(1,ke,7,8,"div",24,me),r()),n&2){let e=c().$implicit;o(),I(e.specs)}}function Te(n,t){if(n&1){let e=M();a(0,"div",18),v("click",function(){let d=C(e).$implicit,_=c(2);return b(_.toggleGroup(d.path))}),s(1,"app-icon",19)(2,"app-icon",20),a(3,"span",21),l(4),r(),g(5,Se,2,1,"span",22),r(),g(6,Ee,3,0,"div",23)}if(n&2){let e=t.$implicit,i=c(2);o(),p("name",i.isGroupOpen(e.path)?"chevronDown":"chevronRight")("size",12),o(),p("size",13),o(2),m(e.title),o(),u(i.driftCountForGroup(e)>0?5:-1),o(),u(i.isGroupOpen(e.path)?6:-1)}}function ze(n,t){if(n&1){let e=M();a(0,"div",25),v("click",function(){let d=C(e).$implicit,_=c(3);return b(_.select(d.briefId))}),s(1,"span",33),a(2,"div",27)(3,"div",29),l(4),r()()()}if(n&2){let e=t.$implicit,i=c(3);$("selected",i.sel()===e.briefId),o(4),m(e.title)}}function De(n,t){if(n&1&&(a(0,"div",30)(1,"span",31),l(2,"IDEAS"),r(),a(3,"span",32),l(4),r()(),D(5,ze,5,3,"div",24,ye)),n&2){let e=c(2);o(4),m(e.ideas().length),o(),I(e.ideas())}}function Ie(n,t){if(n&1&&(a(0,"div",34),l(1),r()),n&2){let e=c();o(),h("Loading source for ",e.id,"\u2026")}}function $e(n,t){if(n&1){let e=M();a(0,"app-spec-editor",38),v("valueChange",function(d){C(e);let _=c(4);return b(_.onEditorValueChange(d))})("save",function(){C(e);let d=c(4);return b(d.onEditorSave())})("cancel",function(){C(e);let d=c(4);return b(d.onEditorCancel())}),r()}if(n&2){let e=c(),i=c(3);p("value",i.editingSource())("path",e.sourcePath)}}function Ne(n,t){n&1&&(a(0,"div",36),l(1),r()),n&2&&(o(),m(t))}function Re(n,t){n&1&&(a(0,"div",37),l(1,"Saving\u2026"),r())}function Ve(n,t){if(n&1&&(g(0,Ie,2,1,"div",34)(1,$e,1,2,"app-spec-editor",35),g(2,Ne,2,1,"div",36),g(3,Re,2,0,"div",37)),n&2){let e,i=c(3);u(i.editingSource()===null?0:1),o(2),u((e=i.saveError())?2:-1,e),o(),u(i.saving()?3:-1)}}function Le(n,t){if(n&1&&g(0,Ve,4,3),n&2){let e,i=c(2);u((e=i.selectedSpec())?0:-1,e)}}function je(n,t){if(n&1&&(a(0,"app-pill"),l(1),r()),n&2){let e=c();o(),m(e.priority)}}function Ae(n,t){if(n&1&&(a(0,"div",45)(1,"div",46),l(2,"Owner"),r(),a(3,"div",47),l(4),r()()),n&2){let e=c();o(4),m(e.owner)}}function Fe(n,t){if(n&1&&(a(0,"details",50)(1,"summary",63),l(2,"Brainstorm"),r(),s(3,"div",64),r()),n&2){let e=c(3);o(3),p("innerHTML",e.briefHtml(),z)}}function We(n,t){n&1&&s(0,"div",51)}function He(n,t){if(n&1&&(a(0,"app-pill",67),l(1),r()),n&2){let e=c().$implicit;o(),h("",e.driftAxis," drift")}}function qe(n,t){if(n&1&&(a(0,"div",66),s(1,"app-state-pill",42),g(2,He,2,1,"app-pill",67),a(3,"span",68),l(4),r(),a(5,"app-pill"),l(6),r(),a(7,"button",69),s(8,"app-icon",60),l(9," Reveal "),r()()),n&2){let e=t.$implicit,i=t.$index;V("border-top",i>0?"1px solid var(--border-subtle)":"none"),o(),p("state",e.state),o(),u(e.driftAxis?2:-1),o(2),m(e.targetQualifiedName),o(2),m(e.provenance),o(2),p("size",12)}}function Ge(n,t){if(n&1&&(a(0,"div",52),D(1,qe,10,7,"div",65,me),r()),n&2){let e=c(3);o(),I(e.selectedLinks())}}function Qe(n,t){n&1&&(a(0,"div",53),s(1,"app-icon",70),a(2,"div",71),l(3," Orphaned \u2014 no code implements this requirement yet "),r()()),n&2&&(o(),p("size",16))}function Be(n,t){n&1&&(a(0,"div",62),l(1),r()),n&2&&(o(),m(t))}function Ue(n,t){if(n&1){let e=M();a(0,"div",12)(1,"div",39)(2,"span",40),l(3),r(),s(4,"app-copy-btn",41)(5,"div",6)(6,"app-state-pill",42),g(7,je,2,1,"app-pill"),r(),a(8,"h1",43),l(9),r(),a(10,"div",44)(11,"div",45)(12,"div",46),l(13,"Kind"),r(),a(14,"div",47),l(15),r()(),g(16,Ae,5,1,"div",45),a(17,"div",45)(18,"div",46),l(19,"Doc"),r(),a(20,"div",47),l(21),r()(),a(22,"div",45)(23,"div",46),l(24,"Siblings"),r(),a(25,"div",47),l(26),r()(),a(27,"div",45)(28,"div",46),l(29,"Links"),r(),a(30,"div",47),l(31),r()()(),a(32,"div",48),l(33,"Requirement"),r(),s(34,"div",49),g(35,Fe,4,1,"details",50),a(36,"div",48),l(37,"Linked code"),r(),g(38,We,1,0,"div",51)(39,Ge,3,0,"div",52)(40,Qe,4,1,"div",53),a(41,"div",54)(42,"button",55),s(43,"app-icon",56),l(44," Implement "),r(),a(45,"button",57),s(46,"app-icon",58),l(47," Verify "),r(),a(48,"button",59),v("click",function(){C(e);let d=c(2);return b(d.onEditClick())}),s(49,"app-icon",60),l(50," Edit spec "),r(),a(51,"button",59),v("click",function(){let d=C(e),_=c(2);return b(_.goToGraph(d.id))}),s(52,"app-icon",61),l(53," Show in graph "),r()(),g(54,Be,2,1,"div",62),r()}if(n&2){let e,i=t,d=c(2);o(3),m(i.id),o(),p("text",i.id),o(2),p("state",i.kind),o(),u(i.priority?7:-1),o(2),m(i.title),o(6),m(i.kind),o(),u(i.owner?16:-1),o(5),m(i.sourcePath.replace("specs/","")),o(5),h("",d.selectedSiblings().length," reqs"),o(5),m(d.selectedLinks().length),o(3),p("innerHTML",d.renderBody(i.body),z),o(),u(d.briefResource.state().data?35:-1),o(3),u(d.detailResource.state().loading?38:d.selectedLinks().length>0?39:40),o(5),p("size",13),o(3),p("size",13),o(3),p("size",13),o(3),p("size",13),o(2),u((e=d.saveError())?54:-1,e)}}function Ke(n,t){n&1&&(a(0,"app-empty",13)(1,"code",72),l(2,"specship init -i"),r()())}function Xe(n,t){if(n&1){let e=M();a(0,"div",1)(1,"div",2)(2,"div",3),s(3,"app-icon",4),a(4,"span",5),l(5,"Specs"),r(),s(6,"span",6),a(7,"span",7),l(8),r()(),g(9,Pe,21,5,"div",8),a(10,"div",9),g(11,Oe,1,0,"app-empty",10),D(12,Te,7,6,null,null,he),g(14,De,7,1),r()(),a(15,"div",11),g(16,Le,1,1)(17,Ue,55,18,"div",12)(18,Ke,3,0,"app-empty",13),r()(),a(19,"app-draft-with-claude-modal",14),v("close",function(){C(e);let d=c();return b(d.onDraftModalClose())}),r()}if(n&2){let e,i,d=c();o(3),p("size",15),o(5),h(" ",d.resource.state().loading?"\u2026":d.totalCount()+" reqs"," "),o(),u((e=d.funnel())?9:-1,e),o(2),u(d.groups().length===0&&!d.resource.state().loading?11:-1),o(),I(d.groups()),o(2),u(d.ideas().length>0?14:-1),o(2),u(d.editing()?16:(i=d.selectedSpec())?17:18,i),o(3),p("open",d.draftModalOpen())}}function Je(n){return n.replace(/<!--[\s\S]*?-->/g,"")}var pe=class n{api=y(J);projects=y(Y);router=y(X);conn=y(Z);sanitizer=y(L);resource=N(this.api,()=>`/api/specs${this.projects.projectQuery()}`);funnelResource=N(this.api,()=>`/api/spec/funnel${this.projects.projectQuery()}`);funnel=f(()=>this.funnelResource.state().data??null);ideas=f(()=>this.funnel()?.ideas??[]);detailResource=N(this.api,()=>{let t=this.sel();return t?`/api/spec/${encodeURIComponent(t)}${this.projects.projectQuery()}`:null});briefResource=N(this.api,()=>{let t=this.sel();return t?`/api/spec/${encodeURIComponent(t)}/brief${this.projects.projectQuery()}`:null});briefHtml=f(()=>this.renderBody(this.briefResource.state().data?.markdown??""));sel=x(null);expandedGroups=x(new Set);editing=x(!1);editingSource=x(null);editingDirty=x(!1);saving=x(!1);saveError=x(null);draftModalOpen=x(!1);STATE=q;groups=f(()=>{let t=(this.resource.state().data?.specs??[]).filter(i=>i.kind!=="brief"),e=new Map;for(let i of t){let d=i.sourcePath||"(unknown)";e.has(d)||e.set(d,{path:d,title:d.replace(/^specs\//,""),specs:[]}),e.get(d).specs.push(i)}return[...e.values()]});totalCount=f(()=>this.groups().reduce((t,e)=>t+e.specs.length,0));selectedSpec=f(()=>{let t=this.sel();return t?(this.resource.state().data?.specs??[]).find(i=>i.id===t)??null:null});selectedLinks=f(()=>this.detailResource.state().data?.links??[]);selectedSiblings=f(()=>{let t=this.selectedSpec();if(!t)return[];let e=this.groups().find(i=>i.path===t.sourcePath);return e?e.specs.filter(i=>i.id!==t.id):[]});isGroupOpen(t){return!this.expandedGroups().has("closed:"+t)}toggleGroup(t){this.expandedGroups.update(e=>{let i="closed:"+t,d=new Set(e);return d.has(i)?d.delete(i):d.add(i),d})}driftCountForGroup(t){let e=this.selectedSpec();return!e||e.sourcePath!==t.path?0:this.selectedLinks().filter(i=>["drifted","broken","orphaned"].includes(i.state)).length}stateColorFor(t){return q[t]?.color??"var(--node-spec)"}select(t){this.editing()&&(this.editing.set(!1),this.editingSource.set(null),this.editingDirty.set(!1)),this.sel.set(t)}renderBody(t){return this.sanitizer.bypassSecurityTrustHtml(j(Je(t)))}goToGraph(t){this.router.navigate(["/graph"],{queryParams:{focus:"spec:"+t}})}async onEditClick(){let t=this.selectedSpec();if(t){this.saveError.set(null),this.editing.set(!0),this.editingSource.set(null);try{let e=this.projects.projectQuery(),i=await this.api.get(`/api/spec/${encodeURIComponent(t.id)}${e}`);this.editingSource.set(i.source??t.body)}catch(e){this.saveError.set(`Couldn't load source: ${e instanceof Error?e.message:String(e)}`),this.editing.set(!1)}}}onEditorValueChange(t){this.editingSource.set(t),this.editingDirty.set(!0)}async onEditorSave(){let t=this.selectedSpec(),e=this.editingSource();if(!(!t||e===null)){if(!this.conn.online()){this.saveError.set("Offline \u2014 reconnect to save your changes");return}this.saving.set(!0),this.saveError.set(null);try{let i=this.projects.projectQuery();await this.api.put(`/api/spec/${encodeURIComponent(t.id)}${i}`,{content:e}),this.editing.set(!1),this.editingDirty.set(!1),this.editingSource.set(null),this.resource.refetch()}catch(i){this.saveError.set(`Save failed: ${i instanceof Error?i.message:String(i)}`)}finally{this.saving.set(!1)}}}onEditorCancel(){this.editingDirty()&&!window.confirm("Discard unsaved changes?")||(this.editing.set(!1),this.editingSource.set(null),this.editingDirty.set(!1),this.saveError.set(null))}onDraftWithClaudeClick(){this.draftModalOpen.set(!0)}onDraftModalClose(){this.draftModalOpen.set(!1)}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=k({type:n,selectors:[["app-specs"]],decls:2,vars:1,consts:[["surface","Specs"],[1,"specs-shell"],[1,"tree-col"],[1,"tree-header","row","gap-8"],["name","book",2,"color","var(--accent)",3,"size"],[2,"font-weight","600","font-size","13px"],[1,"grow"],[1,"muted","tabular",2,"font-size","11px"],["aria-label","Spec lifecycle funnel",1,"row","gap-8",2,"padding","6px 12px","border-bottom","1px solid var(--border-subtle)","font-size","11px","color","var(--text-secondary)"],[1,"scroll-y","tree-scroll"],["icon","book","title","No specs found","body","Run specship init -i against a project with a specs/ directory."],[1,"detail-col","col"],[1,"scroll-y","detail-scroll"],["icon","book","title","Pick a spec from the tree","body","Or run specship init -i to index your specs/ folder if you haven't yet."],[3,"close","open"],[2,"color","var(--text-primary)"],[2,"color","var(--text-muted)"],[2,"color","var(--warn)"],[1,"doc-row","row","gap-6",3,"click"],[2,"color","var(--text-muted)",3,"name","size"],["name","book",2,"color","var(--node-spec)",3,"size"],[1,"mono","grow","doc-name"],[1,"pill",2,"font-size","9.5px","color","var(--warn)","background","var(--warn-soft)"],[1,"group-body"],[1,"req-row","row","gap-6",3,"selected"],[1,"req-row","row","gap-6",3,"click"],[1,"pill-dot",2,"flex-shrink","0"],[1,"grow",2,"min-width","0"],[1,"mono","req-id"],[1,"muted","req-title"],[1,"row","gap-6",2,"padding","10px 12px 2px","font-size","11px","color","var(--text-muted)"],[1,"mono","grow",2,"letter-spacing","0.5px"],[1,"tabular",2,"font-size","10.5px"],[1,"pill-dot",2,"background","var(--text-muted)","flex-shrink","0"],[1,"loading-detail"],[3,"value","path"],[1,"save-error"],[1,"save-status"],[3,"valueChange","save","cancel","value","path"],[1,"row","gap-8",2,"margin-bottom","4px"],[1,"mono",2,"font-size","12px","color","var(--node-spec)"],[3,"text"],[3,"state"],[1,"detail-title"],[1,"meta-row","row"],[1,"meta-item"],[1,"muted",2,"font-size","10.5px"],[1,"mono",2,"font-size","12.5px","margin-top","1px"],[1,"eyebrow",2,"margin-bottom","8px"],[1,"detail-body","md-content",3,"innerHTML"],[1,"brief-panel"],[1,"skel",2,"height","42px","border-radius","8px","margin-bottom","22px"],[1,"card",2,"overflow","hidden","margin-bottom","22px"],[1,"card","card-pad","orphan-card"],[1,"row","gap-8",2,"flex-wrap","wrap"],["type","button",1,"btn","btn-primary","btn-sm"],["name","play",3,"size"],["type","button",1,"btn","btn-secondary","btn-sm"],["name","check",3,"size"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click"],["name","reveal",3,"size"],["name","graph",3,"size"],[1,"save-error",2,"margin-top","16px"],[1,"eyebrow","brief-summary"],[1,"detail-body","brief-body","md-content",3,"innerHTML"],[1,"row","gap-10","link-row",3,"border-top"],[1,"row","gap-10","link-row"],["color","var(--warn)","bg","var(--warn-soft)"],[1,"mono","grow","link-target"],["type","button",1,"btn","btn-ghost","btn-xs"],["name","drift",3,"size"],[2,"margin-top","6px","font-size","12.5px"],["action","",1,"mono",2,"font-size","11.5px","color","var(--accent)","background","var(--bg-canvas)","padding","5px 10px","border-radius","6px","border","1px solid var(--border-subtle)"]],template:function(e,i){e&1&&g(0,Me,1,0,"app-pick-project-empty",0)(1,Xe,20,7),e&2&&u(i.resource.state().noProject?0:1)},dependencies:[ee,E,F,W,ie,te,oe,ne],styles:['@charset "UTF-8";[_nghost-%COMP%]{display:contents}.specs-shell[_ngcontent-%COMP%]{flex:1;display:flex;min-height:0}.tree-col[_ngcontent-%COMP%]{width:280px;flex-shrink:0;border-right:1px solid var(--border-subtle);background:var(--bg-panel);display:flex;flex-direction:column;min-height:0}.tree-header[_ngcontent-%COMP%]{padding:11px 12px;border-bottom:1px solid var(--border-subtle);align-items:center}.tree-scroll[_ngcontent-%COMP%]{flex:1;padding:6px}.doc-row[_ngcontent-%COMP%]{padding:6px 8px;border-radius:6px;cursor:pointer;color:var(--text-secondary);align-items:center}.doc-row[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.doc-name[_ngcontent-%COMP%]{font-size:12px;color:var(--text-primary);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.group-body[_ngcontent-%COMP%]{margin-left:14px;border-left:1px solid var(--border-subtle);padding-left:6px}.req-row[_ngcontent-%COMP%]{padding:5px 8px;border-radius:6px;cursor:pointer;align-items:flex-start;background:transparent}.req-row[_ngcontent-%COMP%]:not(.selected):hover{background:var(--bg-hover)}.req-row.selected[_ngcontent-%COMP%]{background:var(--accent-soft)}.req-id[_ngcontent-%COMP%]{font-size:11px}.req-title[_ngcontent-%COMP%]{font-size:10.5px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.detail-col[_ngcontent-%COMP%]{flex:1;min-width:0}.detail-scroll[_ngcontent-%COMP%]{flex:1;padding:22px}.detail-title[_ngcontent-%COMP%]{font-size:22px;font-weight:650;letter-spacing:-.01em;margin:2px 0 14px;text-wrap:pretty}.meta-row[_ngcontent-%COMP%]{gap:18px;padding:10px 0;border-top:1px solid var(--border-subtle);border-bottom:1px solid var(--border-subtle);margin-bottom:18px;flex-wrap:wrap}.detail-body[_ngcontent-%COMP%]{font-size:13.5px;line-height:1.65;color:var(--text-secondary);margin-bottom:22px;text-wrap:pretty}.brief-panel[_ngcontent-%COMP%]{border:1px solid var(--border-subtle);border-radius:8px;padding:0 12px;margin-bottom:22px;background:var(--bg-panel)}.brief-summary[_ngcontent-%COMP%]{padding:10px 0;cursor:pointer;list-style:none;display:flex;align-items:center;gap:6px;-webkit-user-select:none;user-select:none;margin-bottom:0}.brief-summary[_ngcontent-%COMP%]::-webkit-details-marker{display:none}.brief-summary[_ngcontent-%COMP%]:before{content:"\\25b6";font-size:8px;color:var(--text-muted);transition:transform .15s}details[open][_ngcontent-%COMP%] > .brief-summary[_ngcontent-%COMP%]:before{transform:rotate(90deg)}.brief-body[_ngcontent-%COMP%]{margin-bottom:12px}.link-row[_ngcontent-%COMP%]{padding:10px 12px}.link-target[_ngcontent-%COMP%]{font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.orphan-card[_ngcontent-%COMP%]{text-align:center;color:var(--error);margin-bottom:22px;border-color:#f2555a4d}.loading-detail[_ngcontent-%COMP%]{padding:40px 18px;color:var(--text-muted);font-size:13px;text-align:center}.save-error[_ngcontent-%COMP%]{padding:10px 14px;border:1px solid rgba(255,90,90,.35);background:var(--error-soft);color:var(--error);border-radius:8px;font-size:12.5px;line-height:1.5}.save-status[_ngcontent-%COMP%]{margin-top:8px;color:var(--text-muted);font-size:12px}.md-content[_ngcontent-%COMP%] .md-h1[_ngcontent-%COMP%]{font-size:15px;font-weight:650;color:var(--text-primary);letter-spacing:-.01em;margin:0 0 10px}.md-content[_ngcontent-%COMP%] .md-h2[_ngcontent-%COMP%]{font-size:13px;font-weight:650;color:var(--text-primary);letter-spacing:-.005em;margin:18px 0 6px;padding-bottom:4px;border-bottom:1px solid var(--border-subtle)}.md-content[_ngcontent-%COMP%] .md-h3[_ngcontent-%COMP%]{font-size:12px;font-weight:650;color:var(--text-primary);margin:14px 0 6px}.md-content[_ngcontent-%COMP%] .md-h4[_ngcontent-%COMP%]{font-size:10.5px;font-weight:700;text-transform:uppercase;letter-spacing:.06em;color:var(--text-muted);margin:12px 0 4px}.md-content[_ngcontent-%COMP%] .md-p[_ngcontent-%COMP%]{font-size:12.5px;line-height:1.6;color:var(--text-secondary);margin:0 0 4px;overflow-wrap:anywhere}.md-content[_ngcontent-%COMP%] .md-p[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--text-primary)}.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%], .md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%]{padding:0;margin:4px 0 6px}.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%] li[_ngcontent-%COMP%], .md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{position:relative;padding:2px 0 2px 22px;font-size:12.5px;line-height:1.6;color:var(--text-secondary);overflow-wrap:anywhere}.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%] li[_ngcontent-%COMP%] strong[_ngcontent-%COMP%], .md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--text-primary)}.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%]{list-style:none}.md-content[_ngcontent-%COMP%] .md-list[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:before{content:"\\2022";position:absolute;left:6px;top:2px;color:var(--text-faint)}.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%]{list-style:none;counter-reset:md-ol}.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{counter-increment:md-ol}.md-content[_ngcontent-%COMP%] .md-ol[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:before{content:counter(md-ol) ".";position:absolute;left:0;top:2px;color:var(--text-faint);font-family:var(--font-mono);font-size:11.5px;min-width:18px;text-align:right}.md-content[_ngcontent-%COMP%] .md-spacer[_ngcontent-%COMP%]{height:6px}.md-content[_ngcontent-%COMP%] .md-import[_ngcontent-%COMP%]{display:inline-block;font-size:11.5px;color:var(--node-route);background:var(--node-route-soft);padding:2px 8px;border-radius:5px;margin:4px 0}.md-content[_ngcontent-%COMP%] .md-inline-code[_ngcontent-%COMP%]{font-size:11.5px;background:var(--bg-canvas);padding:1px 6px;border-radius:4px;border:1px solid var(--border-subtle);color:var(--node-spec)}.md-content[_ngcontent-%COMP%] .md-blockquote[_ngcontent-%COMP%]{margin:6px 0;padding:8px 12px;border-left:3px solid var(--accent);background:var(--accent-soft);color:var(--text-secondary);font-size:12.5px;line-height:1.55;border-radius:0 6px 6px 0}.md-content[_ngcontent-%COMP%] .md-pre[_ngcontent-%COMP%]{position:relative;margin:8px 0 10px;padding:12px 14px;background:var(--bg-canvas);border:1px solid var(--border-subtle);border-radius:8px;overflow-x:auto;max-width:100%}.md-content[_ngcontent-%COMP%] .md-pre[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{display:block;font-size:11.5px;line-height:1.55;color:var(--text-primary);white-space:pre}.md-content[_ngcontent-%COMP%] .md-pre-lang[_ngcontent-%COMP%]{position:absolute;top:6px;right:10px;font-size:10px;font-weight:600;color:var(--text-muted);text-transform:lowercase;background:var(--bg-panel);padding:1px 6px;border-radius:4px;border:1px solid var(--border-subtle)}.md-content[_ngcontent-%COMP%] .md-table-scroll[_ngcontent-%COMP%]{max-width:100%;overflow-x:auto;margin:10px 0;border:1px solid var(--border-subtle);border-radius:8px}.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%]{width:100%;border-collapse:collapse;font-size:11.5px}.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] th[_ngcontent-%COMP%], .md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{padding:8px 12px;text-align:left;vertical-align:top;border-bottom:1px solid var(--border-subtle)}.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] thead[_ngcontent-%COMP%] th[_ngcontent-%COMP%]{background:var(--bg-panel);font-weight:650;color:var(--text-primary);font-size:10.5px;text-transform:uppercase;letter-spacing:.04em;border-bottom:1px solid var(--border-strong);white-space:nowrap}.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] td[_ngcontent-%COMP%]{color:var(--text-secondary)}.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:last-child td[_ngcontent-%COMP%]{border-bottom:0}.md-content[_ngcontent-%COMP%] .md-table[_ngcontent-%COMP%] tbody[_ngcontent-%COMP%] tr[_ngcontent-%COMP%]:hover{background:var(--bg-hover)}.md-content[_ngcontent-%COMP%] > [_ngcontent-%COMP%]:first-child{margin-top:0}'],changeDetection:0})};export{pe as Specs};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as N,b as D}from"./chunk-Y6WWDS4R.js";import{a as z}from"./chunk-UYC52MBC.js";import{a as T}from"./chunk-SUZYBYDW.js";import{a as M}from"./chunk-E44X4RH2.js";import{Aa as a,Ga as C,I as v,Ia as c,Ka as P,M as S,N as E,Ta as u,Ua as g,Va as n,W as f,Wa as b,ea as o,ka as w,qa as m,ra as x,sa as y,ua as k,va as _,wa as h,xa as s,ya as e,za as t,zb as O}from"./chunk-PDN6QYGJ.js";import"./chunk-Q7L6LLAK.js";var A=(r,l)=>l.model;function B(r,l){r&1&&n(0," Enabled \u2014 popups fire while the dashboard is open or backgrounded ")}function j(r,l){r&1&&n(0," Blocked \u2014 re-enable notifications for this site in your browser settings ")}function V(r,l){r&1&&n(0," Not supported in this browser ")}function $(r,l){r&1&&n(0," Get a desktop popup when a run needs approval, finishes, or drift appears ")}function F(r,l){if(r&1){let p=C();e(0,"button",50),c("click",function(){S(p);let d=P();return E(d.enableNotifications())}),n(1,"Enable"),t()}}function L(r,l){r&1&&(e(0,"span",24),n(1,"\u25CF On"),t())}function H(r,l){r&1&&(e(0,"span",25),n(1,"\u2014"),t())}function W(r,l){if(r&1&&(e(0,"div",34)(1,"span",51),n(2),t(),a(3,"input",52)(4,"input",52),t()),r&2){let p=l.$implicit;o(2),b(p.model),o(),s("value",p.input),o(),s("value",p.output)}}function q(r,l){if(r&1&&(e(0,"option"),n(1),t()),r&2){let p=l.$implicit;o(),b(p)}}var I=class r{api=v(M);theme=v(N);notify=v(D);setTheme(l){this.theme.setPref(l)}enableNotifications(){this.notify.requestPermission()}ingest=f(!0);watch=f(!0);motion=f(!1);toggleIngest(){this.ingest.update(l=>!l)}toggleWatch(){this.watch.update(l=>!l)}toggleMotion(){this.motion.update(l=>!l)}replayIntro(){try{sessionStorage.removeItem("specship-booted")}catch{}window.location.reload()}themeOptions=[{value:"dark",label:"Dark"},{value:"light",label:"Light"},{value:"system",label:"System"}];editorOptions=["code (VS Code)","subl (Sublime)","cursor","nvim"];pricing=[{model:"claude-opus-4",input:"15.00",output:"75.00"},{model:"claude-sonnet-4",input:"3.00",output:"15.00"},{model:"claude-haiku-4",input:"0.80",output:"4.00"}];static \u0275fac=function(p){return new(p||r)};static \u0275cmp=w({type:r,selectors:[["app-settings"]],decls:183,vars:42,consts:[[1,"settings-page","scroll-y"],["icon","settings","title","Settings"],[1,"settings-body"],[1,"card","card-pad","section-card"],[1,"section-head","row","gap-8"],["name","folder",2,"color","var(--accent)",3,"size"],[1,"section-title"],[1,"field"],[1,"field-label"],["value","~/dev/specship","readonly","",1,"input","mono",2,"width","100%"],[1,"field-hint"],["value","specs/",1,"input","mono",2,"width","100%"],["value","node_modules/, dist/, .cg/wt/",1,"input","mono",2,"width","100%"],["name","sessions",2,"color","var(--accent)",3,"size"],["value","~/.claude/projects/",1,"input","mono",2,"width","100%"],[1,"toggle-row","row"],[1,"grow"],[1,"toggle-label"],[1,"muted",2,"font-size","11px"],["type","button","aria-label","Enable transcript ingest",1,"toggle-btn",3,"click"],[1,"toggle-thumb"],["type","button","aria-label","Real-time watch",1,"toggle-btn",3,"click"],["name","zap",2,"color","var(--accent)",3,"size"],["type","button",2,"height","30px","padding","0 12px","border-radius","6px","border","1px solid var(--accent)","background","var(--accent)","color","#fff","font-size","12px","cursor","pointer"],[2,"font-size","12px","color","var(--accent)"],[1,"muted",2,"font-size","12px"],["type","button","aria-label","Notify when a run needs approval",1,"toggle-btn",3,"click"],["type","button","aria-label","Notify when a run completes or fails",1,"toggle-btn",3,"click"],["type","button","aria-label","Notify when drift is detected",1,"toggle-btn",3,"click"],["type","button","aria-label","Notify when a new improvement is found",1,"toggle-btn",3,"click"],["name","dollar",2,"color","var(--accent)",3,"size"],[1,"muted",2,"font-size","11.5px","margin-bottom","12px"],[1,"pricing-header","row"],[1,"price-col"],[1,"pricing-row","row"],["name","sparkles",2,"color","var(--accent)",3,"size"],[3,"change","value","options"],["type","button","aria-label","Reduced motion",1,"toggle-btn",3,"click"],[1,"toggle-row","row",2,"border-top","1px solid var(--border-subtle)","margin-top","4px","padding-top","8px"],["type","button",1,"btn","btn-secondary","btn-sm",3,"click"],["name","refresh",3,"size"],["name","reveal",2,"color","var(--accent)",3,"size"],[1,"input",2,"width","200px"],["name","graph",2,"color","var(--accent)",3,"size"],[1,"about-grid"],[1,"about-row","row"],[1,"mono",2,"font-size","12px"],[1,"mono",2,"font-size","12px","color","var(--success)"],[1,"status-dot",2,"background","var(--success)"],[2,"height","30px"],["type","button",2,"height","30px","padding","0 12px","border-radius","6px","border","1px solid var(--accent)","background","var(--accent)","color","#fff","font-size","12px","cursor","pointer",3,"click"],[1,"mono","grow",2,"font-size","12px"],[1,"input","mono","tabular","price-input",3,"value"]],template:function(p,i){if(p&1&&(e(0,"div",0),a(1,"app-page-head",1),e(2,"div",2)(3,"section",3)(4,"div",4),a(5,"app-icon",5),e(6,"span",6),n(7,"Project"),t()(),e(8,"div",7)(9,"label",8),n(10,"Project root"),t(),a(11,"input",9),e(12,"div",10),n(13,"Set at app open \xB7 read-only"),t()(),e(14,"div",7)(15,"label",8),n(16,"Spec roots"),t(),a(17,"input",11),t(),e(18,"div",7)(19,"label",8),n(20,"Ignore patterns"),t(),a(21,"input",12),t()(),e(22,"section",3)(23,"div",4),a(24,"app-icon",13),e(25,"span",6),n(26,"Claude Code"),t()(),e(27,"div",7)(28,"label",8),n(29,"Transcripts path"),t(),a(30,"input",14),e(31,"div",10),n(32,"Auto-detected \xB7 overridable"),t()(),e(33,"div",15)(34,"div",16)(35,"div",17),n(36,"Enable transcript ingest"),t(),e(37,"div",18),n(38,"Read JSONL transcripts for analytics"),t()(),e(39,"button",19),c("click",function(){return i.toggleIngest()}),a(40,"span",20),t()(),e(41,"div",15)(42,"div",16)(43,"div",17),n(44,"Real-time watch"),t(),e(45,"div",18),n(46,"Tail new transcript lines as they're written"),t()(),e(47,"button",21),c("click",function(){return i.toggleWatch()}),a(48,"span",20),t()()(),e(49,"section",3)(50,"div",4),a(51,"app-icon",22),e(52,"span",6),n(53,"Notifications"),t()(),e(54,"div",15)(55,"div",16)(56,"div",17),n(57,"Desktop notifications"),t(),e(58,"div",18),x(59,B,1,0)(60,j,1,0)(61,V,1,0)(62,$,1,0),t()(),x(63,F,2,0,"button",23)(64,L,2,0,"span",24)(65,H,2,0,"span",25),t(),e(66,"div",15)(67,"div",16)(68,"div",17),n(69,"Run needs approval"),t(),e(70,"div",18),n(71,"A workflow run paused at an approval gate"),t()(),e(72,"button",26),c("click",function(){return i.notify.toggle("approval")}),a(73,"span",20),t()(),e(74,"div",15)(75,"div",16)(76,"div",17),n(77,"Run completed or failed"),t(),e(78,"div",18),n(79,"A workflow run finished or errored"),t()(),e(80,"button",27),c("click",function(){return i.notify.toggle("runDone")}),a(81,"span",20),t()(),e(82,"div",15)(83,"div",16)(84,"div",17),n(85,"Drift detected"),t(),e(86,"div",18),n(87,"Spec \u2192 code drift appeared"),t()(),e(88,"button",28),c("click",function(){return i.notify.toggle("drift")}),a(89,"span",20),t()(),e(90,"div",15)(91,"div",16)(92,"div",17),n(93,"New improvement"),t(),e(94,"div",18),n(95,"A new high-severity self-improvement proposal was found"),t()(),e(96,"button",29),c("click",function(){return i.notify.toggle("reflect")}),a(97,"span",20),t()()(),e(98,"section",3)(99,"div",4),a(100,"app-icon",30),e(101,"span",6),n(102,"Pricing table"),t()(),e(103,"div",31),n(104,"Per-million-token prices. Bump these when Anthropic publishes new tiers."),t(),e(105,"div",32)(106,"span",16),n(107,"Model"),t(),e(108,"span",33),n(109,"Input $/M"),t(),e(110,"span",33),n(111,"Output $/M"),t()(),_(112,W,5,3,"div",34,A),t(),e(114,"section",3)(115,"div",4),a(116,"app-icon",35),e(117,"span",6),n(118,"Appearance"),t()(),e(119,"div",7)(120,"label",8),n(121,"Theme"),t(),e(122,"app-segmented",36),c("change",function(R){return i.setTheme(R)}),t(),e(123,"div",10),n(124,"Now fully supported \u2014 dark, light, or follow your OS"),t()(),e(125,"div",15)(126,"div",16)(127,"div",17),n(128,"Reduced motion"),t(),e(129,"div",18),n(130,"Honor OS preference \u2014 instant transitions"),t()(),e(131,"button",37),c("click",function(){return i.toggleMotion()}),a(132,"span",20),t()(),e(133,"div",38)(134,"div",16)(135,"div",17),n(136,"Boot animation"),t(),e(137,"div",18),n(138,"The graph-assembly splash on app launch"),t()(),e(139,"button",39),c("click",function(){return i.replayIntro()}),a(140,"app-icon",40),n(141," Replay intro "),t()()(),e(142,"section",3)(143,"div",4),a(144,"app-icon",41),e(145,"span",6),n(146,"Editor"),t()(),e(147,"div",7)(148,"label",8),n(149,"Open files with"),t(),e(150,"select",42),_(151,q,2,1,"option",null,k),t(),e(153,"div",10),n(154,"Detected via code / subl / etc."),t()()(),e(155,"section",3)(156,"div",4),a(157,"app-icon",43),e(158,"span",6),n(159,"About"),t()(),e(160,"div",44)(161,"div",45)(162,"span",25),n(163,"Version"),t(),e(164,"span",46),n(165,"0.4.0"),t()(),e(166,"div",45)(167,"span",25),n(168,"MCP server"),t(),e(169,"span",47),a(170,"span",48),n(171,"running "),t()(),e(172,"div",45)(173,"span",25),n(174,"Backend"),t(),e(175,"span",46),n(176),t()(),e(177,"div",45)(178,"span",25),n(179,"Log path"),t(),e(180,"span",46),n(181,"~/.cg/logs/desktop.log"),t()()()(),a(182,"div",49),t()()),p&2){let d;o(5),s("size",15),o(19),s("size",15),o(15),g("on",i.ingest()),m("aria-pressed",i.ingest()),o(8),g("on",i.watch()),m("aria-pressed",i.watch()),o(4),s("size",15),o(8),y((d=i.notify.permission())==="granted"?59:d==="denied"?60:d==="unsupported"?61:62),o(4),y(i.notify.permission()==="default"?63:i.notify.permission()==="granted"?64:65),o(3),u("opacity",i.notify.granted()?"1":"0.5"),o(6),g("on",i.notify.enabled("approval")),m("aria-pressed",i.notify.enabled("approval")),o(2),u("opacity",i.notify.granted()?"1":"0.5"),o(6),g("on",i.notify.enabled("runDone")),m("aria-pressed",i.notify.enabled("runDone")),o(2),u("opacity",i.notify.granted()?"1":"0.5"),o(6),g("on",i.notify.enabled("drift")),m("aria-pressed",i.notify.enabled("drift")),o(2),u("opacity",i.notify.granted()?"1":"0.5"),o(6),g("on",i.notify.enabled("reflect")),m("aria-pressed",i.notify.enabled("reflect")),o(4),s("size",15),o(12),h(i.pricing),o(4),s("size",15),o(6),s("value",i.theme.pref())("options",i.themeOptions),o(9),g("on",i.motion()),m("aria-pressed",i.motion()),o(9),s("size",13),o(4),s("size",15),o(7),h(i.editorOptions),o(6),s("size",15),o(19),b(i.api.isConfigured?i.api.apiBase:"not configured")}},dependencies:[O,z,T],styles:["[_nghost-%COMP%]{display:flex;flex:1;min-height:0}.settings-page[_ngcontent-%COMP%]{flex:1;padding:18px;overflow-y:auto}.settings-body[_ngcontent-%COMP%]{max-width:720px}.section-card[_ngcontent-%COMP%]{margin-bottom:14px}.section-head[_ngcontent-%COMP%]{align-items:center;margin-bottom:14px;padding-bottom:12px;border-bottom:1px solid var(--border-subtle)}.section-title[_ngcontent-%COMP%]{font-weight:600;font-size:13.5px}.field[_ngcontent-%COMP%]{margin-bottom:16px}.field-label[_ngcontent-%COMP%]{display:block;font-size:12.5px;font-weight:500;margin-bottom:6px;color:var(--text-primary)}.field-hint[_ngcontent-%COMP%]{color:var(--text-muted);font-size:11px;margin-top:5px}.toggle-row[_ngcontent-%COMP%]{align-items:center;padding:8px 0}.toggle-label[_ngcontent-%COMP%]{font-size:12.5px;font-weight:500}.toggle-btn[_ngcontent-%COMP%]{width:36px;height:20px;border-radius:999px;border:none;cursor:pointer;padding:2px;background:var(--bg-elevated);display:flex;justify-content:flex-start;align-items:center;transition:background .12s;flex-shrink:0}.toggle-btn.on[_ngcontent-%COMP%]{background:var(--accent);justify-content:flex-end}.toggle-btn[_ngcontent-%COMP%]:focus-visible{outline:2px solid var(--accent);outline-offset:2px}.toggle-thumb[_ngcontent-%COMP%]{width:16px;height:16px;border-radius:50%;background:#fff;flex-shrink:0}.pricing-header[_ngcontent-%COMP%]{font-size:10.5px;color:var(--text-muted);text-transform:uppercase;letter-spacing:.05em;font-weight:600;margin-bottom:6px}.pricing-row[_ngcontent-%COMP%]{padding:6px 0;border-top:1px solid var(--border-subtle);align-items:center;gap:10px}.price-col[_ngcontent-%COMP%]{width:110px;text-align:right}.price-input[_ngcontent-%COMP%]{width:100px;text-align:right;padding:4px 8px}.about-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:10px 20px}.about-row[_ngcontent-%COMP%]{justify-content:space-between;padding:5px 0;border-bottom:1px solid var(--border-subtle)}.status-dot[_ngcontent-%COMP%]{display:inline-block;width:6px;height:6px;border-radius:50%;margin-right:6px;vertical-align:middle}.muted[_ngcontent-%COMP%]{color:var(--text-muted)}.mono[_ngcontent-%COMP%]{font-family:var(--font-mono)}.grow[_ngcontent-%COMP%]{flex:1}"],changeDetection:0})};export{I as Settings};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{E as n,I as p,R as l,W as s,X as y,lb as f}from"./chunk-PDN6QYGJ.js";import{a as o,b as d}from"./chunk-Q7L6LLAK.js";var m="specship.theme",h=class i{destroyRef=p(l);pref=s(this.loadPref());effective=s("dark");constructor(){this.applyEffective();let e=window.matchMedia("(prefers-color-scheme: light)"),t=()=>{this.pref()==="system"&&this.applyEffective()};e.addEventListener("change",t),this.destroyRef.onDestroy(()=>e.removeEventListener("change",t)),y(()=>{let r=this.pref();try{localStorage.setItem(m,r)}catch{}this.applyEffective()})}setPref(e){this.pref.set(e)}toggle(){this.setPref(this.effective()==="dark"?"light":"dark")}loadPref(){try{let e=localStorage.getItem(m);if(e==="dark"||e==="light"||e==="system")return e}catch{}return"dark"}applyEffective(){let e=window.matchMedia("(prefers-color-scheme: light)").matches?"light":"dark",t=this.pref(),r=t==="system"?e:t;document.documentElement.setAttribute("data-theme",r),this.effective.set(r)}static \u0275fac=function(t){return new(t||i)};static \u0275prov=n({token:i,factory:i.\u0275fac,providedIn:"root"})};var u="specship.notify.prefs",a={approval:!0,runDone:!0,drift:!0,reflect:!0},g=class i{permission=s("default");prefs=s(this.loadPrefs());supported=f(()=>this.permission()!=="unsupported");granted=f(()=>this.permission()==="granted");constructor(){if(typeof window>"u"||typeof Notification>"u"){this.permission.set("unsupported");return}this.permission.set(Notification.permission)}enabled(e){return this.prefs()[e]!==!1}toggle(e){let t=d(o({},this.prefs()),{[e]:!this.enabled(e)});this.prefs.set(t),this.savePrefs(t)}async requestPermission(){if(typeof Notification>"u"){this.permission.set("unsupported");return}try{let e=await Notification.requestPermission();this.permission.set(e)}catch{}}notify(e,t,r={}){if(!(this.permission()!=="granted"||!this.enabled(e))&&!(typeof Notification>"u"))try{let c=new Notification(t,{body:r.body,tag:r.tag});r.onClick&&(c.onclick=()=>{try{window.focus()}catch{}r.onClick(),c.close()})}catch{}}loadPrefs(){if(typeof localStorage>"u")return o({},a);try{let e=localStorage.getItem(u);return e?o(o({},a),JSON.parse(e)):o({},a)}catch{return o({},a)}}savePrefs(e){if(!(typeof localStorage>"u"))try{localStorage.setItem(u,JSON.stringify(e))}catch{}}static \u0275fac=function(t){return new(t||i)};static \u0275prov=n({token:i,factory:i.\u0275fac,providedIn:"root"})};export{h as a,g as b};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as M}from"./chunk-X2HTISHL.js";import{a as W}from"./chunk-UYC52MBC.js";import{a as E}from"./chunk-WDU3WICG.js";import{c as P}from"./chunk-GR72OOCN.js";import{a as h}from"./chunk-7RNS77UP.js";import{a as b}from"./chunk-E44X4RH2.js";import{Aa as d,I as w,Ka as f,Va as a,Wa as p,Xa as k,bb as m,ea as n,ka as _,lb as C,ra as g,sa as u,ua as v,va as l,wa as s,xa as y,ya as r,za as i}from"./chunk-PDN6QYGJ.js";import"./chunk-Q7L6LLAK.js";var x=()=>[],j=(e,o)=>o.workflow.name,F=(e,o)=>o.name;function T(e,o){e&1&&d(0,"app-pick-project-empty",0)}function O(e,o){if(e&1&&(r(0,"code",12),a(1),i()),e&2){let t=o.$implicit;n(),p(t)}}function $(e,o){if(e&1&&(r(0,"code",14),a(1),i()),e&2){let t=o.$implicit;n(),k("$",t.name)}}function D(e,o){if(e&1&&(r(0,"span",13),a(1,"inputs"),i(),l(2,$,2,1,"code",14,F)),e&2){let t=f().$implicit;n(2),s(t.workflow.inputs??m(0,x))}}function I(e,o){if(e&1&&(r(0,"div",4)(1,"div",5)(2,"span",6),a(3),i(),r(4,"app-pill",7),a(5),i(),d(6,"span",8),i(),r(7,"div",9),a(8),i(),r(9,"div",10)(10,"span",11),a(11,"requires"),i(),l(12,O,2,1,"code",12,v),g(14,D,4,1),i()()),e&2){let t=o.$implicit,c=f(2);n(3),p(t.workflow.name),n(),y("color",c.scopeColor[t.scope])("bg",c.scopeBg[t.scope]),n(),p(t.scope),n(3),p(t.workflow.description||"\u2014"),n(4),s(t.workflow.requires??m(6,x)),n(2),u((t.workflow.inputs??m(7,x)).length>0?14:-1)}}function z(e,o){if(e&1&&(r(0,"div",1),d(1,"app-page-head",2),r(2,"div",3),l(3,I,15,8,"div",4,j),i()()),e&2){let t=f();n(3),s(t.entries())}}var S=class e{api=w(b);projects=w(h);resource=P(this.api,()=>`/api/workflows${this.projects.projectQuery()}`);entries=C(()=>this.resource.state().data?.workflows??[]);scopeColor={bundled:"var(--node-spec)",global:"var(--node-code)",project:"var(--node-route)"};scopeBg={bundled:"color-mix(in srgb, var(--node-spec) 14%, transparent)",global:"color-mix(in srgb, var(--node-code) 14%, transparent)",project:"color-mix(in srgb, var(--node-route) 14%, transparent)"};static \u0275fac=function(t){return new(t||e)};static \u0275cmp=_({type:e,selectors:[["app-workflows"]],decls:2,vars:1,consts:[["surface","Workflows"],[1,"scroll-y","wf-page"],["icon","workflow","title","Workflows","sub","Run a YAML-defined DAG of agent, shell and approval steps"],[1,"wf-grid"],[1,"card","card-pad","wf-card"],[1,"row","gap-8"],[1,"mono","wf-name"],[3,"color","bg"],[1,"grow"],[1,"secondary","wf-desc"],[1,"row","gap-6","wf-footer"],[1,"muted",2,"font-size","10.5px"],[1,"mono","wf-req-chip"],[1,"muted",2,"font-size","10.5px","margin-left","6px"],[1,"mono","wf-inp-chip"]],template:function(t,c){t&1&&g(0,T,1,0,"app-pick-project-empty",0)(1,z,5,0,"div",1),t&2&&u(c.resource.state().noProject?0:1)},dependencies:[E,W,M],styles:["[_nghost-%COMP%]{display:contents}.wf-page[_ngcontent-%COMP%]{flex:1;padding:18px}.wf-grid[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:12px}.wf-card[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:10px}.wf-name[_ngcontent-%COMP%]{font-size:13.5px;font-weight:600}.wf-desc[_ngcontent-%COMP%]{font-size:12.5px;line-height:1.5;min-height:36px}.wf-footer[_ngcontent-%COMP%]{flex-wrap:wrap;border-top:1px solid var(--border-subtle);padding-top:10px}.wf-req-chip[_ngcontent-%COMP%]{font-size:10.5px;color:var(--text-secondary);background:var(--bg-canvas);padding:1px 6px;border-radius:4px;font-family:var(--font-mono)}.wf-inp-chip[_ngcontent-%COMP%]{font-size:10.5px;color:var(--node-spec);background:var(--node-spec-soft);padding:1px 6px;border-radius:4px;font-family:var(--font-mono)}"],changeDetection:0})};export{S as Workflows};
|
|
Binary file
|
|
Binary file
|