@browserbridge/bbx 1.0.0 → 1.1.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.
Files changed (72) hide show
  1. package/README.md +6 -4
  2. package/package.json +53 -53
  3. package/packages/agent-client/src/cli-helpers.js +43 -5
  4. package/packages/agent-client/src/cli.js +176 -171
  5. package/packages/agent-client/src/client.js +66 -21
  6. package/packages/agent-client/src/command-registry.js +104 -69
  7. package/packages/agent-client/src/detect.js +162 -54
  8. package/packages/agent-client/src/install.js +34 -28
  9. package/packages/agent-client/src/mcp-config.js +40 -40
  10. package/packages/agent-client/src/runtime.js +41 -20
  11. package/packages/agent-client/src/setup-status.js +23 -30
  12. package/packages/mcp-server/src/bin.js +57 -5
  13. package/packages/mcp-server/src/handlers.js +573 -256
  14. package/packages/mcp-server/src/server.js +568 -257
  15. package/packages/native-host/bin/bridge-daemon.js +39 -6
  16. package/packages/native-host/bin/install-manifest.js +26 -4
  17. package/packages/native-host/bin/postinstall.js +4 -2
  18. package/packages/native-host/src/config.js +142 -13
  19. package/packages/native-host/src/daemon-process.js +396 -0
  20. package/packages/native-host/src/daemon.js +350 -150
  21. package/packages/native-host/src/framing.js +131 -11
  22. package/packages/native-host/src/install-manifest.js +194 -29
  23. package/packages/native-host/src/native-host.js +154 -102
  24. package/packages/protocol/src/budget.js +3 -7
  25. package/packages/protocol/src/capabilities.js +6 -3
  26. package/packages/protocol/src/defaults.js +1 -0
  27. package/packages/protocol/src/errors.js +15 -11
  28. package/packages/protocol/src/payload-cost.js +19 -6
  29. package/packages/protocol/src/protocol.js +242 -73
  30. package/packages/protocol/src/registry.js +311 -45
  31. package/packages/protocol/src/summary.js +260 -109
  32. package/packages/protocol/src/types.js +29 -4
  33. package/skills/browser-bridge/SKILL.md +3 -2
  34. package/skills/browser-bridge/agents/openai.yaml +3 -3
  35. package/skills/browser-bridge/references/interaction.md +34 -11
  36. package/skills/browser-bridge/references/patch-workflow.md +3 -0
  37. package/skills/browser-bridge/references/protocol.md +127 -71
  38. package/skills/browser-bridge/references/tailwind.md +12 -11
  39. package/skills/browser-bridge/references/token-efficiency.md +23 -22
  40. package/skills/browser-bridge/references/ui-workflows.md +8 -0
  41. package/CHANGELOG.md +0 -55
  42. package/assets/banner.jpg +0 -0
  43. package/assets/logo.png +0 -0
  44. package/assets/logo.svg +0 -65
  45. package/docs/api-reference.md +0 -157
  46. package/docs/cli-guide.md +0 -128
  47. package/docs/index.md +0 -25
  48. package/docs/manual-setup.md +0 -140
  49. package/docs/mcp-vs-cli.md +0 -258
  50. package/docs/publishing.md +0 -114
  51. package/docs/quickstart.md +0 -104
  52. package/docs/troubleshooting.md +0 -59
  53. package/docs/usage-scenarios.md +0 -136
  54. package/manifest.json +0 -52
  55. package/packages/extension/assets/icon-128.png +0 -0
  56. package/packages/extension/assets/icon-16.png +0 -0
  57. package/packages/extension/assets/icon-32.png +0 -0
  58. package/packages/extension/assets/icon-48.png +0 -0
  59. package/packages/extension/src/background-helpers.js +0 -459
  60. package/packages/extension/src/background-routing.js +0 -91
  61. package/packages/extension/src/background.js +0 -3227
  62. package/packages/extension/src/content-script-helpers.js +0 -281
  63. package/packages/extension/src/content-script.js +0 -1977
  64. package/packages/extension/src/debugger-coordinator.js +0 -188
  65. package/packages/extension/src/sidepanel-helpers.js +0 -102
  66. package/packages/extension/ui/offscreen.html +0 -6
  67. package/packages/extension/ui/offscreen.js +0 -61
  68. package/packages/extension/ui/popup.html +0 -35
  69. package/packages/extension/ui/popup.js +0 -279
  70. package/packages/extension/ui/sidepanel.html +0 -102
  71. package/packages/extension/ui/sidepanel.js +0 -1854
  72. package/packages/extension/ui/ui.css +0 -1159
@@ -1,1159 +0,0 @@
1
- :root {
2
- color-scheme: light dark;
3
- --bg: #faf7f5;
4
- --panel: #ffffff;
5
- --ink: #1a1d23;
6
- --fg: #1a1d23;
7
- --muted: #7a7068;
8
- --accent: #d34a1e;
9
- --accent-strong: #b33e18;
10
- --update-bg: #4b8a6e;
11
- --update-bg-hover: #3d7259;
12
- --stroke: #e8e3de;
13
- --cmd-bg: rgba(128, 112, 100, 0.07);
14
- --cmd-bg-hover: rgba(128, 112, 100, 0.12);
15
- --card-shadow: rgba(0, 0, 0, 0.04);
16
- --disabled-bg: #c8c3be;
17
- --hist-surface-top: rgba(255, 255, 255, 0.38);
18
- --hist-surface-bottom: rgba(255, 255, 255, 0.12);
19
- --hist-border: rgba(226, 229, 234, 0.72);
20
- --hist-bar-bg: rgba(107, 114, 128, 0.13);
21
- --hist-bar-border: rgba(107, 114, 128, 0.18);
22
- --hist-dom: rgba(59, 108, 206, 0.82);
23
- --hist-page: rgba(45, 86, 168, 0.7);
24
- --hist-layout: rgba(75, 138, 110, 0.8);
25
- --hist-style: rgba(96, 165, 136, 0.7);
26
- --hist-input: rgba(107, 114, 128, 0.75);
27
- --hist-patch: rgba(168, 137, 88, 0.88);
28
- --hist-capture: rgba(196, 160, 98, 0.9);
29
- --hist-other: rgba(107, 114, 128, 0.35);
30
- }
31
-
32
- [hidden] {
33
- display: none !important;
34
- }
35
-
36
- html {
37
- min-height: 100%;
38
- background: var(--bg);
39
- }
40
-
41
- html[data-windowed="true"] {
42
- min-height: 0;
43
- }
44
-
45
- @media (prefers-color-scheme: dark) {
46
- :root {
47
- --bg: #1a1816;
48
- --panel: #222018;
49
- --ink: #e8e2da;
50
- --fg: #e8e2da;
51
- --muted: #9a9088;
52
- --accent: #e8673f;
53
- --accent-strong: #f08050;
54
- --update-bg: #5ea882;
55
- --update-bg-hover: #72bf96;
56
- --stroke: #352f2a;
57
- --cmd-bg: rgba(255, 248, 240, 0.06);
58
- --cmd-bg-hover: rgba(255, 248, 240, 0.10);
59
- --card-shadow: rgba(0, 0, 0, 0.3);
60
- --disabled-bg: #3d3a34;
61
- --hist-surface-top: rgba(224, 226, 232, 0.08);
62
- --hist-surface-bottom: rgba(224, 226, 232, 0.02);
63
- --hist-border: rgba(139, 144, 160, 0.2);
64
- --hist-bar-bg: rgba(224, 226, 232, 0.12);
65
- --hist-bar-border: rgba(224, 226, 232, 0.18);
66
- --hist-dom: #6b9bef;
67
- --hist-page: #5580d0;
68
- --hist-layout: #5ea882;
69
- --hist-style: #4d9070;
70
- --hist-input: #8b90a0;
71
- --hist-patch: #c5a66e;
72
- --hist-capture: #ddb87a;
73
- --hist-other: rgba(139, 144, 160, 0.45);
74
- }
75
-
76
- html {
77
- background: var(--bg);
78
- }
79
- }
80
-
81
- body {
82
- margin: 0;
83
- height: 100vh;
84
- font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
85
- font-size: 13px;
86
- background: transparent;
87
- color: var(--ink);
88
- overflow: hidden;
89
- border-radius: 8px;
90
- }
91
-
92
- body[data-windowed="true"] {
93
- height: auto;
94
- overflow: visible;
95
- }
96
-
97
- .panel {
98
- min-width: 0;
99
- min-height: 160px;
100
- padding: 14px;
101
- box-sizing: border-box;
102
- display: flex;
103
- flex-direction: column;
104
- height: 100%;
105
- overflow: hidden;
106
- }
107
-
108
- body[data-windowed="true"] .panel {
109
- height: auto;
110
- min-height: 0;
111
- overflow: visible;
112
- }
113
-
114
- body[data-windowed="true"] .panel-popup {
115
- min-height: 0;
116
- }
117
-
118
- .panel-popup {
119
- min-width: 380px;
120
- min-height: 240px;
121
- padding-top: 12px;
122
- padding-bottom: 14px;
123
- border-radius: 8px;
124
- }
125
-
126
- .panel-wide {
127
- width: 100%;
128
- max-width: 440px;
129
- }
130
-
131
- .panel section + section {
132
- margin-top: 12px;
133
- }
134
-
135
- .panel header {
136
- margin-bottom: 12px;
137
- }
138
-
139
- .panel header.panel-header-compact {
140
- margin-bottom: 4px;
141
- }
142
-
143
- .panel-header {
144
- display: flex;
145
- align-items: baseline;
146
- justify-content: space-between;
147
- gap: 12px;
148
- }
149
-
150
- .panel-header-compact {
151
- justify-content: flex-end;
152
- align-items: center;
153
- gap: 8px;
154
- }
155
-
156
- .panel-header-compact .header-status-indicator[data-connected="true"] {
157
- display: none;
158
- }
159
-
160
- .stack {
161
- display: grid;
162
- gap: 8px;
163
- }
164
-
165
- .card {
166
- padding: 10px 12px;
167
- border: 1px solid var(--stroke);
168
- border-radius: 8px;
169
- background: var(--panel);
170
- box-shadow: 0 1px 3px var(--card-shadow);
171
- overflow-wrap: anywhere;
172
- flex-shrink: 0;
173
- }
174
-
175
- .activity-card {
176
- padding: 8px 10px 6px 10px;
177
- border-radius: 6px;
178
- box-shadow: 0 1px 2px var(--card-shadow);
179
- }
180
-
181
- .card-title {
182
- margin: 0;
183
- font-size: 13px;
184
- white-space: nowrap;
185
- overflow: hidden;
186
- text-overflow: ellipsis;
187
- min-width: 0;
188
- }
189
-
190
- .activity-title {
191
- display: flex;
192
- align-items: center;
193
- gap: 6px;
194
- }
195
-
196
- .activity-method {
197
- display: block;
198
- flex: 1 1 auto;
199
- min-width: 0;
200
- overflow: hidden;
201
- text-overflow: ellipsis;
202
- white-space: nowrap;
203
- }
204
-
205
- .activity-source-tag {
206
- flex-shrink: 0;
207
- padding: 1px 5px;
208
- border-radius: 3px;
209
- background: var(--cmd-bg);
210
- color: var(--muted);
211
- font-size: 9px;
212
- font-weight: 600;
213
- letter-spacing: 0.04em;
214
- text-transform: uppercase;
215
- }
216
-
217
- .popup-title {
218
- margin: 0;
219
- max-width: 360px;
220
- font-size: 15px;
221
- font-weight: 600;
222
- line-height: 1.15;
223
- letter-spacing: -0.01em;
224
- }
225
-
226
- .eyebrow {
227
- margin: 0 0 6px;
228
- font-size: 11px;
229
- font-weight: 600;
230
- letter-spacing: 0.04em;
231
- text-transform: uppercase;
232
- color: var(--muted);
233
- }
234
-
235
- .muted {
236
- margin: 0 0 10px;
237
- color: var(--muted);
238
- overflow-wrap: anywhere;
239
- }
240
-
241
- .control-card {
242
- display: grid;
243
- gap: 0;
244
- }
245
-
246
- .control-copy {
247
- display: grid;
248
- gap: 6px;
249
- }
250
-
251
- .control-heading {
252
- display: flex;
253
- align-items: baseline;
254
- justify-content: space-between;
255
- gap: 10px;
256
- }
257
-
258
- .control-heading .eyebrow {
259
- margin: 0;
260
- flex: 1 1 auto;
261
- min-width: 0;
262
- }
263
-
264
- .control-detail {
265
- margin: 0;
266
- font-size: 12px;
267
- line-height: 1.4;
268
- }
269
-
270
- .control-disclosure {
271
- color: var(--muted);
272
- }
273
-
274
- .control-links {
275
- display: flex;
276
- flex-wrap: nowrap;
277
- gap: 10px;
278
- margin-bottom: 0;
279
- justify-content: flex-end;
280
- flex: 0 0 auto;
281
- }
282
-
283
- @keyframes attention-pulse {
284
- 0% { box-shadow: 0 0 0 0 rgba(211, 74, 30, 0.4); }
285
- 30% { box-shadow: 0 0 0 3px rgba(211, 74, 30, 0.2); }
286
- 60% { box-shadow: 0 0 0 0 rgba(211, 74, 30, 0.4); }
287
- 100% { box-shadow: 0 0 0 0 rgba(211, 74, 30, 0.4); }
288
- }
289
-
290
- .control-card.attention {
291
- animation: attention-pulse 0.9s ease-out infinite;
292
- }
293
-
294
- .popup-control-card {
295
- margin-top: 2px;
296
- padding-right: 12px;
297
- padding-left: 12px;
298
- }
299
-
300
- .panel-popup .panel-header {
301
- margin-bottom: 8px;
302
- }
303
-
304
- .activity-header {
305
- display: flex;
306
- align-items: baseline;
307
- justify-content: space-between;
308
- gap: 8px;
309
- }
310
-
311
- .activity-footer {
312
- display: flex;
313
- align-items: flex-start;
314
- justify-content: space-between;
315
- flex-wrap: wrap;
316
- gap: 6px;
317
- margin-top: 3px;
318
- }
319
-
320
- .activity-badges {
321
- display: inline-flex;
322
- align-items: center;
323
- flex-wrap: wrap;
324
- gap: 4px;
325
- flex: 0 1 auto;
326
- max-width: 100%;
327
- min-width: 0;
328
- justify-content: flex-end;
329
- margin-left: auto;
330
- }
331
-
332
- .activity-time {
333
- margin: 0;
334
- font-size: 11px;
335
- white-space: nowrap;
336
- flex-shrink: 0;
337
- }
338
-
339
- .activity-tokens {
340
- margin: 0;
341
- font-size: 10px;
342
- flex: 0 1 auto;
343
- max-width: 100%;
344
- white-space: nowrap;
345
- overflow: hidden;
346
- text-overflow: ellipsis;
347
- text-align: right;
348
- line-height: 1.25;
349
- padding: 1px 5px;
350
- border-radius: 3px;
351
- background: var(--panel);
352
- border: 1px solid var(--stroke);
353
- letter-spacing: 0.01em;
354
- }
355
-
356
- .activity-tokens[data-cost-class="heavy"],
357
- .activity-tokens[data-cost-class="extreme"] {
358
- background: rgba(209, 17, 68, 0.1);
359
- color: var(--ink);
360
- }
361
-
362
- .activity-badge {
363
- margin: 0;
364
- font-size: 10px;
365
- white-space: nowrap;
366
- padding: 1px 5px;
367
- border-radius: 3px;
368
- letter-spacing: 0.02em;
369
- }
370
-
371
- .activity-badge-neutral {
372
- background: var(--cmd-bg);
373
- color: var(--muted);
374
- }
375
-
376
- .activity-badge-warn {
377
- background: rgba(209, 17, 68, 0.1);
378
- color: var(--ink);
379
- }
380
-
381
- .activity-hint {
382
- margin: 6px 0 0;
383
- font-size: 11px;
384
- line-height: 1.35;
385
- overflow-wrap: anywhere;
386
- word-break: break-word;
387
- white-space: normal;
388
- }
389
-
390
- .activity-scope-link {
391
- color: var(--muted);
392
- opacity: 0.5;
393
- transition: opacity 0.15s;
394
- line-height: 0;
395
- vertical-align: middle;
396
- margin-left: 3px;
397
- }
398
-
399
- .activity-scope-link:hover {
400
- opacity: 1;
401
- }
402
-
403
- .activity-summary {
404
- display: flex;
405
- align-items: flex-start;
406
- flex: 1 1 auto;
407
- min-width: 0;
408
- gap: 4px;
409
- font-size: 11px;
410
- line-height: 1.3;
411
- color: var(--muted);
412
- }
413
-
414
- .activity-summary > span:last-child {
415
- min-width: 0;
416
- overflow-wrap: anywhere;
417
- white-space: normal;
418
- }
419
-
420
- .activity-summary.activity-summary-error > span:last-child {
421
- color: var(--ink);
422
- }
423
-
424
- .activity-status-dot {
425
- display: inline-block;
426
- width: 6px;
427
- height: 6px;
428
- border-radius: 50%;
429
- background: #3faa6f;
430
- flex-shrink: 0;
431
- margin-top: 4px;
432
- }
433
-
434
- .activity-status-dot[data-ok="false"] {
435
- background: #c44;
436
- }
437
-
438
- .setup-status-note {
439
- margin-bottom: 10px;
440
- font-size: 12px;
441
- }
442
-
443
- .setup-status-note[hidden] {
444
- display: none;
445
- }
446
-
447
- .setup-status-item,
448
- .setup-status-placeholder {
449
- display: flex;
450
- align-items: flex-start;
451
- justify-content: space-between;
452
- gap: 10px;
453
- padding: 7px 9px;
454
- border-radius: 6px;
455
- background: var(--cmd-bg);
456
- }
457
-
458
- .setup-status-copy {
459
- display: grid;
460
- gap: 2px;
461
- min-width: 0;
462
- }
463
-
464
- .setup-status-label {
465
- font-size: 12px;
466
- font-weight: 600;
467
- }
468
-
469
- .setup-status-detail,
470
- .setup-status-placeholder {
471
- color: var(--muted);
472
- font-size: 11px;
473
- line-height: 1.35;
474
- }
475
-
476
- .setup-status-badge {
477
- display: inline-flex;
478
- align-items: center;
479
- justify-content: center;
480
- flex-shrink: 0;
481
- border-radius: 4px;
482
- padding: 2px 6px;
483
- font-size: 10px;
484
- font-weight: 500;
485
- letter-spacing: 0.02em;
486
- background: rgba(209, 17, 68, 0.1);
487
- color: #c44;
488
- white-space: nowrap;
489
- }
490
-
491
- .setup-status-badge[data-ok="true"] {
492
- background: rgba(45, 138, 87, 0.1);
493
- color: #2d8a57;
494
- }
495
-
496
- .setup-status-matrix-wrap {
497
- margin-top: 4px;
498
- overflow-x: auto;
499
- }
500
-
501
- .setup-status-guidance {
502
- margin: 10px 0 0;
503
- color: var(--muted);
504
- font-size: 11px;
505
- line-height: 1.45;
506
- }
507
-
508
- .setup-status-matrix {
509
- width: 100%;
510
- border-collapse: collapse;
511
- table-layout: auto;
512
- }
513
-
514
- .setup-status-matrix th:first-child,
515
- .setup-status-matrix td:first-child {
516
- width: 100%;
517
- }
518
-
519
- .setup-status-matrix th:nth-child(2),
520
- .setup-status-matrix td:nth-child(2),
521
- .setup-status-matrix th:nth-child(3),
522
- .setup-status-matrix td:nth-child(3) {
523
- width: 60px;
524
- min-width: 60px;
525
- white-space: nowrap;
526
- }
527
-
528
- .setup-status-matrix th,
529
- .setup-status-matrix td {
530
- padding: 8px 6px;
531
- text-align: left;
532
- vertical-align: middle;
533
- border-top: 1px solid var(--stroke);
534
- white-space: nowrap;
535
- }
536
-
537
- .setup-status-matrix thead th {
538
- padding-top: 8px;
539
- border-top: 1px solid var(--stroke);
540
- font-size: 11px;
541
- letter-spacing: 0.08em;
542
- text-transform: uppercase;
543
- color: var(--muted);
544
- }
545
-
546
- .setup-matrix-client {
547
- font-size: 12px;
548
- font-weight: 600;
549
- }
550
-
551
- .setup-matrix-beta {
552
- color: #9aa0a6;
553
- font-weight: 500;
554
- }
555
-
556
- .setup-matrix-muted {
557
- color: var(--muted);
558
- font-size: 12px;
559
- }
560
-
561
- .setup-install-button {
562
- display: inline-flex;
563
- align-items: center;
564
- justify-content: center;
565
- margin-right: 0;
566
- padding: 4px 10px;
567
- font-size: 11px;
568
- font-weight: 600;
569
- line-height: 1.1;
570
- white-space: nowrap;
571
- border-radius: 4px;
572
- }
573
-
574
- .setup-install-button[data-variant="update"] {
575
- background: var(--update-bg);
576
- }
577
-
578
- .setup-install-button[data-variant="update"]:hover {
579
- background: var(--update-bg-hover);
580
- }
581
-
582
- .setup-install-button:disabled {
583
- background: var(--disabled-bg);
584
- cursor: progress;
585
- }
586
-
587
- .setup-context-menu {
588
- position: fixed;
589
- z-index: 1000;
590
- min-width: 190px;
591
- padding: 4px;
592
- border: 1px solid var(--stroke);
593
- border-radius: 8px;
594
- background: var(--panel);
595
- box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
596
- }
597
-
598
- .setup-context-menu[hidden] {
599
- display: none;
600
- }
601
-
602
- .setup-context-menu-item {
603
- width: 100%;
604
- justify-content: flex-start;
605
- padding: 6px 10px;
606
- font-size: 12px;
607
- text-align: left;
608
- background: transparent;
609
- color: var(--fg);
610
- border-radius: 6px;
611
- }
612
-
613
- .setup-context-menu-item:hover {
614
- background: var(--cmd-bg-hover);
615
- }
616
-
617
- .status-line {
618
- display: flex;
619
- align-items: center;
620
- gap: 10px;
621
- margin: 0;
622
- color: var(--muted);
623
- font-size: 14px;
624
- }
625
-
626
- .status-dot {
627
- width: 8px;
628
- height: 8px;
629
- border-radius: 999px;
630
- background: #d14;
631
- box-shadow: 0 0 0 3px rgba(209, 17, 68, 0.12);
632
- flex: 0 0 auto;
633
- }
634
-
635
- .status-dot[data-connected="true"] {
636
- background: #2d8a57;
637
- box-shadow: 0 0 0 3px rgba(45, 138, 87, 0.12);
638
- }
639
-
640
- .header-status-indicator {
641
- margin-top: 0;
642
- cursor: help;
643
- }
644
-
645
- .toggle-row {
646
- display: flex;
647
- align-items: center;
648
- justify-content: space-between;
649
- gap: 16px;
650
- }
651
-
652
- .toggle-row input[type="checkbox"] {
653
- width: 42px;
654
- height: 24px;
655
- accent-color: var(--accent);
656
- }
657
-
658
- button {
659
- margin-right: 8px;
660
- border: 0;
661
- border-radius: 6px;
662
- padding: 7px 14px;
663
- font-size: 13px;
664
- font-weight: 500;
665
- background: var(--accent);
666
- color: white;
667
- cursor: pointer;
668
- transition: background 0.12s;
669
- }
670
-
671
- button:hover {
672
- background: var(--accent-strong);
673
- }
674
-
675
- .popup-action {
676
- margin-top: 10px;
677
- width: 100%;
678
- margin-right: 0;
679
- }
680
-
681
- .popup-power-button {
682
- min-height: 40px;
683
- font-size: 14px;
684
- font-weight: 600;
685
- border-radius: 6px;
686
- }
687
-
688
- .popup-power-button[data-pending="true"] {
689
- opacity: 0.7;
690
- cursor: wait;
691
- pointer-events: none;
692
- }
693
-
694
- .power-button {
695
- width: 100%;
696
- min-height: 40px;
697
- margin-top: 10px;
698
- margin-right: 0;
699
- font-size: 14px;
700
- font-weight: 600;
701
- border-radius: 6px;
702
- }
703
-
704
- .power-button:disabled {
705
- background: var(--disabled-bg);
706
- cursor: not-allowed;
707
- }
708
-
709
- .power-button[data-pending="true"] {
710
- opacity: 0.7;
711
- cursor: wait;
712
- pointer-events: none;
713
- }
714
-
715
- .toggle-error {
716
- margin: 6px 0 0;
717
- padding: 6px 10px;
718
- background: var(--status-badge-bg, #fef3cd);
719
- color: var(--text-primary, #856404);
720
- border-radius: 6px;
721
- font-size: 12px;
722
- line-height: 1.4;
723
- }
724
-
725
- .setup-steps {
726
- display: grid;
727
- gap: 6px;
728
- margin-bottom: 12px;
729
- }
730
-
731
- .examples-eyebrow {
732
- margin-bottom: 8px;
733
- }
734
-
735
- .examples-list {
736
- display: grid;
737
- gap: 6px;
738
- min-width: 0;
739
- }
740
-
741
- .examples-content {
742
- display: grid;
743
- gap: 0px;
744
- padding-top: 12px;
745
- }
746
-
747
- .examples-group {
748
- display: grid;
749
- gap: 4px;
750
- }
751
-
752
- .examples-group-title {
753
- margin: 0;
754
- font-size: 11px;
755
- font-weight: 700;
756
- letter-spacing: 0.08em;
757
- text-transform: uppercase;
758
- color: var(--muted);
759
- }
760
-
761
- .example-cmd {
762
- width: 100%;
763
- min-width: 0;
764
- box-sizing: border-box;
765
- overflow: hidden;
766
- user-select: none;
767
- }
768
-
769
- .example-cmd::after {
770
- display: none;
771
- }
772
-
773
- .example-cmd-text {
774
- display: block;
775
- width: 100%;
776
- min-width: 0;
777
- max-width: 100%;
778
- font-size: 11px;
779
- white-space: nowrap;
780
- overflow: hidden;
781
- text-overflow: ellipsis;
782
- word-break: normal;
783
- user-select: none;
784
- }
785
-
786
- .example-copy-button {
787
- position: absolute;
788
- right: 6px;
789
- top: 6px;
790
- border: 0;
791
- background: transparent;
792
- padding: 0;
793
- margin: 0;
794
- font-size: 14px;
795
- font-family: system-ui, sans-serif;
796
- line-height: 1;
797
- color: var(--muted);
798
- cursor: pointer;
799
- }
800
-
801
- .example-copy-button:hover {
802
- background: transparent;
803
- color: var(--muted);
804
- }
805
-
806
- .example-copy-button:focus-visible {
807
- outline: 1px solid var(--accent);
808
- outline-offset: 2px;
809
- }
810
-
811
- .setup-step-hint {
812
- display: block;
813
- font-size: 11px;
814
- color: var(--muted);
815
- margin-top: 6px;
816
- }
817
-
818
- .setup-step-hint:first-child {
819
- margin-top: 0;
820
- }
821
-
822
- .setup-cmd {
823
- display: block;
824
- position: relative;
825
- padding: 6px 10px;
826
- padding-right: 28px;
827
- border-radius: 4px;
828
- background: var(--cmd-bg);
829
- border: 1px solid var(--stroke);
830
- font-family: ui-monospace, 'SF Mono', 'Menlo', 'Monaco', 'Courier New', monospace;
831
- font-size: 11.5px;
832
- color: var(--ink);
833
- cursor: pointer;
834
- word-break: break-all;
835
- user-select: none;
836
- }
837
-
838
- .setup-cmd:hover {
839
- background: var(--cmd-bg-hover);
840
- }
841
-
842
- .setup-cmd::after {
843
- content: '⧉';
844
- position: absolute;
845
- right: 6px;
846
- top: 6px;
847
- font-size: 14px;
848
- font-family: system-ui, sans-serif;
849
- color: var(--muted);
850
- user-select: none;
851
- line-height: 1;
852
- }
853
-
854
- .setup-cmd:hover::after {
855
- color: var(--ink);
856
- }
857
-
858
- .setup-cmd.copied {
859
- background: rgba(45, 138, 87, 0.07);
860
- border-color: rgba(45, 138, 87, 0.25);
861
- }
862
-
863
- .setup-cmd.copied::after {
864
- content: '✓';
865
- color: #2d8a57;
866
- }
867
-
868
- .setup-link {
869
- font-size: 12px;
870
- color: var(--accent);
871
- text-decoration: none;
872
- white-space: nowrap;
873
- }
874
-
875
- .setup-link:hover {
876
- text-decoration: underline;
877
- }
878
-
879
- /* Activity section: fill remaining space & scroll */
880
- #activity-section {
881
- flex: 1 1 0;
882
- min-height: 0;
883
- display: flex;
884
- flex-direction: column;
885
- overflow: hidden;
886
- margin-top: 12px;
887
- }
888
-
889
- .activity-histogram {
890
- display: flex;
891
- flex-direction: column;
892
- gap: 6px;
893
- margin: 0 0 10px;
894
- padding: 8px 10px 10px;
895
- border: 1px solid var(--hist-border);
896
- border-radius: 8px;
897
- background: var(--panel);
898
- box-shadow: 0 1px 3px var(--card-shadow);
899
- flex-shrink: 0;
900
- }
901
-
902
- .activity-histogram-meta {
903
- display: flex;
904
- align-items: center;
905
- justify-content: space-between;
906
- gap: 8px;
907
- }
908
-
909
- .activity-histogram-label {
910
- margin: 0;
911
- }
912
-
913
- .activity-histogram-range {
914
- margin: 0;
915
- font-size: 10px;
916
- line-height: 1.1;
917
- letter-spacing: 0.03em;
918
- opacity: 0.58;
919
- white-space: nowrap;
920
- }
921
-
922
- .activity-histogram-bars {
923
- display: grid;
924
- grid-auto-flow: column;
925
- grid-auto-columns: minmax(0, 1fr);
926
- align-items: end;
927
- gap: 4px;
928
- height: 58px;
929
- padding-top: 2px;
930
- }
931
-
932
- .activity-histogram-bar {
933
- display: flex;
934
- flex-direction: column-reverse;
935
- justify-content: flex-start;
936
- min-width: 0;
937
- min-height: 8px;
938
- overflow: hidden;
939
- background: var(--hist-bar-bg);
940
- border: 1px solid var(--hist-bar-border);
941
- opacity: 0.9;
942
- }
943
-
944
- .activity-histogram-bar[data-empty="true"] {
945
- opacity: 0.42;
946
- }
947
-
948
- .activity-histogram-segment {
949
- display: block;
950
- width: 100%;
951
- min-height: 2px;
952
- }
953
-
954
- .activity-histogram-segment[data-family="dom"] {
955
- background: var(--hist-dom);
956
- }
957
-
958
- .activity-histogram-segment[data-family="page"] {
959
- background: var(--hist-page);
960
- }
961
-
962
- .activity-histogram-segment[data-family="layout"] {
963
- background: var(--hist-layout);
964
- }
965
-
966
- .activity-histogram-segment[data-family="style"] {
967
- background: var(--hist-style);
968
- }
969
-
970
- .activity-histogram-segment[data-family="input"] {
971
- background: var(--hist-input);
972
- }
973
-
974
- .activity-histogram-segment[data-family="patch"] {
975
- background: var(--hist-patch);
976
- }
977
-
978
- .activity-histogram-segment[data-family="capture"] {
979
- background: var(--hist-capture);
980
- }
981
-
982
- .activity-histogram-segment[data-family="other"] {
983
- background: var(--hist-other);
984
- }
985
-
986
- .activity-section-header {
987
- display: flex;
988
- align-items: center;
989
- justify-content: space-between;
990
- gap: 8px;
991
- margin: 0 0 8px;
992
- flex-shrink: 0;
993
- }
994
-
995
- #activity-section h2 {
996
- margin: 0;
997
- font-size: 15px;
998
- flex-shrink: 0;
999
- }
1000
-
1001
- .activity-summary-tokens {
1002
- font-size: 10px;
1003
- line-height: 1.2;
1004
- color: var(--muted);
1005
- white-space: nowrap;
1006
- padding: 2px 7px;
1007
- border-radius: 4px;
1008
- background: var(--panel);
1009
- border: 1px solid var(--stroke);
1010
- letter-spacing: 0.02em;
1011
- }
1012
-
1013
- .activity-summary-tokens[data-cost-class="heavy"],
1014
- .activity-summary-tokens[data-cost-class="extreme"] {
1015
- background: rgba(209, 17, 68, 0.1);
1016
- color: var(--ink);
1017
- }
1018
-
1019
- #activity-section .stack {
1020
- flex: 1 1 0;
1021
- min-height: 0;
1022
- overflow-y: auto;
1023
- overflow-x: hidden;
1024
- padding-right: 4px;
1025
- align-content: start;
1026
- }
1027
-
1028
- #activity-section .stack::-webkit-scrollbar {
1029
- width: 4px;
1030
- }
1031
- #activity-section .stack::-webkit-scrollbar-thumb {
1032
- background: var(--stroke);
1033
- border-radius: 2px;
1034
- }
1035
-
1036
- /* Collapsible examples section */
1037
- .examples-details,
1038
- .setup-details {
1039
- flex-shrink: 0;
1040
- margin-top: 12px;
1041
- }
1042
-
1043
- .setup-details,
1044
- .setup-details * {
1045
- -webkit-user-select: none;
1046
- user-select: none;
1047
- }
1048
-
1049
- .examples-details summary,
1050
- .setup-details summary {
1051
- cursor: pointer;
1052
- list-style: none;
1053
- display: flex;
1054
- align-items: center;
1055
- gap: 6px;
1056
- }
1057
-
1058
- .examples-details summary::-webkit-details-marker,
1059
- .setup-details summary::-webkit-details-marker {
1060
- display: none;
1061
- }
1062
-
1063
- .examples-details summary .eyebrow,
1064
- .setup-details summary .eyebrow {
1065
- margin: 0;
1066
- }
1067
-
1068
- .examples-details summary::after {
1069
- content: '\25B6';
1070
- font-size: 8px;
1071
- color: var(--muted);
1072
- transition: transform 0.15s;
1073
- }
1074
-
1075
- .examples-details[open] summary::after {
1076
- transform: rotate(90deg);
1077
- }
1078
-
1079
- .setup-details summary {
1080
- justify-content: space-between;
1081
- gap: 12px;
1082
- width: 100%;
1083
- }
1084
-
1085
- .setup-details-summary-heading {
1086
- display: inline-flex;
1087
- align-items: center;
1088
- gap: 6px;
1089
- flex-shrink: 0;
1090
- }
1091
-
1092
- .setup-details-summary-icon::before {
1093
- content: '\25B6';
1094
- font-size: 8px;
1095
- color: var(--muted);
1096
- transition: transform 0.15s;
1097
- display: inline-block;
1098
- }
1099
-
1100
- .setup-details[open] .setup-details-summary-icon::before {
1101
- transform: rotate(90deg);
1102
- }
1103
-
1104
- .setup-summary-note {
1105
- margin-left: auto;
1106
- color: var(--muted);
1107
- opacity: 0.72;
1108
- font-size: 12px;
1109
- flex: 1 1 auto;
1110
- min-width: 0;
1111
- text-align: right;
1112
- white-space: nowrap;
1113
- }
1114
-
1115
- .setup-details:not([open]) .setup-summary-note {
1116
- display: none;
1117
- }
1118
-
1119
- .examples-details .examples-list,
1120
- .setup-details .setup-details-body {
1121
- margin-top: 8px;
1122
- }
1123
-
1124
- @media (max-width: 360px) {
1125
- .panel {
1126
- padding: 10px;
1127
- }
1128
-
1129
- .panel header {
1130
- margin-bottom: 10px;
1131
- }
1132
-
1133
- .panel-header {
1134
- gap: 8px;
1135
- }
1136
-
1137
- .panel-header h1 {
1138
- margin: 0;
1139
- font-size: 16px;
1140
- line-height: 1.15;
1141
- }
1142
-
1143
- .card {
1144
- padding: 8px 10px;
1145
- }
1146
-
1147
- .control-card {
1148
- gap: 0;
1149
- }
1150
-
1151
- .power-button {
1152
- min-height: 36px;
1153
- font-size: 13px;
1154
- }
1155
-
1156
- .stack {
1157
- gap: 6px;
1158
- }
1159
- }