create-pmos 0.399.0 → 0.401.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 (425) hide show
  1. package/package.json +30 -25
  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 +3 -3
  8. package/workspace/briefing-premium-doc-edit-test.js +2 -8
  9. package/workspace/briefing-premium-sources-test.js +2 -0
  10. package/workspace/briefing-premium-test.js +6 -2
  11. package/workspace/briefing-premium-work-test.js +9 -4
  12. package/workspace/c3-capture-test.js +0 -17
  13. package/workspace/changelog.json +29 -0
  14. package/workspace/guide/briefing-premium.md +2 -2
  15. package/workspace/guide/home.md +24 -3
  16. package/workspace/guide/layout.md +2 -2
  17. package/workspace/guide/notes.md +2 -2
  18. package/workspace/guide/phone-companion.md +1 -1
  19. package/workspace/lib/core-docs.js +2 -2
  20. package/workspace/lib/route-modules.js +1 -9
  21. package/workspace/lib/routes-phone-day.js +18 -9
  22. package/workspace/lib/routes-slash.js +95 -0
  23. package/workspace/package-lock.json +2 -2
  24. package/workspace/package.json +1 -2
  25. package/workspace/premium-chat-goal-view-test.js +1 -1
  26. package/workspace/premium-chat-term-test.js +0 -10
  27. package/workspace/premium-menu-rows-test.js +1 -1
  28. package/workspace/premium-phone-card-test.js +8 -3
  29. package/workspace/premium-vw-cal-test.js +4 -1
  30. package/workspace/premium-vw-doc-test.js +1 -8
  31. package/workspace/premium-work-depth-test.js +2 -3
  32. package/workspace/public/capture.html +23 -0
  33. package/workspace/public/pm/c3-base.js +47 -0
  34. package/workspace/public/pm/c3-capture.js +1 -1
  35. package/workspace/public/pm/c3-ini-ui.js +1 -1
  36. package/workspace/public/pm/c3-sheet.js +1 -1
  37. package/workspace/public/pm/c3-toast.js +1 -1
  38. package/workspace/public/pm/console3.css +3 -0
  39. package/workspace/public/pm/cozy-home.css +21 -6
  40. package/workspace/public/pm/cozy-today.css +4 -3
  41. package/workspace/public/pm/cozy-viewer.js +4 -2
  42. package/workspace/public/pm/cozy.css +9 -0
  43. package/workspace/public/pm/goal-chat.js +5 -1
  44. package/workspace/public/pm/home-app.js +65 -33
  45. package/workspace/public/pm/home-chat.js +34 -29
  46. package/workspace/public/pm/home-data.js +10 -2
  47. package/workspace/public/pm/home-dictate.js +7 -4
  48. package/workspace/public/pm/home-ini.js +13 -3
  49. package/workspace/public/pm/home-list.js +18 -10
  50. package/workspace/public/pm/home-more.js +2 -2
  51. package/workspace/public/pm/home-phone-card.js +9 -4
  52. package/workspace/public/pm/home-review.js +2 -3
  53. package/workspace/public/pm/home-today.js +11 -8
  54. package/workspace/public/pm/home-work.js +13 -8
  55. package/workspace/public/pm/note-dock.js +1 -2
  56. package/workspace/public/pm/notes-links.js +1 -2
  57. package/workspace/public/pm/notes-task.js +3 -4
  58. package/workspace/public/pm/premium-board.js +1 -1
  59. package/workspace/public/pm/premium-initiative-head.js +3 -3
  60. package/workspace/public/pm/premium-vw-doc.css +20 -2
  61. package/workspace/public/pm/premium-vw-doc.js +22 -7
  62. package/workspace/public/pm/premium-vw-item.css +6 -0
  63. package/workspace/public/pm/view-notes.js +2 -2
  64. package/workspace/replaced-tests.json +435 -0
  65. package/workspace/run-tests.js +323 -28
  66. package/workspace/server.js +15 -10
  67. package/workspace/test-files.json +4 -140
  68. package/workspace/test-lists/base.json +1 -2
  69. package/workspace/test-lists/c3-desktop-light-load.json +1 -2
  70. package/workspace/test-lists/c3-initiative-boards.json +1 -2
  71. package/workspace/test-lists/c3-meeting-focus.json +2 -12
  72. package/workspace/test-lists/c3-work-agent.json +1 -2
  73. package/workspace/test-lists/calendar-tidy-up.json +1 -2
  74. package/workspace/test-lists/console3-reports.json +1 -2
  75. package/workspace/test-lists/docs-three-way-sync.json +1 -2
  76. package/workspace/test-lists/extension-capture.json +5 -0
  77. package/workspace/test-lists/jira-wbs.json +1 -2
  78. package/workspace/test-lists/legacy-cleanup-a.json +9 -0
  79. package/workspace/test-lists/meeting-material.json +1 -2
  80. package/workspace/test-lists/meeting-notes.json +2 -36
  81. package/workspace/test-lists/meeting-replay.json +1 -2
  82. package/workspace/test-lists/mm-capture.json +2 -12
  83. package/workspace/test-lists/my-work.json +2 -10
  84. package/workspace/test-lists/onboarding-firstrun.json +2 -12
  85. package/workspace/test-lists/people-directory.json +1 -2
  86. package/workspace/test-lists/run2-a.json +1 -2
  87. package/workspace/test-lists/run2-d.json +2 -19
  88. package/workspace/test-lists/run3-b.json +1 -2
  89. package/workspace/test-lists/run3-c.json +2 -12
  90. package/workspace/test-lists/run4-b.json +1 -2
  91. package/workspace/test-lists/run4-d.json +1 -5
  92. package/workspace/test-lists/run5-c.json +1 -11
  93. package/workspace/test-lists/run6.json +1 -5
  94. package/workspace/test-lists/workspace-launch-flags.json +2 -12
  95. package/workspace/test-lists/workspace-profile-detection.json +2 -10
  96. package/workspace/test-timings.json +242 -123
  97. package/workspace/c3-briefing-test.js +0 -136
  98. package/workspace/c3-core-docs-test.js +0 -170
  99. package/workspace/c3-driver-fixture.js +0 -64
  100. package/workspace/c3-driver-test.js +0 -169
  101. package/workspace/c3-foundation-test.js +0 -163
  102. package/workspace/c3-ib-items-test.js +0 -114
  103. package/workspace/c3-ib-more-test.js +0 -146
  104. package/workspace/c3-ib-triage-backlog-test.js +0 -128
  105. package/workspace/c3-ini-harness.js +0 -66
  106. package/workspace/c3-ini-life-test.js +0 -167
  107. package/workspace/c3-initiatives-test.js +0 -186
  108. package/workspace/c3-light-load-test.js +0 -112
  109. package/workspace/c3-one-home-test.js +0 -149
  110. package/workspace/c3-phone-test.js +0 -289
  111. package/workspace/c3-quiet-test.js +0 -157
  112. package/workspace/c3-report-design-real-test.js +0 -264
  113. package/workspace/c3-report-design-test.js +0 -442
  114. package/workspace/c3-report-setup-test.js +0 -192
  115. package/workspace/c3-report-structure-real-test.js +0 -248
  116. package/workspace/c3-report-structure-test.js +0 -397
  117. package/workspace/c3-reports-test.js +0 -288
  118. package/workspace/c3-scan-test.js +0 -517
  119. package/workspace/c3-sessions-panel-test.js +0 -365
  120. package/workspace/c3-settings-test.js +0 -204
  121. package/workspace/c3-updates-test.js +0 -131
  122. package/workspace/c3-work-test.js +0 -260
  123. package/workspace/cut-stub.js +0 -40
  124. package/workspace/first-paint-audit.js +0 -160
  125. package/workspace/lib/c3-full-console.js +0 -15
  126. package/workspace/lib/engine/derived/trust.js +0 -3
  127. package/workspace/lib/engine/plan-forecast.js +0 -342
  128. package/workspace/lib/engine/report-families.js +0 -175
  129. package/workspace/lib/engine/truth-table.js +0 -57
  130. package/workspace/lib/routes-c3-init.js +0 -54
  131. package/workspace/lib/routes-c3-life.js +0 -120
  132. package/workspace/lib/routes-c3-timeline.js +0 -192
  133. package/workspace/lib/routes-forecast.js +0 -86
  134. package/workspace/lib/routes-releases.js +0 -130
  135. package/workspace/lib/routes-report-facts.js +0 -85
  136. package/workspace/lib/routes-report-families.js +0 -33
  137. package/workspace/lib/routes-signals.js +0 -51
  138. package/workspace/lib/routes-timeline.js +0 -197
  139. package/workspace/public/c3.html +0 -35
  140. package/workspace/public/index.html +0 -156
  141. package/workspace/public/pm/app.js +0 -831
  142. package/workspace/public/pm/bd-board.js +0 -159
  143. package/workspace/public/pm/bd-drag.js +0 -59
  144. package/workspace/public/pm/bd-model.js +0 -152
  145. package/workspace/public/pm/bd-timeline.js +0 -233
  146. package/workspace/public/pm/bd-tree.js +0 -244
  147. package/workspace/public/pm/board-copy.js +0 -59
  148. package/workspace/public/pm/board-read.js +0 -38
  149. package/workspace/public/pm/branches-sheet.js +0 -56
  150. package/workspace/public/pm/breakdown-api.js +0 -58
  151. package/workspace/public/pm/breakdown-copy.js +0 -138
  152. package/workspace/public/pm/briefing-deck.js +0 -441
  153. package/workspace/public/pm/briefing-model.js +0 -251
  154. package/workspace/public/pm/c3-ambient.js +0 -100
  155. package/workspace/public/pm/c3-audience-link.js +0 -21
  156. package/workspace/public/pm/c3-audience.js +0 -46
  157. package/workspace/public/pm/c3-boot.js +0 -13
  158. package/workspace/public/pm/c3-breakdown.js +0 -240
  159. package/workspace/public/pm/c3-brief-data.js +0 -11
  160. package/workspace/public/pm/c3-brief-mentions.js +0 -137
  161. package/workspace/public/pm/c3-brief-needs.js +0 -288
  162. package/workspace/public/pm/c3-brief-pulse.js +0 -112
  163. package/workspace/public/pm/c3-brief-summary.js +0 -139
  164. package/workspace/public/pm/c3-brief-today.js +0 -79
  165. package/workspace/public/pm/c3-brief.js +0 -279
  166. package/workspace/public/pm/c3-cal-strategy.js +0 -529
  167. package/workspace/public/pm/c3-calendar.js +0 -965
  168. package/workspace/public/pm/c3-calpop.js +0 -111
  169. package/workspace/public/pm/c3-case.js +0 -196
  170. package/workspace/public/pm/c3-core-docs.css +0 -18
  171. package/workspace/public/pm/c3-core-docs.js +0 -236
  172. package/workspace/public/pm/c3-daypart.js +0 -176
  173. package/workspace/public/pm/c3-demo-boards.js +0 -764
  174. package/workspace/public/pm/c3-demo-brief-ix.js +0 -350
  175. package/workspace/public/pm/c3-demo-brief-page.js +0 -70
  176. package/workspace/public/pm/c3-demo-cal-ix.js +0 -74
  177. package/workspace/public/pm/c3-demo-cal2.js +0 -66
  178. package/workspace/public/pm/c3-demo-cal3.js +0 -173
  179. package/workspace/public/pm/c3-demo-cal4.js +0 -169
  180. package/workspace/public/pm/c3-demo-cal5.js +0 -52
  181. package/workspace/public/pm/c3-demo-coredocs.js +0 -221
  182. package/workspace/public/pm/c3-demo-data.js +0 -552
  183. package/workspace/public/pm/c3-demo-focus.js +0 -181
  184. package/workspace/public/pm/c3-demo-init.js +0 -430
  185. package/workspace/public/pm/c3-demo-life.js +0 -77
  186. package/workspace/public/pm/c3-demo-material.js +0 -58
  187. package/workspace/public/pm/c3-demo-misc2.js +0 -34
  188. package/workspace/public/pm/c3-demo-phone.js +0 -48
  189. package/workspace/public/pm/c3-demo-plan2.js +0 -30
  190. package/workspace/public/pm/c3-demo-rd.js +0 -432
  191. package/workspace/public/pm/c3-demo-rep-ix.js +0 -126
  192. package/workspace/public/pm/c3-demo-rep2.js +0 -130
  193. package/workspace/public/pm/c3-demo-rep3.js +0 -138
  194. package/workspace/public/pm/c3-demo-rs.js +0 -287
  195. package/workspace/public/pm/c3-demo-term.js +0 -153
  196. package/workspace/public/pm/c3-demo-time.js +0 -49
  197. package/workspace/public/pm/c3-demo-work-ix.js +0 -32
  198. package/workspace/public/pm/c3-demo.js +0 -131
  199. package/workspace/public/pm/c3-design-studio.js +0 -369
  200. package/workspace/public/pm/c3-doc-formats.js +0 -153
  201. package/workspace/public/pm/c3-doc-sheet.js +0 -1230
  202. package/workspace/public/pm/c3-dock.js +0 -206
  203. package/workspace/public/pm/c3-docs.js +0 -291
  204. package/workspace/public/pm/c3-driver-work.js +0 -110
  205. package/workspace/public/pm/c3-driver.css +0 -18
  206. package/workspace/public/pm/c3-driver.js +0 -298
  207. package/workspace/public/pm/c3-focus.css +0 -304
  208. package/workspace/public/pm/c3-focus.js +0 -983
  209. package/workspace/public/pm/c3-ib-docs.js +0 -92
  210. package/workspace/public/pm/c3-ib-initiatives.js +0 -201
  211. package/workspace/public/pm/c3-ib-items.js +0 -210
  212. package/workspace/public/pm/c3-ib-releases.js +0 -48
  213. package/workspace/public/pm/c3-ib-sprints.js +0 -201
  214. package/workspace/public/pm/c3-ib-triage.js +0 -177
  215. package/workspace/public/pm/c3-ii-tabs.js +0 -252
  216. package/workspace/public/pm/c3-ini-life.css +0 -34
  217. package/workspace/public/pm/c3-ini-life.js +0 -379
  218. package/workspace/public/pm/c3-ini-records.js +0 -197
  219. package/workspace/public/pm/c3-ini-timeline.js +0 -278
  220. package/workspace/public/pm/c3-ini-work.js +0 -139
  221. package/workspace/public/pm/c3-init-extras.js +0 -170
  222. package/workspace/public/pm/c3-initiatives.js +0 -852
  223. package/workspace/public/pm/c3-lifecycle-panels.js +0 -479
  224. package/workspace/public/pm/c3-look.js +0 -27
  225. package/workspace/public/pm/c3-material.css +0 -22
  226. package/workspace/public/pm/c3-material.js +0 -321
  227. package/workspace/public/pm/c3-md.js +0 -3
  228. package/workspace/public/pm/c3-misc-panels.js +0 -89
  229. package/workspace/public/pm/c3-new-session.js +0 -110
  230. package/workspace/public/pm/c3-notes.js +0 -751
  231. package/workspace/public/pm/c3-phone-boot.js +0 -47
  232. package/workspace/public/pm/c3-phone-detail.js +0 -97
  233. package/workspace/public/pm/c3-phone-model.js +0 -3
  234. package/workspace/public/pm/c3-phone.css +0 -66
  235. package/workspace/public/pm/c3-phone.js +0 -444
  236. package/workspace/public/pm/c3-plan-panels.js +0 -163
  237. package/workspace/public/pm/c3-plan.js +0 -193
  238. package/workspace/public/pm/c3-quiet.css +0 -113
  239. package/workspace/public/pm/c3-quiet.js +0 -177
  240. package/workspace/public/pm/c3-replay.css +0 -133
  241. package/workspace/public/pm/c3-replay.js +0 -429
  242. package/workspace/public/pm/c3-report-deck.css +0 -163
  243. package/workspace/public/pm/c3-report-deck.js +0 -598
  244. package/workspace/public/pm/c3-report-frame.css +0 -20
  245. package/workspace/public/pm/c3-report-print.css +0 -20
  246. package/workspace/public/pm/c3-report-setup.css +0 -67
  247. package/workspace/public/pm/c3-report-setup.js +0 -298
  248. package/workspace/public/pm/c3-report-store.js +0 -244
  249. package/workspace/public/pm/c3-report-structure.css +0 -44
  250. package/workspace/public/pm/c3-report-structure.js +0 -473
  251. package/workspace/public/pm/c3-reports.css +0 -68
  252. package/workspace/public/pm/c3-reports.js +0 -377
  253. package/workspace/public/pm/c3-roadmap.js +0 -249
  254. package/workspace/public/pm/c3-scan-api.js +0 -167
  255. package/workspace/public/pm/c3-scan-next.js +0 -248
  256. package/workspace/public/pm/c3-scan-setup.js +0 -313
  257. package/workspace/public/pm/c3-scan-words.js +0 -41
  258. package/workspace/public/pm/c3-scan.css +0 -74
  259. package/workspace/public/pm/c3-scan.js +0 -93
  260. package/workspace/public/pm/c3-session-chat.js +0 -103
  261. package/workspace/public/pm/c3-session-conv.js +0 -165
  262. package/workspace/public/pm/c3-session-term.js +0 -216
  263. package/workspace/public/pm/c3-settings.css +0 -85
  264. package/workspace/public/pm/c3-settings.js +0 -1045
  265. package/workspace/public/pm/c3-shell.js +0 -628
  266. package/workspace/public/pm/c3-signals.js +0 -196
  267. package/workspace/public/pm/c3-strategy-panels.js +0 -45
  268. package/workspace/public/pm/c3-swipe.js +0 -230
  269. package/workspace/public/pm/c3-terminal-data.js +0 -48
  270. package/workspace/public/pm/c3-terminal-edge.js +0 -91
  271. package/workspace/public/pm/c3-terminal-icons.js +0 -40
  272. package/workspace/public/pm/c3-terminal-results.js +0 -141
  273. package/workspace/public/pm/c3-terminal.js +0 -52
  274. package/workspace/public/pm/c3-tickets.js +0 -163
  275. package/workspace/public/pm/c3-timeline.js +0 -201
  276. package/workspace/public/pm/calendar-views.js +0 -1049
  277. package/workspace/public/pm/console3-lift.md +0 -220
  278. package/workspace/public/pm/cozy-home.js +0 -172
  279. package/workspace/public/pm/cozy-initiative.css +0 -138
  280. package/workspace/public/pm/cycle-review.js +0 -125
  281. package/workspace/public/pm/data.js +0 -1577
  282. package/workspace/public/pm/dest-board.js +0 -444
  283. package/workspace/public/pm/dest-docs.js +0 -530
  284. package/workspace/public/pm/dest-initiatives.js +0 -162
  285. package/workspace/public/pm/dest-mywork.js +0 -307
  286. package/workspace/public/pm/dest-notes.js +0 -537
  287. package/workspace/public/pm/dest-people.js +0 -449
  288. package/workspace/public/pm/dest-reports.js +0 -383
  289. package/workspace/public/pm/dest-settings.js +0 -601
  290. package/workspace/public/pm/dest-today.js +0 -267
  291. package/workspace/public/pm/display-word.js +0 -56
  292. package/workspace/public/pm/doc-editor.js +0 -473
  293. package/workspace/public/pm/doc-graph.js +0 -272
  294. package/workspace/public/pm/doc-health-panel.js +0 -110
  295. package/workspace/public/pm/doc-rail.js +0 -167
  296. package/workspace/public/pm/doc-remote.js +0 -180
  297. package/workspace/public/pm/dock-sessions.js +0 -472
  298. package/workspace/public/pm/dock.js +0 -216
  299. package/workspace/public/pm/fixture.js +0 -821
  300. package/workspace/public/pm/flag-picker.js +0 -104
  301. package/workspace/public/pm/frame-copy.js +0 -278
  302. package/workspace/public/pm/freshness-line.js +0 -149
  303. package/workspace/public/pm/handoff-box.js +0 -82
  304. package/workspace/public/pm/initiative-list.js +0 -235
  305. package/workspace/public/pm/initiative-sheet.js +0 -331
  306. package/workspace/public/pm/initiatives-api.js +0 -95
  307. package/workspace/public/pm/initiatives-copy.js +0 -287
  308. package/workspace/public/pm/initiatives-timeline-copy.js +0 -59
  309. package/workspace/public/pm/initiatives-timeline.js +0 -410
  310. package/workspace/public/pm/initiatives-ui.js +0 -291
  311. package/workspace/public/pm/item-sheet.js +0 -268
  312. package/workspace/public/pm/keep-card.js +0 -204
  313. package/workspace/public/pm/lifecycle-lens-model.js +0 -246
  314. package/workspace/public/pm/lifecycle-lens.js +0 -276
  315. package/workspace/public/pm/lifecycle.js +0 -111
  316. package/workspace/public/pm/mobile.css +0 -366
  317. package/workspace/public/pm/mobile.js +0 -581
  318. package/workspace/public/pm/modes-live.js +0 -453
  319. package/workspace/public/pm/modes.js +0 -147
  320. package/workspace/public/pm/my-work-card.js +0 -51
  321. package/workspace/public/pm/my-work-data.js +0 -36
  322. package/workspace/public/pm/new-initiative-sheet.js +0 -169
  323. package/workspace/public/pm/next-step-ui.js +0 -190
  324. package/workspace/public/pm/outbox-panel.js +0 -125
  325. package/workspace/public/pm/palette-copy.js +0 -55
  326. package/workspace/public/pm/palette.js +0 -343
  327. package/workspace/public/pm/panel-breakdown.js +0 -702
  328. package/workspace/public/pm/panel-cockpit.js +0 -425
  329. package/workspace/public/pm/panel-detail.js +0 -1513
  330. package/workspace/public/pm/panel-initiatives.js +0 -929
  331. package/workspace/public/pm/panel-newsess.js +0 -709
  332. package/workspace/public/pm/panel-repos.js +0 -741
  333. package/workspace/public/pm/panel-tabs.js +0 -1506
  334. package/workspace/public/pm/panel-trees.js +0 -204
  335. package/workspace/public/pm/people-link.js +0 -106
  336. package/workspace/public/pm/phone-deck.js +0 -167
  337. package/workspace/public/pm/pm-work-view.js +0 -1533
  338. package/workspace/public/pm/portfolio-report.js +0 -61
  339. package/workspace/public/pm/premium-acts.js +0 -280
  340. package/workspace/public/pm/premium-brief.js +0 -111
  341. package/workspace/public/pm/premium-chat.js +0 -22
  342. package/workspace/public/pm/premium-doc-sheet.js +0 -312
  343. package/workspace/public/pm/premium-initiative.js +0 -324
  344. package/workspace/public/pm/premium-insights.css +0 -228
  345. package/workspace/public/pm/premium-metric-tiles.js +0 -68
  346. package/workspace/public/pm/premium-report-brief.js +0 -132
  347. package/workspace/public/pm/premium-vw-rec.js +0 -67
  348. package/workspace/public/pm/premium-wide.css +0 -30
  349. package/workspace/public/pm/print.css +0 -44
  350. package/workspace/public/pm/provider-cards.js +0 -136
  351. package/workspace/public/pm/registry.js +0 -203
  352. package/workspace/public/pm/release-card.js +0 -110
  353. package/workspace/public/pm/releases-view.js +0 -248
  354. package/workspace/public/pm/report-families-view.js +0 -505
  355. package/workspace/public/pm/report-slides.js +0 -438
  356. package/workspace/public/pm/report-tab.js +0 -33
  357. package/workspace/public/pm/report-view.js +0 -337
  358. package/workspace/public/pm/reports-copy.js +0 -134
  359. package/workspace/public/pm/roadmap.js +0 -294
  360. package/workspace/public/pm/run-card.js +0 -260
  361. package/workspace/public/pm/sessions-panel.js +0 -219
  362. package/workspace/public/pm/sheet-jira.js +0 -353
  363. package/workspace/public/pm/shell-bell.js +0 -163
  364. package/workspace/public/pm/shell-model.js +0 -83
  365. package/workspace/public/pm/shell-phone.js +0 -124
  366. package/workspace/public/pm/shell-readaloud.js +0 -53
  367. package/workspace/public/pm/shell-recording.js +0 -274
  368. package/workspace/public/pm/shell-ticker.js +0 -90
  369. package/workspace/public/pm/sig-watch.js +0 -41
  370. package/workspace/public/pm/slide-confirm.js +0 -163
  371. package/workspace/public/pm/slides-copy.js +0 -52
  372. package/workspace/public/pm/status-banner.js +0 -95
  373. package/workspace/public/pm/tab-doc.js +0 -859
  374. package/workspace/public/pm/tab-gone.js +0 -21
  375. package/workspace/public/pm/tab-term.js +0 -1210
  376. package/workspace/public/pm/tab-web.js +0 -90
  377. package/workspace/public/pm/timeline-copy.js +0 -48
  378. package/workspace/public/pm/timeline-forecast-view.js +0 -164
  379. package/workspace/public/pm/today-agenda.js +0 -331
  380. package/workspace/public/pm/today-cards.js +0 -244
  381. package/workspace/public/pm/today-copy.js +0 -506
  382. package/workspace/public/pm/today-day.js +0 -1371
  383. package/workspace/public/pm/today-goals.js +0 -297
  384. package/workspace/public/pm/today-jobs.js +0 -84
  385. package/workspace/public/pm/today-mentions.js +0 -50
  386. package/workspace/public/pm/topbar.js +0 -202
  387. package/workspace/public/pm/triage-card.js +0 -60
  388. package/workspace/public/pm/undo-hold.js +0 -103
  389. package/workspace/public/pm/view-addrepo.js +0 -208
  390. package/workspace/public/pm/view-files.js +0 -197
  391. package/workspace/public/pm/view-livenotes.js +0 -399
  392. package/workspace/public/pm/view-today.js +0 -13
  393. package/workspace/public/pm/view-validate.js +0 -171
  394. package/workspace/public/pm/welcome.js +0 -391
  395. package/workspace/public/pm/work-place.js +0 -68
  396. package/workspace/public/pm/xlsx-read.js +0 -117
  397. package/workspace/public/welcome.html +0 -22
  398. package/workspace/test-lists/browser-suites-green.json +0 -5
  399. package/workspace/test-lists/c3-core-docs.json +0 -9
  400. package/workspace/test-lists/c3-doc-sheet-rich.json +0 -6
  401. package/workspace/test-lists/c3-doc-sheet-size.json +0 -6
  402. package/workspace/test-lists/c3-doc-sheet-v2.json +0 -6
  403. package/workspace/test-lists/c3-ib-items.json +0 -9
  404. package/workspace/test-lists/c3-ib-more.json +0 -9
  405. package/workspace/test-lists/c3-ib-triage-backlog.json +0 -9
  406. package/workspace/test-lists/c3-ini-life.json +0 -9
  407. package/workspace/test-lists/c3-meeting-board.json +0 -5
  408. package/workspace/test-lists/c3-meeting-card.json +0 -5
  409. package/workspace/test-lists/c3-notes-place.json +0 -5
  410. package/workspace/test-lists/c3-notes-series.json +0 -5
  411. package/workspace/test-lists/calendar-time-page.json +0 -5
  412. package/workspace/test-lists/calpop.json +0 -4
  413. package/workspace/test-lists/console3-briefing.json +0 -9
  414. package/workspace/test-lists/console3-foundation.json +0 -9
  415. package/workspace/test-lists/console3-work-page.json +0 -9
  416. package/workspace/test-lists/premium-brief-parity.json +0 -9
  417. package/workspace/test-lists/report-design-studio-ui.json +0 -5
  418. package/workspace/test-lists/report-structure-ui.json +0 -11
  419. package/workspace/test-lists/report-workspace-ui.json +0 -5
  420. package/workspace/test-lists/run3-a.json +0 -5
  421. package/workspace/test-lists/run3-d.json +0 -6
  422. package/workspace/test-lists/run4-c.json +0 -13
  423. package/workspace/test-lists/today-goals-jobs-ui.json +0 -5
  424. package/workspace/test-lists/today-mentions-cards.json +0 -5
  425. package/workspace/test-lists/workspace-tabs-declutter.json +0 -13
@@ -1,321 +0,0 @@
1
- /* pm/c3-material.js — the material of a meeting (initiative meeting-material-replay, part 1; the mockup the PM approved on 2026-10-14, hashes #material, #material-add, #focus-material).
2
- *
3
- * materialSection({ event, date, ws, level, brief, back }) → Node the Material part of the meeting card: each linked item with its kind, topic and source,
4
- * Present or Open, remove, and Add material
5
- * openAddMaterial({ event, date, ws, level, brief, back }) the Add material sheet: Suggested from the meeting's level, Find in PMOS, Or paste a link; For,
6
- * Topic and You (Present it / Only read it)
7
- * openItem(item) · presentItem(item) · audienceItem(item) Open in PMOS or in a new tab; Present (a PMOS deck in the presenter view, Google Slides in present
8
- * mode); the audience view of a PMOS deck
9
- * classifyLink(url) · KIND · pmosUrl(item)
10
- * window.C3Material = { open(event, opts), section, openItem, presentItem, audienceItem } for any page that wants to add or show material
11
- *
12
- * It reads and writes GET and POST /api/meeting-material (lib/routes-meeting-material.js). PMOS keeps the link on its own record of the meeting; the calendar invite is not
13
- * changed. A change fires `c3-material-changed` on window, so the card and Focus read again. Nothing is sent anywhere. */
14
- import { el } from './dom.js';
15
- import { pmGet, pmPost } from './http.js';
16
- import { ensureC3Css } from './pm-work-view.js';
17
- import { ensureComponentsCss } from './primitives.js';
18
- import { icon, pbtn, sect, put, lk, ib, list, empty } from './c3-ini-ui.js';
19
- import { openSheet, closeSheet } from './c3-sheet.js';
20
- import { toast } from './c3-toast.js';
21
- import { openAudienceWindow } from './c3-audience-link.js';
22
-
23
- /** What each kind of item is called, and which icon it takes. `deck`: PMOS presents it itself. `present`: it can be presented at all. */
24
- export const KIND = {
25
- 'pmos-deck': { tag: 'PMOS deck', ic: 'report', deck: true, present: true },
26
- 'pmos-doc': { tag: 'PMOS document', ic: 'doc' },
27
- report: { tag: 'PMOS report', ic: 'report' },
28
- slides: { tag: 'Google Slides', ic: 'out', present: true },
29
- gdoc: { tag: 'Google Docs', ic: 'out' },
30
- conf: { tag: 'Confluence', ic: 'out' },
31
- link: { tag: 'Link', ic: 'out' },
32
- };
33
- const BY = { invite: 'from the invite', brief: 'found by today’s brief', you: 'added by you' };
34
- const isPmos = (k) => k === 'pmos-deck' || k === 'pmos-doc' || k === 'report';
35
-
36
- function ensureCss() {
37
- ensureC3Css(); ensureComponentsCss();
38
- if (typeof document === 'undefined' || document.querySelector('link[data-c3-material]')) return;
39
- const l = document.createElement('link');
40
- l.rel = 'stylesheet'; l.href = new URL('./c3-material.css', import.meta.url).href; l.setAttribute('data-c3-material', '');
41
- document.head.appendChild(l);
42
- }
43
- const wsParam = () => { try { return new URLSearchParams(location.search).get('ws') || ''; } catch { return ''; } };
44
- const pad = (n) => String(n).padStart(2, '0');
45
- const MON = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
46
- const dateText = (iso) => { const m = /^(\d{4})-(\d{2})-(\d{2})/.exec(String(iso || '')); return m ? (+m[3]) + ' ' + MON[+m[2] - 1] : ''; };
47
- const timeText = (iso) => { const d = new Date(iso); return Number.isFinite(d.getTime()) ? pad(d.getHours()) + ':' + pad(d.getMinutes()) : ''; };
48
-
49
- /** What an address is, as the server decides it (lib/meeting-material.js classifyUrl). null for anything that is not an https address. */
50
- export function classifyLink(raw) {
51
- const s = String(raw || '').trim();
52
- if (!s || /\s/.test(s)) return null;
53
- let u; try { u = new URL(/^[a-z][a-z0-9+.-]*:/i.test(s) ? s : 'https://' + s); } catch { return null; }
54
- if (u.protocol !== 'https:' || !u.hostname.includes('.')) return null;
55
- if (u.hostname === 'docs.google.com' && /^\/presentation\/d\//.test(u.pathname)) return { kind: 'slides', url: u.href, title: 'Google Slides deck', meta: 'read through your Google Drive connection' };
56
- if (u.hostname === 'docs.google.com' && /^\/document\/d\//.test(u.pathname)) return { kind: 'gdoc', url: u.href, title: 'Google Docs page', meta: 'read through your Google Drive connection' };
57
- if (/\.atlassian\.net$/.test(u.hostname) && u.pathname.startsWith('/wiki')) return { kind: 'conf', url: u.href, title: 'Confluence page', meta: 'read through your Atlassian connection' };
58
- return { kind: 'link', url: u.href, title: u.hostname, meta: 'opens in a new tab · PMOS does not read it' };
59
- }
60
- /** The pseudo address Focus gives a PMOS item, so its link list can hold it beside web links (c3-focus.js classify). */
61
- export const pmosUrl = (item) => 'pmos:' + item.kind + ':' + (item.ws || '') + ':' + item.ref;
62
-
63
- /* ── what is stored ───────────────────────────────────────────────────────────────────────────────────────────────── */
64
-
65
- const evParams = (event, extra) => {
66
- const e = event || {};
67
- const p = new URLSearchParams({ title: String(e.title || e.id || '') });
68
- if (e.id) p.set('event', String(e.id));
69
- if (e.series) p.set('series', String(e.series));
70
- const date = (extra && extra.date) || String(e.at || e.start || '').slice(0, 10);
71
- if (date) p.set('date', date);
72
- const ws = (extra && extra.ws) || wsParam(); if (ws) p.set('ws', ws);
73
- if (extra && extra.topics) p.set('topics', '1');
74
- return p;
75
- };
76
- const evKey = (e) => (e && (e.id || e.title)) + '|' + ((e && e.series) || '');
77
- const CACHE = new Map(); // event key → { items, at }
78
- const FRESH_MS = 4000;
79
-
80
- async function readItems(event, extra) {
81
- const r = await pmGet('/api/meeting-material?' + evParams(event, extra).toString()).catch(() => null);
82
- if (r && r.ok && Array.isArray(r.items)) { CACHE.set(evKey(event), { items: r.items, at: Date.now() }); return r; }
83
- return null;
84
- }
85
- const changed = (event) => { try { window.dispatchEvent(new CustomEvent('c3-material-changed', { detail: { key: evKey(event) } })); } catch { /* no window */ } };
86
-
87
- async function save(event, body) {
88
- const e = event || {};
89
- const r = await pmPost('/api/meeting-material', { event: { id: e.id || undefined, title: e.title || e.id, series: e.series || undefined }, ...body }).catch((err) => ({ ok: false, error: String((err && err.message) || err) }));
90
- if (!r || !r.ok) { toast({ text: 'The material was not saved: ' + ((r && (r.error || r.reason)) || 'no answer') + '.', tone: 'error', timeout: 6000 }); return null; }
91
- CACHE.set(evKey(event), { items: r.items || [], at: Date.now() });
92
- changed(event);
93
- return r;
94
- }
95
-
96
- /* ── open and present ─────────────────────────────────────────────────────────────────────────────────────────────── */
97
-
98
- function openWeb(url) { try { window.open(url, '_blank', 'noopener,noreferrer'); } catch { /* a blocked pop-up */ } }
99
- const slidesPresentUrl = (url) => { const m = /^(https:\/\/docs\.google\.com\/presentation\/d\/[A-Za-z0-9_-]+)/.exec(String(url || '')); return m ? m[1] + '/present' : url; };
100
-
101
- async function openDocument(item) {
102
- try {
103
- const { openDocSheet } = await import('./c3-doc-sheet.js');
104
- const ws = item.ws || wsParam();
105
- openDocSheet({ ws, doc: { path: item.ref, name: item.title || item.ref, ty: 'Document', v: '', st: 'current', ini: '', iniName: '' },
106
- library: () => Promise.resolve(pmGet('/api/docs/library' + (ws ? '?ws=' + encodeURIComponent(ws) : ''))).catch(() => ({ ok: true, files: [], edges: [], kinds: [], categories: [], initiatives: {} })) });
107
- } catch { toast('The document sheet could not open. The file is ' + item.ref + '.'); }
108
- }
109
- async function openReport(item) {
110
- try {
111
- const store = await import('./c3-report-store.js');
112
- const setup = await import('./c3-report-setup.js');
113
- await store.loadReports(item.ws || wsParam(), true);
114
- const d = store.RS.docs.find((x) => x.path === item.ref);
115
- if (d) { setup.openReportDoc(d); return; }
116
- } catch { /* fall back to the plain document */ }
117
- openDocument(item);
118
- }
119
- /** Open an item: a PMOS item in PMOS (the document sheet), a link in a new tab. */
120
- export function openItem(item) {
121
- if (!item) return;
122
- if (item.kind === 'pmos-doc') return openDocument(item);
123
- if (isPmos(item.kind)) return openReport(item);
124
- if (item.url) openWeb(item.url);
125
- }
126
-
127
- /** The presenter view (or the audience view) of a PMOS deck: the report deck's own (c3-report-deck.js), with your speaker notes. */
128
- async function showDeck(item, mode) {
129
- let deck = null;
130
- try {
131
- const { createDeck } = await import('./c3-report-deck.js');
132
- deck = createDeck({ ws: item.ws || wsParam(), path: item.ref, name: item.title || 'Deck', cycle: '' });
133
- const t0 = Date.now();
134
- while (!deck.state.loaded && Date.now() - t0 < 10000) await new Promise((r) => setTimeout(r, 60));
135
- } catch { deck = null; }
136
- const S = deck && deck.state;
137
- if (!S || !S.loaded || !S.cyc || !S.cyc.designed || !S.R || S.R.format !== 'deck') {
138
- toast('This report has no designed deck yet, so it opens as a document.');
139
- return openItem(item);
140
- }
141
- deck.present(mode);
142
- }
143
- export function presentItem(item) {
144
- if (!item) return;
145
- if (item.kind === 'slides') return openWeb(slidesPresentUrl(item.url));
146
- if (item.kind === 'pmos-deck') return showDeck(item, 'pres');
147
- return openItem(item);
148
- }
149
- /** Audience view: a PMOS deck opens in a window of its own, slides only (initiative meeting-material-replay-gaps). The window opens at once, on the press, because a browser
150
- * blocks a window that opens after a wait. When it is blocked a notice says so and offers the full-screen view in this window. */
151
- export function audienceItem(item) {
152
- if (item && item.kind === 'pmos-deck') {
153
- if (openAudienceWindow({ ws: item.ws || wsParam(), path: item.ref, name: item.title || 'Deck' })) return;
154
- toast({ text: 'The audience window was blocked. Allow pop-ups for this page, or use the full-screen view here.', actionLabel: 'Full-screen view here', timeout: 10000, onAction: () => showDeck(item, 'aud') });
155
- return;
156
- }
157
- return openItem(item);
158
- }
159
-
160
- /* ── the Material part of the meeting card ────────────────────────────────────────────────────────────────────────── */
161
-
162
- /** The links the invite and today's brief already carry, as read-only rows. */
163
- function givenRows(event, brief) {
164
- const seen = new Set(); const rows = [];
165
- const add = (label, url, from) => {
166
- const c = classifyLink(url); if (!c || seen.has(c.url)) return;
167
- seen.add(c.url); rows.push({ id: from + ':' + c.url, kind: c.kind, url: c.url, title: label || c.title, topic: null, present: false, scope: null, from });
168
- };
169
- for (const l of (event && Array.isArray(event.links) ? event.links : [])) add(l && l.label, l && l.url, 'invite');
170
- for (const l of (brief && Array.isArray(brief.links) ? brief.links : [])) add(l && l.label, l && l.url, 'brief');
171
- for (const r of (brief && Array.isArray(brief.refs) ? brief.refs : [])) if (r && r.link) add(r.label, r.link, 'brief');
172
- return rows;
173
- }
174
-
175
- function rowOf(item, o) {
176
- const k = KIND[item.kind] || KIND.link;
177
- const canPresent = !!item.present && k.present;
178
- const where = item.scope === 'series' ? 'every meeting in the series' : item.scope === 'meeting' ? 'this meeting' : '';
179
- const meta = [item.topic ? 'for ' + item.topic : null, BY[item.from] || BY.you, where || null, canPresent ? 'you present it' : null].filter(Boolean).join(' · ');
180
- const act = canPresent
181
- ? lk({ 'data-mm-act': 'present', title: item.kind === 'slides' ? 'Opens it in Google Slides in present mode. Share that tab in the call.' : 'Opens the presenter view in PMOS. Press Audience view before you share the screen.', onclick: () => presentItem(item) }, icon('play', 'sm'), 'Present')
182
- : lk({ 'data-mm-act': 'open', title: isPmos(item.kind) ? 'Opens it in PMOS' : 'Opens it in a new tab', onclick: () => openItem(item) }, icon('out', 'sm'), 'Open');
183
- const rm = item.from === 'you' ? ib('Remove ' + item.title, 'x', { 'data-mm-act': 'remove', title: 'Remove from this meeting. The document itself is not changed.',
184
- onclick: async () => {
185
- const r = await save(o.event, { op: 'remove', scope: item.scope, item: isPmos(item.kind) ? { kind: item.kind, ref: item.ref, ws: item.ws || undefined } : { url: item.url } });
186
- if (r) toast('Removed from the meeting. The document itself is not changed.');
187
- } }) : null;
188
- return el('li', { class: 'cal3-ci mm-row', 'data-mm-item': item.kind, 'data-mm-from': item.from, ...(item.topic ? { 'data-mm-topic': item.topic } : {}) },
189
- el('span', { class: 'tag' }, k.tag), el('span', { class: 'cal3-ct' }, item.title, el('span', { class: 'dim mm-meta' }, meta)), act, rm);
190
- }
191
-
192
- function sectionBody(o, items) {
193
- const rows = [...givenRows(o.event, o.brief), ...(items || [])];
194
- return [
195
- el('h4', null, icon('doc', 'sm'), 'Material ', el('span', { class: 'bdg g', 'data-mm': 'count' }, String(rows.length))),
196
- rows.length ? el('ul', { class: 'cal3-cl', role: 'list' }, ...rows.map((r) => rowOf(r, o))) : el('div', { class: 'fold', 'data-mm': 'none' }, icon('info', 'sm'), items ? 'Nothing is linked to this meeting yet.' : 'Reading the material of this meeting.'),
197
- el('div', { class: 'chips2 mm-foot' }, pbtn('outline', 'Add material', 'plus', { 'data-mm': 'add', onclick: () => openAddMaterial(o) }), el('span', { class: 'dim cal3-note' }, 'Shows in Focus, by topic. Your calendar invite is not changed.')),
198
- ];
199
- }
200
-
201
- /** The Material part of the meeting card (before the meeting). It draws what it holds at once and reads again when it is older than a few seconds. */
202
- export function materialSection(o) {
203
- ensureCss();
204
- const box = el('div', { class: 'cal3-ctx mm', 'data-mm': 'section', 'data-cal3-ctx': 'material' });
205
- const key = evKey(o.event);
206
- const draw = () => { const c = CACHE.get(key); put(box, ...sectionBody(o, c ? c.items : null)); };
207
- draw();
208
- const heard = () => { if (!box.isConnected) return; draw(); };
209
- const onChanged = (ev) => { if (!box.isConnected) { window.removeEventListener('c3-material-changed', onChanged); return; } if (!ev.detail || ev.detail.key === key) draw(); };
210
- window.addEventListener('c3-material-changed', onChanged);
211
- const c = CACHE.get(key);
212
- if (!c || Date.now() - c.at > FRESH_MS) readItems(o.event, { date: o.date, ws: o.ws }).then((r) => { if (r) heard(); });
213
- return box;
214
- }
215
-
216
- /* ── the Add material sheet ───────────────────────────────────────────────────────────────────────────────────────── */
217
-
218
- const levelIni = (o) => {
219
- const lv = o.level; const b = o.brief; const e = o.event || {};
220
- if (lv && lv.kind === 'initiative' && lv.id) return lv.id;
221
- if (lv && lv.kind) return '';
222
- return (b && b.initiative && b.initiative.id) || (typeof e.initiative === 'string' ? e.initiative : '') || '';
223
- };
224
-
225
- function pickRow(it, on, onPick) {
226
- const k = KIND[it.kind] || KIND.link;
227
- return el('li', { class: 'nrow mm-opt' + (on ? ' on' : ''), 'data-mm-opt': it.kind },
228
- el('span', { class: 'ki' }, icon(k.ic)),
229
- el('div', { class: 'nb' }, el('span', { class: 'tt' }, it.title),
230
- el('div', { class: 'chips' }, el('span', { class: 'chip2' }, icon(k.ic, 'sm'), k.tag), it.meta ? el('span', { class: 'tag' }, it.meta) : null,
231
- it.why ? el('span', { class: 'tag mm-why' }, icon('spark', 'sm'), it.why) : null)),
232
- el('div', { class: 'acts' }, on ? el('span', { class: 'tag mm-sel' }, icon('check', 'sm'), 'Picked') : pbtn('ghost', 'Pick', null, { 'data-mm-pick': '', onclick: () => onPick(it) })));
233
- }
234
-
235
- /** Add material: Suggested from the meeting's level, Find in PMOS, Or paste a link; then For, Topic and You. */
236
- export function openAddMaterial(o) {
237
- ensureCss();
238
- const event = o.event || {};
239
- const S = { pick: null, scope: 'meeting', topic: null, present: true, q: '', link: '', sug: null, found: [], topics: [], busy: false, token: 0 };
240
- const root = el('div', { class: 'mm-sheet', 'data-mm': 'sheet' });
241
- const sugBox = el('div', { 'data-mm': 'suggested' });
242
- const foundBox = el('div', { 'data-mm': 'found' });
243
- const pasteBox = el('div', { 'data-mm': 'pasted' });
244
- const optsBox = el('div', { 'data-mm': 'options' });
245
- const findIn = el('input', { class: 'mm-in', type: 'search', 'data-mm': 'find', placeholder: 'A document, report or deck', 'aria-label': 'Find a document, report or deck in PMOS', autocomplete: 'off' });
246
- const linkIn = el('input', { class: 'mm-in', type: 'url', 'data-mm': 'link', placeholder: 'Google Slides, Google Docs, Confluence or any web page', 'aria-label': 'Paste a link', autocomplete: 'off' });
247
- let timer = null;
248
-
249
- const pasted = () => { const c = classifyLink(S.link); return c ? { kind: c.kind, url: c.url, title: c.title, meta: c.meta, present: c.kind === 'slides' } : null; };
250
- const same = (a, b) => !!a && !!b && a.kind === b.kind && (a.ref || a.url) === (b.ref || b.url);
251
- const choose = (it) => { S.pick = it; S.present = !!(KIND[it.kind] && KIND[it.kind].present) && it.present !== false; paint(); };
252
-
253
- function paint() {
254
- put(sugBox, S.sug == null ? el('div', { class: 'fold' }, icon('info', 'sm'), 'Looking in PMOS.') : S.sug.length ? list(S.sug.map((it) => pickRow(it, same(it, S.pick), choose)), { role: 'list' }) : empty('Nothing to suggest yet. Search below, or paste a link.'));
255
- put(foundBox, S.q.length >= 2 ? (S.found.length ? list(S.found.map((it) => pickRow(it, same(it, S.pick), choose)), { role: 'list' }) : el('div', { class: 'fold' }, icon('info', 'sm'), S.busy ? 'Searching.' : 'Nothing in PMOS matches that.')) : null);
256
- const p = pasted();
257
- put(pasteBox, p ? list([pickRow(p, same(p, S.pick), choose)], { role: 'list' }) : el('p', { class: 'dim cal3-note' }, S.link ? 'Paste an https address.' : 'Google Slides gets Present. A web page opens in a new tab and PMOS does not read it.'));
258
- put(optsBox, S.pick ? settings() : null);
259
- }
260
- const seg = (label, rows, cur, key) => el('div', { class: 'seg mm-wrap', role: 'group', 'aria-label': label }, ...rows.map(([v, l]) => pbtn('ghost', l, null, { 'aria-pressed': String(cur === v), [key]: String(v), onclick: () => { S[key === 'data-mm-scope' ? 'scope' : key === 'data-mm-topic' ? 'topic' : 'present'] = v; paint(); } })));
261
- function settings() {
262
- const pick = S.pick; const k = KIND[pick.kind] || KIND.link;
263
- const canPresent = !!k.present;
264
- const topicName = S.topic;
265
- const where = event.series ? 'Every meeting in the series' : 'Every meeting with this title';
266
- const note = canPresent
267
- ? (pick.kind === 'slides' ? 'Present opens it in Google Slides in present mode. You share that tab in the call. ' : 'Present opens the presenter view in PMOS with your speaker notes. The presenter view and the audience view are one switch: press Audience view, then share the screen in the call. ')
268
- : '';
269
- const focusNote = topicName ? 'Focus brings it up when the room gets to ' + topicName + '.' : 'Focus keeps it under Material for the whole meeting.';
270
- return sect({ ic: 'settings', title: 'How it shows', attrs: { class: 'mm-set', 'data-mm': 'settings' } },
271
- el('div', { class: 'mm-f' }, el('span', { class: 'mk-lbl dim mono' }, 'For'),
272
- seg('For', [['meeting', 'This meeting · ' + [dateText(String(event.at || event.start || o.date || '')), timeText(event.at || event.start)].filter(Boolean).join(' ')], ['series', where]], S.scope, 'data-mm-scope')),
273
- S.topics.length ? el('div', { class: 'mm-f' }, el('span', { class: 'mk-lbl dim mono' }, 'Topic'),
274
- el('div', { class: 'seg mm-wrap', role: 'group', 'aria-label': 'Topic' },
275
- ...S.topics.map((t, i) => pbtn('ghost', (i + 1) + '. ' + t.text, null, { 'aria-pressed': String(S.topic === t.text), 'data-mm-topic': t.id, onclick: () => { S.topic = t.text; paint(); } })),
276
- pbtn('ghost', 'Whole meeting', null, { 'aria-pressed': String(S.topic == null), 'data-mm-topic': 'none', onclick: () => { S.topic = null; paint(); } }))) : null,
277
- canPresent ? el('div', { class: 'mm-f' }, el('span', { class: 'mk-lbl dim mono' }, 'You'), seg('Do you present it', [[true, 'Present it'], [false, 'Only read it']], S.present, 'data-mm-pres')) : null,
278
- el('p', { class: 'dim cal3-note' }, note + focusNote),
279
- el('div', { class: 'iacts' }, pbtn('primary', 'Add to the meeting', 'plus', { 'data-mm': 'do', onclick: add }), pbtn('ghost', 'Cancel', null, { 'data-mm': 'cancel', onclick: () => { S.pick = null; paint(); } })));
280
- }
281
- async function add() {
282
- const pick = S.pick; if (!pick) return;
283
- const item = isPmos(pick.kind) ? { kind: pick.kind, ref: pick.ref, title: pick.title, ws: pick.ws || undefined } : { url: pick.url, title: pick.title };
284
- const r = await save(event, { op: 'add', scope: S.scope, item, topic: S.topic || undefined, present: S.present && !!(KIND[pick.kind] || {}).present });
285
- if (!r) return;
286
- closeSheet();
287
- toast('Added to ' + (S.scope === 'series' ? 'every meeting in the series' : 'this meeting') + '. Focus shows it' + (S.topic ? ' at ' + S.topic : '') + '.');
288
- }
289
-
290
- findIn.addEventListener('input', () => {
291
- S.q = findIn.value.trim(); S.busy = S.q.length >= 2; S.found = []; paint();
292
- clearTimeout(timer);
293
- if (!S.busy) return;
294
- const my = ++S.token;
295
- timer = setTimeout(async () => {
296
- const p = new URLSearchParams({ q: S.q }); const ws = o.ws || wsParam(); if (ws) p.set('ws', ws);
297
- const r = await pmGet('/api/meeting-material/suggest?' + p.toString()).catch(() => null);
298
- if (my !== S.token) return;
299
- S.busy = false; S.found = r && r.ok && Array.isArray(r.found) ? r.found : []; paint();
300
- }, 220);
301
- });
302
- linkIn.addEventListener('input', () => { S.link = linkIn.value.trim(); const p = pasted(); if (p) S.pick = p; else if (S.pick && !S.pick.ref && S.pick.url) S.pick = null; paint(); });
303
-
304
- put(root,
305
- el('p', { class: 'dim cal3-note' }, (event.title || 'This meeting') + (event.at || event.start ? ' · ' + dateText(event.at || event.start) + ' ' + timeText(event.at || event.start) : '') + '. PMOS keeps the link on its record of this meeting. The invite in your calendar is not changed.'),
306
- sect({ ic: 'spark', title: 'Suggested for this meeting', attrs: { 'data-mm': 'suggest-sect' } }, sugBox),
307
- sect({ ic: 'search', title: 'Find in PMOS' }, findIn, foundBox),
308
- sect({ ic: 'out', title: 'Or paste a link' }, linkIn, pasteBox),
309
- optsBox);
310
- paint();
311
- openSheet({ title: 'Add material', icon: 'doc', wide: true, body: [el('div', { class: 'c3x' }, root)], onClose: () => { clearTimeout(timer); if (typeof o.back === 'function') { try { o.back(); } catch { /* the page is gone */ } } } });
312
-
313
- const ini = levelIni(o);
314
- const p = new URLSearchParams(); const ws = o.ws || wsParam(); if (ws) p.set('ws', ws); if (ini) p.set('initiative', ini);
315
- pmGet('/api/meeting-material/suggest?' + p.toString()).then((r) => { S.sug = r && r.ok && Array.isArray(r.suggested) ? r.suggested : []; paint(); }).catch(() => { S.sug = []; paint(); });
316
- readItems(event, { date: o.date, ws: o.ws, topics: true }).then((r) => { S.topics = r && Array.isArray(r.topics) ? r.topics : []; paint(); });
317
- }
318
-
319
- if (typeof window !== 'undefined') {
320
- window.C3Material = { open: (event, opts) => openAddMaterial({ event, ...(opts || {}) }), section: materialSection, openItem, presentItem, audienceItem, KIND };
321
- }
@@ -1,3 +0,0 @@
1
- /* pm/c3-md.js — moved to pm/cozy-md.js (premium-agreed-design: no c3-* module loads on a premium page). The console keeps importing
2
- * this name, so it re-exports the one copy. */
3
- export * from './cozy-md.js';
@@ -1,89 +0,0 @@
1
- /* pm/c3-misc-panels.js — three panels of the console3 mockup that the Briefing, Work and Reports views lacked (content audit, planning/research/console3-content-parity.md).
2
- * stopCard(rows) Briefing, Reflect lens: "What I could stop" (console3.html vBrief, line 1475): the agent's proposals, an icon and a line each.
3
- * It is a read-only list, as in the mockup: nothing here acts, so nothing outward can be sent from it.
4
- * forecastChecksCard(opts) Reports, Project family: "Forecast at each check, <initiative>" with the chart "Forecast date at each check against the promise"
5
- * (console3.html driftSVG, line 3964). The points are the CHECKS of the plan from GET /api/c3-timeline?initiative=<id>
6
- * (workspace/lib/routes-c3-timeline.js, which folds the plan ledger with scripts/plan-forecast.js checkFrames): per check the forecast end
7
- * and the promised date. opts = { id, title }. With no id, the initiative with the largest slip among the Calendar's quarter rows is used.
8
- * With fewer than two checks that carry a forecast, the card says so and draws nothing.
9
- * Nothing here writes or sends. Built with el(): data never goes through innerHTML. */
10
- import { el } from './dom.js';
11
- import { pmGet } from './http.js';
12
- import { c3ic } from './pm-work-view.js';
13
- import { readQuarter } from './c3-plan.js';
14
-
15
- /* ── What I could stop ── */
16
- export function stopCard(rows) {
17
- const list = (Array.isArray(rows) ? rows : []).filter((r) => r && r.text);
18
- if (!list.length) return null;
19
- return el('section', { class: 'card sect', 'data-c3pg': 'stop', 'aria-label': 'What I could stop' },
20
- el('div', { class: 'sh2' }, el('h2', null, c3ic('moon', 'sm'), 'What I could stop')),
21
- el('ul', { class: 'list', role: 'list' }, ...list.map((r) => el('li', { class: 'nrow', style: 'grid-template-columns:auto minmax(0,1fr)', 'data-stop-row': '' },
22
- el('span', { class: 'ki' }, c3ic(r.icon || 'check')), el('div', { class: 'nb' }, r.text)))));
23
- }
24
-
25
- /* ── Forecast at each check ── */
26
- const NSV = 'http://www.w3.org/2000/svg';
27
- const sv = (tag, attrs, ...kids) => { const n = document.createElementNS(NSV, tag); for (const k of Object.keys(attrs || {})) n.setAttribute(k, attrs[k]); for (const c of kids) if (c) n.appendChild(c); return n; };
28
- const svt = (x, y, t, a) => { const n = sv('text', { x, y, ...(a || {}) }); n.textContent = t; return n; };
29
- const MON = ['Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'];
30
- const dayNum = (iso) => Math.round(Date.parse(iso + 'T00:00:00Z') / 864e5);
31
- const dlab = (n) => { const d = new Date(n * 864e5); return d.getUTCDate() + ' ' + MON[d.getUTCMonth()]; };
32
-
33
- /** The chart, from [{ date: 'YYYY-MM-DD', forecast_end, promised }] (the frames that carry a forecast). */
34
- export function forecastChart(frames) {
35
- const W = 560; const H = 160; const x0 = 58; const x1 = W - 20; const y0 = 16; const y1 = H - 30;
36
- const vals = frames.map((f) => dayNum(f.forecast_end)); const pr = dayNum(frames[0].promised || frames[0].forecast_end);
37
- const mn = Math.min(pr, ...vals) - 2; const mx = Math.max(pr, ...vals) + 2; const n = frames.length;
38
- const X = (i) => x0 + i * (x1 - x0) / (n - 1); const Y = (v) => y1 - (v - mn) / (mx - mn) * (y1 - y0);
39
- const s = sv('svg', { class: 'mat', viewBox: `0 0 ${W} ${H}`, role: 'img', 'aria-label': 'Forecast date at each check against the promise', 'data-rp-chart': 'forecast-checks' });
40
- [pr, Math.round((mn + mx) / 2), mx - 1].forEach((v) => s.append(sv('line', { x1: x0, x2: x1, y1: Y(v), y2: Y(v), stroke: 'var(--border)' }), svt(x0 - 5, Y(v) + 4, dlab(v), { 'text-anchor': 'end' })));
41
- s.append(sv('line', { x1: x0, x2: x1, y1: Y(pr), y2: Y(pr), stroke: 'var(--success)', 'stroke-dasharray': '5 4', 'stroke-width': 2 }),
42
- sv('polyline', { points: vals.map((v, i) => X(i).toFixed(1) + ',' + Y(v).toFixed(1)).join(' '), fill: 'none', stroke: 'var(--destructive)', 'stroke-width': 2.5, 'stroke-linejoin': 'round' }));
43
- vals.forEach((v, i) => {
44
- const c = sv('circle', { cx: X(i), cy: Y(v), r: i === n - 1 ? 6 : 4, fill: v > pr ? 'var(--destructive)' : 'var(--success)', stroke: 'var(--card)', 'stroke-width': 2 });
45
- const t = sv('title', {}); t.textContent = dlab(dayNum(frames[i].date)) + ': forecast ' + dlab(v) + (v > pr ? ', ' + (v - pr) + ' days after the promise' : ', on the promise');
46
- c.appendChild(t); s.append(c, svt(X(i), H - 12, dlab(dayNum(frames[i].date)), { 'text-anchor': 'middle' }));
47
- });
48
- s.append(svt(x1, Y(pr) - 6, 'promised ' + dlab(pr), { 'text-anchor': 'end', fill: 'var(--success)' }));
49
- return s;
50
- }
51
-
52
- const done = new Map(); // initiative id → the frames that carry a forecast, or { error }
53
- const pending = new Map();
54
- function readChecks(id) {
55
- if (done.has(id)) return Promise.resolve(done.get(id));
56
- if (!pending.has(id)) {
57
- pending.set(id, pmGet('/api/c3-timeline?initiative=' + encodeURIComponent(id)).then((j) => {
58
- const r = j && j.ok !== false && Array.isArray(j.frames) ? j.frames.filter((f) => f.forecast_end && f.date) : { error: (j && j.error) || 'unreadable' };
59
- done.set(id, r); pending.delete(id); return r;
60
- }, (e) => { pending.delete(id); return { error: String((e && e.message) || e) }; }));
61
- }
62
- return pending.get(id);
63
- }
64
- /** With no initiative named: the one with the largest slip among the quarter rows that have a promise. */
65
- async function pickInitiative() {
66
- const j = await readQuarter().catch(() => null);
67
- const rows = ((j && j.gantt) || []).filter((g) => g.status !== 'no plan' && g.promised);
68
- rows.sort((a, b) => (b.slip_days || 0) - (a.slip_days || 0));
69
- return rows[0] ? { id: rows[0].id, title: rows[0].title || rows[0].id } : null;
70
- }
71
-
72
- export function forecastChecksCard(opts = {}) {
73
- const head = (t) => el('h3', null, c3ic('clock'), 'Forecast at each check' + (t ? ', ' + t : ''));
74
- const box = el('section', { class: 'card', 'data-rp-section': 'forecast-checks' });
75
- const paint = (t, r) => {
76
- if (r && r.error) box.replaceChildren(head(t), el('p', { class: 'dim mono', style: 'font-size:var(--fs-2)', role: 'status' }, 'The checks could not be read: ' + r.error));
77
- else if (!r || r.length < 2) box.replaceChildren(head(t), el('p', { class: 'dim mono', style: 'font-size:var(--fs-2)', role: 'status', 'data-rp-empty': '' }, 'Fewer than two checks have a forecast date yet, so there is no history to draw.'));
78
- else box.replaceChildren(head(t), forecastChart(r));
79
- };
80
- const run = async () => {
81
- const who = opts.id ? { id: opts.id, title: opts.title } : await pickInitiative();
82
- if (!who) { box.replaceChildren(head(''), el('p', { class: 'dim mono', style: 'font-size:var(--fs-2)', role: 'status', 'data-rp-empty': '' }, 'No initiative has a promised date yet, so there is nothing to check a forecast against.')); return; }
83
- if (done.has(who.id)) { paint(who.title, done.get(who.id)); return; }
84
- box.replaceChildren(head(who.title), el('p', { class: 'dim mono', style: 'font-size:var(--fs-2)', role: 'status' }, 'Reading the checks.'));
85
- paint(who.title, await readChecks(who.id));
86
- };
87
- run();
88
- return box;
89
- }
@@ -1,110 +0,0 @@
1
- /* pm/c3-new-session.js — start a session from console3, in a sheet, and open its terminal in the console (c3-new-session).
2
- * openNewSession({ ws, boards, trees, initiative, on, onStarted }) on: 'auto' (default), 'ws:<id>' (that tree) or 'new'
3
- * boards: the workspace's repositories ({ id, name }); the sheet's Board select picks one, and Runs on then lists that repository's trees.
4
- * onStarted(id, ws): the new session's id and the board it started on
5
- * Before this, every "start a session" press on console3 went to the classic app (/classic.html), because the page had no way
6
- * to start one. A session starts over the terminal connection, so this uses the same request as the classic dock's new-session
7
- * sheet (tab-term.js requestSpawn) and then opens the terminal with c3-session-term.js. Nothing opens unless the server says the
8
- * session started; a refusal stays in the sheet as the server's sentence.
9
- * Fields: name (empty: Shell or Claude, numbered when taken), agent (the Settings default first), the board (repository), and where it runs:
10
- * Automatic the server's start policy picks the tree (the initiative's own working copy, or the main tree)
11
- * a listed tree that working tree as it is
12
- * New branch a new branch in its own working copy
13
- * A Claude session takes the server's default profile and the Settings launch flags and tier, as the classic dock does. */
14
- import { el } from './dom.js';
15
- import { openSheet } from './c3-sheet.js';
16
- import { button } from './primitives.js';
17
- import { toast } from './c3-toast.js';
18
- import { pmGet } from './http.js';
19
- import { sessionDefaults, adoptProfileDefault, CLIS } from './dock.js';
20
-
21
- const AGENT = { shell: 'Shell', claude: 'Claude' };
22
-
23
- /** A free name: `base`, else `base 2`, `base 3`, … among the sessions that have not ended. Pure, for Node. */
24
- export function freeName(base, sessions) {
25
- const taken = new Set((sessions || []).filter((s) => s && s.state !== 'exited' && s.shown !== 'exited').map((s) => s.name));
26
- if (!taken.has(base)) return base;
27
- for (let i = 2; ; i += 1) if (!taken.has(base + ' ' + i)) return base + ' ' + i;
28
- }
29
-
30
- /** What requestSpawn is sent, from the form. Pure, for Node. Returns { error } when the form is not complete. */
31
- export function spawnOpts(f, d) {
32
- const claude = f.agent === 'claude';
33
- const common = {
34
- name: f.name, agent: f.agent, initiative: f.initiative || null,
35
- profile: claude ? (f.profile === undefined ? null : f.profile) : null,
36
- flags: claude && d && Array.isArray(d.flags) && d.flags.length ? d.flags.map((x) => ({ flag: x.flag, ...(x.value ? { value: x.value } : {}) })) : undefined,
37
- tier: claude && d && d.tier && d.tier !== 'auto' ? d.tier : null,
38
- workType: 'general',
39
- };
40
- if (f.on === 'new') {
41
- const b = String(f.branch || '').trim();
42
- if (!b) return { error: 'Type a name for the new branch.' };
43
- return { ...common, ws: f.ws, branch: b, createBranch: true, isolate: true };
44
- }
45
- if (f.on && f.on.startsWith('ws:')) return { ...common, ws: f.on.slice(3), branch: null, createBranch: false, isolate: null };
46
- return { ...common, ws: f.ws, start: true };
47
- }
48
-
49
- export function openNewSession(opts) {
50
- const o = opts || {};
51
- const d = sessionDefaults();
52
- let trees = (o.trees || []).filter((t) => t && !t.missing && t.ws);
53
- const F = { ws: o.ws, agent: CLIS.includes(d.cli) ? d.cli : 'shell', on: o.on && (o.on === 'new' || trees.some((t) => 'ws:' + t.ws === o.on)) ? o.on : 'auto', busy: false };
54
- const boards = (o.boards || []).filter((w) => w && w.id);
55
- if (o.ws && !boards.some((w) => w.id === o.ws)) boards.unshift({ id: o.ws, name: o.ws });
56
-
57
- const name = el('input', { type: 'text', 'aria-label': 'Name', placeholder: 'Empty: Shell or Claude', 'data-c3ns': 'name' });
58
- const agent = el('select', { 'aria-label': 'Agent', 'data-c3ns': 'agent', onchange: (e) => { F.agent = e.target.value; } },
59
- ...CLIS.map((c) => el('option', { value: c, selected: c === F.agent }, AGENT[c] || c)));
60
- const branch = el('input', { type: 'text', 'aria-label': 'New branch', placeholder: 'feature/…', 'data-c3ns': 'branch' });
61
- const branchRow = el('label', { class: 'c3ns-f', hidden: F.on !== 'new' }, el('span', { class: 'dim mono' }, 'New branch'), branch);
62
- const where = el('select', { 'aria-label': 'Runs on', 'data-c3ns': 'on', onchange: (e) => { F.on = e.target.value; branchRow.hidden = F.on !== 'new'; } });
63
- const fillWhere = () => where.replaceChildren(
64
- el('option', { value: 'auto', selected: F.on === 'auto' }, o.initiative ? 'Automatic: the working copy of initiative/' + o.initiative : 'Automatic: the main working tree'),
65
- ...trees.map((t) => el('option', { value: 'ws:' + t.ws, selected: F.on === 'ws:' + t.ws }, (t.main ? 'Main tree' : '⑂') + ' ' + (t.branch || 'detached'))),
66
- el('option', { value: 'new', selected: F.on === 'new' }, 'New branch'));
67
- fillWhere();
68
- // another board: its own working trees, read from the server; Runs on goes back to Automatic
69
- const board = el('select', { 'aria-label': 'Board', 'data-c3ns': 'board', onchange: async (e) => {
70
- F.ws = e.target.value; F.on = 'auto'; branchRow.hidden = true; trees = []; fillWhere();
71
- const ws = F.ws;
72
- const r = await pmGet('/api/git/worktrees?ws=' + encodeURIComponent(ws)).catch(() => null);
73
- if (ws !== F.ws) return;
74
- trees = (r && r.ok && Array.isArray(r.worktrees) ? r.worktrees : []).filter((t) => t && !t.missing && t.ws && (t.ws === ws || t.main));
75
- fillWhere();
76
- } }, ...boards.map((w) => el('option', { value: w.id, selected: w.id === F.ws }, w.name || w.id)));
77
- const err = el('p', { class: 'c3ns-err', role: 'alert', 'data-c3ns': 'error' });
78
- const go = button({ label: 'Start', variant: 'primary', size: 'sm', onClick: () => start(), attrs: { 'data-c3ns': 'start' } });
79
- const body = el('div', { class: 'c3ns', 'data-c3ns': 'form' },
80
- el('label', { class: 'c3ns-f' }, el('span', { class: 'dim mono' }, 'Name'), name),
81
- el('label', { class: 'c3ns-f' }, el('span', { class: 'dim mono' }, 'Agent'), agent),
82
- boards.length ? el('label', { class: 'c3ns-f' }, el('span', { class: 'dim mono' }, 'Board'), board) : null,
83
- el('label', { class: 'c3ns-f' }, el('span', { class: 'dim mono' }, 'Runs on'), where),
84
- branchRow, err, el('div', { class: 'c3ns-go' }, go));
85
- const sheet = openSheet({ title: o.initiative ? 'New session for ' + o.initiative : 'New session', icon: 'term', body });
86
- requestAnimationFrame(() => name.focus());
87
-
88
- async function start() {
89
- if (F.busy) return;
90
- if (!F.ws) { err.textContent = 'Pick a board first.'; return; }
91
- F.busy = true; go.disabled = true; err.textContent = '';
92
- const sessions = await pmGet('/api/sessions').then((r) => (r && Array.isArray(r.sessions) ? r.sessions : []), () => []);
93
- const base = (AGENT[F.agent] || 'Shell') + (o.initiative ? ' · ' + o.initiative : '');
94
- // the default profile is the server's; this browser's copy can be old, so a Claude start reads it first
95
- const profile = F.agent === 'claude' ? adoptProfileDefault(await pmGet('/api/profiles').catch(() => null)) : null;
96
- const req = spawnOpts({ name: name.value.trim() || freeName(base, sessions), agent: F.agent, initiative: o.initiative, profile, on: F.on, branch: branch.value, ws: F.ws }, d);
97
- if (req.error) { err.textContent = req.error; F.busy = false; go.disabled = false; return; }
98
- const term = await import('./tab-term.js').catch(() => null);
99
- const res = term ? await term.requestSpawn(req) : { ok: false, error: 'The terminal connection could not be loaded on this page.' };
100
- F.busy = false; go.disabled = false;
101
- if (!res || !res.ok) { err.textContent = (res && res.error) || 'The session was not started.'; return; }
102
- sheet.close();
103
- if (o.onStarted) o.onStarted(res.id, F.ws);
104
- const m = await import('./c3-session-term.js');
105
- m.openSessionTerm({ id: res.id, name: req.name });
106
- // a session that shares its working tree with a running one is told so: their edits land in the same files
107
- if (res.notice && /already running/.test(res.notice)) toast({ text: res.notice, timeout: 12000 });
108
- }
109
- return sheet;
110
- }