chamba 0.7.0 → 0.8.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 (120) hide show
  1. package/LICENSE +53 -14
  2. package/README.md +28 -8
  3. package/dist/commands/advanced.js +7 -278
  4. package/dist/commands/dev.js +11 -612
  5. package/dist/commands/doctor.js +1 -29
  6. package/dist/commands/menu.js +1 -80
  7. package/dist/commands/onboard.js +6 -230
  8. package/dist/commands/settings.js +15 -349
  9. package/dist/lib/agent-commands.js +2 -0
  10. package/dist/lib/agent-context.js +6 -210
  11. package/dist/lib/browser.js +1 -40
  12. package/dist/lib/chamba-yaml.js +10 -191
  13. package/dist/lib/constants.js +1 -125
  14. package/dist/lib/dockerfile-builder.js +41 -261
  15. package/dist/lib/env.js +2 -78
  16. package/dist/lib/git-env.js +1 -21
  17. package/dist/lib/global-config.js +4 -66
  18. package/dist/lib/pnpm-store.js +1 -19
  19. package/dist/lib/ports.js +1 -210
  20. package/dist/lib/safe-rm.js +1 -36
  21. package/dist/lib/sessions.js +2 -34
  22. package/dist/lib/shadows.js +1 -176
  23. package/dist/lib/skills.js +2 -0
  24. package/dist/lib/templates.js +1 -0
  25. package/dist/lib/webterm.js +1 -305
  26. package/dist/lib/workspace-identity.js +4 -260
  27. package/package.json +4 -4
  28. package/templates/Dockerfile +12 -19
  29. package/templates/claude-statusline.sh +5 -7
  30. package/templates/context/baseline.md +2 -0
  31. package/templates/pane-apps/client/assets/c-BNa-DeUl.json +3552 -0
  32. package/templates/pane-apps/client/assets/cpp-B-T4NRoH.json +20239 -0
  33. package/templates/pane-apps/client/assets/csharp-BbxHChhA.json +6010 -0
  34. package/templates/pane-apps/client/assets/css-CWCxuwmz.json +1860 -0
  35. package/templates/pane-apps/client/assets/diff-B-2N89g8.json +154 -0
  36. package/templates/pane-apps/client/assets/docker-DWTvYW26.json +103 -0
  37. package/templates/pane-apps/client/assets/files-D0nJgFAA.js +12 -0
  38. package/templates/pane-apps/client/assets/files-h0K1vZyQ.css +1 -0
  39. package/templates/pane-apps/client/assets/go-B2hyYeNg.json +3156 -0
  40. package/templates/pane-apps/client/assets/graphql-Z6Id2aNO.json +1292 -0
  41. package/templates/pane-apps/client/assets/html-BtzvlIfu.json +2627 -0
  42. package/templates/pane-apps/client/assets/ini-Bn3Twap1.json +108 -0
  43. package/templates/pane-apps/client/assets/java-C7t2dwLO.json +1885 -0
  44. package/templates/pane-apps/client/assets/javascript-DuC2v0C0.json +5996 -0
  45. package/templates/pane-apps/client/assets/json-CwdkWeV5.json +206 -0
  46. package/templates/pane-apps/client/assets/jsonc-MYWDbTU3.json +206 -0
  47. package/templates/pane-apps/client/assets/jsx-Cn8EZuIC.json +5996 -0
  48. package/templates/pane-apps/client/assets/kotlin-CFNOz1gw.json +580 -0
  49. package/templates/pane-apps/client/assets/make-BVnlFCcl.json +629 -0
  50. package/templates/pane-apps/client/assets/markdown-B4Xk2WM_.json +3263 -0
  51. package/templates/pane-apps/client/assets/php-CAQzQmmI.json +4188 -0
  52. package/templates/pane-apps/client/assets/python-CYQee8m4.json +4174 -0
  53. package/templates/pane-apps/client/assets/reviews-BsoGZ35r.css +1 -0
  54. package/templates/pane-apps/client/assets/reviews-iW0Mbn4e.js +153 -0
  55. package/templates/pane-apps/client/assets/ruby-D7R58tus.json +3114 -0
  56. package/templates/pane-apps/client/assets/rust-BFBbFiei.json +1103 -0
  57. package/templates/pane-apps/client/assets/scss-TQRhBkPG.json +1874 -0
  58. package/templates/pane-apps/client/assets/shellscript-DieAkC4W.json +2375 -0
  59. package/templates/pane-apps/client/assets/specs-D9z3neR-.js +13 -0
  60. package/templates/pane-apps/client/assets/sql-Bxd030LV.json +634 -0
  61. package/templates/pane-apps/client/assets/toml-ChrKGzsV.json +430 -0
  62. package/templates/pane-apps/client/assets/tsx-D2e90MFw.json +5996 -0
  63. package/templates/pane-apps/client/assets/typescript-DonXQ_n1.json +5747 -0
  64. package/templates/pane-apps/client/assets/xml-B17r2RXF.json +382 -0
  65. package/templates/pane-apps/client/assets/yaml-CKn4h1zy.json +627 -0
  66. package/templates/pane-apps/client/reviews/index.html +15 -0
  67. package/templates/pane-apps/client/specs/index.html +3 -2
  68. package/templates/pane-apps/server/reviews.mjs +20 -0
  69. package/templates/pane-apps/server/specs.mjs +5 -1588
  70. package/templates/skills/chamba-statusline/SKILL.md +7 -19
  71. package/templates/skills/dx-review/SKILL.md +123 -0
  72. package/templates/skills/dx-review/references/acts.md +162 -0
  73. package/templates/skills/dx-spec/SKILL.md +223 -27
  74. package/templates/skills/dx-spec/references/principles-template.md +2 -0
  75. package/templates/skills/dx-spec/references/review-guide.md +4 -50
  76. package/templates/skills/dx-spec/references/spec-guide.md +24 -4
  77. package/templates/skills/dx-spec/references/stages.md +143 -58
  78. package/templates/skills/dx-spec-execute/SKILL.md +148 -35
  79. package/templates/startup.mjs +10 -4
  80. package/templates/tool-helper.sh +166 -0
  81. package/templates/webterm/README.md +60 -26
  82. package/templates/webterm/color.js +61 -0
  83. package/templates/webterm/config.js +35 -4
  84. package/templates/webterm/context/claude.md +0 -1
  85. package/templates/webterm/public/app/alerts.js +4 -4
  86. package/templates/webterm/public/app/anchored.js +81 -0
  87. package/templates/webterm/public/app/connection.js +9 -0
  88. package/templates/webterm/public/app/dom.js +2 -0
  89. package/templates/webterm/public/app/frames.js +51 -17
  90. package/templates/webterm/public/app/main.js +22 -8
  91. package/templates/webterm/public/app/new-session.js +13 -41
  92. package/templates/webterm/public/app/palette.js +58 -0
  93. package/templates/webterm/public/app/pane-shape.js +167 -0
  94. package/templates/webterm/public/app/pane-shell.js +199 -134
  95. package/templates/webterm/public/app/pane.js +33 -24
  96. package/templates/webterm/public/app/reviews-host.js +15 -0
  97. package/templates/webterm/public/app/specs-host.js +12 -218
  98. package/templates/webterm/public/app/state.js +5 -0
  99. package/templates/webterm/public/app/tabs.js +6 -2
  100. package/templates/webterm/public/app/theme.js +75 -27
  101. package/templates/webterm/public/app/tool-host.js +302 -0
  102. package/templates/webterm/public/app/workspace-color.js +192 -0
  103. package/templates/webterm/public/index.html +17 -3
  104. package/templates/webterm/public/styles.css +143 -21
  105. package/templates/webterm/server.js +198 -150
  106. package/templates/webterm/tools/commands.js +61 -0
  107. package/templates/webterm/tools/index.js +25 -0
  108. package/templates/webterm/tools/mount.js +337 -0
  109. package/templates/webterm/tools/paths.js +34 -0
  110. package/templates/webterm/tools/reviews.js +133 -0
  111. package/templates/webterm/tools/specs.js +154 -0
  112. package/templates/webterm/typed-line.js +70 -7
  113. package/templates/context/context-usage.md +0 -1
  114. package/templates/context-usage.sh +0 -266
  115. package/templates/pane-apps/client/assets/specs-B1970L17.css +0 -1
  116. package/templates/pane-apps/client/assets/specs-cEee_SPn.js +0 -23
  117. package/templates/skills/dx-spec-config/SKILL.md +0 -313
  118. package/templates/skills/dx-spec-config/references/principles-template.md +0 -12
  119. package/templates/specs.sh +0 -106
  120. package/templates/webterm/specs.js +0 -358
@@ -634,13 +634,13 @@ body.dragging {
634
634
  }
635
635
 
636
636
  /* The width is app/pane-shell.js's, in a custom property so the three rules that must win - the collapsed
637
- spine, the full row and the narrow-screen layout - still do. The value here is what shows before the first
638
- drag. */
637
+ spine, the full row and the narrow-screen layout - still do. The value here shows for the moment before the
638
+ first draw sets the property, so it is the same half the pane's own default is. */
639
639
  #pane {
640
640
  display: flex;
641
641
  flex: none;
642
642
  flex-direction: column;
643
- width: var(--pane-width, 44%);
643
+ width: var(--pane-width, 50%);
644
644
  min-width: 0;
645
645
  background: var(--bg);
646
646
  }
@@ -706,9 +706,9 @@ body.dragging {
706
706
  #panebar {
707
707
  display: flex;
708
708
  flex: none;
709
- align-items: flex-end;
709
+ align-items: center;
710
710
  gap: 2px;
711
- padding: 7px 10px 0;
711
+ padding: 0 8px;
712
712
  background: var(--bg);
713
713
  border-bottom: 1px solid var(--border);
714
714
  }
@@ -720,21 +720,23 @@ body.dragging {
720
720
  overflow: hidden;
721
721
  }
722
722
 
723
- /* A tab is a folder mouth: the open one carries the panel's own background up into the bar, so the two read
724
- as one surface and the others read as behind it. */
723
+ /* A tab is a label with a line under it: the pane's bar is chrome rather than a surface of its own, and the
724
+ workspace's colour under the open one is what says which tool is on the screen. */
725
725
  .tool-tab {
726
726
  display: flex;
727
727
  flex: none;
728
728
  align-items: center;
729
729
  gap: 6px;
730
- padding: 4px 14px;
731
- border: 1px solid transparent;
732
- border-bottom: none;
733
- border-radius: 7px 7px 0 0;
730
+ height: 34px;
731
+ padding: 0 12px;
732
+ border: none;
733
+ /* On every tab, transparent until one is open, so the open one takes no extra height and the row of them
734
+ does not move as the tool changes. */
735
+ border-bottom: 2px solid transparent;
734
736
  background: none;
735
737
  color: var(--muted);
736
738
  font: inherit;
737
- font-size: 12.5px;
739
+ font-size: 13px;
738
740
  cursor: pointer;
739
741
  }
740
742
 
@@ -743,8 +745,7 @@ body.dragging {
743
745
  }
744
746
 
745
747
  .tool-tab.on {
746
- background: var(--panel);
747
- border-color: var(--border);
748
+ border-bottom-color: var(--ws);
748
749
  color: var(--text);
749
750
  }
750
751
 
@@ -759,22 +760,36 @@ body.dragging {
759
760
  font-weight: 700;
760
761
  }
761
762
 
763
+ /* A tool that counts nothing says only that something arrived, so its mark carries no number and is drawn
764
+ as the dot it means. */
765
+ .tool-mark.dot {
766
+ width: 6px;
767
+ height: 6px;
768
+ padding: 0;
769
+ border-radius: 50%;
770
+ align-self: center;
771
+ }
772
+
762
773
  #pane-ctl {
763
774
  display: flex;
764
775
  flex: none;
765
776
  margin-left: auto;
766
- gap: 4px;
767
- padding-bottom: 5px;
777
+ gap: 2px;
768
778
  }
769
779
 
780
+ /* The three widths, drawn as one row: the whole window, half of it, and away. */
770
781
  #pane-ctl .pane-nav {
771
782
  display: flex;
772
783
  align-items: center;
773
784
  justify-content: center;
774
- padding: 2px 5px;
785
+ width: 28px;
786
+ height: 28px;
787
+ padding: 0;
788
+ border-radius: 6px;
775
789
  }
776
790
 
777
- /* The pane is already at the far end, and the button is the way back from it. */
791
+ /* The pane is already in the state the button names, so the button says so - and for the far end it is also
792
+ the way back from it. */
778
793
  #pane-ctl .pane-nav.on {
779
794
  background: #10151c;
780
795
  color: var(--accent);
@@ -1053,6 +1068,14 @@ body.dragging .tool-frame {
1053
1068
  writing-mode: horizontal-tb;
1054
1069
  }
1055
1070
 
1071
+ #spine-badge.dot {
1072
+ display: inline-block;
1073
+ width: 6px;
1074
+ height: 6px;
1075
+ padding: 0;
1076
+ border-radius: 50%;
1077
+ }
1078
+
1056
1079
  #spine-badge[hidden] {
1057
1080
  display: none;
1058
1081
  }
@@ -1071,13 +1094,17 @@ body.dragging .tool-frame {
1071
1094
 
1072
1095
  /* ---- Overlay cards (take over / end session / limit reached) ---- */
1073
1096
 
1097
+ /* Fixed to the viewport and above every pop, so the card is in the middle of the screen whatever the width of
1098
+ the terminal column beside the pane. */
1074
1099
  #overlay {
1075
1100
  display: none;
1076
- position: absolute;
1101
+ position: fixed;
1077
1102
  inset: 0;
1103
+ z-index: 70;
1078
1104
  background: rgba(13, 17, 23, 0.82);
1079
1105
  align-items: center;
1080
1106
  justify-content: center;
1107
+ padding: 16px;
1081
1108
  }
1082
1109
 
1083
1110
  #overlay.show {
@@ -1085,7 +1112,9 @@ body.dragging .tool-frame {
1085
1112
  }
1086
1113
 
1087
1114
  .card {
1115
+ width: 100%;
1088
1116
  max-width: 460px;
1117
+ box-sizing: border-box;
1089
1118
  padding: 18px 20px;
1090
1119
  background: var(--panel);
1091
1120
  border: 1px solid var(--border);
@@ -1201,9 +1230,102 @@ body.dragging .tool-frame {
1201
1230
  }
1202
1231
  }
1203
1232
 
1233
+ /* ---- The workspace colour ---- */
1234
+
1235
+ /* The one control in the bar about what this window *is* rather than what it does, so it sits beside the name
1236
+ it belongs with. It carries no colour of its own, and is drawn exactly as the bell and the power button
1237
+ are: the bar already says which colour is in force, on the edge of the active tab, and a filled swatch in
1238
+ a row of glyphs reads as something that wandered in rather than as one of the row. */
1239
+ #wscolorbtn {
1240
+ display: flex;
1241
+ align-items: center;
1242
+ justify-content: center;
1243
+ padding: 4px;
1244
+ background: transparent;
1245
+ color: var(--muted);
1246
+ border: 1px solid transparent;
1247
+ border-radius: 7px;
1248
+ cursor: pointer;
1249
+ }
1250
+
1251
+ #wscolorbtn:hover:not(:disabled),
1252
+ #wscolorbtn.open {
1253
+ color: var(--text);
1254
+ border-color: var(--border);
1255
+ }
1256
+
1257
+ /* Nothing to open while this window is not talking to the server: a pick it could not send would be undone by
1258
+ the next frame, which is worse than not offering it. */
1259
+ #wscolorbtn:disabled {
1260
+ opacity: 0.45;
1261
+ cursor: default;
1262
+ }
1263
+
1264
+ /* Anchored under the button and hung off the body, like the new-session panel: the bar is emptied on every
1265
+ frame, and picking a colour is itself a frame, so a panel inside the bar would close as it was used. */
1266
+ #wscolorpop {
1267
+ position: fixed;
1268
+ z-index: 60;
1269
+ display: flex;
1270
+ flex-direction: column;
1271
+ width: 268px;
1272
+ padding: 12px;
1273
+ background: var(--panel);
1274
+ border: 1px solid var(--border);
1275
+ border-radius: 10px;
1276
+ box-shadow: 0 12px 28px rgba(0, 0, 0, 0.5);
1277
+ }
1278
+
1279
+ .wsgrid {
1280
+ display: grid;
1281
+ grid-template-columns: repeat(6, 1fr);
1282
+ gap: 8px;
1283
+ }
1284
+
1285
+ .wscell {
1286
+ display: flex;
1287
+ align-items: center;
1288
+ justify-content: center;
1289
+ aspect-ratio: 1;
1290
+ padding: 0;
1291
+ border: 1px solid rgba(255, 255, 255, 0.08);
1292
+ border-radius: 7px;
1293
+ cursor: pointer;
1294
+ }
1295
+
1296
+ /* Two rings rather than a thicker border, so the mark reads on every one of the eleven and the cell does not
1297
+ move when it lands. The mark says what is *stored*, so it sits on the automatic cell when nothing is. */
1298
+ .wscell.chosen {
1299
+ box-shadow:
1300
+ 0 0 0 2px var(--panel),
1301
+ 0 0 0 3.5px var(--text);
1302
+ }
1303
+
1304
+ /* Automatic takes the last cell: it is one of the choices rather than a button underneath them. */
1305
+ .wscell.auto {
1306
+ background: repeating-linear-gradient(135deg, var(--border) 0 4px, #21262d 4px 8px);
1307
+ color: var(--muted);
1308
+ font-size: 15px;
1309
+ line-height: 1;
1310
+ }
1311
+
1312
+ .wscolorfoot {
1313
+ margin: 11px 0 0;
1314
+ padding-top: 10px;
1315
+ color: var(--muted);
1316
+ border-top: 1px solid var(--border);
1317
+ font-size: 11.5px;
1318
+ line-height: 1.45;
1319
+ }
1320
+
1204
1321
  /* The moment the socket drops, before any curtain: a control whose answer goes nowhere must stop taking
1205
- clicks. The composer disables itself, so this is about the bar - its tabs, its X, its + New session. */
1206
- body.offline #tabbar {
1322
+ clicks. The composer disables itself, so this is about the bar - its tabs, its X, its + New session.
1323
+ The two anchored panels are named as well: they hang off the body rather than the bar, so the bar's own
1324
+ selector does not cover them. connection.js closes them outright when the socket goes, and this is the second
1325
+ line - a rule that holds whatever order things happen in. */
1326
+ body.offline #tabbar,
1327
+ body.offline #newpop,
1328
+ body.offline #wscolorpop {
1207
1329
  pointer-events: none;
1208
1330
  }
1209
1331