@bom0792/herdgate 0.9.37 → 0.9.38
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/.agents/skills/herdr/SKILL.md +65 -0
- package/DESIGN.md +28 -0
- package/README.md +55 -1
- package/package.json +2 -1
- package/plugin/herdr-plugin.toml +17 -0
- package/plugin/server/attachments.mjs +184 -0
- package/plugin/server/git-safe.mjs +126 -0
- package/plugin/server/index.mjs +300 -3
- package/plugin/server/mobile-tui-core.mjs +141 -45
- package/plugin/server/mobile-tui-stream.mjs +258 -1
- package/plugin/server/pi-receipt-gc.mjs +183 -0
- package/plugin/server/pi-receipt-search.mjs +217 -0
- package/plugin/server/pi-receipts.mjs +121 -13
- package/plugin/server/pi-transcript.mjs +217 -0
- package/plugin/server/pi-usage.mjs +84 -0
- package/plugin/server/pi-wake.mjs +319 -0
- package/plugin/server/pi-worker.mjs +16 -3
- package/plugin/server/port-attr.mjs +172 -0
- package/plugin/server/sysmon.mjs +212 -0
- package/plugin/server/wake-event.mjs +255 -0
- package/src/agent/index.ts +4 -2
- package/src/agent/qr.ts +70 -0
- package/src/cloud/gateway.ts +5 -1
- package/src/host/main.ts +14 -1
- package/src/web/app.css +356 -0
- package/src/web/app.js +1395 -14
- package/src/web/index.html +1 -0
- package/windows/npm-update.mjs +261 -11
- package/windows/update-policy.mjs +98 -0
package/src/agent/qr.ts
ADDED
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Pairing QR output (lesson from pairfob): wherever a host prints a pairing
|
|
3
|
+
* code for a human to retype into the PWA, it can also hand the code to a
|
|
4
|
+
* camera. The phone opens `https://<gate>/#pair=<code>` and the PWA prefills
|
|
5
|
+
* the code — the human only presses approve.
|
|
6
|
+
*
|
|
7
|
+
* Pure pieces first (`pairingQrPayload`, `renderPairingQr` — no I/O, fully
|
|
8
|
+
* testable), then one console wrapper (`printPairingQr`). The `qrcode-terminal`
|
|
9
|
+
* dependency loads lazily and only when the stream is an interactive TTY, so
|
|
10
|
+
* non-interactive hosts print just the URL line and never touch the library.
|
|
11
|
+
*/
|
|
12
|
+
import { createRequire } from "node:module";
|
|
13
|
+
|
|
14
|
+
/** The URL a phone camera opens: the PWA with the pairing code prefilled. */
|
|
15
|
+
export function pairingQrPayload(gateUrl: string, code: string): string {
|
|
16
|
+
const base = gateUrl.trim().replace(/\/+$/, "");
|
|
17
|
+
if (!/^https?:\/\/[^\s]+$/.test(base)) {
|
|
18
|
+
throw new Error(`pairing QR: gate URL must be http(s)://…, got: ${JSON.stringify(gateUrl)}`);
|
|
19
|
+
}
|
|
20
|
+
// Pairing codes are `randomCode` output (no-lookalike alphanumerics); anything
|
|
21
|
+
// else would leak into a URL, so refuse it here rather than encode it.
|
|
22
|
+
if (!/^[A-Za-z0-9]{4,64}$/.test(code)) {
|
|
23
|
+
throw new Error(`pairing QR: pairing code must be 4–64 alphanumerics, got: ${JSON.stringify(code)}`);
|
|
24
|
+
}
|
|
25
|
+
return `${base}/#pair=${code}`;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
export interface QrRenderOpts {
|
|
29
|
+
/** Interactive check; defaults to `process.stdout.isTTY` in `printPairingQr`. */
|
|
30
|
+
isTTY?: boolean;
|
|
31
|
+
/** ASCII-QR renderer (injectable — tests pass a spy instead of the library). */
|
|
32
|
+
renderQr?: (payload: string) => string;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/** Build the lines to print: framed guidance + URL + ASCII QR on a TTY,
|
|
36
|
+
* a plain URL line otherwise (no QR call — grep-safe for scripts and logs). */
|
|
37
|
+
export function renderPairingQr(payload: string, o: QrRenderOpts = {}): { lines: string[]; usedQr: boolean } {
|
|
38
|
+
if (!o.isTTY) return { lines: [payload], usedQr: false };
|
|
39
|
+
const lines = [
|
|
40
|
+
"── pairing " + "─".repeat(46),
|
|
41
|
+
"Quét bằng điện thoại để mở PWA đã điền sẵn code",
|
|
42
|
+
payload,
|
|
43
|
+
];
|
|
44
|
+
const qr = (o.renderQr ?? defaultQr)(payload);
|
|
45
|
+
lines.push(...qr.split("\n"));
|
|
46
|
+
lines.push("─".repeat(56));
|
|
47
|
+
return { lines, usedQr: true };
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/** Print the payload (and, on a TTY, its QR) through `log`. Returns whether a
|
|
51
|
+
* QR was rendered. Throws only if the QR library itself fails to render. */
|
|
52
|
+
export function printPairingQr(payload: string, log: (line: string) => void, o: QrRenderOpts = {}): boolean {
|
|
53
|
+
const { lines, usedQr } = renderPairingQr(payload, { isTTY: o.isTTY ?? process.stdout.isTTY ?? false, renderQr: o.renderQr });
|
|
54
|
+
for (const line of lines) log(line);
|
|
55
|
+
return usedQr;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
/** The real renderer: `qrcode-terminal` is CJS and only worth loading when an
|
|
59
|
+
* interactive human is actually looking. Its callback is synchronous. */
|
|
60
|
+
function defaultQr(payload: string): string {
|
|
61
|
+
const require = createRequire(import.meta.url);
|
|
62
|
+
const mod = require("qrcode-terminal") as {
|
|
63
|
+
generate: (text: string, opts: { small: boolean }, cb: (qr: string) => void) => void;
|
|
64
|
+
};
|
|
65
|
+
let out = "";
|
|
66
|
+
mod.generate(payload, { small: true }, (qr) => {
|
|
67
|
+
out = qr;
|
|
68
|
+
});
|
|
69
|
+
return out;
|
|
70
|
+
}
|
package/src/cloud/gateway.ts
CHANGED
|
@@ -1040,7 +1040,11 @@ export function startCloud(cfg: CloudConfig): Promise<Cloud> {
|
|
|
1040
1040
|
})
|
|
1041
1041
|
: Promise.resolve(null);
|
|
1042
1042
|
|
|
1043
|
-
|
|
1043
|
+
// Resolve the Cloud only once the sshd has bound (or cleanly failed):
|
|
1044
|
+
// a caller reading cloud.ssh?.port right after `await startCloud` used to
|
|
1045
|
+
// race the bind, fall back to port 22 in ssh2's defaults, and flake with
|
|
1046
|
+
// ECONNREFUSED under load (ssh.test.ts publickey, seen ~1/3 full runs).
|
|
1047
|
+
sshPromise.then((h) => {
|
|
1044
1048
|
sshd = h;
|
|
1045
1049
|
resolve({
|
|
1046
1050
|
server,
|
package/src/host/main.ts
CHANGED
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
*/
|
|
13
13
|
import { hostname } from "node:os";
|
|
14
14
|
import { HerdGateAgent, provision } from "../agent/index.ts";
|
|
15
|
+
import { pairingQrPayload, printPairingQr } from "../agent/qr.ts";
|
|
15
16
|
import { HerdrAdapter } from "./herdr.ts";
|
|
16
17
|
import { createSshBridge } from "./ssh.ts";
|
|
17
18
|
import type { AgentAdapter, PairAsk } from "../agent/adapter.ts";
|
|
@@ -36,7 +37,19 @@ if (!roomToken) {
|
|
|
36
37
|
const paired = await provision({
|
|
37
38
|
baseUrl: base,
|
|
38
39
|
name,
|
|
39
|
-
onCode: (
|
|
40
|
+
onCode: (info) => {
|
|
41
|
+
log(`approve this host at ${info.url} (expires in 10 minutes)`);
|
|
42
|
+
// The camera path (pairfob lesson): a QR of `https://<gate>/#pair=<code>`
|
|
43
|
+
// opens the PWA with the code prefilled. ASCII QR only on an interactive
|
|
44
|
+
// terminal; otherwise the URL line above is the fallback.
|
|
45
|
+
try {
|
|
46
|
+
printPairingQr(pairingQrPayload(base, info.code), (line) => console.error(line), {
|
|
47
|
+
isTTY: process.stderr.isTTY,
|
|
48
|
+
});
|
|
49
|
+
} catch {
|
|
50
|
+
log(`open on your phone: ${base}/#pair=${info.code}`);
|
|
51
|
+
}
|
|
52
|
+
},
|
|
40
53
|
});
|
|
41
54
|
roomToken = paired.roomToken;
|
|
42
55
|
console.error(`herdgate-host: paired into room ${paired.roomId}`);
|
package/src/web/app.css
CHANGED
|
@@ -274,6 +274,7 @@ dialog::backdrop {
|
|
|
274
274
|
|
|
275
275
|
.row {
|
|
276
276
|
display: flex;
|
|
277
|
+
flex-wrap: wrap; /* a receipt detail expansion wraps under its row */
|
|
277
278
|
gap: 10px;
|
|
278
279
|
}
|
|
279
280
|
.row button {
|
|
@@ -354,3 +355,358 @@ dialog::backdrop {
|
|
|
354
355
|
overflow-wrap: anywhere;
|
|
355
356
|
margin: 4px 0;
|
|
356
357
|
}
|
|
358
|
+
|
|
359
|
+
/* Worker activity bar: one row of tab buttons over the shared worker surface. */
|
|
360
|
+
.activity-bar {
|
|
361
|
+
display: flex;
|
|
362
|
+
flex-wrap: wrap;
|
|
363
|
+
gap: 0.4rem;
|
|
364
|
+
margin: 0.2rem 0 0.5rem;
|
|
365
|
+
}
|
|
366
|
+
.activity-bar button.active {
|
|
367
|
+
font-weight: 700;
|
|
368
|
+
border-color: currentColor;
|
|
369
|
+
}
|
|
370
|
+
.recap-view > p:first-of-type {
|
|
371
|
+
margin-top: 0.4rem;
|
|
372
|
+
}
|
|
373
|
+
#view .worker .recap-view > p,
|
|
374
|
+
#view .worker .usage-view > p {
|
|
375
|
+
font-weight: 600;
|
|
376
|
+
margin: 0.5rem 0 0.15rem;
|
|
377
|
+
}
|
|
378
|
+
#view .worker .recap-view > p.muted,
|
|
379
|
+
#view .worker .usage-view > p.muted {
|
|
380
|
+
font-weight: 400;
|
|
381
|
+
}
|
|
382
|
+
#view .worker table {
|
|
383
|
+
border-collapse: collapse;
|
|
384
|
+
font-variant-numeric: tabular-nums;
|
|
385
|
+
font-size: 0.85em;
|
|
386
|
+
margin: 0.25rem 0 0.6rem;
|
|
387
|
+
}
|
|
388
|
+
#view .worker th,
|
|
389
|
+
#view .worker td {
|
|
390
|
+
padding: 0.1rem 0.5rem 0.1rem 0;
|
|
391
|
+
text-align: left;
|
|
392
|
+
}
|
|
393
|
+
#view .worker th {
|
|
394
|
+
font-weight: 600;
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
/* PWA v2 — Herdr status glyphs: ◉ needs-you, ◐ working, ● done, ✓ idle. */
|
|
398
|
+
:root {
|
|
399
|
+
--warn: #e0af68;
|
|
400
|
+
}
|
|
401
|
+
@media (prefers-color-scheme: light) {
|
|
402
|
+
:root {
|
|
403
|
+
--warn: #a8781f;
|
|
404
|
+
}
|
|
405
|
+
}
|
|
406
|
+
.glyph {
|
|
407
|
+
margin-left: 8px;
|
|
408
|
+
font-weight: 700;
|
|
409
|
+
}
|
|
410
|
+
.glyph-needs {
|
|
411
|
+
color: var(--bad);
|
|
412
|
+
}
|
|
413
|
+
.glyph-working {
|
|
414
|
+
color: var(--warn);
|
|
415
|
+
}
|
|
416
|
+
.glyph-done {
|
|
417
|
+
color: var(--good);
|
|
418
|
+
}
|
|
419
|
+
.glyph-idle {
|
|
420
|
+
color: var(--muted);
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
/* Chat threads (the Timeline tab, re-imagined): user/assistant bubbles,
|
|
424
|
+
tool-run folds, Delegation cards — and the path:line flash in Diff. */
|
|
425
|
+
.chat-view .threads {
|
|
426
|
+
display: flex;
|
|
427
|
+
flex-direction: column;
|
|
428
|
+
gap: 10px;
|
|
429
|
+
margin-top: 6px;
|
|
430
|
+
}
|
|
431
|
+
.thread {
|
|
432
|
+
display: flex;
|
|
433
|
+
flex-direction: column;
|
|
434
|
+
gap: 8px;
|
|
435
|
+
border: 1px solid var(--line);
|
|
436
|
+
border-radius: 10px;
|
|
437
|
+
background: var(--surface);
|
|
438
|
+
padding: 10px 12px;
|
|
439
|
+
}
|
|
440
|
+
.msg {
|
|
441
|
+
max-width: 92%;
|
|
442
|
+
padding: 8px 11px;
|
|
443
|
+
border-radius: 12px;
|
|
444
|
+
white-space: pre-wrap;
|
|
445
|
+
overflow-wrap: anywhere;
|
|
446
|
+
font-size: 13.5px;
|
|
447
|
+
}
|
|
448
|
+
.msg.user {
|
|
449
|
+
align-self: flex-end;
|
|
450
|
+
background: color-mix(in srgb, var(--accent) 22%, var(--surface));
|
|
451
|
+
border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--line));
|
|
452
|
+
}
|
|
453
|
+
.msg.assistant {
|
|
454
|
+
align-self: flex-start;
|
|
455
|
+
background: var(--bg);
|
|
456
|
+
border: 1px solid var(--line);
|
|
457
|
+
}
|
|
458
|
+
/* tool-run FOLD: one muted line until clicked open. */
|
|
459
|
+
.fold {
|
|
460
|
+
border: 1px dashed var(--line);
|
|
461
|
+
border-radius: 8px;
|
|
462
|
+
padding: 4px 10px;
|
|
463
|
+
font-size: 12.5px;
|
|
464
|
+
color: var(--muted);
|
|
465
|
+
}
|
|
466
|
+
.fold summary {
|
|
467
|
+
cursor: pointer;
|
|
468
|
+
user-select: none;
|
|
469
|
+
white-space: nowrap;
|
|
470
|
+
overflow: hidden;
|
|
471
|
+
text-overflow: ellipsis;
|
|
472
|
+
}
|
|
473
|
+
.fold[open] summary {
|
|
474
|
+
margin-bottom: 4px;
|
|
475
|
+
}
|
|
476
|
+
.folddetail {
|
|
477
|
+
display: flex;
|
|
478
|
+
flex-direction: column;
|
|
479
|
+
gap: 2px;
|
|
480
|
+
font: 11.5px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace;
|
|
481
|
+
}
|
|
482
|
+
/* Delegation cards: one per background spawn principal. */
|
|
483
|
+
.subagent-cards {
|
|
484
|
+
display: flex;
|
|
485
|
+
flex-wrap: wrap;
|
|
486
|
+
gap: 8px;
|
|
487
|
+
margin: 6px 0;
|
|
488
|
+
}
|
|
489
|
+
.subagent {
|
|
490
|
+
display: flex;
|
|
491
|
+
flex-direction: column;
|
|
492
|
+
align-items: flex-start;
|
|
493
|
+
gap: 2px;
|
|
494
|
+
width: auto;
|
|
495
|
+
margin: 0;
|
|
496
|
+
padding: 8px 12px;
|
|
497
|
+
border-radius: 10px;
|
|
498
|
+
background: var(--surface);
|
|
499
|
+
border: 1px solid var(--line);
|
|
500
|
+
color: var(--fg);
|
|
501
|
+
font-weight: 400;
|
|
502
|
+
text-align: left;
|
|
503
|
+
}
|
|
504
|
+
.subagent.active {
|
|
505
|
+
outline: 2px solid var(--accent);
|
|
506
|
+
}
|
|
507
|
+
.subagent-name {
|
|
508
|
+
font-weight: 600;
|
|
509
|
+
}
|
|
510
|
+
.subagent-status {
|
|
511
|
+
font-size: 12px;
|
|
512
|
+
color: var(--muted);
|
|
513
|
+
}
|
|
514
|
+
.subagent-tokens {
|
|
515
|
+
font-size: 12px;
|
|
516
|
+
color: var(--dim);
|
|
517
|
+
font-variant-numeric: tabular-nums;
|
|
518
|
+
}
|
|
519
|
+
.spawn-thread {
|
|
520
|
+
border: 1px dashed var(--line);
|
|
521
|
+
border-radius: 10px;
|
|
522
|
+
padding: 8px 12px;
|
|
523
|
+
margin: 6px 0;
|
|
524
|
+
}
|
|
525
|
+
/* Receipt detail (receipt.enrich): the expansion under a tapped receipt row —
|
|
526
|
+
transcript facts, two columns on mobile: label left, value right. */
|
|
527
|
+
.receipt-detail {
|
|
528
|
+
flex: 1 1 100%;
|
|
529
|
+
margin-top: 6px;
|
|
530
|
+
padding: 10px 12px;
|
|
531
|
+
border: 1px solid var(--line);
|
|
532
|
+
border-radius: 10px;
|
|
533
|
+
background: var(--bg);
|
|
534
|
+
display: grid;
|
|
535
|
+
grid-template-columns: max-content 1fr;
|
|
536
|
+
gap: 4px 14px;
|
|
537
|
+
font-size: 13px;
|
|
538
|
+
}
|
|
539
|
+
.receipt-detail dt {
|
|
540
|
+
color: var(--muted);
|
|
541
|
+
}
|
|
542
|
+
.receipt-detail dd {
|
|
543
|
+
margin: 0;
|
|
544
|
+
justify-self: end;
|
|
545
|
+
text-align: right;
|
|
546
|
+
font-variant-numeric: tabular-nums;
|
|
547
|
+
overflow-wrap: anywhere;
|
|
548
|
+
}
|
|
549
|
+
.receipt-detail .error {
|
|
550
|
+
margin: 0;
|
|
551
|
+
}
|
|
552
|
+
/* Context fill bar — only rendered when a real window cap is known. */
|
|
553
|
+
.receipt-detail .ctxbar {
|
|
554
|
+
grid-column: 1 / -1;
|
|
555
|
+
height: 6px;
|
|
556
|
+
border-radius: 3px;
|
|
557
|
+
background: color-mix(in srgb, var(--fg) 12%, transparent);
|
|
558
|
+
overflow: hidden;
|
|
559
|
+
}
|
|
560
|
+
.receipt-detail .ctxbar i {
|
|
561
|
+
display: block;
|
|
562
|
+
height: 100%;
|
|
563
|
+
background: var(--accent);
|
|
564
|
+
}
|
|
565
|
+
/* `path:line` links inside a chat bubble jump into the Diff view. */
|
|
566
|
+
.msg .pathline {
|
|
567
|
+
margin: 0;
|
|
568
|
+
font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
|
|
569
|
+
font-size: 0.95em;
|
|
570
|
+
}
|
|
571
|
+
/* path:line deep-link flash in the Diff patch — 3s, then it fades on its own. */
|
|
572
|
+
.diff-patch .flash {
|
|
573
|
+
animation: hg-flash-line 3s ease-out;
|
|
574
|
+
border-radius: 3px;
|
|
575
|
+
}
|
|
576
|
+
@keyframes hg-flash-line {
|
|
577
|
+
0% {
|
|
578
|
+
background: color-mix(in srgb, var(--accent) 45%, transparent);
|
|
579
|
+
}
|
|
580
|
+
100% {
|
|
581
|
+
background: transparent;
|
|
582
|
+
}
|
|
583
|
+
}
|
|
584
|
+
|
|
585
|
+
/* Diff: stat header, then the patch with + green, - red, @@ purple. */
|
|
586
|
+
.diff-view .diff-out {
|
|
587
|
+
margin-top: 4px;
|
|
588
|
+
}
|
|
589
|
+
.diff-stat {
|
|
590
|
+
margin: 6px 0;
|
|
591
|
+
white-space: pre-wrap;
|
|
592
|
+
word-break: break-word;
|
|
593
|
+
color: var(--muted);
|
|
594
|
+
font: 12px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace;
|
|
595
|
+
}
|
|
596
|
+
.diff-patch {
|
|
597
|
+
margin-top: 6px;
|
|
598
|
+
border: 1px solid var(--line);
|
|
599
|
+
border-radius: 8px;
|
|
600
|
+
background: var(--surface);
|
|
601
|
+
max-height: 60vh;
|
|
602
|
+
overflow: auto;
|
|
603
|
+
font: 12px/1.5 ui-monospace, SFMono-Regular, Menlo, monospace;
|
|
604
|
+
}
|
|
605
|
+
.diff-add {
|
|
606
|
+
color: var(--good);
|
|
607
|
+
white-space: pre;
|
|
608
|
+
}
|
|
609
|
+
.diff-del {
|
|
610
|
+
color: var(--bad);
|
|
611
|
+
white-space: pre;
|
|
612
|
+
}
|
|
613
|
+
.diff-hunk {
|
|
614
|
+
color: #c678dd;
|
|
615
|
+
white-space: pre;
|
|
616
|
+
}
|
|
617
|
+
.diff-ctx {
|
|
618
|
+
color: var(--muted);
|
|
619
|
+
white-space: pre;
|
|
620
|
+
}
|
|
621
|
+
|
|
622
|
+
/* Cmd+K fuzzy-jump overlay (opened by the chord or the header hint). */
|
|
623
|
+
#cmdk-open {
|
|
624
|
+
background: none;
|
|
625
|
+
border: 1px solid var(--line);
|
|
626
|
+
color: var(--dim);
|
|
627
|
+
border-radius: 8px;
|
|
628
|
+
width: auto;
|
|
629
|
+
height: 30px;
|
|
630
|
+
padding: 0 10px;
|
|
631
|
+
margin: 0;
|
|
632
|
+
font-size: 11.5px;
|
|
633
|
+
font-weight: 500;
|
|
634
|
+
cursor: pointer;
|
|
635
|
+
}
|
|
636
|
+
.cmdk {
|
|
637
|
+
position: fixed;
|
|
638
|
+
inset: 0;
|
|
639
|
+
background: rgb(0 0 0 / 0.45);
|
|
640
|
+
display: flex;
|
|
641
|
+
justify-content: center;
|
|
642
|
+
align-items: flex-start;
|
|
643
|
+
padding: 12vh 16px 16px;
|
|
644
|
+
z-index: 40;
|
|
645
|
+
}
|
|
646
|
+
.cmdk[hidden] {
|
|
647
|
+
display: none;
|
|
648
|
+
}
|
|
649
|
+
.cmdk-box {
|
|
650
|
+
width: min(92vw, 480px);
|
|
651
|
+
height: fit-content;
|
|
652
|
+
background: var(--surface);
|
|
653
|
+
border: 1px solid var(--line);
|
|
654
|
+
border-radius: 12px;
|
|
655
|
+
padding: 12px;
|
|
656
|
+
box-shadow: 0 18px 50px rgb(0 0 0 / 0.35);
|
|
657
|
+
}
|
|
658
|
+
.cmdk-box input {
|
|
659
|
+
margin-bottom: 8px;
|
|
660
|
+
}
|
|
661
|
+
.cmdk-list {
|
|
662
|
+
list-style: none;
|
|
663
|
+
margin: 0 0 8px;
|
|
664
|
+
padding: 0;
|
|
665
|
+
max-height: 46vh;
|
|
666
|
+
overflow-y: auto;
|
|
667
|
+
display: flex;
|
|
668
|
+
flex-direction: column;
|
|
669
|
+
gap: 2px;
|
|
670
|
+
}
|
|
671
|
+
.cmdk-list li {
|
|
672
|
+
padding: 8px 10px;
|
|
673
|
+
border-radius: 8px;
|
|
674
|
+
cursor: pointer;
|
|
675
|
+
font-size: 13.5px;
|
|
676
|
+
}
|
|
677
|
+
.cmdk-list li.active {
|
|
678
|
+
background: var(--bg);
|
|
679
|
+
outline: 1px solid var(--accent);
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
/* ---- Wave C3: composer attachments (📎) ---- */
|
|
683
|
+
|
|
684
|
+
/* The paperclip sits in the composer row like a sibling action, not a full-width
|
|
685
|
+
input: same tap target, quieter than the primary Submit. */
|
|
686
|
+
button.attach {
|
|
687
|
+
width: auto;
|
|
688
|
+
padding: 11px 14px;
|
|
689
|
+
background: none;
|
|
690
|
+
color: var(--fg);
|
|
691
|
+
border-color: var(--line);
|
|
692
|
+
font-weight: 500;
|
|
693
|
+
line-height: 1;
|
|
694
|
+
}
|
|
695
|
+
|
|
696
|
+
/* One transient refusal line pinned above the fold's bottom — upload errors say
|
|
697
|
+
themselves, no view blanks behind them. */
|
|
698
|
+
.toast {
|
|
699
|
+
position: fixed;
|
|
700
|
+
left: 50%;
|
|
701
|
+
bottom: 18px;
|
|
702
|
+
transform: translateX(-50%);
|
|
703
|
+
max-width: min(92vw, 480px);
|
|
704
|
+
background: var(--surface);
|
|
705
|
+
border: 1px solid var(--bad);
|
|
706
|
+
color: var(--fg);
|
|
707
|
+
border-radius: var(--radius);
|
|
708
|
+
padding: 10px 14px;
|
|
709
|
+
font-size: 13px;
|
|
710
|
+
box-shadow: 0 6px 24px rgb(0 0 0 / 0.35);
|
|
711
|
+
z-index: 40;
|
|
712
|
+
}
|