create-pmos 0.399.0 → 0.400.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 (421) hide show
  1. package/package.json +18 -13
  2. package/payload/KIT-VERSION +1 -1
  3. package/payload/planning/evals/eval-calibration.md +1 -1
  4. package/payload/planning/okrs/health-budgets.md +1 -1
  5. package/payload/state/discoveries.md +1 -1
  6. package/workspace/briefing-premium-adddoc-test.js +2 -2
  7. package/workspace/briefing-premium-board-test.js +2 -2
  8. package/workspace/briefing-premium-doc-edit-test.js +2 -8
  9. package/workspace/briefing-premium-test.js +3 -2
  10. package/workspace/briefing-premium-work-test.js +9 -4
  11. package/workspace/c3-capture-test.js +0 -17
  12. package/workspace/changelog.json +17 -0
  13. package/workspace/guide/briefing-premium.md +2 -2
  14. package/workspace/guide/home.md +20 -2
  15. package/workspace/guide/layout.md +2 -2
  16. package/workspace/guide/notes.md +2 -2
  17. package/workspace/guide/phone-companion.md +1 -1
  18. package/workspace/lib/route-modules.js +1 -9
  19. package/workspace/lib/routes-phone-day.js +18 -9
  20. package/workspace/lib/routes-slash.js +95 -0
  21. package/workspace/package-lock.json +2 -2
  22. package/workspace/package.json +1 -2
  23. package/workspace/premium-chat-goal-view-test.js +1 -1
  24. package/workspace/premium-chat-term-test.js +0 -10
  25. package/workspace/premium-menu-rows-test.js +1 -1
  26. package/workspace/premium-phone-card-test.js +2 -2
  27. package/workspace/premium-vw-doc-test.js +1 -8
  28. package/workspace/premium-work-depth-test.js +2 -3
  29. package/workspace/public/capture.html +23 -0
  30. package/workspace/public/pm/c3-base.js +47 -0
  31. package/workspace/public/pm/c3-capture.js +1 -1
  32. package/workspace/public/pm/c3-ini-ui.js +1 -1
  33. package/workspace/public/pm/c3-sheet.js +1 -1
  34. package/workspace/public/pm/c3-toast.js +1 -1
  35. package/workspace/public/pm/console3.css +3 -0
  36. package/workspace/public/pm/cozy-home.css +20 -5
  37. package/workspace/public/pm/cozy-today.css +5 -2
  38. package/workspace/public/pm/cozy-viewer.js +4 -2
  39. package/workspace/public/pm/cozy.css +9 -0
  40. package/workspace/public/pm/goal-chat.js +5 -1
  41. package/workspace/public/pm/home-app.js +47 -26
  42. package/workspace/public/pm/home-chat.js +10 -4
  43. package/workspace/public/pm/home-data.js +3 -1
  44. package/workspace/public/pm/home-dictate.js +7 -4
  45. package/workspace/public/pm/home-ini.js +12 -2
  46. package/workspace/public/pm/home-list.js +20 -7
  47. package/workspace/public/pm/home-more.js +2 -2
  48. package/workspace/public/pm/home-phone-card.js +9 -4
  49. package/workspace/public/pm/home-review.js +2 -3
  50. package/workspace/public/pm/home-today.js +10 -6
  51. package/workspace/public/pm/home-work.js +15 -8
  52. package/workspace/public/pm/note-dock.js +1 -2
  53. package/workspace/public/pm/notes-links.js +1 -2
  54. package/workspace/public/pm/notes-task.js +3 -4
  55. package/workspace/public/pm/premium-board.js +1 -1
  56. package/workspace/public/pm/premium-initiative-head.js +3 -3
  57. package/workspace/public/pm/premium-vw-doc.css +20 -2
  58. package/workspace/public/pm/premium-vw-doc.js +22 -7
  59. package/workspace/public/pm/view-notes.js +2 -2
  60. package/workspace/replaced-tests.json +435 -0
  61. package/workspace/run-tests.js +323 -28
  62. package/workspace/server.js +15 -10
  63. package/workspace/test-files.json +3 -140
  64. package/workspace/test-lists/base.json +1 -2
  65. package/workspace/test-lists/c3-desktop-light-load.json +1 -2
  66. package/workspace/test-lists/c3-initiative-boards.json +1 -2
  67. package/workspace/test-lists/c3-meeting-focus.json +2 -12
  68. package/workspace/test-lists/c3-work-agent.json +1 -2
  69. package/workspace/test-lists/calendar-tidy-up.json +1 -2
  70. package/workspace/test-lists/console3-reports.json +1 -2
  71. package/workspace/test-lists/docs-three-way-sync.json +1 -2
  72. package/workspace/test-lists/extension-capture.json +5 -0
  73. package/workspace/test-lists/jira-wbs.json +1 -2
  74. package/workspace/test-lists/legacy-cleanup-a.json +9 -0
  75. package/workspace/test-lists/meeting-material.json +1 -2
  76. package/workspace/test-lists/meeting-notes.json +2 -36
  77. package/workspace/test-lists/meeting-replay.json +1 -2
  78. package/workspace/test-lists/mm-capture.json +2 -12
  79. package/workspace/test-lists/my-work.json +2 -10
  80. package/workspace/test-lists/onboarding-firstrun.json +2 -12
  81. package/workspace/test-lists/people-directory.json +1 -2
  82. package/workspace/test-lists/run2-a.json +1 -2
  83. package/workspace/test-lists/run2-d.json +2 -19
  84. package/workspace/test-lists/run3-b.json +1 -2
  85. package/workspace/test-lists/run3-c.json +2 -12
  86. package/workspace/test-lists/run4-b.json +1 -2
  87. package/workspace/test-lists/run4-d.json +1 -5
  88. package/workspace/test-lists/run5-c.json +1 -11
  89. package/workspace/test-lists/run6.json +1 -5
  90. package/workspace/test-lists/workspace-launch-flags.json +2 -12
  91. package/workspace/test-lists/workspace-profile-detection.json +2 -10
  92. package/workspace/test-timings.json +242 -123
  93. package/workspace/c3-briefing-test.js +0 -136
  94. package/workspace/c3-core-docs-test.js +0 -170
  95. package/workspace/c3-driver-fixture.js +0 -64
  96. package/workspace/c3-driver-test.js +0 -169
  97. package/workspace/c3-foundation-test.js +0 -163
  98. package/workspace/c3-ib-items-test.js +0 -114
  99. package/workspace/c3-ib-more-test.js +0 -146
  100. package/workspace/c3-ib-triage-backlog-test.js +0 -128
  101. package/workspace/c3-ini-harness.js +0 -66
  102. package/workspace/c3-ini-life-test.js +0 -167
  103. package/workspace/c3-initiatives-test.js +0 -186
  104. package/workspace/c3-light-load-test.js +0 -112
  105. package/workspace/c3-one-home-test.js +0 -149
  106. package/workspace/c3-phone-test.js +0 -289
  107. package/workspace/c3-quiet-test.js +0 -157
  108. package/workspace/c3-report-design-real-test.js +0 -264
  109. package/workspace/c3-report-design-test.js +0 -442
  110. package/workspace/c3-report-setup-test.js +0 -192
  111. package/workspace/c3-report-structure-real-test.js +0 -248
  112. package/workspace/c3-report-structure-test.js +0 -397
  113. package/workspace/c3-reports-test.js +0 -288
  114. package/workspace/c3-scan-test.js +0 -517
  115. package/workspace/c3-sessions-panel-test.js +0 -365
  116. package/workspace/c3-settings-test.js +0 -204
  117. package/workspace/c3-updates-test.js +0 -131
  118. package/workspace/c3-work-test.js +0 -260
  119. package/workspace/cut-stub.js +0 -40
  120. package/workspace/first-paint-audit.js +0 -160
  121. package/workspace/lib/c3-full-console.js +0 -15
  122. package/workspace/lib/engine/derived/trust.js +0 -3
  123. package/workspace/lib/engine/plan-forecast.js +0 -342
  124. package/workspace/lib/engine/report-families.js +0 -175
  125. package/workspace/lib/engine/truth-table.js +0 -57
  126. package/workspace/lib/routes-c3-init.js +0 -54
  127. package/workspace/lib/routes-c3-life.js +0 -120
  128. package/workspace/lib/routes-c3-timeline.js +0 -192
  129. package/workspace/lib/routes-forecast.js +0 -86
  130. package/workspace/lib/routes-releases.js +0 -130
  131. package/workspace/lib/routes-report-facts.js +0 -85
  132. package/workspace/lib/routes-report-families.js +0 -33
  133. package/workspace/lib/routes-signals.js +0 -51
  134. package/workspace/lib/routes-timeline.js +0 -197
  135. package/workspace/public/c3.html +0 -35
  136. package/workspace/public/index.html +0 -156
  137. package/workspace/public/pm/app.js +0 -831
  138. package/workspace/public/pm/bd-board.js +0 -159
  139. package/workspace/public/pm/bd-drag.js +0 -59
  140. package/workspace/public/pm/bd-model.js +0 -152
  141. package/workspace/public/pm/bd-timeline.js +0 -233
  142. package/workspace/public/pm/bd-tree.js +0 -244
  143. package/workspace/public/pm/board-copy.js +0 -59
  144. package/workspace/public/pm/board-read.js +0 -38
  145. package/workspace/public/pm/branches-sheet.js +0 -56
  146. package/workspace/public/pm/breakdown-api.js +0 -58
  147. package/workspace/public/pm/breakdown-copy.js +0 -138
  148. package/workspace/public/pm/briefing-deck.js +0 -441
  149. package/workspace/public/pm/briefing-model.js +0 -251
  150. package/workspace/public/pm/c3-ambient.js +0 -100
  151. package/workspace/public/pm/c3-audience-link.js +0 -21
  152. package/workspace/public/pm/c3-audience.js +0 -46
  153. package/workspace/public/pm/c3-boot.js +0 -13
  154. package/workspace/public/pm/c3-breakdown.js +0 -240
  155. package/workspace/public/pm/c3-brief-data.js +0 -11
  156. package/workspace/public/pm/c3-brief-mentions.js +0 -137
  157. package/workspace/public/pm/c3-brief-needs.js +0 -288
  158. package/workspace/public/pm/c3-brief-pulse.js +0 -112
  159. package/workspace/public/pm/c3-brief-summary.js +0 -139
  160. package/workspace/public/pm/c3-brief-today.js +0 -79
  161. package/workspace/public/pm/c3-brief.js +0 -279
  162. package/workspace/public/pm/c3-cal-strategy.js +0 -529
  163. package/workspace/public/pm/c3-calendar.js +0 -965
  164. package/workspace/public/pm/c3-calpop.js +0 -111
  165. package/workspace/public/pm/c3-case.js +0 -196
  166. package/workspace/public/pm/c3-core-docs.css +0 -18
  167. package/workspace/public/pm/c3-core-docs.js +0 -236
  168. package/workspace/public/pm/c3-daypart.js +0 -176
  169. package/workspace/public/pm/c3-demo-boards.js +0 -764
  170. package/workspace/public/pm/c3-demo-brief-ix.js +0 -350
  171. package/workspace/public/pm/c3-demo-brief-page.js +0 -70
  172. package/workspace/public/pm/c3-demo-cal-ix.js +0 -74
  173. package/workspace/public/pm/c3-demo-cal2.js +0 -66
  174. package/workspace/public/pm/c3-demo-cal3.js +0 -173
  175. package/workspace/public/pm/c3-demo-cal4.js +0 -169
  176. package/workspace/public/pm/c3-demo-cal5.js +0 -52
  177. package/workspace/public/pm/c3-demo-coredocs.js +0 -221
  178. package/workspace/public/pm/c3-demo-data.js +0 -552
  179. package/workspace/public/pm/c3-demo-focus.js +0 -181
  180. package/workspace/public/pm/c3-demo-init.js +0 -430
  181. package/workspace/public/pm/c3-demo-life.js +0 -77
  182. package/workspace/public/pm/c3-demo-material.js +0 -58
  183. package/workspace/public/pm/c3-demo-misc2.js +0 -34
  184. package/workspace/public/pm/c3-demo-phone.js +0 -48
  185. package/workspace/public/pm/c3-demo-plan2.js +0 -30
  186. package/workspace/public/pm/c3-demo-rd.js +0 -432
  187. package/workspace/public/pm/c3-demo-rep-ix.js +0 -126
  188. package/workspace/public/pm/c3-demo-rep2.js +0 -130
  189. package/workspace/public/pm/c3-demo-rep3.js +0 -138
  190. package/workspace/public/pm/c3-demo-rs.js +0 -287
  191. package/workspace/public/pm/c3-demo-term.js +0 -153
  192. package/workspace/public/pm/c3-demo-time.js +0 -49
  193. package/workspace/public/pm/c3-demo-work-ix.js +0 -32
  194. package/workspace/public/pm/c3-demo.js +0 -131
  195. package/workspace/public/pm/c3-design-studio.js +0 -369
  196. package/workspace/public/pm/c3-doc-formats.js +0 -153
  197. package/workspace/public/pm/c3-doc-sheet.js +0 -1230
  198. package/workspace/public/pm/c3-dock.js +0 -206
  199. package/workspace/public/pm/c3-docs.js +0 -291
  200. package/workspace/public/pm/c3-driver-work.js +0 -110
  201. package/workspace/public/pm/c3-driver.css +0 -18
  202. package/workspace/public/pm/c3-driver.js +0 -298
  203. package/workspace/public/pm/c3-focus.css +0 -304
  204. package/workspace/public/pm/c3-focus.js +0 -983
  205. package/workspace/public/pm/c3-ib-docs.js +0 -92
  206. package/workspace/public/pm/c3-ib-initiatives.js +0 -201
  207. package/workspace/public/pm/c3-ib-items.js +0 -210
  208. package/workspace/public/pm/c3-ib-releases.js +0 -48
  209. package/workspace/public/pm/c3-ib-sprints.js +0 -201
  210. package/workspace/public/pm/c3-ib-triage.js +0 -177
  211. package/workspace/public/pm/c3-ii-tabs.js +0 -252
  212. package/workspace/public/pm/c3-ini-life.css +0 -34
  213. package/workspace/public/pm/c3-ini-life.js +0 -379
  214. package/workspace/public/pm/c3-ini-records.js +0 -197
  215. package/workspace/public/pm/c3-ini-timeline.js +0 -278
  216. package/workspace/public/pm/c3-ini-work.js +0 -139
  217. package/workspace/public/pm/c3-init-extras.js +0 -170
  218. package/workspace/public/pm/c3-initiatives.js +0 -852
  219. package/workspace/public/pm/c3-lifecycle-panels.js +0 -479
  220. package/workspace/public/pm/c3-look.js +0 -27
  221. package/workspace/public/pm/c3-material.css +0 -22
  222. package/workspace/public/pm/c3-material.js +0 -321
  223. package/workspace/public/pm/c3-md.js +0 -3
  224. package/workspace/public/pm/c3-misc-panels.js +0 -89
  225. package/workspace/public/pm/c3-new-session.js +0 -110
  226. package/workspace/public/pm/c3-notes.js +0 -751
  227. package/workspace/public/pm/c3-phone-boot.js +0 -47
  228. package/workspace/public/pm/c3-phone-detail.js +0 -97
  229. package/workspace/public/pm/c3-phone-model.js +0 -3
  230. package/workspace/public/pm/c3-phone.css +0 -66
  231. package/workspace/public/pm/c3-phone.js +0 -444
  232. package/workspace/public/pm/c3-plan-panels.js +0 -163
  233. package/workspace/public/pm/c3-plan.js +0 -193
  234. package/workspace/public/pm/c3-quiet.css +0 -113
  235. package/workspace/public/pm/c3-quiet.js +0 -177
  236. package/workspace/public/pm/c3-replay.css +0 -133
  237. package/workspace/public/pm/c3-replay.js +0 -429
  238. package/workspace/public/pm/c3-report-deck.css +0 -163
  239. package/workspace/public/pm/c3-report-deck.js +0 -598
  240. package/workspace/public/pm/c3-report-frame.css +0 -20
  241. package/workspace/public/pm/c3-report-print.css +0 -20
  242. package/workspace/public/pm/c3-report-setup.css +0 -67
  243. package/workspace/public/pm/c3-report-setup.js +0 -298
  244. package/workspace/public/pm/c3-report-store.js +0 -244
  245. package/workspace/public/pm/c3-report-structure.css +0 -44
  246. package/workspace/public/pm/c3-report-structure.js +0 -473
  247. package/workspace/public/pm/c3-reports.css +0 -68
  248. package/workspace/public/pm/c3-reports.js +0 -377
  249. package/workspace/public/pm/c3-roadmap.js +0 -249
  250. package/workspace/public/pm/c3-scan-api.js +0 -167
  251. package/workspace/public/pm/c3-scan-next.js +0 -248
  252. package/workspace/public/pm/c3-scan-setup.js +0 -313
  253. package/workspace/public/pm/c3-scan-words.js +0 -41
  254. package/workspace/public/pm/c3-scan.css +0 -74
  255. package/workspace/public/pm/c3-scan.js +0 -93
  256. package/workspace/public/pm/c3-session-chat.js +0 -103
  257. package/workspace/public/pm/c3-session-conv.js +0 -165
  258. package/workspace/public/pm/c3-session-term.js +0 -216
  259. package/workspace/public/pm/c3-settings.css +0 -85
  260. package/workspace/public/pm/c3-settings.js +0 -1045
  261. package/workspace/public/pm/c3-shell.js +0 -628
  262. package/workspace/public/pm/c3-signals.js +0 -196
  263. package/workspace/public/pm/c3-strategy-panels.js +0 -45
  264. package/workspace/public/pm/c3-swipe.js +0 -230
  265. package/workspace/public/pm/c3-terminal-data.js +0 -48
  266. package/workspace/public/pm/c3-terminal-edge.js +0 -91
  267. package/workspace/public/pm/c3-terminal-icons.js +0 -40
  268. package/workspace/public/pm/c3-terminal-results.js +0 -141
  269. package/workspace/public/pm/c3-terminal.js +0 -52
  270. package/workspace/public/pm/c3-tickets.js +0 -163
  271. package/workspace/public/pm/c3-timeline.js +0 -201
  272. package/workspace/public/pm/calendar-views.js +0 -1049
  273. package/workspace/public/pm/console3-lift.md +0 -220
  274. package/workspace/public/pm/cozy-home.js +0 -172
  275. package/workspace/public/pm/cozy-initiative.css +0 -138
  276. package/workspace/public/pm/cycle-review.js +0 -125
  277. package/workspace/public/pm/data.js +0 -1577
  278. package/workspace/public/pm/dest-board.js +0 -444
  279. package/workspace/public/pm/dest-docs.js +0 -530
  280. package/workspace/public/pm/dest-initiatives.js +0 -162
  281. package/workspace/public/pm/dest-mywork.js +0 -307
  282. package/workspace/public/pm/dest-notes.js +0 -537
  283. package/workspace/public/pm/dest-people.js +0 -449
  284. package/workspace/public/pm/dest-reports.js +0 -383
  285. package/workspace/public/pm/dest-settings.js +0 -601
  286. package/workspace/public/pm/dest-today.js +0 -267
  287. package/workspace/public/pm/display-word.js +0 -56
  288. package/workspace/public/pm/doc-editor.js +0 -473
  289. package/workspace/public/pm/doc-graph.js +0 -272
  290. package/workspace/public/pm/doc-health-panel.js +0 -110
  291. package/workspace/public/pm/doc-rail.js +0 -167
  292. package/workspace/public/pm/doc-remote.js +0 -180
  293. package/workspace/public/pm/dock-sessions.js +0 -472
  294. package/workspace/public/pm/dock.js +0 -216
  295. package/workspace/public/pm/fixture.js +0 -821
  296. package/workspace/public/pm/flag-picker.js +0 -104
  297. package/workspace/public/pm/frame-copy.js +0 -278
  298. package/workspace/public/pm/freshness-line.js +0 -149
  299. package/workspace/public/pm/handoff-box.js +0 -82
  300. package/workspace/public/pm/initiative-list.js +0 -235
  301. package/workspace/public/pm/initiative-sheet.js +0 -331
  302. package/workspace/public/pm/initiatives-api.js +0 -95
  303. package/workspace/public/pm/initiatives-copy.js +0 -287
  304. package/workspace/public/pm/initiatives-timeline-copy.js +0 -59
  305. package/workspace/public/pm/initiatives-timeline.js +0 -410
  306. package/workspace/public/pm/initiatives-ui.js +0 -291
  307. package/workspace/public/pm/item-sheet.js +0 -268
  308. package/workspace/public/pm/keep-card.js +0 -204
  309. package/workspace/public/pm/lifecycle-lens-model.js +0 -246
  310. package/workspace/public/pm/lifecycle-lens.js +0 -276
  311. package/workspace/public/pm/lifecycle.js +0 -111
  312. package/workspace/public/pm/mobile.css +0 -366
  313. package/workspace/public/pm/mobile.js +0 -581
  314. package/workspace/public/pm/modes-live.js +0 -453
  315. package/workspace/public/pm/modes.js +0 -147
  316. package/workspace/public/pm/my-work-card.js +0 -51
  317. package/workspace/public/pm/my-work-data.js +0 -36
  318. package/workspace/public/pm/new-initiative-sheet.js +0 -169
  319. package/workspace/public/pm/next-step-ui.js +0 -190
  320. package/workspace/public/pm/outbox-panel.js +0 -125
  321. package/workspace/public/pm/palette-copy.js +0 -55
  322. package/workspace/public/pm/palette.js +0 -343
  323. package/workspace/public/pm/panel-breakdown.js +0 -702
  324. package/workspace/public/pm/panel-cockpit.js +0 -425
  325. package/workspace/public/pm/panel-detail.js +0 -1513
  326. package/workspace/public/pm/panel-initiatives.js +0 -929
  327. package/workspace/public/pm/panel-newsess.js +0 -709
  328. package/workspace/public/pm/panel-repos.js +0 -741
  329. package/workspace/public/pm/panel-tabs.js +0 -1506
  330. package/workspace/public/pm/panel-trees.js +0 -204
  331. package/workspace/public/pm/people-link.js +0 -106
  332. package/workspace/public/pm/phone-deck.js +0 -167
  333. package/workspace/public/pm/pm-work-view.js +0 -1533
  334. package/workspace/public/pm/portfolio-report.js +0 -61
  335. package/workspace/public/pm/premium-acts.js +0 -280
  336. package/workspace/public/pm/premium-brief.js +0 -111
  337. package/workspace/public/pm/premium-chat.js +0 -22
  338. package/workspace/public/pm/premium-doc-sheet.js +0 -312
  339. package/workspace/public/pm/premium-initiative.js +0 -324
  340. package/workspace/public/pm/premium-insights.css +0 -228
  341. package/workspace/public/pm/premium-metric-tiles.js +0 -68
  342. package/workspace/public/pm/premium-report-brief.js +0 -132
  343. package/workspace/public/pm/premium-vw-rec.js +0 -67
  344. package/workspace/public/pm/premium-wide.css +0 -30
  345. package/workspace/public/pm/print.css +0 -44
  346. package/workspace/public/pm/provider-cards.js +0 -136
  347. package/workspace/public/pm/registry.js +0 -203
  348. package/workspace/public/pm/release-card.js +0 -110
  349. package/workspace/public/pm/releases-view.js +0 -248
  350. package/workspace/public/pm/report-families-view.js +0 -505
  351. package/workspace/public/pm/report-slides.js +0 -438
  352. package/workspace/public/pm/report-tab.js +0 -33
  353. package/workspace/public/pm/report-view.js +0 -337
  354. package/workspace/public/pm/reports-copy.js +0 -134
  355. package/workspace/public/pm/roadmap.js +0 -294
  356. package/workspace/public/pm/run-card.js +0 -260
  357. package/workspace/public/pm/sessions-panel.js +0 -219
  358. package/workspace/public/pm/sheet-jira.js +0 -353
  359. package/workspace/public/pm/shell-bell.js +0 -163
  360. package/workspace/public/pm/shell-model.js +0 -83
  361. package/workspace/public/pm/shell-phone.js +0 -124
  362. package/workspace/public/pm/shell-readaloud.js +0 -53
  363. package/workspace/public/pm/shell-recording.js +0 -274
  364. package/workspace/public/pm/shell-ticker.js +0 -90
  365. package/workspace/public/pm/sig-watch.js +0 -41
  366. package/workspace/public/pm/slide-confirm.js +0 -163
  367. package/workspace/public/pm/slides-copy.js +0 -52
  368. package/workspace/public/pm/status-banner.js +0 -95
  369. package/workspace/public/pm/tab-doc.js +0 -859
  370. package/workspace/public/pm/tab-gone.js +0 -21
  371. package/workspace/public/pm/tab-term.js +0 -1210
  372. package/workspace/public/pm/tab-web.js +0 -90
  373. package/workspace/public/pm/timeline-copy.js +0 -48
  374. package/workspace/public/pm/timeline-forecast-view.js +0 -164
  375. package/workspace/public/pm/today-agenda.js +0 -331
  376. package/workspace/public/pm/today-cards.js +0 -244
  377. package/workspace/public/pm/today-copy.js +0 -506
  378. package/workspace/public/pm/today-day.js +0 -1371
  379. package/workspace/public/pm/today-goals.js +0 -297
  380. package/workspace/public/pm/today-jobs.js +0 -84
  381. package/workspace/public/pm/today-mentions.js +0 -50
  382. package/workspace/public/pm/topbar.js +0 -202
  383. package/workspace/public/pm/triage-card.js +0 -60
  384. package/workspace/public/pm/undo-hold.js +0 -103
  385. package/workspace/public/pm/view-addrepo.js +0 -208
  386. package/workspace/public/pm/view-files.js +0 -197
  387. package/workspace/public/pm/view-livenotes.js +0 -399
  388. package/workspace/public/pm/view-today.js +0 -13
  389. package/workspace/public/pm/view-validate.js +0 -171
  390. package/workspace/public/pm/welcome.js +0 -391
  391. package/workspace/public/pm/work-place.js +0 -68
  392. package/workspace/public/pm/xlsx-read.js +0 -117
  393. package/workspace/public/welcome.html +0 -22
  394. package/workspace/test-lists/browser-suites-green.json +0 -5
  395. package/workspace/test-lists/c3-core-docs.json +0 -9
  396. package/workspace/test-lists/c3-doc-sheet-rich.json +0 -6
  397. package/workspace/test-lists/c3-doc-sheet-size.json +0 -6
  398. package/workspace/test-lists/c3-doc-sheet-v2.json +0 -6
  399. package/workspace/test-lists/c3-ib-items.json +0 -9
  400. package/workspace/test-lists/c3-ib-more.json +0 -9
  401. package/workspace/test-lists/c3-ib-triage-backlog.json +0 -9
  402. package/workspace/test-lists/c3-ini-life.json +0 -9
  403. package/workspace/test-lists/c3-meeting-board.json +0 -5
  404. package/workspace/test-lists/c3-meeting-card.json +0 -5
  405. package/workspace/test-lists/c3-notes-place.json +0 -5
  406. package/workspace/test-lists/c3-notes-series.json +0 -5
  407. package/workspace/test-lists/calendar-time-page.json +0 -5
  408. package/workspace/test-lists/calpop.json +0 -4
  409. package/workspace/test-lists/console3-briefing.json +0 -9
  410. package/workspace/test-lists/console3-foundation.json +0 -9
  411. package/workspace/test-lists/console3-work-page.json +0 -9
  412. package/workspace/test-lists/premium-brief-parity.json +0 -9
  413. package/workspace/test-lists/report-design-studio-ui.json +0 -5
  414. package/workspace/test-lists/report-structure-ui.json +0 -11
  415. package/workspace/test-lists/report-workspace-ui.json +0 -5
  416. package/workspace/test-lists/run3-a.json +0 -5
  417. package/workspace/test-lists/run3-d.json +0 -6
  418. package/workspace/test-lists/run4-c.json +0 -13
  419. package/workspace/test-lists/today-goals-jobs-ui.json +0 -5
  420. package/workspace/test-lists/today-mentions-cards.json +0 -5
  421. package/workspace/test-lists/workspace-tabs-declutter.json +0 -13
@@ -105,9 +105,6 @@ const GROUPS = {
105
105
  // Suites that run elsewhere on purpose, so --check does not count them as unwired.
106
106
  const ELSEWHERE = {
107
107
  'offline-tarball.test.js': 'npm run test:offline (needs a packed tarball)',
108
- // A helper module, not a suite: the Breakdown suites require it (pm-os-absorb Run 1). Its name keeps it out of the
109
- // tarball (BUNDLE_EXCLUDES has 'pm-*-test.js'), which is why it ends in -test.js.
110
- 'pm-breakdown-stub-test.js': 'not a suite — the helpers pm-breakdown-test.js, pm-breakdown-phone-test.js and first-paint-count.test.js require',
111
108
  };
112
109
  for (const [f, h] of Object.entries(fragHelpers)) {
113
110
  if (ELSEWHERE[f]) fragProblems.push(`${h.where}: helper ${f} is already exempt in run-tests.js`);
@@ -144,20 +141,315 @@ function shardOf(list, spec) {
144
141
 
145
142
  // Files every page or every suite loads. A change to one can break any suite, so --changed runs
146
143
  // the whole group. A changed file no suite can be traced to is treated the same way (see below).
144
+ // server.js is not on the list: traceChanges() reads which part of it changed (see there).
147
145
  const WIDE = new Set([
148
- 'server.js', 'test-run.js', 'run-tests.js', 'test-files.json', 'package.json', 'package-lock.json',
146
+ 'test-run.js', 'run-tests.js', 'test-files.json', 'package.json', 'package-lock.json',
149
147
  'public/pm/app.js', 'public/pm/state.js', 'public/pm/dom.js', 'public/pm/data.js',
150
148
  'public/pm/tokens.css', 'public/pm/fixture.js', 'public/pm/mobile.css', 'lib/find-browser.js',
151
149
  ]);
152
150
 
153
- /* The suites in `list` that the diff against `ref` can reach. A suite is selected when its own file
154
- * changed, when its source names a changed file (`panel-tabs` in pm-tabs-test.js), or when its file
155
- * name carries the changed file's stem with any panel-/view-/tab- prefix removed (view-memory.js ->
156
- * pm-r29-memory-test.js). It errs toward running MORE: a WIDE file, or a changed workspace file that
157
- * no suite can be traced to, selects the whole list. Returns { files, suites, why }. */
151
+ /* Tracing a change to the suites it can reach (workspace-legacy-cleanup, step 1).
152
+ *
153
+ * Before this, a change to server.js (then on the WIDE list) or to a lib/ file that no suite names ran every suite: 57 of
154
+ * the 60 workspace commits before 2026-10-23 ran the whole browser group. traceChanges() follows a change along the edges
155
+ * a suite depends on, and falls back to every suite wherever it cannot tell. The rule, by kind of file:
156
+ *
157
+ * - A suite: that suite. A WIDE file: every suite. Prose (guide/, docs/, *.md) and test-timings.json: nothing.
158
+ * - public/, and a lib/ file the server hands to the browser as /lib/<name>.js: the pages that load the file, read from
159
+ * the import graph of each public/*.html (static and dynamic imports and every '/pm/…' or './…' string, comments
160
+ * removed, so it reads MORE edges than the browser follows, never fewer), then every browser suite that opens one of
161
+ * those pages. A browser suite whose page the tracer cannot name (a bare '/', a path built from a variable, a redirect
162
+ * stub with no script) counts as opening every page. A file that no page loads by a path the graph can read may be
163
+ * loaded by a path built at run time, so it reaches every browser suite. Also, as before, every suite whose source
164
+ * names the file's stem.
165
+ * - server.js: the changed lines (git diff -U0). A comment or blank line reaches nothing. A line inside one route block
166
+ * of handleRequest (an `if (p === '/api/…')` statement up to the next statement at its indent) reaches that route. A
167
+ * line inside a top-level function reaches whatever uses that function, followed by name to the route blocks and the
168
+ * functions that use it. Anything else (top-level setup, middleware between route blocks, a page route, a name used
169
+ * outside any function or route block) reaches every suite.
170
+ * - lib/routes-<x>.js (a route module that lib/route-modules.js loads): every '/api/…' route the file names.
171
+ * - Any other file: the files that name it (a require, an import or a path string), followed the same way: server.js
172
+ * through the names it binds the module to, a lib/ file through its own users, a suite directly. A lib/ file that no
173
+ * file names reaches every suite.
174
+ * - A route reaches each suite whose source names it and each public file that names it (then as public/ above). Its
175
+ * parent path counts too ('/api/plan-items/handoff/' for '/api/plan-items/handoff/go'), so a client that builds the
176
+ * last part of the path is still found. A route that nothing names reaches every suite.
177
+ *
178
+ * It errs toward MORE at every step. What it cannot see is a path built from parts, or a require through a variable: a
179
+ * workflow_dispatch run, or the self-hosted runner, still runs every suite. Measured on the 60 workspace commits before
180
+ * 2026-10-23 (browser group): the old rule ran every browser suite for 57, this one for 35. Most of the rest touch code
181
+ * that every server runs at boot or on a timer (session restore, the background ticks), and that rightly reaches every
182
+ * suite. run-tests-trace.test.js holds the rule to these cases. Returns { suites, why }. */
183
+ /* The source with its comments removed and every line kept in place. A scanner, not a regex: '/api/*' in a string, or
184
+ * '//' in a regex, would make a regex eat code, and code read as a comment is a change the tracer would skip. A '/' starts
185
+ * a regex literal after an operator, an opening bracket, a keyword or the start of the file; anywhere else it divides. */
186
+ function strip(src) {
187
+ const s = String(src); let out = ''; let i = 0; const n = s.length;
188
+ const tpl = []; // brace depth at each open ${ of a template literal
189
+ let depth = 0; let prev = ''; // the last significant code character
190
+ const regexOK = () => !prev || /[(,=:[!&|?{};+\-*%<>~^]/.test(prev) || /\b(return|typeof|case|do|else|in|of|void|yield|await)$/.test(out.trimEnd().slice(-8));
191
+ while (i < n) {
192
+ const c = s[i]; const d = s[i + 1];
193
+ if (c === '/' && d === '/') { while (i < n && s[i] !== '\n') i++; continue; }
194
+ if (c === '/' && d === '*') { const e = s.indexOf('*/', i + 2); const end = e < 0 ? n : e + 2; out += s.slice(i, end).replace(/[^\n]/g, ''); i = end; continue; }
195
+ if (c === '\'' || c === '"') {
196
+ let j = i + 1; while (j < n && s[j] !== c && s[j] !== '\n') j += s[j] === '\\' ? 2 : 1;
197
+ out += s.slice(i, j + 1); i = j + 1; prev = c; continue;
198
+ }
199
+ if (c === '`' || (c === '}' && tpl.length && tpl[tpl.length - 1] === depth)) {
200
+ if (c === '}') tpl.pop();
201
+ let j = i + 1;
202
+ while (j < n && s[j] !== '`' && !(s[j] === '$' && s[j + 1] === '{')) j += s[j] === '\\' ? 2 : 1;
203
+ if (s[j] === '$') { tpl.push(depth); out += s.slice(i, j + 2); i = j + 2; prev = '{'; continue; }
204
+ out += s.slice(i, j + 1); i = j + 1; prev = '`'; continue;
205
+ }
206
+ if (c === '/' && regexOK()) {
207
+ let j = i + 1; let cls = false;
208
+ while (j < n && s[j] !== '\n' && (cls || s[j] !== '/')) { if (s[j] === '\\') j++; else if (s[j] === '[') cls = true; else if (s[j] === ']') cls = false; j++; }
209
+ out += s.slice(i, j + 1); i = j + 1; prev = 'a'; continue;
210
+ }
211
+ if (c === '{') depth++; else if (c === '}') depth--;
212
+ out += c; if (!/\s/.test(c)) prev = c; i++;
213
+ }
214
+ return out;
215
+ }
216
+ const SUITE_NAME = /^(test\.js|[^/]+(\.test\.(js|mjs)|-test\.js))$/;
217
+ const reEsc = (s) => s.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
218
+ // The page a path serves, where it is not public/<name>.html (server.js handleRequest, the page routes). A change to those
219
+ // routes in server.js reaches every suite, so this table cannot go stale without a run of everything.
220
+ const PAGE_ALIAS = { '': ['premium.html'], index: ['premium.html'], console: ['c3.html'], c3: ['c3.html', 'premium.html'], classic: ['index.html'] };
221
+
222
+ function traceChanges(changes, ctx) {
223
+ const { list, read, files: allFiles, browser } = ctx;
224
+ const src = new Map();
225
+ const get = (f) => { if (!src.has(f)) src.set(f, read(f)); return src.get(f); };
226
+ const bare = new Map(); // the source without comments
227
+ const sget = (f) => { if (!bare.has(f)) { const t = get(f); bare.set(f, t == null ? null : strip(t)); } return bare.get(f); };
228
+ const stemOf = (f) => path.basename(f).replace(/\.[^.]+$/, '');
229
+ const inList = new Set(list);
230
+ const picked = new Set();
231
+ const nameHits = (f) => {
232
+ const stem = stemOf(f); const key = stem.replace(/^(panel|view|tab)-/, '');
233
+ return list.filter((s) => (get(s) || '').includes(stem) || s.includes(`-${key}-`) || s.includes(`-${key}.`));
234
+ };
235
+ const code = allFiles.filter((f) => /\.(m?js|html)$/.test(f));
236
+
237
+ let rev = null; // the public import graph, reversed: file -> the files that load it
238
+ const publicGraph = () => {
239
+ if (rev) return rev;
240
+ rev = new Map();
241
+ const known = new Set(allFiles);
242
+ for (const f of allFiles.filter((x) => x.startsWith('public/') && /\.(html|m?js|css)$/.test(x))) {
243
+ const dir = path.posix.dirname(f);
244
+ for (const m of strip(get(f) || '').matchAll(/['"`(]((?:\.{1,2}\/|\/)?[\w\-/.]+\.(?:m?js|css))['"`)?#]/g)) {
245
+ const r = m[1];
246
+ const cands = r.startsWith('/lib/') ? [r.slice(1)] : r.startsWith('/') ? ['public' + r] : [path.posix.join(dir, r), 'public/pm/' + path.posix.basename(r)];
247
+ for (const t of cands) if (known.has(t)) { if (!rev.has(t)) rev.set(t, new Set()); rev.get(t).add(f); }
248
+ }
249
+ }
250
+ return rev;
251
+ };
252
+ const pagesOf = (f) => {
253
+ const g = publicGraph(); const seen = new Set([f]); const q = [f]; const pages = new Set();
254
+ while (q.length) {
255
+ const x = q.pop();
256
+ if (/^public\/[^/]+\.html$/.test(x)) pages.add(path.posix.basename(x));
257
+ for (const y of g.get(x) || []) if (!seen.has(y)) { seen.add(y); q.push(y); }
258
+ }
259
+ return pages;
260
+ };
261
+ const opened = new Map(); // suite -> the pages it opens, or null for every page
262
+ const opens = (s) => {
263
+ if (opened.has(s)) return opened.get(s);
264
+ const t = get(s) || '';
265
+ let out = /(?:\}|BASE|base|origin|url)\s*\+?\s*['"`]?\/['"`?#]|['"`]\/['"`]/.test(t) ? null : new Set();
266
+ if (out) {
267
+ for (const m of t.matchAll(/['"`/]\/?([\w-]*?)(?:\.html)?['"`?#]/g)) {
268
+ if (!/^(premium[\w-]*|c3|console|classic|index|welcome)$/.test(m[1])) continue;
269
+ for (const h of PAGE_ALIAS[m[1]] || [`${m[1]}.html`]) {
270
+ const html = get(`public/${h}`);
271
+ if (html == null || !/<script/.test(html)) { out = null; break; }
272
+ out.add(h);
273
+ }
274
+ if (!out) break;
275
+ }
276
+ }
277
+ if (out && !out.size) out = null;
278
+ opened.set(s, out);
279
+ return out;
280
+ };
281
+ const viaPublic = (f) => {
282
+ const pages = pagesOf(f);
283
+ // no page loads it by any path the graph can read: a path built at run time may, so every browser suite
284
+ for (const s of list) if (browser.has(s)) { const o = opens(s); if (!pages.size || o === null || [...o].some((p) => pages.has(p))) picked.add(s); }
285
+ for (const s of nameHits(f)) picked.add(s);
286
+ };
287
+ // a route: its users, or the reason it cannot tell
288
+ const routeMemo = new Map();
289
+ const route = (r, where) => {
290
+ if (routeMemo.has(r)) return routeMemo.get(r);
291
+ routeMemo.set(r, null);
292
+ const w = route1(r, where);
293
+ routeMemo.set(r, w);
294
+ return w;
295
+ };
296
+ const route1 = (r, where) => {
297
+ const keys = [r]; const parent = r.replace(/[^/]+$/, '');
298
+ if (parent.length > '/api/'.length && parent !== r) keys.push(parent);
299
+ let hit = false;
300
+ for (const f of code) {
301
+ if (f === 'server.js' || /^lib\/route(s-|-modules)/.test(f)) continue;
302
+ const t = get(f); if (!t || !keys.some((k) => t.includes(k))) continue;
303
+ hit = true;
304
+ if (inList.has(f)) picked.add(f);
305
+ else if (SUITE_NAME.test(f)) continue; // a suite of another group: nothing depends on it
306
+ else if (f.startsWith('public/')) viaPublic(f);
307
+ else { const w = users(f); if (w) return w; }
308
+ }
309
+ return hit ? null : `${where}: nothing names the route ${r}`;
310
+ };
311
+ const routes = (keys, where) => { for (const r of keys) { const w = route(r, where); if (w) return w; } return null; };
312
+ const routeModule = (f) => {
313
+ const keys = [...new Set([...strip(get(f) || '').matchAll(/['"`](\/api\/[^'"`?$]*)/g)].map((m) => m[1]))];
314
+ return keys.length ? routes(keys, f) : `${f} names no /api/ route`;
315
+ };
316
+
317
+ let S = null; // server.js, parsed once: its top-level functions and the route blocks of handleRequest
318
+ const parseServer = () => {
319
+ if (S) return S;
320
+ const L = (get('server.js') || '').split('\n');
321
+ const C = (sget('server.js') || '').split('\n'); // the same lines, comments removed
322
+ const fn = [];
323
+ for (let i = 0; i < C.length; i++) {
324
+ const m = /^(?:async\s+)?function\s*\*?\s*(\w+)|^(?:const|let)\s+(\w+)\s*=\s*(?:async\s*)?(?:function\b|\([^)]*\)\s*=>|\w+\s*=>)/.exec(C[i]);
325
+ if (!m) continue;
326
+ let j = i;
327
+ if (/\{\s*$/.test(C[i]) || !/;\s*$/.test(C[i])) { j = i + 1; while (j < C.length && !/^\}/.test(C[j])) j++; }
328
+ fn.push({ name: m[1] || m[2], a: i + 1, b: j + 1 });
329
+ i = j;
330
+ }
331
+ const blocks = [];
332
+ const hr = fn.find((x) => x.name === 'handleRequest');
333
+ if (hr) {
334
+ const starts = [];
335
+ for (let i = hr.a; i < hr.b - 1; i++) if (/^ {2}[^\s}\])/]/.test(L[i]) && !/^ {2}\/\//.test(L[i])) starts.push(i + 1);
336
+ starts.push(hr.b);
337
+ for (let k = 0; k < starts.length - 1; k++) {
338
+ const head = L[starts[k] - 1];
339
+ if (!/^ {2}if \(/.test(head) || !/\bp\b/.test(head)) continue;
340
+ const keys = [...head.matchAll(/'(\/[^']*)'/g)].map((m) => m[1]);
341
+ for (const m of head.matchAll(/\/\^((?:\\\/|[\w-])+)/g)) keys.push(m[1].replace(/\\\//g, '/'));
342
+ if (keys.length && keys.every((x) => x.startsWith('/api/'))) blocks.push({ keys, a: starts[k], b: starts[k + 1] - 1 });
343
+ }
344
+ }
345
+ S = { L, C, fn, blocks, fnAt: (n) => fn.find((x) => n >= x.a && n <= x.b), blockAt: (n) => blocks.find((b) => n >= b.a && n <= b.b) };
346
+ return S;
347
+ };
348
+ const used = new Set();
349
+ const serverLines = (lines) => {
350
+ const { C, fnAt, blockAt } = parseServer();
351
+ for (const n of lines) {
352
+ const raw = C[n - 1];
353
+ if (raw === undefined || !raw.trim()) continue; // a comment or a blank line reaches nothing
354
+ const b = blockAt(n);
355
+ if (b) { const w = routes(b.keys, `server.js:${n}`); if (w) return w; continue; }
356
+ const own = fnAt(n);
357
+ if (own && own.name !== 'handleRequest') { const w = useOf(own.name); if (w) return `${own.name} (server.js:${n}) is used by ${w}`; continue; }
358
+ return `server.js:${n}, outside every route and function`;
359
+ }
360
+ return null;
361
+ };
362
+ const useOf = (name) => { // the routes that use the top-level `name` of server.js
363
+ if (used.has(name)) return null;
364
+ used.add(name);
365
+ const { L, C, fnAt } = parseServer();
366
+ const re = new RegExp(`\\b${reEsc(name)}\\b`);
367
+ const at = [];
368
+ for (let i = 0; i < C.length; i++) {
369
+ if (!re.test(C[i])) continue;
370
+ const own = fnAt(i + 1);
371
+ if (own && own.name === name) continue;
372
+ if (!own && /^(?:const|let|var)\s[^=]*=\s*require\(/.test(L[i])) continue; // the binding itself
373
+ at.push(i + 1);
374
+ }
375
+ return serverLines(at);
376
+ };
377
+ // the files that name f, followed until a suite, a route or a page; the reason it cannot tell, or null
378
+ const userMemo = new Map();
379
+ const named = new Map(); // file -> how many files name it
380
+ const users = (f) => {
381
+ if (userMemo.has(f)) return userMemo.get(f);
382
+ userMemo.set(f, null);
383
+ const w = users1(f);
384
+ userMemo.set(f, w);
385
+ return w;
386
+ };
387
+ const users1 = (f) => {
388
+ const re = new RegExp(`[/'"\`]${reEsc(stemOf(f))}(?:\\.m?js)?['"\`]`);
389
+ let n = 0;
390
+ for (const g of code) {
391
+ if (g === f) continue;
392
+ const t = sget(g); if (!t || !re.test(t)) continue;
393
+ n++;
394
+ if (inList.has(g)) { picked.add(g); continue; }
395
+ if (SUITE_NAME.test(g)) continue; // a suite of another group: nothing depends on it
396
+ if (WIDE.has(g)) return `${f} is used by ${g}`;
397
+ if (g.startsWith('public/')) { viaPublic(g); continue; }
398
+ if (g === 'server.js') {
399
+ const names = []; const inline = [];
400
+ t.split('\n').forEach((line, i) => {
401
+ if (!re.test(line)) return;
402
+ if (/'\/lib\//.test(line)) return; // served to the browser: the public graph has it
403
+ const m = /^(?:const|let|var)\s+(?:\{([^}]*)\}|(\w+))\s*=\s*require\(/.exec(line);
404
+ if (m) names.push(...(m[1] ? m[1].split(',').map((x) => x.split(':').pop().trim()).filter(Boolean) : [m[2]]));
405
+ else inline.push(i + 1); // a require inside a function or a route: that line
406
+ });
407
+ for (const name of names) { const w = useOf(name); if (w) return w; }
408
+ const w = serverLines(inline); if (w) return w;
409
+ continue;
410
+ }
411
+ if (/^lib\/routes-/.test(g)) { const w = routeModule(g); if (w) return w; continue; }
412
+ const w = users(g); if (w) return w;
413
+ }
414
+ named.set(f, n);
415
+ if (!n && /^lib\/.*\.m?js$/.test(f)) return `no file names ${f}`;
416
+ return null;
417
+ };
418
+
419
+ for (const { file: f, lines } of changes) {
420
+ if (WIDE.has(f)) return { suites: list, why: `${f} changed, and every suite depends on it` };
421
+ if (inList.has(f)) { picked.add(f); continue; }
422
+ if (SUITE_NAME.test(f)) { nameHits(f).forEach((x) => picked.add(x)); continue; } // a suite of another group, or a removed one: only a suite that names it can depend on it
423
+ if (/^test-lists\/[^/]+\.json$/.test(f)) { // a fragment: the suites it lists are the ones whose list changed
424
+ let frag = null; try { frag = JSON.parse(get(f)); } catch { /* removed or not JSON: --check fails it */ }
425
+ for (const k of ['modules', 'panels', 'exclusive']) for (const s of (frag && frag[k]) || []) if (inList.has(s)) picked.add(s);
426
+ continue;
427
+ }
428
+ if (/^(guide|docs)\/|\.md$/.test(f)) continue; // prose: no suite asserts on it except guide.test.js, a unit suite
429
+ if (f === 'test-timings.json') continue; // run order only: no suite reads it
430
+ let why = null;
431
+ const before = picked.size;
432
+ if (get(f) == null) { // removed: only the names in the suites can say who used it
433
+ nameHits(f).forEach((s) => picked.add(s));
434
+ if (picked.size === before) why = `no suite names ${f}, which this change removes`;
435
+ } else if (f === 'server.js') why = lines ? serverLines(lines) : 'the diff of server.js could not be read';
436
+ else if (/^lib\/routes-/.test(f)) why = routeModule(f);
437
+ else if (f.startsWith('public/')) viaPublic(f);
438
+ else {
439
+ why = users(f);
440
+ if (!why && /^lib\//.test(f) && new RegExp(`'/lib/${reEsc(stemOf(f))}\\.js'`).test(get('server.js') || '')) viaPublic(f);
441
+ nameHits(f).forEach((s) => picked.add(s));
442
+ if (!why && picked.size === before && !named.get(f)) why = `no file names ${f}`;
443
+ }
444
+ if (why) return { suites: list, why: `${why}, so every suite runs` };
445
+ }
446
+ return { suites: list.filter((s) => picked.has(s)), why: `${changes.length} changed file(s) reach these suites` };
447
+ }
448
+
449
+ /* The suites in `list` that the diff against `ref` can reach, by traceChanges() above. Returns { files, suites, why }. */
158
450
  function changedSuites(list, ref, { exact = false } = {}) {
159
451
  const git = (...a) => {
160
- const r = require('child_process').spawnSync('git', a, { cwd: DIR, encoding: 'utf8' });
452
+ const r = require('child_process').spawnSync('git', a, { cwd: DIR, encoding: 'utf8', maxBuffer: 64 * 1024 * 1024 });
161
453
  return r.status === 0 ? r.stdout : null;
162
454
  };
163
455
  const top = (git('rev-parse', '--show-toplevel') || '').trim();
@@ -172,23 +464,25 @@ function changedSuites(list, ref, { exact = false } = {}) {
172
464
  ].join('\n').split('\n').map((f) => f.trim()).filter(Boolean);
173
465
  const files = [...new Set(names)].filter((f) => f.startsWith(prefix)).map((f) => f.slice(prefix.length));
174
466
  if (!files.length) return { files, suites: [], why: `nothing under workspace/ differs from ${ref}` };
175
- const wide = files.filter((f) => WIDE.has(f));
176
- if (wide.length) return { files, suites: list, why: `${wide.join(', ')} changed, and every suite depends on it` };
177
- const source = new Map(list.map((f) => [f, fs.existsSync(path.join(DIR, f)) ? fs.readFileSync(path.join(DIR, f), 'utf8') : '']));
178
- const picked = new Set();
179
- const untraced = [];
180
- for (const f of files) {
181
- if (source.has(f)) { picked.add(f); continue; }
182
- if (/^(guide|docs)\/|\.md$/.test(f)) continue; // prose: no suite asserts on it except guide.test.js, a unit suite
183
- if (f === 'test-timings.json') continue; // run order only: no suite reads it
184
- const stem = path.basename(f).replace(/\.[^.]+$/, '');
185
- const key = stem.replace(/^(panel|view|tab)-/, '');
186
- const hits = list.filter((s) => source.get(s).includes(stem) || s.includes(`-${key}-`) || s.includes(`-${key}.`));
187
- if (!hits.length) untraced.push(f);
188
- for (const h of hits) picked.add(h);
467
+ const all = (git('ls-files', '--full-name', DIR) || '').split('\n').filter((f) => f.startsWith(prefix)).map((f) => f.slice(prefix.length));
468
+ const changes = files.map((file) => {
469
+ if (file !== 'server.js') return { file };
470
+ const d = git('diff', '-U0', base, '--', path.join(DIR, 'server.js'));
471
+ return { file, lines: d == null ? null : diffLines(d) };
472
+ });
473
+ const read = (f) => { try { return fs.readFileSync(path.join(DIR, f), 'utf8'); } catch { return null; } };
474
+ const browser = new Set([...FILES.panels, ...FILES.ui]);
475
+ return { files, ...traceChanges(changes, { list, read, files: [...new Set([...all, ...files])], browser }) };
476
+ }
477
+
478
+ /* The new-side line numbers a `git diff -U0` touches. A pure removal counts the lines on both sides of where it was. */
479
+ function diffLines(diff) {
480
+ const out = [];
481
+ for (const m of String(diff).matchAll(/^@@ -\d+(?:,\d+)? \+(\d+)(?:,(\d+))? @@/gm)) {
482
+ const a = Number(m[1]); const n = m[2] === undefined ? 1 : Number(m[2]);
483
+ if (n === 0) out.push(a, a + 1); else for (let k = 0; k < n; k++) out.push(a + k);
189
484
  }
190
- if (untraced.length) return { files, suites: list, why: `no suite names ${untraced.slice(0, 3).join(', ')}${untraced.length > 3 ? ' …' : ''}, so every suite runs` };
191
- return { files, suites: list.filter((f) => picked.has(f)), why: `${files.length} changed file(s) reach these suites` };
485
+ return out;
192
486
  }
193
487
 
194
488
  function check() {
@@ -269,7 +563,7 @@ async function main() {
269
563
  if (changed) {
270
564
  const ref = changed === true ? 'origin/main' : changed;
271
565
  const pick = changedSuites(list, ref);
272
- console.log(`run-tests: --changed against ${ref}: ${pick.why}. ${pick.suites.length} of ${list.length} suites run here; every suite runs on main after the merge.`);
566
+ console.log(`run-tests: --changed against ${ref}: ${pick.why}. ${pick.suites.length} of ${list.length} suites run here; a workflow_dispatch run runs every suite.`);
273
567
  list = pick.suites;
274
568
  if (!list.length) return;
275
569
  }
@@ -342,4 +636,5 @@ async function main() {
342
636
  if (failed.length) { console.log(`FAILED: ${failed.map((r) => `${r.file} (${r.why})`).join(', ')}`); process.exitCode = 1; }
343
637
  }
344
638
 
345
- main().catch((e) => { console.error(e); process.exitCode = 1; });
639
+ if (require.main === module) main().catch((e) => { console.error(e); process.exitCode = 1; });
640
+ else module.exports = { traceChanges, diffLines, strip, WIDE };
@@ -6410,12 +6410,9 @@ async function handleRequest(req, res) {
6410
6410
  const built = BUILD_RE.exec(url.pathname);
6411
6411
  const p = built ? built[1] : url.pathname;
6412
6412
 
6413
- // The premium Briefing (public/premium.html) is the default page: '/' and '/index.html' serve it (premium-default-page). The console
6414
- // (public/c3.html) is served at '/console.html'. '/c3.html' is an old link: bare, it goes to the premium Briefing; with a query
6415
- // (?tab=, ?studio=, ?audience=, ?capture=, ?demo=) it goes to '/console.html' with the same query, so every link the console made
6416
- // for itself still lands in the console. The older shell (public/index.html) stays at '/classic.html'.
6417
- // ROLLBACK, one line: change the final 'premium.html' in the readFile name chain below to 'c3.html' and delete the '/c3.html'
6418
- // redirect block above.
6413
+ // Home (public/premium.html) is the default page: '/' and '/index.html' serve it. The console (/console.html, /c3.html) and the
6414
+ // classic shell (/classic.html) were removed (workspace-legacy-cleanup); their old links open Home with the same query. The
6415
+ // old first-run page (/welcome) opens the Agreed first run (/premium-welcome.html) with the same query.
6419
6416
  // premium-agreed-design H3: Home replaced the Briefing, My work and Chat. My work and Chat open Home with their own query, so an
6420
6417
  // ?item=, ?about=, ?open= or ?say= link still lands on what it named.
6421
6418
  if (p === '/premium-work' || p === '/premium-work.html' || p === '/premium-chat' || p === '/premium-chat.html') {
@@ -6430,16 +6427,24 @@ async function handleRequest(req, res) {
6430
6427
  res.writeHead(302, { Location: '/premium.html' + (s ? '?' + s : ''), 'Cache-Control': 'no-store' });
6431
6428
  return res.end();
6432
6429
  }
6433
- if (p === '/c3.html' || p === '/c3') {
6434
- res.writeHead(302, { Location: (url.search ? '/console.html' : '/premium.html') + url.search, 'Cache-Control': 'no-store' });
6430
+ // One console address stays: the Chrome extension's popup frames /console.html?capture=1, which serves capture.html.
6431
+ const capture = (p === '/console.html' || p === '/c3.html') && url.searchParams.get('capture') === '1';
6432
+ if (!capture && (p === '/c3.html' || p === '/c3' || p === '/console' || p === '/console.html' || p === '/classic' || p === '/classic.html')) {
6433
+ res.writeHead(302, { Location: '/premium.html' + url.search, 'Cache-Control': 'no-store' });
6434
+ return res.end();
6435
+ }
6436
+ if (p === '/welcome' || p === '/welcome.html') {
6437
+ res.writeHead(302, { Location: '/premium-welcome.html' + url.search, 'Cache-Control': 'no-store' });
6435
6438
  return res.end();
6436
6439
  }
6437
- if (p === '/' || p === '/index.html' || p === '/console' || p === '/console.html' || p === '/classic' || p === '/classic.html' || p === '/welcome' || p === '/welcome.html' || p === '/premium' || p === '/premium.html' || p === '/premium-work' || p === '/premium-work.html' || p === '/premium-board' || p === '/premium-board.html' || p === '/premium-initiative' || p === '/premium-initiative.html' || p === '/premium-insights' || p === '/premium-insights.html' || p === '/premium-welcome' || p === '/premium-welcome.html' || p === '/premium-chat' || p === '/premium-chat.html' || p === '/premium-viewer' || p === '/premium-viewer.html') {
6440
+ const PAGES = { '/': 'premium.html', '/index.html': 'premium.html', '/premium': 'premium.html', '/premium.html': 'premium.html', '/premium-board': 'premium-board.html', '/premium-board.html': 'premium-board.html', '/premium-insights': 'premium-insights.html', '/premium-insights.html': 'premium-insights.html', '/premium-welcome': 'premium-welcome.html', '/premium-welcome.html': 'premium-welcome.html', '/premium-viewer': 'premium-viewer.html', '/premium-viewer.html': 'premium-viewer.html' };
6441
+ const page = capture ? 'capture.html' : Object.prototype.hasOwnProperty.call(PAGES, p) ? PAGES[p] : null;
6442
+ if (page) {
6438
6443
  // pm-os-absorb Run 2 (R25, X11): the per-launch nonce goes into the base meta line, nowhere else. no-store, so a
6439
6444
  // restarted server never answers a press from a page that holds the previous launch's value. The page code is
6440
6445
  // referenced under this launch's build prefix.
6441
6446
  const n = pmGuard.launchNonce();
6442
- return fs.readFile(path.join(PUB, (p === '/classic' || p === '/classic.html') ? 'index.html' : (p === '/welcome' || p === '/welcome.html') ? 'welcome.html' : (p === '/premium' || p === '/premium.html') ? 'premium.html' : (p === '/premium-work' || p === '/premium-work.html') ? 'premium-work.html' : (p === '/premium-board' || p === '/premium-board.html') ? 'premium-board.html' : (p === '/premium-initiative' || p === '/premium-initiative.html') ? 'premium-initiative.html' : (p === '/premium-insights' || p === '/premium-insights.html') ? 'premium-insights.html' : (p === '/premium-welcome' || p === '/premium-welcome.html') ? 'premium-welcome.html' : (p === '/premium-chat' || p === '/premium-chat.html') ? 'premium-chat.html' : (p === '/premium-viewer' || p === '/premium-viewer.html') ? 'premium-viewer.html' : (p === '/console' || p === '/console.html') ? 'c3.html' : 'premium.html'), 'utf8', (err, html) => {
6447
+ return fs.readFile(path.join(PUB, page), 'utf8', (err, html) => {
6443
6448
  if (err) { res.writeHead(404); res.end('not found'); return; }
6444
6449
  let out = withBuild(html);
6445
6450
  if (n) out = out.replace('<meta name="' + pmGuard.NONCE_META + '" content="" />', '<meta name="' + pmGuard.NONCE_META + '" content="' + n + '" />');