@aayambansal/squint 0.5.1 → 0.6.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/App-HPUWFBRV.js +24 -0
- package/dist/{cdp-D2F4P7UQ.js → cdp-RFQCIQFP.js} +1 -1
- package/dist/{chrome-EEXJCG6W.js → chrome-CAN7TVH6.js} +2 -2
- package/dist/{chunk-2NYNTVMX.js → chunk-2KJLEM53.js} +2 -2
- package/dist/{chunk-VJ2QKHYK.js → chunk-3GHZOVAA.js} +1 -1
- package/dist/{chunk-ERF2SPUW.js → chunk-7FAS2O3L.js} +9 -8
- package/dist/{chunk-AMA3F2Y2.js → chunk-BYT6OOGK.js} +1 -1
- package/dist/{chunk-GV2HAALP.js → chunk-DABIMOMV.js} +136 -1
- package/dist/{chunk-6NPUVPQD.js → chunk-DOWWBLX2.js} +1 -1
- package/dist/{chunk-J7ITMK6X.js → chunk-GDGKEMBS.js} +1 -1
- package/dist/{chunk-4XSHHGA6.js → chunk-K7JNVCCU.js} +38 -1
- package/dist/{chunk-2I3YHT6P.js → chunk-KNPLVGZB.js} +3 -3
- package/dist/{chunk-3YCG234A.js → chunk-P6D4RSWD.js} +1 -1
- package/dist/{chunk-PYC53J7D.js → chunk-PZV2FJE5.js} +1 -1
- package/dist/{chunk-G5NS2IFQ.js → chunk-VCDZGQBB.js} +27 -11
- package/dist/cli.js +33 -28
- package/dist/{commands-WC7V6EAE.js → commands-RVCKIMNV.js} +1 -1
- package/dist/flows-G5K3XYQZ.js +13 -0
- package/dist/{preview-JN5PTWLX.js → preview-WYFBPFFL.js} +4 -4
- package/dist/receipts-INSRID6M.js +60 -0
- package/dist/{registry-JBP7J3JB.js → registry-ZCCZVXSX.js} +1 -1
- package/dist/{remote-UOV4ZXWU.js → remote-WS6XGUBU.js} +9 -9
- package/dist/{run-GDDIYEBP.js → run-IAA2C5LM.js} +2 -2
- package/dist/{server-2WPGU3KQ.js → server-BCHVAJJQ.js} +6 -6
- package/dist/shots-HDHPCENU.js +13 -0
- package/dist/{variants-VURXVIQO.js → variants-WBRY2U37.js} +3 -3
- package/package.json +1 -1
- package/dist/App-KTNAMHY6.js +0 -24
- package/dist/flows-MXJL45HW.js +0 -11
- package/dist/shots-6DRTXFDI.js +0 -13
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
App
|
|
4
|
+
} from "./chunk-2KJLEM53.js";
|
|
5
|
+
import "./chunk-3GHZOVAA.js";
|
|
6
|
+
import "./chunk-VCDZGQBB.js";
|
|
7
|
+
import "./chunk-UBADCBPT.js";
|
|
8
|
+
import "./chunk-IEQGTVWN.js";
|
|
9
|
+
import "./chunk-AUJJGMZG.js";
|
|
10
|
+
import "./chunk-YHRAOBI2.js";
|
|
11
|
+
import "./chunk-KNPLVGZB.js";
|
|
12
|
+
import "./chunk-GDGKEMBS.js";
|
|
13
|
+
import "./chunk-DOWWBLX2.js";
|
|
14
|
+
import "./chunk-K5QJMSJH.js";
|
|
15
|
+
import "./chunk-WAJXATCO.js";
|
|
16
|
+
import "./chunk-62JNF5M2.js";
|
|
17
|
+
import "./chunk-7FAS2O3L.js";
|
|
18
|
+
import "./chunk-7CAGWFAQ.js";
|
|
19
|
+
import "./chunk-P6D4RSWD.js";
|
|
20
|
+
import "./chunk-PZV2FJE5.js";
|
|
21
|
+
import "./chunk-DABIMOMV.js";
|
|
22
|
+
export {
|
|
23
|
+
App
|
|
24
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
completeCommand
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-3GHZOVAA.js";
|
|
5
5
|
import {
|
|
6
6
|
Session
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-VCDZGQBB.js";
|
|
8
8
|
|
|
9
9
|
// src/tui/App.tsx
|
|
10
10
|
import { Box as Box3, Static, Text as Text3, useApp, useInput } from "ink";
|
|
@@ -15,7 +15,7 @@ var COMMANDS = [
|
|
|
15
15
|
{ name: "review", args: "[focus]", group: "verify", description: "screenshots + the engine critiques its own rendered work" },
|
|
16
16
|
{ name: "polish", args: "[1-5]", group: "verify", description: "unattended rounds of review \u2192 fix (default 2)" },
|
|
17
17
|
{ name: "score", group: "verify", description: "deterministic quality snapshot (problems, a11y, tells, runtime, LCP)" },
|
|
18
|
-
{ name: "flows", args: "[name]", group: "verify", description: "replay declared
|
|
18
|
+
{ name: "flows", args: "[name]", group: "verify", description: "replay declared journeys; /flows suggest drafts them from live routes" },
|
|
19
19
|
{ name: "variants", args: "<2-4> <ask>", group: "explore", description: "parallel design explorations; apply/list/clean" },
|
|
20
20
|
{ name: "sandbox", args: "[on|diff|apply|discard]", group: "explore", description: "asks accumulate in a shadow worktree until you apply" },
|
|
21
21
|
{ name: "undo", group: "explore", description: "revert the last ask (files only)" },
|
|
@@ -5,11 +5,11 @@ import {
|
|
|
5
5
|
import {
|
|
6
6
|
cdpCapture,
|
|
7
7
|
hasWebSocket
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-P6D4RSWD.js";
|
|
9
9
|
import {
|
|
10
10
|
findChrome,
|
|
11
11
|
screenshot
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-PZV2FJE5.js";
|
|
13
13
|
|
|
14
14
|
// src/preview/preview.ts
|
|
15
15
|
import fs2 from "fs";
|
|
@@ -21,7 +21,7 @@ import fs from "fs";
|
|
|
21
21
|
import path from "path";
|
|
22
22
|
var MAX_CHECKS = 20;
|
|
23
23
|
var MAX_BYTES = 1e4;
|
|
24
|
-
function loadChecks(cwd) {
|
|
24
|
+
function loadChecks(cwd, context = "audit") {
|
|
25
25
|
const dir = path.join(cwd, ".squint", "checks");
|
|
26
26
|
let entries;
|
|
27
27
|
try {
|
|
@@ -34,11 +34,12 @@ function loadChecks(cwd) {
|
|
|
34
34
|
try {
|
|
35
35
|
const source = fs.readFileSync(path.join(dir, entry), "utf8");
|
|
36
36
|
if (source.trim().length === 0 || Buffer.byteLength(source) > MAX_BYTES) continue;
|
|
37
|
-
|
|
37
|
+
const pragma = /^\s*\/\/\s*squint-trigger:\s*(turn|audit)/.exec(source);
|
|
38
|
+
checks.push({ name: entry.replace(/\.js$/, ""), source, trigger: pragma?.[1] === "audit" ? "audit" : "turn" });
|
|
38
39
|
} catch {
|
|
39
40
|
}
|
|
40
41
|
}
|
|
41
|
-
return checks;
|
|
42
|
+
return context === "audit" ? checks : checks.filter((c) => c.trigger === "turn");
|
|
42
43
|
}
|
|
43
44
|
|
|
44
45
|
// src/preview/preview.ts
|
|
@@ -153,7 +154,7 @@ async function probeRuntime(url, cwd) {
|
|
|
153
154
|
cwd ? [{ name: "pulse", width: 1280, height: 800 }] : [],
|
|
154
155
|
1500,
|
|
155
156
|
false,
|
|
156
|
-
cwd ? loadChecks(cwd) : []
|
|
157
|
+
cwd ? loadChecks(cwd, "turn") : []
|
|
157
158
|
);
|
|
158
159
|
return { report, pulsePath: shots[0]?.path, perf, checkFailures };
|
|
159
160
|
} catch {
|
|
@@ -163,13 +164,13 @@ async function probeRuntime(url, cwd) {
|
|
|
163
164
|
async function comparePulse(previous, current) {
|
|
164
165
|
const chrome = findChrome();
|
|
165
166
|
if (!chrome || !hasWebSocket()) return null;
|
|
166
|
-
const { pixelDiffPct } = await import("./cdp-
|
|
167
|
+
const { pixelDiffPct } = await import("./cdp-RFQCIQFP.js");
|
|
167
168
|
return pixelDiffPct(chrome, previous, current);
|
|
168
169
|
}
|
|
169
170
|
async function comparePulseAttributed(previous, current, url) {
|
|
170
171
|
const chrome = findChrome();
|
|
171
172
|
if (!chrome || !hasWebSocket()) return null;
|
|
172
|
-
const { pixelDiffAttributed } = await import("./cdp-
|
|
173
|
+
const { pixelDiffAttributed } = await import("./cdp-RFQCIQFP.js");
|
|
173
174
|
return pixelDiffAttributed(chrome, previous, current, url);
|
|
174
175
|
}
|
|
175
176
|
function buildRuntimeFixPrompt(report) {
|
|
@@ -271,6 +271,141 @@ function itemToEvents(item, phase) {
|
|
|
271
271
|
}
|
|
272
272
|
}
|
|
273
273
|
|
|
274
|
+
// src/engines/codexApp.ts
|
|
275
|
+
var DRIVER_SOURCE = String.raw`
|
|
276
|
+
const { spawn } = require('node:child_process');
|
|
277
|
+
const opts = JSON.parse(process.argv[1]);
|
|
278
|
+
const bin = process.env.SQUINT_CODEX_BIN || 'codex';
|
|
279
|
+
const child = spawn(bin, ['app-server'], { stdio: ['pipe', 'pipe', 'pipe'], cwd: opts.cwd });
|
|
280
|
+
const emit = (obj) => process.stdout.write(JSON.stringify(obj) + '\n');
|
|
281
|
+
const send = (msg) => child.stdin.write(JSON.stringify(msg) + '\n');
|
|
282
|
+
let threadId = opts.resume || null;
|
|
283
|
+
let done = false;
|
|
284
|
+
const finish = (ok, error) => {
|
|
285
|
+
if (done) return;
|
|
286
|
+
done = true;
|
|
287
|
+
emit({ kind: 'result', ok, sessionId: threadId || undefined, error });
|
|
288
|
+
try { child.kill(); } catch {}
|
|
289
|
+
process.exit(ok ? 0 : 1);
|
|
290
|
+
};
|
|
291
|
+
process.on('SIGTERM', () => finish(false, 'interrupted'));
|
|
292
|
+
process.on('SIGINT', () => finish(false, 'interrupted'));
|
|
293
|
+
setTimeout(() => finish(false, 'app-server timeout'), 30 * 60 * 1000).unref();
|
|
294
|
+
child.on('exit', () => finish(false, 'app-server exited early'));
|
|
295
|
+
child.stderr.on('data', () => {});
|
|
296
|
+
let buf = '';
|
|
297
|
+
child.stdout.on('data', (chunk) => {
|
|
298
|
+
buf += chunk.toString();
|
|
299
|
+
let idx;
|
|
300
|
+
while ((idx = buf.indexOf('\n')) >= 0) {
|
|
301
|
+
const line = buf.slice(0, idx);
|
|
302
|
+
buf = buf.slice(idx + 1);
|
|
303
|
+
if (!line.trim()) continue;
|
|
304
|
+
let msg;
|
|
305
|
+
try { msg = JSON.parse(line); } catch { continue; }
|
|
306
|
+
if (msg.error && msg.id !== undefined) return finish(false, String(msg.error.message || 'app-server error'));
|
|
307
|
+
if (msg.id === 1 && msg.result !== undefined) {
|
|
308
|
+
send({ jsonrpc: '2.0', method: 'initialized' });
|
|
309
|
+
if (threadId) send({ jsonrpc: '2.0', id: 2, method: 'thread/resume', params: { threadId } });
|
|
310
|
+
else send({ jsonrpc: '2.0', id: 2, method: 'thread/start', params: {
|
|
311
|
+
cwd: opts.cwd, sandbox: opts.sandbox, approvalPolicy: 'never', model: opts.model || null,
|
|
312
|
+
} });
|
|
313
|
+
continue;
|
|
314
|
+
}
|
|
315
|
+
if (msg.id === 2 && msg.result !== undefined) {
|
|
316
|
+
threadId = (msg.result.thread && msg.result.thread.id) || msg.result.threadId || threadId;
|
|
317
|
+
send({ jsonrpc: '2.0', id: 3, method: 'turn/start', params: {
|
|
318
|
+
threadId, input: [{ type: 'text', text: opts.prompt }],
|
|
319
|
+
model: opts.model || null, sandboxPolicy: null, cwd: opts.cwd,
|
|
320
|
+
} });
|
|
321
|
+
continue;
|
|
322
|
+
}
|
|
323
|
+
switch (msg.method) {
|
|
324
|
+
case 'item/agentMessage/delta':
|
|
325
|
+
emit({ kind: 'delta', text: msg.params.delta });
|
|
326
|
+
break;
|
|
327
|
+
case 'item/reasoning/summaryTextDelta':
|
|
328
|
+
case 'item/reasoning/textDelta':
|
|
329
|
+
emit({ kind: 'thinking' });
|
|
330
|
+
break;
|
|
331
|
+
case 'item/started': {
|
|
332
|
+
const item = msg.params.item || {};
|
|
333
|
+
if (item.type === 'commandExecution') emit({ kind: 'tool', name: 'shell', detail: item.command });
|
|
334
|
+
else if (item.type === 'fileChange') emit({ kind: 'tool', name: 'edit', detail: item.path });
|
|
335
|
+
else if (item.type === 'mcpToolCall') emit({ kind: 'tool', name: item.tool || 'mcp' });
|
|
336
|
+
else if (item.type === 'webSearch') emit({ kind: 'tool', name: 'search' });
|
|
337
|
+
break;
|
|
338
|
+
}
|
|
339
|
+
case 'item/completed': {
|
|
340
|
+
const item = msg.params.item || {};
|
|
341
|
+
if (item.type === 'agentMessage' && item.text) emit({ kind: 'message', text: item.text });
|
|
342
|
+
break;
|
|
343
|
+
}
|
|
344
|
+
case 'error':
|
|
345
|
+
emit({ kind: 'note', text: String((msg.params && msg.params.message) || 'error') });
|
|
346
|
+
break;
|
|
347
|
+
case 'turn/completed': {
|
|
348
|
+
const status = msg.params && msg.params.turn && msg.params.turn.status;
|
|
349
|
+
finish(status === 'completed', status === 'completed' ? undefined : String(status));
|
|
350
|
+
break;
|
|
351
|
+
}
|
|
352
|
+
}
|
|
353
|
+
}
|
|
354
|
+
});
|
|
355
|
+
send({ jsonrpc: '2.0', id: 1, method: 'initialize', params: { clientInfo: { name: 'squint', title: 'squint', version: '0' } } });
|
|
356
|
+
`;
|
|
357
|
+
var codexApp = {
|
|
358
|
+
id: "codex-app",
|
|
359
|
+
name: "Codex (app-server)",
|
|
360
|
+
binary: "node",
|
|
361
|
+
install: "npm install -g @openai/codex (requires codex on PATH)",
|
|
362
|
+
supportsResume: true,
|
|
363
|
+
env: {},
|
|
364
|
+
buildArgs(opts) {
|
|
365
|
+
const sandbox = opts.mode === "plan" ? "read-only" : opts.mode === "yolo" ? "danger-full-access" : "workspace-write";
|
|
366
|
+
const payload = {
|
|
367
|
+
prompt: opts.prompt,
|
|
368
|
+
cwd: opts.cwd,
|
|
369
|
+
model: opts.model,
|
|
370
|
+
sandbox,
|
|
371
|
+
resume: opts.sessionId
|
|
372
|
+
};
|
|
373
|
+
return ["-e", DRIVER_SOURCE, JSON.stringify(payload)];
|
|
374
|
+
},
|
|
375
|
+
createParser() {
|
|
376
|
+
let streamed = false;
|
|
377
|
+
return (line) => {
|
|
378
|
+
let data;
|
|
379
|
+
try {
|
|
380
|
+
data = JSON.parse(line);
|
|
381
|
+
} catch {
|
|
382
|
+
return [];
|
|
383
|
+
}
|
|
384
|
+
switch (data.kind) {
|
|
385
|
+
case "delta":
|
|
386
|
+
streamed = true;
|
|
387
|
+
return [{ type: "delta", text: data.text ?? "" }];
|
|
388
|
+
case "message":
|
|
389
|
+
if (streamed) {
|
|
390
|
+
streamed = false;
|
|
391
|
+
return [{ type: "text", text: data.text ?? "", streamed: true }];
|
|
392
|
+
}
|
|
393
|
+
return [{ type: "text", text: data.text ?? "" }];
|
|
394
|
+
case "thinking":
|
|
395
|
+
return [{ type: "thinking", text: "" }];
|
|
396
|
+
case "tool":
|
|
397
|
+
return [{ type: "tool", name: data.detail ? `${data.name}: ${truncate(data.detail, 80)}` : data.name ?? "tool" }];
|
|
398
|
+
case "note":
|
|
399
|
+
return [{ type: "status", text: data.text ?? "" }];
|
|
400
|
+
case "result":
|
|
401
|
+
return [{ type: "result", ok: data.ok === true, sessionId: data.sessionId, summary: data.error }];
|
|
402
|
+
default:
|
|
403
|
+
return [];
|
|
404
|
+
}
|
|
405
|
+
};
|
|
406
|
+
}
|
|
407
|
+
};
|
|
408
|
+
|
|
274
409
|
// src/engines/copilot.ts
|
|
275
410
|
var copilot = {
|
|
276
411
|
id: "copilot",
|
|
@@ -419,7 +554,7 @@ var opencode = {
|
|
|
419
554
|
};
|
|
420
555
|
|
|
421
556
|
// src/engines/registry.ts
|
|
422
|
-
var engines = [claude, codex, gemini, opencode, amp, cursor, copilot, aider];
|
|
557
|
+
var engines = [claude, codex, codexApp, gemini, opencode, amp, cursor, copilot, aider];
|
|
423
558
|
function getEngine(id) {
|
|
424
559
|
const engine = engines.find((e) => e.id === id);
|
|
425
560
|
if (!engine) {
|
|
@@ -140,9 +140,46 @@ function stepExpression(step) {
|
|
|
140
140
|
return null;
|
|
141
141
|
}
|
|
142
142
|
}
|
|
143
|
+
async function suggestFlows(cwd, baseUrl, chromePath) {
|
|
144
|
+
const fs2 = await import("fs");
|
|
145
|
+
const path2 = await import("path");
|
|
146
|
+
const { cdpCapture } = await import("./cdp-RFQCIQFP.js");
|
|
147
|
+
const { loadRoutes } = await import("./preview-WYFBPFFL.js");
|
|
148
|
+
const dir = path2.join(cwd, ".squint", "flows");
|
|
149
|
+
fs2.mkdirSync(dir, { recursive: true });
|
|
150
|
+
const created = [];
|
|
151
|
+
const skipped = [];
|
|
152
|
+
for (const route of loadRoutes(cwd)) {
|
|
153
|
+
const slug = route === "/" ? "home" : route.replace(/^\//, "").replace(/[^a-z0-9]+/gi, "-").toLowerCase();
|
|
154
|
+
const file = path2.join(dir, `${slug}.flow`);
|
|
155
|
+
if (fs2.existsSync(file)) {
|
|
156
|
+
skipped.push(slug);
|
|
157
|
+
continue;
|
|
158
|
+
}
|
|
159
|
+
const url = new URL(route, baseUrl).toString();
|
|
160
|
+
const shotDir = fs2.mkdtempSync(path2.join((await import("os")).tmpdir(), "squint-suggest-"));
|
|
161
|
+
let heading = null;
|
|
162
|
+
try {
|
|
163
|
+
const capture = await cdpCapture(chromePath, url, shotDir, [], 1200, true);
|
|
164
|
+
const match = capture.narration.map((n) => /^heading \d: "(.+)"$/.exec(n)).find(Boolean);
|
|
165
|
+
heading = match?.[1] ?? null;
|
|
166
|
+
} catch {
|
|
167
|
+
} finally {
|
|
168
|
+
fs2.rmSync(shotDir, { recursive: true, force: true });
|
|
169
|
+
}
|
|
170
|
+
const lines = [`goto ${route}`];
|
|
171
|
+
if (heading) lines.push(`expect ${heading}`);
|
|
172
|
+
lines.push(`shot ${slug}`);
|
|
173
|
+
fs2.writeFileSync(file, `${lines.join("\n")}
|
|
174
|
+
`);
|
|
175
|
+
created.push(slug);
|
|
176
|
+
}
|
|
177
|
+
return { created, skipped };
|
|
178
|
+
}
|
|
143
179
|
|
|
144
180
|
export {
|
|
145
181
|
parseFlow,
|
|
146
182
|
loadFlows,
|
|
147
|
-
stepExpression
|
|
183
|
+
stepExpression,
|
|
184
|
+
suggestFlows
|
|
148
185
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
variantsRoot
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-GDGKEMBS.js";
|
|
5
5
|
import {
|
|
6
6
|
findChrome,
|
|
7
7
|
screenshot
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-PZV2FJE5.js";
|
|
9
9
|
import {
|
|
10
10
|
lineSplitter
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-DABIMOMV.js";
|
|
12
12
|
|
|
13
13
|
// src/variants/shots.ts
|
|
14
14
|
import path2 from "path";
|
|
@@ -179,7 +179,7 @@ var describe = (value) => {
|
|
|
179
179
|
return String(value);
|
|
180
180
|
};
|
|
181
181
|
async function runFlow(chromePath, baseUrl, flow, outDir) {
|
|
182
|
-
const { stepExpression } = await import("./flows-
|
|
182
|
+
const { stepExpression } = await import("./flows-G5K3XYQZ.js");
|
|
183
183
|
const { child, wsUrl, profileDir } = await launchChrome(chromePath);
|
|
184
184
|
const shots = [];
|
|
185
185
|
let connection = null;
|
|
@@ -25,16 +25,16 @@ import {
|
|
|
25
25
|
buildFixPrompt,
|
|
26
26
|
detectDevCommand,
|
|
27
27
|
screenshotVariants
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-KNPLVGZB.js";
|
|
29
29
|
import {
|
|
30
30
|
applyVariant,
|
|
31
31
|
cleanVariants,
|
|
32
32
|
listVariants,
|
|
33
33
|
runVariants
|
|
34
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-GDGKEMBS.js";
|
|
35
35
|
import {
|
|
36
36
|
runAgent
|
|
37
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-DOWWBLX2.js";
|
|
38
38
|
import {
|
|
39
39
|
composePrompt
|
|
40
40
|
} from "./chunk-WAJXATCO.js";
|
|
@@ -51,7 +51,7 @@ import {
|
|
|
51
51
|
comparePulseAttributed,
|
|
52
52
|
probeRuntime,
|
|
53
53
|
runtimeSummary
|
|
54
|
-
} from "./chunk-
|
|
54
|
+
} from "./chunk-7FAS2O3L.js";
|
|
55
55
|
import {
|
|
56
56
|
clearState,
|
|
57
57
|
loadState,
|
|
@@ -59,10 +59,10 @@ import {
|
|
|
59
59
|
} from "./chunk-7CAGWFAQ.js";
|
|
60
60
|
import {
|
|
61
61
|
findChrome
|
|
62
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-PZV2FJE5.js";
|
|
63
63
|
import {
|
|
64
64
|
getEngine
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-DABIMOMV.js";
|
|
66
66
|
|
|
67
67
|
// src/session/engine.ts
|
|
68
68
|
import fs2 from "fs";
|
|
@@ -873,7 +873,7 @@ They are objective defects, not style preferences.`
|
|
|
873
873
|
const arg = rest.join(" ").trim();
|
|
874
874
|
switch (name) {
|
|
875
875
|
case "engines": {
|
|
876
|
-
void import("./registry-
|
|
876
|
+
void import("./registry-ZCCZVXSX.js").then(({ detectEngines }) => {
|
|
877
877
|
const lines = detectEngines().map(({ engine, path: binaryPath }) => {
|
|
878
878
|
const mark = binaryPath ? "\u2713" : "\u2717";
|
|
879
879
|
const traits = [engine.createParser ? "stream" : "text", engine.supportsResume ? "resume" : null].filter(Boolean).join(" \xB7 ");
|
|
@@ -1122,8 +1122,24 @@ every ask now carries it; auto-fix presses to ${MAX_GOAL_FIX_ATTEMPTS} attempts
|
|
|
1122
1122
|
this.push("error", "dev server not running \u2014 /dev first");
|
|
1123
1123
|
break;
|
|
1124
1124
|
}
|
|
1125
|
+
if (arg.trim() === "suggest") {
|
|
1126
|
+
void (async () => {
|
|
1127
|
+
const chrome = findChrome();
|
|
1128
|
+
if (!chrome) {
|
|
1129
|
+
this.push("error", "no Chrome/Chromium found");
|
|
1130
|
+
return;
|
|
1131
|
+
}
|
|
1132
|
+
const { suggestFlows } = await import("./flows-G5K3XYQZ.js");
|
|
1133
|
+
this.push("status", "drafting flows from the live routes\u2026");
|
|
1134
|
+
const { created, skipped } = await suggestFlows(this.opts.cwd, this.state.devUrl, chrome);
|
|
1135
|
+
if (created.length > 0) this.push("status", `drafted ${created.length} flow(s): ${created.join(", ")} \u2014 edit .squint/flows/*.flow or ask the engine to deepen them`);
|
|
1136
|
+
if (skipped.length > 0) this.push("status", `kept existing: ${skipped.join(", ")}`);
|
|
1137
|
+
if (created.length === 0 && skipped.length === 0) this.push("status", "no routes to draft from \u2014 add .squint/routes");
|
|
1138
|
+
})();
|
|
1139
|
+
break;
|
|
1140
|
+
}
|
|
1125
1141
|
void (async () => {
|
|
1126
|
-
const { loadFlows } = await import("./flows-
|
|
1142
|
+
const { loadFlows } = await import("./flows-G5K3XYQZ.js");
|
|
1127
1143
|
const flows = loadFlows(this.opts.cwd);
|
|
1128
1144
|
if (flows.length === 0) {
|
|
1129
1145
|
this.push("status", "no flows \u2014 add .squint/flows/<name>.flow (goto/click/fill/press/expect/shot lines), or ask the engine to write one");
|
|
@@ -1134,8 +1150,8 @@ every ask now carries it; auto-fix presses to ${MAX_GOAL_FIX_ATTEMPTS} attempts
|
|
|
1134
1150
|
this.push("error", "no Chrome/Chromium found for flows");
|
|
1135
1151
|
return;
|
|
1136
1152
|
}
|
|
1137
|
-
const { runFlow } = await import("./cdp-
|
|
1138
|
-
const { previewDir } = await import("./preview-
|
|
1153
|
+
const { runFlow } = await import("./cdp-RFQCIQFP.js");
|
|
1154
|
+
const { previewDir } = await import("./preview-WYFBPFFL.js");
|
|
1139
1155
|
this.push("status", `replaying ${flows.length} flow(s)\u2026`);
|
|
1140
1156
|
this.notify({ running: true, runStartedAt: Date.now() });
|
|
1141
1157
|
const failures = [];
|
|
@@ -1459,7 +1475,7 @@ ${sandboxFiles(this.opts.cwd).join("\n")}`);
|
|
|
1459
1475
|
this.notify({ items: [], totals: { costUsd: 0, turns: 0 } });
|
|
1460
1476
|
break;
|
|
1461
1477
|
case "help": {
|
|
1462
|
-
void import("./commands-
|
|
1478
|
+
void import("./commands-RVCKIMNV.js").then(({ commandHelp }) => this.push("status", commandHelp()));
|
|
1463
1479
|
break;
|
|
1464
1480
|
}
|
|
1465
1481
|
case "quit":
|
package/dist/cli.js
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
App
|
|
4
|
-
} from "./chunk-
|
|
5
|
-
import "./chunk-
|
|
4
|
+
} from "./chunk-2KJLEM53.js";
|
|
5
|
+
import "./chunk-3GHZOVAA.js";
|
|
6
6
|
import {
|
|
7
7
|
connectDaemon,
|
|
8
8
|
socketPath,
|
|
9
9
|
startDaemon
|
|
10
|
-
} from "./chunk-
|
|
11
|
-
import "./chunk-
|
|
10
|
+
} from "./chunk-BYT6OOGK.js";
|
|
11
|
+
import "./chunk-VCDZGQBB.js";
|
|
12
12
|
import "./chunk-UBADCBPT.js";
|
|
13
13
|
import "./chunk-IEQGTVWN.js";
|
|
14
14
|
import "./chunk-AUJJGMZG.js";
|
|
15
15
|
import "./chunk-YHRAOBI2.js";
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-KNPLVGZB.js";
|
|
17
|
+
import "./chunk-GDGKEMBS.js";
|
|
18
18
|
import {
|
|
19
19
|
runAgent
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-DOWWBLX2.js";
|
|
21
21
|
import "./chunk-K5QJMSJH.js";
|
|
22
22
|
import {
|
|
23
23
|
composePrompt
|
|
24
24
|
} from "./chunk-WAJXATCO.js";
|
|
25
25
|
import "./chunk-62JNF5M2.js";
|
|
26
|
-
import "./chunk-
|
|
26
|
+
import "./chunk-7FAS2O3L.js";
|
|
27
27
|
import "./chunk-7CAGWFAQ.js";
|
|
28
|
-
import "./chunk-
|
|
29
|
-
import "./chunk-
|
|
28
|
+
import "./chunk-P6D4RSWD.js";
|
|
29
|
+
import "./chunk-PZV2FJE5.js";
|
|
30
30
|
import {
|
|
31
31
|
detectEngines,
|
|
32
32
|
getEngine
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-DABIMOMV.js";
|
|
34
34
|
|
|
35
35
|
// src/cli.tsx
|
|
36
36
|
import { Command } from "commander";
|
|
@@ -187,18 +187,18 @@ function registerDaemon(program2) {
|
|
|
187
187
|
process.on("SIGTERM", stop);
|
|
188
188
|
});
|
|
189
189
|
program2.command("mcp").description("serve the gates as MCP tools over stdio (check, shot, flows, context)").action(async () => {
|
|
190
|
-
const { runMcpServer } = await import("./server-
|
|
190
|
+
const { runMcpServer } = await import("./server-BCHVAJJQ.js");
|
|
191
191
|
runMcpServer(process.cwd());
|
|
192
192
|
});
|
|
193
193
|
program2.command("attach").description("attach this terminal to a running squint daemon (full TUI; --plain for line mode)").option("--plain", "line-mode attach instead of the full TUI").action(async (opts) => {
|
|
194
194
|
const cwd = process.cwd();
|
|
195
195
|
if (!opts.plain) {
|
|
196
196
|
try {
|
|
197
|
-
const { RemoteSession } = await import("./remote-
|
|
197
|
+
const { RemoteSession } = await import("./remote-WS6XGUBU.js");
|
|
198
198
|
const remote = await RemoteSession.connect(cwd);
|
|
199
199
|
const config = loadConfig(defaultPaths(cwd));
|
|
200
200
|
const { render: render2 } = await import("ink");
|
|
201
|
-
const { App: App2 } = await import("./App-
|
|
201
|
+
const { App: App2 } = await import("./App-HPUWFBRV.js");
|
|
202
202
|
const React = await import("react");
|
|
203
203
|
render2(
|
|
204
204
|
React.createElement(App2, {
|
|
@@ -292,7 +292,7 @@ function registerEnv(program2) {
|
|
|
292
292
|
console.log(`${status} ${engine.name}${binaryPath ? "" : pc3.dim(` \u2014 install: ${engine.install}`)}`);
|
|
293
293
|
}
|
|
294
294
|
if (options.probe) {
|
|
295
|
-
const { runAgent: runAgent2 } = await import("./run-
|
|
295
|
+
const { runAgent: runAgent2 } = await import("./run-IAA2C5LM.js");
|
|
296
296
|
console.log(pc3.dim("\nprobing engines with a one-word prompt (verifies auth end to end)\u2026"));
|
|
297
297
|
for (const { engine, path: binaryPath } of detected) {
|
|
298
298
|
if (!binaryPath) continue;
|
|
@@ -314,8 +314,8 @@ function registerEnv(program2) {
|
|
|
314
314
|
);
|
|
315
315
|
}
|
|
316
316
|
}
|
|
317
|
-
const { findChrome } = await import("./chrome-
|
|
318
|
-
const { hasWebSocket } = await import("./cdp-
|
|
317
|
+
const { findChrome } = await import("./chrome-CAN7TVH6.js");
|
|
318
|
+
const { hasWebSocket } = await import("./cdp-RFQCIQFP.js");
|
|
319
319
|
const chrome = findChrome();
|
|
320
320
|
console.log(
|
|
321
321
|
chrome ? `${pc3.green("\u2713")} Chrome ${pc3.dim(chrome)}` : `${pc3.yellow("\u25CB")} Chrome ${pc3.dim("\u2014 screenshots and runtime probing disabled")}`
|
|
@@ -456,7 +456,7 @@ function registerProject(program2) {
|
|
|
456
456
|
process.exitCode = 1;
|
|
457
457
|
return;
|
|
458
458
|
}
|
|
459
|
-
const { runVariants, cleanVariants } = await import("./variants-
|
|
459
|
+
const { runVariants, cleanVariants } = await import("./variants-WBRY2U37.js");
|
|
460
460
|
const config = loadConfig(defaultPaths(cwd));
|
|
461
461
|
const engineId = resolveEngineId(config, options.engine);
|
|
462
462
|
const engine = getEngine(engineId);
|
|
@@ -474,7 +474,7 @@ function registerProject(program2) {
|
|
|
474
474
|
);
|
|
475
475
|
const succeeded = runs.filter((r) => r.result.ok);
|
|
476
476
|
if (options.shots && succeeded.length > 0) {
|
|
477
|
-
const { screenshotVariants } = await import("./shots-
|
|
477
|
+
const { screenshotVariants } = await import("./shots-HDHPCENU.js");
|
|
478
478
|
console.log(pc4.dim("capturing screenshots\u2026"));
|
|
479
479
|
const shots = await screenshotVariants(cwd, succeeded.map((r) => r.variant));
|
|
480
480
|
for (const shot of shots) {
|
|
@@ -489,7 +489,7 @@ ${succeeded.length}/${runs.length} variants ready in .squint/variants/ \u2014 `
|
|
|
489
489
|
}
|
|
490
490
|
);
|
|
491
491
|
variantsCommand.command("list").description("List generated variants").action(async () => {
|
|
492
|
-
const { listVariants } = await import("./variants-
|
|
492
|
+
const { listVariants } = await import("./variants-WBRY2U37.js");
|
|
493
493
|
const ids = listVariants(process.cwd());
|
|
494
494
|
if (ids.length === 0) {
|
|
495
495
|
console.log(pc4.dim('no variants \u2014 squint variants gen <n> "<ask>"'));
|
|
@@ -498,7 +498,7 @@ ${succeeded.length}/${runs.length} variants ready in .squint/variants/ \u2014 `
|
|
|
498
498
|
for (const id of ids) console.log(id);
|
|
499
499
|
});
|
|
500
500
|
variantsCommand.command("apply").description("Apply one variant\u2019s changes to the main tree and discard the rest").argument("<id>", "family id of the winning variant").action(async (id) => {
|
|
501
|
-
const { applyVariant, cleanVariants } = await import("./variants-
|
|
501
|
+
const { applyVariant, cleanVariants } = await import("./variants-WBRY2U37.js");
|
|
502
502
|
const cwd = process.cwd();
|
|
503
503
|
const result = applyVariant(cwd, id);
|
|
504
504
|
if (!result.ok) {
|
|
@@ -510,7 +510,7 @@ ${succeeded.length}/${runs.length} variants ready in .squint/variants/ \u2014 `
|
|
|
510
510
|
console.log(pc4.green(`\u2713 applied ${id} to the working tree`) + pc4.dim(" \u2014 review with git diff"));
|
|
511
511
|
});
|
|
512
512
|
variantsCommand.command("clean").description("Discard all variants").action(async () => {
|
|
513
|
-
const { cleanVariants } = await import("./variants-
|
|
513
|
+
const { cleanVariants } = await import("./variants-WBRY2U37.js");
|
|
514
514
|
const count = cleanVariants(process.cwd());
|
|
515
515
|
console.log(pc4.dim(`removed ${count} variant(s)`));
|
|
516
516
|
});
|
|
@@ -551,7 +551,7 @@ function registerQuality(program2) {
|
|
|
551
551
|
report.gates = gateResults.map((r) => ({ id: r.gate.id, ok: r.ok, durationMs: r.durationMs, outputTail: r.ok ? void 0 : r.outputTail }));
|
|
552
552
|
if (gateResults.some((r) => !r.ok)) failed = true;
|
|
553
553
|
if (opts.url) {
|
|
554
|
-
const { captureViewports, runtimeSummary, previewDir } = await import("./preview-
|
|
554
|
+
const { captureViewports, runtimeSummary, previewDir } = await import("./preview-WYFBPFFL.js");
|
|
555
555
|
const capture = await captureViewports(cwd, opts.url);
|
|
556
556
|
if (!capture) {
|
|
557
557
|
console.log(pc5.red("\u2717 audit: capture failed (Chrome missing or URL unreachable)"));
|
|
@@ -583,14 +583,14 @@ function registerQuality(program2) {
|
|
|
583
583
|
console.log(`${pc5.green("\u2713")} audit ${pc5.dim(`(${advisories.a11y.length} a11y, ${advisories.slop.length} slop, ${advisories.jank.length} jank advisories)`)}`);
|
|
584
584
|
}
|
|
585
585
|
}
|
|
586
|
-
const { loadFlows } = await import("./flows-
|
|
586
|
+
const { loadFlows } = await import("./flows-G5K3XYQZ.js");
|
|
587
587
|
const flows = loadFlows(cwd);
|
|
588
588
|
if (flows.length > 0) {
|
|
589
|
-
const { findChrome } = await import("./chrome-
|
|
589
|
+
const { findChrome } = await import("./chrome-CAN7TVH6.js");
|
|
590
590
|
const chrome = findChrome();
|
|
591
591
|
const flowReport = [];
|
|
592
592
|
if (chrome) {
|
|
593
|
-
const { runFlow } = await import("./cdp-
|
|
593
|
+
const { runFlow } = await import("./cdp-RFQCIQFP.js");
|
|
594
594
|
for (const flow of flows) {
|
|
595
595
|
const result = await runFlow(chrome, opts.url, flow, previewDir(cwd));
|
|
596
596
|
flowReport.push({ name: flow.name, ok: result.ok, detail: result.ok ? void 0 : `step ${result.failedStep}: ${result.detail}` });
|
|
@@ -603,6 +603,11 @@ function registerQuality(program2) {
|
|
|
603
603
|
}
|
|
604
604
|
report.ok = !failed;
|
|
605
605
|
report.finishedAt = (/* @__PURE__ */ new Date()).toISOString();
|
|
606
|
+
try {
|
|
607
|
+
const { writeReceipt } = await import("./receipts-INSRID6M.js");
|
|
608
|
+
console.log(pc5.dim(`receipt \u2192 ${writeReceipt(cwd, report)}`));
|
|
609
|
+
} catch {
|
|
610
|
+
}
|
|
606
611
|
if (opts.json) {
|
|
607
612
|
const fs2 = await import("fs");
|
|
608
613
|
fs2.writeFileSync(opts.json, JSON.stringify(report, null, 2));
|
|
@@ -611,7 +616,7 @@ function registerQuality(program2) {
|
|
|
611
616
|
if (failed) process.exitCode = 1;
|
|
612
617
|
});
|
|
613
618
|
program2.command("shot").description("Screenshot a running app at mobile/tablet/desktop viewports (+ .squint/routes)").argument("<url>", "URL of the running app (e.g. http://localhost:5173)").action(async (url) => {
|
|
614
|
-
const { captureViewports } = await import("./preview-
|
|
619
|
+
const { captureViewports } = await import("./preview-WYFBPFFL.js");
|
|
615
620
|
const result = await captureViewports(process.cwd(), url);
|
|
616
621
|
if (!result) {
|
|
617
622
|
console.error(pc5.red("\u2717 no Chrome/Chromium found"));
|
|
@@ -798,7 +803,7 @@ function registerTui(program2) {
|
|
|
798
803
|
}
|
|
799
804
|
|
|
800
805
|
// src/cli.tsx
|
|
801
|
-
var VERSION = true ? "0.
|
|
806
|
+
var VERSION = true ? "0.6.0" : "0.0.0-dev";
|
|
802
807
|
var program = new Command();
|
|
803
808
|
program.name("squint").description("Lovable for your terminal \u2014 a frontend harness on top of Claude Code, Codex, and friends.").version(VERSION);
|
|
804
809
|
registerRun(program);
|
|
@@ -11,11 +11,11 @@ import {
|
|
|
11
11
|
probeRuntime,
|
|
12
12
|
routeShotName,
|
|
13
13
|
runtimeSummary
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-7FAS2O3L.js";
|
|
15
15
|
import "./chunk-7CAGWFAQ.js";
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-P6D4RSWD.js";
|
|
17
|
+
import "./chunk-PZV2FJE5.js";
|
|
18
|
+
import "./chunk-DABIMOMV.js";
|
|
19
19
|
export {
|
|
20
20
|
VIEWPORTS,
|
|
21
21
|
buildReviewPrompt,
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
|
|
3
|
+
// src/quality/receipts.ts
|
|
4
|
+
import { execFileSync } from "child_process";
|
|
5
|
+
import crypto from "crypto";
|
|
6
|
+
import fs from "fs";
|
|
7
|
+
import path from "path";
|
|
8
|
+
function sha256(data) {
|
|
9
|
+
return crypto.createHash("sha256").update(data).digest("hex");
|
|
10
|
+
}
|
|
11
|
+
function canonical(value) {
|
|
12
|
+
if (Array.isArray(value)) return `[${value.map(canonical).join(",")}]`;
|
|
13
|
+
if (value && typeof value === "object") {
|
|
14
|
+
const entries = Object.entries(value).filter(([, v]) => v !== void 0).sort(([a], [b]) => a < b ? -1 : 1);
|
|
15
|
+
return `{${entries.map(([k, v]) => `${JSON.stringify(k)}:${canonical(v)}`).join(",")}}`;
|
|
16
|
+
}
|
|
17
|
+
return JSON.stringify(value);
|
|
18
|
+
}
|
|
19
|
+
function buildReceipt(cwd, report) {
|
|
20
|
+
let gitHead = null;
|
|
21
|
+
try {
|
|
22
|
+
gitHead = execFileSync("git", ["rev-parse", "HEAD"], { cwd, encoding: "utf8", stdio: ["ignore", "pipe", "pipe"] }).trim();
|
|
23
|
+
} catch {
|
|
24
|
+
}
|
|
25
|
+
const screenshots = {};
|
|
26
|
+
const shots = report.audit?.shots ?? [];
|
|
27
|
+
for (const shot of shots) {
|
|
28
|
+
try {
|
|
29
|
+
screenshots[path.basename(shot)] = sha256(fs.readFileSync(shot));
|
|
30
|
+
} catch {
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
const unsigned = {
|
|
34
|
+
version: true ? "0.6.0" : "0.0.0-dev",
|
|
35
|
+
node: process.version,
|
|
36
|
+
gitHead,
|
|
37
|
+
report,
|
|
38
|
+
screenshots
|
|
39
|
+
};
|
|
40
|
+
return { ...unsigned, digest: sha256(canonical(unsigned)) };
|
|
41
|
+
}
|
|
42
|
+
function verifyReceipt(receipt) {
|
|
43
|
+
const { digest, ...unsigned } = receipt;
|
|
44
|
+
return sha256(canonical(unsigned)) === digest;
|
|
45
|
+
}
|
|
46
|
+
function writeReceipt(cwd, report) {
|
|
47
|
+
const receipt = buildReceipt(cwd, report);
|
|
48
|
+
const dir = path.join(cwd, ".squint", "receipts");
|
|
49
|
+
fs.mkdirSync(dir, { recursive: true });
|
|
50
|
+
const stamp = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-");
|
|
51
|
+
const file = path.join(dir, `${stamp}${receipt.report.ok ? "" : "-failed"}.json`);
|
|
52
|
+
fs.writeFileSync(file, JSON.stringify(receipt, null, 2));
|
|
53
|
+
return file;
|
|
54
|
+
}
|
|
55
|
+
export {
|
|
56
|
+
buildReceipt,
|
|
57
|
+
canonical,
|
|
58
|
+
verifyReceipt,
|
|
59
|
+
writeReceipt
|
|
60
|
+
};
|
|
@@ -2,23 +2,23 @@
|
|
|
2
2
|
import {
|
|
3
3
|
connectDaemon,
|
|
4
4
|
socketPath
|
|
5
|
-
} from "./chunk-
|
|
6
|
-
import "./chunk-
|
|
5
|
+
} from "./chunk-BYT6OOGK.js";
|
|
6
|
+
import "./chunk-VCDZGQBB.js";
|
|
7
7
|
import "./chunk-UBADCBPT.js";
|
|
8
8
|
import "./chunk-IEQGTVWN.js";
|
|
9
9
|
import "./chunk-AUJJGMZG.js";
|
|
10
10
|
import "./chunk-YHRAOBI2.js";
|
|
11
|
-
import "./chunk-
|
|
12
|
-
import "./chunk-
|
|
13
|
-
import "./chunk-
|
|
11
|
+
import "./chunk-KNPLVGZB.js";
|
|
12
|
+
import "./chunk-GDGKEMBS.js";
|
|
13
|
+
import "./chunk-DOWWBLX2.js";
|
|
14
14
|
import "./chunk-K5QJMSJH.js";
|
|
15
15
|
import "./chunk-WAJXATCO.js";
|
|
16
16
|
import "./chunk-62JNF5M2.js";
|
|
17
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-7FAS2O3L.js";
|
|
18
18
|
import "./chunk-7CAGWFAQ.js";
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
21
|
-
import "./chunk-
|
|
19
|
+
import "./chunk-P6D4RSWD.js";
|
|
20
|
+
import "./chunk-PZV2FJE5.js";
|
|
21
|
+
import "./chunk-DABIMOMV.js";
|
|
22
22
|
|
|
23
23
|
// src/daemon/remote.ts
|
|
24
24
|
var noteId = 0;
|
|
@@ -12,18 +12,18 @@ import {
|
|
|
12
12
|
} from "./chunk-62JNF5M2.js";
|
|
13
13
|
import {
|
|
14
14
|
loadFlows
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-K7JNVCCU.js";
|
|
16
16
|
import {
|
|
17
17
|
captureViewports,
|
|
18
18
|
previewDir,
|
|
19
19
|
runtimeSummary
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-7FAS2O3L.js";
|
|
21
21
|
import "./chunk-7CAGWFAQ.js";
|
|
22
|
-
import "./chunk-
|
|
22
|
+
import "./chunk-P6D4RSWD.js";
|
|
23
23
|
import {
|
|
24
24
|
findChrome
|
|
25
|
-
} from "./chunk-
|
|
26
|
-
import "./chunk-
|
|
25
|
+
} from "./chunk-PZV2FJE5.js";
|
|
26
|
+
import "./chunk-DABIMOMV.js";
|
|
27
27
|
|
|
28
28
|
// src/mcp/server.ts
|
|
29
29
|
import readline from "readline";
|
|
@@ -75,7 +75,7 @@ ${list.join("\n")}`);
|
|
|
75
75
|
if (flows.length === 0) return "no flows declared \u2014 add .squint/flows/<name>.flow";
|
|
76
76
|
const chrome = findChrome();
|
|
77
77
|
if (!chrome) return "no Chrome/Chromium found";
|
|
78
|
-
const { runFlow } = await import("./cdp-
|
|
78
|
+
const { runFlow } = await import("./cdp-RFQCIQFP.js");
|
|
79
79
|
const lines = [];
|
|
80
80
|
for (const flow of flows) {
|
|
81
81
|
const result = await runFlow(chrome, url, flow, previewDir(cwd));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import {
|
|
3
|
+
screenshotVariants
|
|
4
|
+
} from "./chunk-KNPLVGZB.js";
|
|
5
|
+
import "./chunk-GDGKEMBS.js";
|
|
6
|
+
import "./chunk-DOWWBLX2.js";
|
|
7
|
+
import "./chunk-K5QJMSJH.js";
|
|
8
|
+
import "./chunk-WAJXATCO.js";
|
|
9
|
+
import "./chunk-PZV2FJE5.js";
|
|
10
|
+
import "./chunk-DABIMOMV.js";
|
|
11
|
+
export {
|
|
12
|
+
screenshotVariants
|
|
13
|
+
};
|
|
@@ -9,11 +9,11 @@ import {
|
|
|
9
9
|
runVariants,
|
|
10
10
|
variantPrompt,
|
|
11
11
|
variantsRoot
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-GDGKEMBS.js";
|
|
13
|
+
import "./chunk-DOWWBLX2.js";
|
|
14
14
|
import "./chunk-K5QJMSJH.js";
|
|
15
15
|
import "./chunk-WAJXATCO.js";
|
|
16
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-DABIMOMV.js";
|
|
17
17
|
export {
|
|
18
18
|
MAX_VARIANTS,
|
|
19
19
|
applyVariant,
|
package/package.json
CHANGED
package/dist/App-KTNAMHY6.js
DELETED
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
App
|
|
4
|
-
} from "./chunk-2NYNTVMX.js";
|
|
5
|
-
import "./chunk-VJ2QKHYK.js";
|
|
6
|
-
import "./chunk-G5NS2IFQ.js";
|
|
7
|
-
import "./chunk-UBADCBPT.js";
|
|
8
|
-
import "./chunk-IEQGTVWN.js";
|
|
9
|
-
import "./chunk-AUJJGMZG.js";
|
|
10
|
-
import "./chunk-YHRAOBI2.js";
|
|
11
|
-
import "./chunk-2I3YHT6P.js";
|
|
12
|
-
import "./chunk-J7ITMK6X.js";
|
|
13
|
-
import "./chunk-6NPUVPQD.js";
|
|
14
|
-
import "./chunk-K5QJMSJH.js";
|
|
15
|
-
import "./chunk-WAJXATCO.js";
|
|
16
|
-
import "./chunk-62JNF5M2.js";
|
|
17
|
-
import "./chunk-ERF2SPUW.js";
|
|
18
|
-
import "./chunk-7CAGWFAQ.js";
|
|
19
|
-
import "./chunk-3YCG234A.js";
|
|
20
|
-
import "./chunk-PYC53J7D.js";
|
|
21
|
-
import "./chunk-GV2HAALP.js";
|
|
22
|
-
export {
|
|
23
|
-
App
|
|
24
|
-
};
|
package/dist/flows-MXJL45HW.js
DELETED
package/dist/shots-6DRTXFDI.js
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import {
|
|
3
|
-
screenshotVariants
|
|
4
|
-
} from "./chunk-2I3YHT6P.js";
|
|
5
|
-
import "./chunk-J7ITMK6X.js";
|
|
6
|
-
import "./chunk-6NPUVPQD.js";
|
|
7
|
-
import "./chunk-K5QJMSJH.js";
|
|
8
|
-
import "./chunk-WAJXATCO.js";
|
|
9
|
-
import "./chunk-PYC53J7D.js";
|
|
10
|
-
import "./chunk-GV2HAALP.js";
|
|
11
|
-
export {
|
|
12
|
-
screenshotVariants
|
|
13
|
-
};
|