create-pmos 0.398.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 (515) 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 +19 -15
  7. package/workspace/briefing-premium-board-test.js +82 -50
  8. package/workspace/briefing-premium-calendar-2-test.js +36 -36
  9. package/workspace/briefing-premium-calendar-3-test.js +39 -39
  10. package/workspace/briefing-premium-calendar-test.js +23 -24
  11. package/workspace/briefing-premium-doc-edit-test.js +8 -10
  12. package/workspace/briefing-premium-initiative-test.js +38 -16
  13. package/workspace/briefing-premium-insights-test.js +114 -37
  14. package/workspace/briefing-premium-metrics-test.js +6 -4
  15. package/workspace/briefing-premium-products-test.js +10 -7
  16. package/workspace/briefing-premium-sources-test.js +25 -22
  17. package/workspace/briefing-premium-test.js +48 -43
  18. package/workspace/briefing-premium-work-test.js +16 -11
  19. package/workspace/c3-capture-test.js +0 -17
  20. package/workspace/changelog.json +29 -0
  21. package/workspace/ev-everywhere-test.js +210 -0
  22. package/workspace/fixtures/premium-viewer-fixtures.js +11 -6
  23. package/workspace/guide/briefing-premium.md +2 -2
  24. package/workspace/guide/home.md +58 -19
  25. package/workspace/guide/index.md +1 -1
  26. package/workspace/guide/layout.md +2 -2
  27. package/workspace/guide/notes.md +2 -2
  28. package/workspace/guide/phone-companion.md +1 -1
  29. package/workspace/lib/board-grill.js +63 -0
  30. package/workspace/lib/board-premium.js +36 -5
  31. package/workspace/lib/initiative-layout.js +77 -0
  32. package/workspace/lib/insights-premium.js +3 -2
  33. package/workspace/lib/insights-records.js +21 -7
  34. package/workspace/lib/meeting-points.js +52 -0
  35. package/workspace/lib/news-for-you.js +88 -0
  36. package/workspace/lib/notes-series.js +29 -6
  37. package/workspace/lib/report-confirm.js +48 -0
  38. package/workspace/lib/route-modules.js +9 -9
  39. package/workspace/lib/routes-board-docs.js +46 -0
  40. package/workspace/lib/routes-board-grill.js +90 -0
  41. package/workspace/lib/routes-home-review.js +108 -0
  42. package/workspace/lib/routes-initiative-layout.js +57 -0
  43. package/workspace/lib/routes-insights-premium.js +4 -1
  44. package/workspace/lib/routes-insights-records.js +8 -4
  45. package/workspace/lib/routes-meeting-points.js +37 -0
  46. package/workspace/lib/routes-news.js +57 -0
  47. package/workspace/lib/routes-notes.js +2 -1
  48. package/workspace/lib/routes-phone-day.js +18 -9
  49. package/workspace/lib/routes-report-confirm.js +31 -0
  50. package/workspace/lib/routes-search.js +38 -0
  51. package/workspace/lib/routes-slash.js +95 -0
  52. package/workspace/lib/search-index.js +176 -0
  53. package/workspace/package-lock.json +2 -2
  54. package/workspace/package.json +1 -2
  55. package/workspace/premium-board-actions-test.js +86 -50
  56. package/workspace/premium-briefing-depth-test.js +55 -54
  57. package/workspace/premium-chat-chart-tab-test.js +4 -2
  58. package/workspace/premium-chat-goal-view-test.js +1 -1
  59. package/workspace/premium-chat-report-tab-test.js +16 -2
  60. package/workspace/premium-chat-term-test.js +0 -10
  61. package/workspace/premium-core-doc-issue-test.js +15 -13
  62. package/workspace/premium-menu-rows-test.js +1 -1
  63. package/workspace/premium-phone-card-test.js +7 -5
  64. package/workspace/premium-report-read-test.js +55 -18
  65. package/workspace/premium-vw-backlog-test.js +2 -2
  66. package/workspace/premium-vw-cal-test.js +50 -35
  67. package/workspace/premium-vw-doc-test.js +10 -11
  68. package/workspace/premium-vw-item-test.js +1 -1
  69. package/workspace/premium-vw-jira-test.js +2 -2
  70. package/workspace/premium-vw-meet-test.js +37 -40
  71. package/workspace/premium-vw-notes-test.js +21 -19
  72. package/workspace/premium-vw-rec-test.js +11 -12
  73. package/workspace/premium-welcome-test.js +3 -3
  74. package/workspace/premium-work-depth-test.js +5 -6
  75. package/workspace/public/capture.html +23 -0
  76. package/workspace/public/pm/bd-acts.js +303 -225
  77. package/workspace/public/pm/bd-asks.js +261 -0
  78. package/workspace/public/pm/bd-pop.js +59 -0
  79. package/workspace/public/pm/bd-span.js +49 -13
  80. package/workspace/public/pm/bd-views.js +169 -0
  81. package/workspace/public/pm/c3-base.js +47 -0
  82. package/workspace/public/pm/c3-capture.js +1 -1
  83. package/workspace/public/pm/c3-ini-ui.js +1 -1
  84. package/workspace/public/pm/c3-sheet.js +1 -1
  85. package/workspace/public/pm/c3-toast.js +1 -1
  86. package/workspace/public/pm/console3.css +3 -0
  87. package/workspace/public/pm/cozy-board.css +301 -0
  88. package/workspace/public/pm/cozy-ev.css +228 -0
  89. package/workspace/public/pm/cozy-evmodel.js +106 -0
  90. package/workspace/public/pm/cozy-evui.js +47 -0
  91. package/workspace/public/pm/cozy-home.css +20 -5
  92. package/workspace/public/pm/cozy-insights.css +148 -10
  93. package/workspace/public/pm/cozy-nav.js +103 -39
  94. package/workspace/public/pm/cozy-news.js +140 -0
  95. package/workspace/public/pm/cozy-search.js +203 -0
  96. package/workspace/public/pm/cozy-settings.js +198 -0
  97. package/workspace/public/pm/cozy-sources.js +89 -0
  98. package/workspace/public/pm/cozy-today.css +220 -0
  99. package/workspace/public/pm/cozy-viewer.js +5 -2
  100. package/workspace/public/pm/cozy-vw-mtg.css +350 -0
  101. package/workspace/public/pm/cozy-vw-rp.css +152 -0
  102. package/workspace/public/pm/cozy.css +9 -0
  103. package/workspace/public/pm/goal-chat.js +5 -1
  104. package/workspace/public/pm/home-adddoc.js +5 -5
  105. package/workspace/public/pm/home-app.js +365 -70
  106. package/workspace/public/pm/home-around.js +24 -126
  107. package/workspace/public/pm/home-chat.js +77 -18
  108. package/workspace/public/pm/home-data.js +9 -7
  109. package/workspace/public/pm/home-dictate.js +57 -0
  110. package/workspace/public/pm/home-draft.js +6 -6
  111. package/workspace/public/pm/home-ini-model.js +190 -0
  112. package/workspace/public/pm/home-ini.css +171 -0
  113. package/workspace/public/pm/home-ini.js +466 -0
  114. package/workspace/public/pm/home-list.js +289 -0
  115. package/workspace/public/pm/home-more.js +18 -135
  116. package/workspace/public/pm/home-phone-card.js +13 -8
  117. package/workspace/public/pm/home-review.js +103 -0
  118. package/workspace/public/pm/home-task.js +67 -0
  119. package/workspace/public/pm/home-today.js +148 -0
  120. package/workspace/public/pm/home-work.js +63 -28
  121. package/workspace/public/pm/note-dock.js +1 -2
  122. package/workspace/public/pm/notes-links.js +1 -2
  123. package/workspace/public/pm/notes-task.js +3 -4
  124. package/workspace/public/pm/premium-board.js +164 -40
  125. package/workspace/public/pm/premium-chart-tab.js +4 -5
  126. package/workspace/public/pm/premium-first.js +5 -7
  127. package/workspace/public/pm/premium-initiative-head.js +3 -3
  128. package/workspace/public/pm/premium-insights.js +499 -202
  129. package/workspace/public/pm/premium-mtg-present.js +138 -0
  130. package/workspace/public/pm/premium-mtg-replay.js +142 -0
  131. package/workspace/public/pm/premium-report-read.js +216 -52
  132. package/workspace/public/pm/premium-report-tab.js +44 -19
  133. package/workspace/public/pm/premium-shell.js +7 -7
  134. package/workspace/public/pm/premium-vw-cal.js +150 -60
  135. package/workspace/public/pm/premium-vw-doc.css +20 -2
  136. package/workspace/public/pm/premium-vw-doc.js +22 -7
  137. package/workspace/public/pm/premium-vw-mtg.js +488 -261
  138. package/workspace/public/pm/premium-vw-notes.js +61 -0
  139. package/workspace/public/pm/rp-parts.js +269 -0
  140. package/workspace/public/pm/view-notes.js +2 -2
  141. package/workspace/public/premium-board.html +4 -3
  142. package/workspace/public/premium-insights.html +10 -10
  143. package/workspace/public/premium.html +3 -1
  144. package/workspace/r/m1.png +0 -0
  145. package/workspace/r/m2.png +0 -0
  146. package/workspace/r/m3.png +0 -0
  147. package/workspace/r/nl.png +0 -0
  148. package/workspace/replaced-tests.json +435 -0
  149. package/workspace/run-tests.js +323 -28
  150. package/workspace/server.js +15 -10
  151. package/workspace/test-files.json +3 -140
  152. package/workspace/test-lists/base.json +1 -2
  153. package/workspace/test-lists/c3-desktop-light-load.json +1 -2
  154. package/workspace/test-lists/c3-initiative-boards.json +1 -2
  155. package/workspace/test-lists/c3-meeting-focus.json +2 -12
  156. package/workspace/test-lists/c3-work-agent.json +1 -2
  157. package/workspace/test-lists/calendar-tidy-up.json +1 -2
  158. package/workspace/test-lists/console3-reports.json +1 -2
  159. package/workspace/test-lists/docs-three-way-sync.json +1 -2
  160. package/workspace/test-lists/extension-capture.json +5 -0
  161. package/workspace/test-lists/initiative-layout.json +9 -0
  162. package/workspace/test-lists/jira-wbs.json +1 -2
  163. package/workspace/test-lists/legacy-cleanup-a.json +9 -0
  164. package/workspace/test-lists/meeting-material.json +1 -2
  165. package/workspace/test-lists/meeting-notes.json +2 -36
  166. package/workspace/test-lists/meeting-replay.json +1 -2
  167. package/workspace/test-lists/mm-capture.json +2 -12
  168. package/workspace/test-lists/my-work.json +2 -10
  169. package/workspace/test-lists/onboarding-firstrun.json +2 -12
  170. package/workspace/test-lists/people-directory.json +1 -2
  171. package/workspace/test-lists/premium-uncovered-meetings.json +9 -0
  172. package/workspace/test-lists/premium-uncovered-reports.json +9 -0
  173. package/workspace/test-lists/run2-a.json +1 -2
  174. package/workspace/test-lists/run2-d.json +2 -19
  175. package/workspace/test-lists/run3-b.json +1 -2
  176. package/workspace/test-lists/run3-c.json +2 -12
  177. package/workspace/test-lists/run4-b.json +1 -2
  178. package/workspace/test-lists/run4-d.json +1 -5
  179. package/workspace/test-lists/run5-c.json +1 -11
  180. package/workspace/test-lists/run6.json +1 -5
  181. package/workspace/test-lists/uf-everywhere.json +15 -0
  182. package/workspace/test-lists/uf-home.json +9 -0
  183. package/workspace/test-lists/uncovered-board.json +9 -0
  184. package/workspace/test-lists/workspace-launch-flags.json +2 -12
  185. package/workspace/test-lists/workspace-profile-detection.json +2 -10
  186. package/workspace/test-timings.json +242 -123
  187. package/workspace/c3-briefing-test.js +0 -136
  188. package/workspace/c3-core-docs-test.js +0 -170
  189. package/workspace/c3-driver-fixture.js +0 -64
  190. package/workspace/c3-driver-test.js +0 -169
  191. package/workspace/c3-foundation-test.js +0 -163
  192. package/workspace/c3-ib-items-test.js +0 -114
  193. package/workspace/c3-ib-more-test.js +0 -146
  194. package/workspace/c3-ib-triage-backlog-test.js +0 -128
  195. package/workspace/c3-ini-harness.js +0 -66
  196. package/workspace/c3-ini-life-test.js +0 -167
  197. package/workspace/c3-initiatives-test.js +0 -186
  198. package/workspace/c3-light-load-test.js +0 -112
  199. package/workspace/c3-one-home-test.js +0 -149
  200. package/workspace/c3-phone-test.js +0 -289
  201. package/workspace/c3-quiet-test.js +0 -157
  202. package/workspace/c3-report-design-real-test.js +0 -264
  203. package/workspace/c3-report-design-test.js +0 -442
  204. package/workspace/c3-report-setup-test.js +0 -192
  205. package/workspace/c3-report-structure-real-test.js +0 -248
  206. package/workspace/c3-report-structure-test.js +0 -397
  207. package/workspace/c3-reports-test.js +0 -288
  208. package/workspace/c3-scan-test.js +0 -517
  209. package/workspace/c3-sessions-panel-test.js +0 -365
  210. package/workspace/c3-settings-test.js +0 -204
  211. package/workspace/c3-updates-test.js +0 -131
  212. package/workspace/c3-work-test.js +0 -260
  213. package/workspace/cut-stub.js +0 -40
  214. package/workspace/first-paint-audit.js +0 -160
  215. package/workspace/lib/c3-full-console.js +0 -15
  216. package/workspace/lib/engine/derived/trust.js +0 -3
  217. package/workspace/lib/engine/plan-forecast.js +0 -342
  218. package/workspace/lib/engine/report-families.js +0 -175
  219. package/workspace/lib/engine/truth-table.js +0 -57
  220. package/workspace/lib/routes-c3-init.js +0 -54
  221. package/workspace/lib/routes-c3-life.js +0 -120
  222. package/workspace/lib/routes-c3-timeline.js +0 -192
  223. package/workspace/lib/routes-forecast.js +0 -86
  224. package/workspace/lib/routes-releases.js +0 -130
  225. package/workspace/lib/routes-report-facts.js +0 -85
  226. package/workspace/lib/routes-report-families.js +0 -33
  227. package/workspace/lib/routes-signals.js +0 -51
  228. package/workspace/lib/routes-timeline.js +0 -197
  229. package/workspace/public/c3.html +0 -35
  230. package/workspace/public/index.html +0 -156
  231. package/workspace/public/pm/app.js +0 -831
  232. package/workspace/public/pm/bd-board.js +0 -159
  233. package/workspace/public/pm/bd-drag.js +0 -59
  234. package/workspace/public/pm/bd-model.js +0 -152
  235. package/workspace/public/pm/bd-timeline.js +0 -233
  236. package/workspace/public/pm/bd-tree.js +0 -244
  237. package/workspace/public/pm/board-copy.js +0 -59
  238. package/workspace/public/pm/board-read.js +0 -38
  239. package/workspace/public/pm/branches-sheet.js +0 -56
  240. package/workspace/public/pm/breakdown-api.js +0 -58
  241. package/workspace/public/pm/breakdown-copy.js +0 -138
  242. package/workspace/public/pm/briefing-deck.js +0 -441
  243. package/workspace/public/pm/briefing-model.js +0 -251
  244. package/workspace/public/pm/c3-ambient.js +0 -100
  245. package/workspace/public/pm/c3-audience-link.js +0 -21
  246. package/workspace/public/pm/c3-audience.js +0 -46
  247. package/workspace/public/pm/c3-boot.js +0 -13
  248. package/workspace/public/pm/c3-breakdown.js +0 -240
  249. package/workspace/public/pm/c3-brief-data.js +0 -11
  250. package/workspace/public/pm/c3-brief-mentions.js +0 -137
  251. package/workspace/public/pm/c3-brief-needs.js +0 -288
  252. package/workspace/public/pm/c3-brief-pulse.js +0 -112
  253. package/workspace/public/pm/c3-brief-summary.js +0 -139
  254. package/workspace/public/pm/c3-brief-today.js +0 -79
  255. package/workspace/public/pm/c3-brief.js +0 -279
  256. package/workspace/public/pm/c3-cal-strategy.js +0 -529
  257. package/workspace/public/pm/c3-calendar.js +0 -965
  258. package/workspace/public/pm/c3-calpop.js +0 -111
  259. package/workspace/public/pm/c3-case.js +0 -196
  260. package/workspace/public/pm/c3-core-docs.css +0 -18
  261. package/workspace/public/pm/c3-core-docs.js +0 -236
  262. package/workspace/public/pm/c3-daypart.js +0 -176
  263. package/workspace/public/pm/c3-demo-boards.js +0 -764
  264. package/workspace/public/pm/c3-demo-brief-ix.js +0 -350
  265. package/workspace/public/pm/c3-demo-brief-page.js +0 -70
  266. package/workspace/public/pm/c3-demo-cal-ix.js +0 -74
  267. package/workspace/public/pm/c3-demo-cal2.js +0 -66
  268. package/workspace/public/pm/c3-demo-cal3.js +0 -173
  269. package/workspace/public/pm/c3-demo-cal4.js +0 -169
  270. package/workspace/public/pm/c3-demo-cal5.js +0 -52
  271. package/workspace/public/pm/c3-demo-coredocs.js +0 -221
  272. package/workspace/public/pm/c3-demo-data.js +0 -552
  273. package/workspace/public/pm/c3-demo-focus.js +0 -181
  274. package/workspace/public/pm/c3-demo-init.js +0 -430
  275. package/workspace/public/pm/c3-demo-life.js +0 -77
  276. package/workspace/public/pm/c3-demo-material.js +0 -58
  277. package/workspace/public/pm/c3-demo-misc2.js +0 -34
  278. package/workspace/public/pm/c3-demo-phone.js +0 -48
  279. package/workspace/public/pm/c3-demo-plan2.js +0 -30
  280. package/workspace/public/pm/c3-demo-rd.js +0 -432
  281. package/workspace/public/pm/c3-demo-rep-ix.js +0 -126
  282. package/workspace/public/pm/c3-demo-rep2.js +0 -130
  283. package/workspace/public/pm/c3-demo-rep3.js +0 -138
  284. package/workspace/public/pm/c3-demo-rs.js +0 -287
  285. package/workspace/public/pm/c3-demo-term.js +0 -153
  286. package/workspace/public/pm/c3-demo-time.js +0 -49
  287. package/workspace/public/pm/c3-demo-work-ix.js +0 -32
  288. package/workspace/public/pm/c3-demo.js +0 -131
  289. package/workspace/public/pm/c3-design-studio.js +0 -369
  290. package/workspace/public/pm/c3-doc-formats.js +0 -153
  291. package/workspace/public/pm/c3-doc-sheet.js +0 -1230
  292. package/workspace/public/pm/c3-dock.js +0 -206
  293. package/workspace/public/pm/c3-docs.js +0 -291
  294. package/workspace/public/pm/c3-driver-work.js +0 -110
  295. package/workspace/public/pm/c3-driver.css +0 -18
  296. package/workspace/public/pm/c3-driver.js +0 -298
  297. package/workspace/public/pm/c3-focus.css +0 -304
  298. package/workspace/public/pm/c3-focus.js +0 -983
  299. package/workspace/public/pm/c3-ib-docs.js +0 -92
  300. package/workspace/public/pm/c3-ib-initiatives.js +0 -201
  301. package/workspace/public/pm/c3-ib-items.js +0 -210
  302. package/workspace/public/pm/c3-ib-releases.js +0 -48
  303. package/workspace/public/pm/c3-ib-sprints.js +0 -201
  304. package/workspace/public/pm/c3-ib-triage.js +0 -177
  305. package/workspace/public/pm/c3-ii-tabs.js +0 -252
  306. package/workspace/public/pm/c3-ini-life.css +0 -34
  307. package/workspace/public/pm/c3-ini-life.js +0 -379
  308. package/workspace/public/pm/c3-ini-records.js +0 -197
  309. package/workspace/public/pm/c3-ini-timeline.js +0 -278
  310. package/workspace/public/pm/c3-ini-work.js +0 -139
  311. package/workspace/public/pm/c3-init-extras.js +0 -170
  312. package/workspace/public/pm/c3-initiatives.js +0 -852
  313. package/workspace/public/pm/c3-lifecycle-panels.js +0 -479
  314. package/workspace/public/pm/c3-look.js +0 -27
  315. package/workspace/public/pm/c3-material.css +0 -22
  316. package/workspace/public/pm/c3-material.js +0 -321
  317. package/workspace/public/pm/c3-md.js +0 -3
  318. package/workspace/public/pm/c3-misc-panels.js +0 -89
  319. package/workspace/public/pm/c3-new-session.js +0 -110
  320. package/workspace/public/pm/c3-notes.js +0 -751
  321. package/workspace/public/pm/c3-phone-boot.js +0 -47
  322. package/workspace/public/pm/c3-phone-detail.js +0 -97
  323. package/workspace/public/pm/c3-phone-model.js +0 -3
  324. package/workspace/public/pm/c3-phone.css +0 -66
  325. package/workspace/public/pm/c3-phone.js +0 -444
  326. package/workspace/public/pm/c3-plan-panels.js +0 -163
  327. package/workspace/public/pm/c3-plan.js +0 -193
  328. package/workspace/public/pm/c3-quiet.css +0 -113
  329. package/workspace/public/pm/c3-quiet.js +0 -177
  330. package/workspace/public/pm/c3-replay.css +0 -133
  331. package/workspace/public/pm/c3-replay.js +0 -429
  332. package/workspace/public/pm/c3-report-deck.css +0 -163
  333. package/workspace/public/pm/c3-report-deck.js +0 -598
  334. package/workspace/public/pm/c3-report-frame.css +0 -20
  335. package/workspace/public/pm/c3-report-print.css +0 -20
  336. package/workspace/public/pm/c3-report-setup.css +0 -67
  337. package/workspace/public/pm/c3-report-setup.js +0 -298
  338. package/workspace/public/pm/c3-report-store.js +0 -244
  339. package/workspace/public/pm/c3-report-structure.css +0 -44
  340. package/workspace/public/pm/c3-report-structure.js +0 -473
  341. package/workspace/public/pm/c3-reports.css +0 -68
  342. package/workspace/public/pm/c3-reports.js +0 -377
  343. package/workspace/public/pm/c3-roadmap.js +0 -249
  344. package/workspace/public/pm/c3-scan-api.js +0 -167
  345. package/workspace/public/pm/c3-scan-next.js +0 -248
  346. package/workspace/public/pm/c3-scan-setup.js +0 -313
  347. package/workspace/public/pm/c3-scan-words.js +0 -41
  348. package/workspace/public/pm/c3-scan.css +0 -74
  349. package/workspace/public/pm/c3-scan.js +0 -93
  350. package/workspace/public/pm/c3-session-chat.js +0 -103
  351. package/workspace/public/pm/c3-session-conv.js +0 -165
  352. package/workspace/public/pm/c3-session-term.js +0 -216
  353. package/workspace/public/pm/c3-settings.css +0 -85
  354. package/workspace/public/pm/c3-settings.js +0 -1045
  355. package/workspace/public/pm/c3-shell.js +0 -628
  356. package/workspace/public/pm/c3-signals.js +0 -196
  357. package/workspace/public/pm/c3-strategy-panels.js +0 -45
  358. package/workspace/public/pm/c3-swipe.js +0 -230
  359. package/workspace/public/pm/c3-terminal-data.js +0 -48
  360. package/workspace/public/pm/c3-terminal-edge.js +0 -91
  361. package/workspace/public/pm/c3-terminal-icons.js +0 -40
  362. package/workspace/public/pm/c3-terminal-results.js +0 -141
  363. package/workspace/public/pm/c3-terminal.js +0 -52
  364. package/workspace/public/pm/c3-tickets.js +0 -163
  365. package/workspace/public/pm/c3-timeline.js +0 -201
  366. package/workspace/public/pm/calendar-views.js +0 -1049
  367. package/workspace/public/pm/console3-lift.md +0 -220
  368. package/workspace/public/pm/cozy-home.js +0 -172
  369. package/workspace/public/pm/cozy-initiative.css +0 -138
  370. package/workspace/public/pm/cycle-review.js +0 -125
  371. package/workspace/public/pm/data.js +0 -1577
  372. package/workspace/public/pm/dest-board.js +0 -444
  373. package/workspace/public/pm/dest-docs.js +0 -530
  374. package/workspace/public/pm/dest-initiatives.js +0 -162
  375. package/workspace/public/pm/dest-mywork.js +0 -307
  376. package/workspace/public/pm/dest-notes.js +0 -537
  377. package/workspace/public/pm/dest-people.js +0 -449
  378. package/workspace/public/pm/dest-reports.js +0 -383
  379. package/workspace/public/pm/dest-settings.js +0 -601
  380. package/workspace/public/pm/dest-today.js +0 -267
  381. package/workspace/public/pm/display-word.js +0 -56
  382. package/workspace/public/pm/doc-editor.js +0 -473
  383. package/workspace/public/pm/doc-graph.js +0 -272
  384. package/workspace/public/pm/doc-health-panel.js +0 -110
  385. package/workspace/public/pm/doc-rail.js +0 -167
  386. package/workspace/public/pm/doc-remote.js +0 -180
  387. package/workspace/public/pm/dock-sessions.js +0 -472
  388. package/workspace/public/pm/dock.js +0 -216
  389. package/workspace/public/pm/fixture.js +0 -821
  390. package/workspace/public/pm/flag-picker.js +0 -104
  391. package/workspace/public/pm/frame-copy.js +0 -278
  392. package/workspace/public/pm/freshness-line.js +0 -149
  393. package/workspace/public/pm/handoff-box.js +0 -82
  394. package/workspace/public/pm/initiative-list.js +0 -235
  395. package/workspace/public/pm/initiative-sheet.js +0 -331
  396. package/workspace/public/pm/initiatives-api.js +0 -95
  397. package/workspace/public/pm/initiatives-copy.js +0 -287
  398. package/workspace/public/pm/initiatives-timeline-copy.js +0 -59
  399. package/workspace/public/pm/initiatives-timeline.js +0 -410
  400. package/workspace/public/pm/initiatives-ui.js +0 -291
  401. package/workspace/public/pm/item-sheet.js +0 -268
  402. package/workspace/public/pm/keep-card.js +0 -204
  403. package/workspace/public/pm/lifecycle-lens-model.js +0 -246
  404. package/workspace/public/pm/lifecycle-lens.js +0 -276
  405. package/workspace/public/pm/lifecycle.js +0 -111
  406. package/workspace/public/pm/mobile.css +0 -366
  407. package/workspace/public/pm/mobile.js +0 -581
  408. package/workspace/public/pm/modes-live.js +0 -453
  409. package/workspace/public/pm/modes.js +0 -147
  410. package/workspace/public/pm/my-work-card.js +0 -51
  411. package/workspace/public/pm/my-work-data.js +0 -36
  412. package/workspace/public/pm/new-initiative-sheet.js +0 -169
  413. package/workspace/public/pm/next-step-ui.js +0 -190
  414. package/workspace/public/pm/outbox-panel.js +0 -125
  415. package/workspace/public/pm/palette-copy.js +0 -55
  416. package/workspace/public/pm/palette.js +0 -343
  417. package/workspace/public/pm/panel-breakdown.js +0 -702
  418. package/workspace/public/pm/panel-cockpit.js +0 -425
  419. package/workspace/public/pm/panel-detail.js +0 -1513
  420. package/workspace/public/pm/panel-initiatives.js +0 -929
  421. package/workspace/public/pm/panel-newsess.js +0 -709
  422. package/workspace/public/pm/panel-repos.js +0 -741
  423. package/workspace/public/pm/panel-tabs.js +0 -1506
  424. package/workspace/public/pm/panel-trees.js +0 -204
  425. package/workspace/public/pm/people-link.js +0 -106
  426. package/workspace/public/pm/phone-deck.js +0 -167
  427. package/workspace/public/pm/pm-work-view.js +0 -1533
  428. package/workspace/public/pm/portfolio-report.js +0 -61
  429. package/workspace/public/pm/premium-acts.js +0 -280
  430. package/workspace/public/pm/premium-brief.js +0 -111
  431. package/workspace/public/pm/premium-chat.js +0 -22
  432. package/workspace/public/pm/premium-doc-sheet.js +0 -312
  433. package/workspace/public/pm/premium-initiative.js +0 -324
  434. package/workspace/public/pm/premium-insights.css +0 -228
  435. package/workspace/public/pm/premium-metric-tiles.js +0 -68
  436. package/workspace/public/pm/premium-report-brief.js +0 -132
  437. package/workspace/public/pm/premium-vw-rec.js +0 -67
  438. package/workspace/public/pm/premium-wide.css +0 -30
  439. package/workspace/public/pm/print.css +0 -44
  440. package/workspace/public/pm/provider-cards.js +0 -136
  441. package/workspace/public/pm/registry.js +0 -203
  442. package/workspace/public/pm/release-card.js +0 -110
  443. package/workspace/public/pm/releases-view.js +0 -248
  444. package/workspace/public/pm/report-families-view.js +0 -505
  445. package/workspace/public/pm/report-slides.js +0 -438
  446. package/workspace/public/pm/report-tab.js +0 -33
  447. package/workspace/public/pm/report-view.js +0 -337
  448. package/workspace/public/pm/reports-copy.js +0 -134
  449. package/workspace/public/pm/roadmap.js +0 -294
  450. package/workspace/public/pm/run-card.js +0 -260
  451. package/workspace/public/pm/sessions-panel.js +0 -219
  452. package/workspace/public/pm/sheet-jira.js +0 -353
  453. package/workspace/public/pm/shell-bell.js +0 -163
  454. package/workspace/public/pm/shell-model.js +0 -83
  455. package/workspace/public/pm/shell-phone.js +0 -124
  456. package/workspace/public/pm/shell-readaloud.js +0 -53
  457. package/workspace/public/pm/shell-recording.js +0 -274
  458. package/workspace/public/pm/shell-ticker.js +0 -90
  459. package/workspace/public/pm/sig-watch.js +0 -41
  460. package/workspace/public/pm/slide-confirm.js +0 -163
  461. package/workspace/public/pm/slides-copy.js +0 -52
  462. package/workspace/public/pm/status-banner.js +0 -95
  463. package/workspace/public/pm/tab-doc.js +0 -859
  464. package/workspace/public/pm/tab-gone.js +0 -21
  465. package/workspace/public/pm/tab-term.js +0 -1210
  466. package/workspace/public/pm/tab-web.js +0 -90
  467. package/workspace/public/pm/timeline-copy.js +0 -48
  468. package/workspace/public/pm/timeline-forecast-view.js +0 -164
  469. package/workspace/public/pm/today-agenda.js +0 -331
  470. package/workspace/public/pm/today-cards.js +0 -244
  471. package/workspace/public/pm/today-copy.js +0 -506
  472. package/workspace/public/pm/today-day.js +0 -1371
  473. package/workspace/public/pm/today-goals.js +0 -297
  474. package/workspace/public/pm/today-jobs.js +0 -84
  475. package/workspace/public/pm/today-mentions.js +0 -50
  476. package/workspace/public/pm/topbar.js +0 -202
  477. package/workspace/public/pm/triage-card.js +0 -60
  478. package/workspace/public/pm/undo-hold.js +0 -103
  479. package/workspace/public/pm/view-addrepo.js +0 -208
  480. package/workspace/public/pm/view-files.js +0 -197
  481. package/workspace/public/pm/view-livenotes.js +0 -399
  482. package/workspace/public/pm/view-today.js +0 -13
  483. package/workspace/public/pm/view-validate.js +0 -171
  484. package/workspace/public/pm/welcome.js +0 -391
  485. package/workspace/public/pm/work-place.js +0 -68
  486. package/workspace/public/pm/xlsx-read.js +0 -117
  487. package/workspace/public/welcome.html +0 -22
  488. package/workspace/test-lists/browser-suites-green.json +0 -5
  489. package/workspace/test-lists/c3-core-docs.json +0 -9
  490. package/workspace/test-lists/c3-doc-sheet-rich.json +0 -6
  491. package/workspace/test-lists/c3-doc-sheet-size.json +0 -6
  492. package/workspace/test-lists/c3-doc-sheet-v2.json +0 -6
  493. package/workspace/test-lists/c3-ib-items.json +0 -9
  494. package/workspace/test-lists/c3-ib-more.json +0 -9
  495. package/workspace/test-lists/c3-ib-triage-backlog.json +0 -9
  496. package/workspace/test-lists/c3-ini-life.json +0 -9
  497. package/workspace/test-lists/c3-meeting-board.json +0 -5
  498. package/workspace/test-lists/c3-meeting-card.json +0 -5
  499. package/workspace/test-lists/c3-notes-place.json +0 -5
  500. package/workspace/test-lists/c3-notes-series.json +0 -5
  501. package/workspace/test-lists/calendar-time-page.json +0 -5
  502. package/workspace/test-lists/calpop.json +0 -4
  503. package/workspace/test-lists/console3-briefing.json +0 -9
  504. package/workspace/test-lists/console3-foundation.json +0 -9
  505. package/workspace/test-lists/console3-work-page.json +0 -9
  506. package/workspace/test-lists/premium-brief-parity.json +0 -9
  507. package/workspace/test-lists/report-design-studio-ui.json +0 -5
  508. package/workspace/test-lists/report-structure-ui.json +0 -11
  509. package/workspace/test-lists/report-workspace-ui.json +0 -5
  510. package/workspace/test-lists/run3-a.json +0 -5
  511. package/workspace/test-lists/run3-d.json +0 -6
  512. package/workspace/test-lists/run4-c.json +0 -13
  513. package/workspace/test-lists/today-goals-jobs-ui.json +0 -5
  514. package/workspace/test-lists/today-mentions-cards.json +0 -5
  515. package/workspace/test-lists/workspace-tabs-declutter.json +0 -13
@@ -2,7 +2,8 @@
2
2
  'use strict';
3
3
  /* premium-board-actions-test.js — the board presses of the premium Board and initiative pages (initiative premium-board-actions; planning/prd/premium-board-actions-prd.md A1 to A12).
4
4
  * A real server on a scratch `team` repository (planning/initiatives, pmos/state), never the PMOS checkout. The real pages press the real routes.
5
- * Re-pointed for the Agreed Board (premium-agreed-design): the Board's presses are the plain versions of pm/bd-acts.js in the side panel.
5
+ * Re-pointed for the uncovered-features designs (premium-uncovered-features: BdAsks, BdNew, BdGrill, BdActions): popovers and side panels, each
6
+ * press done at once with Undo, and the first questions of a new initiative (lib/routes-board-grill.js).
6
7
  * T triage (accept, decline) · N New initiative · M move and Undo · L hold, resume, cancel, reopen, archive, restore · I the initiative page's bar
7
8
  * S the PMOS-self board (a model answer, since only the embedded checkout is self) · P the POST allow-list and the refusals · F floors */
8
9
  const fs = require('fs');
@@ -45,7 +46,8 @@ const lines = (name) => {
45
46
  };
46
47
  /** A press on a choice chip inside the dialog's pane, as a click event on the element (Playwright's pointer check races the dialog's spring). */
47
48
  const tap = (pg, sel) => pg.$eval(sel, (b) => b.click());
48
- const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive)|lifecycle|briefing-premium\/note)$/;
49
+ // the Board's first questions (board-grill: start, file, answer, later) write only triage-answers.jsonl and the material folder; intake/draft only drafts
50
+ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive)|lifecycle|briefing-premium\/note|board-grill\/(?:start|file|answer|later)|intake\/draft|initiative-layout)$/; // initiative-layout: the card's Moves on by itself switch (premium-uncovered-features)
49
51
 
50
52
  (async () => {
51
53
  const exe = findBrowser();
@@ -75,98 +77,116 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
75
77
  };
76
78
  const P = await open('/premium-board.html');
77
79
  const p = P.page;
78
- // re-pointed for the Agreed Board (premium-agreed-design): the presses live in plain versions in the side panel (pm/bd-acts.js), tagged
79
- // "Waiting for design"; a row's actions open from the panel's ⋯; the toast is #bdToast with its Undo; the old dialog never opens.
80
+ // re-pointed for the uncovered-features designs (premium-uncovered-features): the asks, the row menu, Find and Filter are popovers (#bdPop,
81
+ // BdAsks, BdActions); New initiative and Cancelled and archived are side panels; the toast is #bdToast with its Undo; the old dialog never opens.
80
82
  const listed = (id) => p.evaluate((x) => [...document.querySelectorAll('#ibBody .ini2')].some((b) => b.dataset.key === 'board:' + x), id);
81
83
  const toastIs = (re) => until(() => p.evaluate((s) => { const t = document.querySelector('#bdToast'); return t && !t.hidden && new RegExp(s).test(t.textContent) ? t.textContent : null; }, re.source));
82
- const peekOn = (title) => until(() => p.evaluate((t) => { const k = document.querySelector('#peek'); return k && !k.hidden && (document.querySelector('#pkTitle') || {}).textContent === t && !!k.querySelector('.bd-wtag'); }, title));
84
+ const peekOn = (title) => until(() => p.evaluate((t) => { const k = document.querySelector('#peek'); return k && !k.hidden && (document.querySelector('#pkTitle') || {}).textContent === t && !k.querySelector('.bd-wtag'); }, title));
85
+ const popOn = (re) => until(() => p.evaluate((s) => { const k = document.querySelector('#bdPop'); return k && !k.hidden && new RegExp(s).test(k.textContent) ? k.textContent : null; }, re.source));
83
86
  const noDlg = () => p.evaluate(() => !document.querySelector('#dlg.on'));
84
- const acts = async (id) => { await until(() => listed(id), 30000); await p.click(`#ibBody .ini2[data-key="board:${id}"]`); await until(() => p.evaluate(() => !!document.querySelector('#peek [data-pk="acts"]'))); await p.click('#peek [data-pk="acts"]'); return peekOn('Initiative actions'); };
87
+ const acts = async (id) => { await until(() => listed(id), 30000); await p.click(`#ibBody .ini2[data-key="board:${id}"]`); await until(() => p.evaluate(() => !!document.querySelector('#peek [data-pk="acts"]'))); await p.click('#peek [data-pk="acts"]'); return until(() => p.evaluate(() => { const m = document.querySelector('#bdPop'); return !!m && !m.hidden && m.getAttribute('role') === 'menu'; })); };
88
+ const closeAll = async () => { for (let i = 0; i < 3; i++) { if (await p.evaluate(() => document.querySelector('#peek').hidden && (!document.querySelector('#bdPop') || document.querySelector('#bdPop').hidden))) return; await p.keyboard.press('Escape'); await sleep(100); } };
85
89
  await until(() => p.evaluate(() => document.querySelectorAll('#ibBody .ini2').length > 0), 30000);
86
90
  await p.click('#chAsks');
87
- ok('A2 the New asks panel lists both asks with Accept and Decline', await until(() => p.evaluate(() => document.querySelectorAll('#peek .bd-ask').length === 2 && document.querySelectorAll('#peek [data-act="accept"]').length === 2)), await p.evaluate(() => (document.querySelector('#peek') || {}).textContent));
88
- ok('A2 an ask shows its source, not an invented name, and the panel is tagged "Waiting for design"', await p.evaluate(() => /Email from Rina/.test(document.querySelector('#peek').textContent) && !/demo/i.test(document.querySelector('#peek').textContent) && !!document.querySelector('#peek .bd-wtag')));
91
+ ok('A2 the New asks popover lists both asks with Accept and Decline (BdAsks)', await until(() => p.evaluate(() => document.querySelectorAll('#bdPop .bd-acard[data-ask]').length === 2 && document.querySelectorAll('#bdPop [data-askact="accept"]').length === 2 && document.querySelectorAll('#bdPop [data-askact="decline"]').length === 2)), await p.evaluate(() => (document.querySelector('#bdPop') || {}).textContent));
92
+ ok('A2 an ask shows its source and the product with the reason, not an invented name, and no "Waiting for design" tag', await p.evaluate(() => { const t = document.querySelector('#bdPop').textContent; return /Email from Rina/.test(t) && /Why: came in through Email from Rina/.test(t) && !/demo/i.test(t) && !document.querySelector('#bdPop .bd-wtag'); }));
89
93
 
90
94
  /* T triage */
91
- await p.click(`#peek [data-act="accept"][data-id="${a1.body.ask.id}"]`); await peekOn('Accept ask');
95
+ await p.click(`#bdPop [data-askact="accept"][data-id="${a1.body.ask.id}"]`); await peekOn('Accept ask');
92
96
  const anc = await until(() => p.evaluate(() => { const s = document.querySelector('#peek select[name="anchor"]'); return s && !s.disabled ? [...s.options].map((o) => o.value) : null; }));
93
- ok('T1 Accept opens the form with the anchors the board declares', !!anc && anc.includes('health:tech'), JSON.stringify(anc));
94
- await p.fill('#peek input[name="title"]', ''); await p.click('#peek form[data-form="new"] [type="submit"]');
95
- ok('T2 an empty title is refused on the page, before any press', await p.evaluate(() => /Give it a title/.test(document.querySelector('#formM').textContent)) && !P.posts.some((x) => x.path === '/api/boards/asks/accept'));
96
- await p.fill('#peek input[name="title"]', 'Daily CSV of failed payouts'); await p.selectOption('#peek select[name="anchor"]', 'health:tech'); await p.click('#peek form[data-form="new"] [type="submit"]');
97
+ ok('T1 Accept of an ask with no goal opens New initiative with the anchors the board declares, and no lane field', !!anc && anc.includes('health:tech') && await p.evaluate(() => !document.querySelector('#peek [name="lane"]')), JSON.stringify(anc));
98
+ await p.fill('#peek input[name="title"]', ''); await p.click('#peek form[data-form="new2"] [type="submit"]');
99
+ ok('T2 an empty name is refused on the page, before any press', await p.evaluate(() => /Give it a name/.test(document.querySelector('#formM').textContent)) && !P.posts.some((x) => x.path === '/api/boards/asks/accept'));
100
+ await p.fill('#peek input[name="title"]', 'Daily CSV of failed payouts'); await p.selectOption('#peek select[name="anchor"]', 'health:tech');
101
+ await p.click('#peek [data-newact="link"]'); await p.fill('#nwLink input', 'https://slack.example.com/archives/finance'); await p.click('#peek [data-newact="addlink"]');
102
+ ok('T2 a pasted link shows as material', await p.evaluate(() => /slack\.example\.com/.test(document.querySelector('#nwMat').textContent)));
103
+ await p.click('#peek form[data-form="new2"] [type="submit"]');
97
104
  ok('T3 Accept records the accept line and a new initiative, and says so', !!(await toastIs(/accepted in/)) && lines('boards.jsonl').some((l) => l.kind === 'ask-accept' && l.ask === a1.body.ask.id), JSON.stringify(lines('boards.jsonl').map((l) => l.kind)));
105
+ const g0 = await until(() => lines('triage-answers.jsonl').find((l) => l.kind === 'start'));
106
+ ok('T3 the Why and the link start its first questions (BdGrill): one start line, and the questions open in the same panel', !!g0 && /Finance wants a CSV/.test(g0.why) && g0.links.length === 1 && !!(await until(() => p.evaluate(() => !!document.querySelector('#peek .bd-qc.on') && /questions? before the BRD/.test(document.querySelector('#peek').textContent)))), JSON.stringify(g0));
107
+ await p.click('#peek .bd-qc.on [data-qchip]'); await p.click('#peek [data-grill="next"]');
108
+ ok('T3 an answer is kept per question', await until(() => lines('triage-answers.jsonl').some((l) => l.kind === 'answer' && l.answer)));
109
+ await p.click('#peek [data-grill="later"]');
110
+ ok('T3 Later keeps the open questions as the next step', await until(() => lines('triage-answers.jsonl').some((l) => l.kind === 'later')) && !!(await toastIs(/Kept as the next step/)));
98
111
  await until(() => p.evaluate(() => document.querySelector('#chAsks') && /\b1\b/.test(document.querySelector('#chAsks').textContent)), 30000);
99
112
  await p.click('#chAsks');
100
- ok('T4 the accepted ask leaves the panel', await until(() => p.evaluate((id) => !document.querySelector(`#peek [data-act="accept"][data-id="${id}"]`) && document.querySelectorAll('#peek .bd-ask').length === 1, a1.body.ask.id)));
101
- await p.click(`#peek [data-act="decline"][data-id="${a2.body.ask.id}"]`); await peekOn('Decline ask');
102
- await p.click('#peek form[data-form="decline"] [type="submit"]');
103
- ok('T5 Decline waits for a reason', await p.evaluate(() => document.querySelector('#peek textarea[name="why"]').validity.valueMissing) && !P.posts.some((x) => x.path === '/api/boards/asks/decline'));
104
- await p.fill('#peek textarea[name="why"]', 'Not tied to a goal this quarter'); await p.click('#peek form[data-form="decline"] [type="submit"]');
105
- ok('T6 Decline records the reason in the board ledger', !!(await toastIs(/Ask declined/)) && lines('boards.jsonl').some((l) => l.kind === 'ask-decline' && l.why === 'Not tied to a goal this quarter'));
113
+ ok('T4 the accepted ask leaves the popover', await until(() => p.evaluate((id) => !document.querySelector(`#bdPop [data-askact="accept"][data-id="${id}"]`) && document.querySelectorAll('#bdPop .bd-acard[data-ask]').length === 1, a1.body.ask.id)));
114
+ await p.click(`#bdPop [data-askact="decline"][data-id="${a2.body.ask.id}"]`);
115
+ ok('T5 Decline asks why not, with the chips', !!(await popOn(/Why not.*Out of scope.*Already planned.*Not now.*Other/)) && !P.posts.some((x) => x.path === '/api/boards/asks/decline'));
116
+ await p.click('#bdPop [data-whynot="Not now"]'); await p.fill('#bdPop input[name="why"]', 'Not tied to a goal this quarter'); await p.click('#bdPop [data-askact="decline-go"]');
117
+ ok('T6 Decline records the reason in the board ledger', !!(await toastIs(/Ask declined/)) && lines('boards.jsonl').some((l) => l.kind === 'ask-decline' && l.why === 'Not now: Not tied to a goal this quarter'), JSON.stringify(lines('boards.jsonl').filter((l) => l.kind === 'ask-decline')));
106
118
  await until(() => p.evaluate(() => /^No new asks|0 new asks/.test((document.querySelector('#chAsks') || {}).textContent.trim())), 30000);
107
119
  await p.click('#chAsks');
108
- ok('T7 the panel says nothing is left to triage', await until(() => p.evaluate(() => /No new ask waits for triage/.test(document.querySelector('#peek').textContent))));
109
- await p.keyboard.press('Escape');
120
+ ok('T7 the popover says nothing is left to triage', !!(await popOn(/No new ask waits for triage/)));
121
+ await closeAll();
110
122
 
111
123
  /* N New initiative */
112
124
  ok('N1 New initiative is offered on a team board', await p.evaluate(() => !document.querySelector('#newIni').hidden));
113
125
  await p.click('#newIni'); await peekOn('New initiative');
114
126
  await until(() => p.evaluate(() => { const s = document.querySelector('#peek select[name="anchor"]'); return s && !s.disabled; }));
115
- await p.fill('#peek input[name="title"]', 'Partner usage per key'); await p.click('#peek form[data-form="new"] [type="submit"]');
116
- ok('N2 an unanchored create is refused on the page', await p.evaluate(() => /Choose an anchor/.test(document.querySelector('#formM').textContent)));
117
- await p.selectOption('#peek select[name="anchor"]', 'health:tech'); await p.click('#peek form[data-form="new"] [type="submit"]');
127
+ await p.fill('#peek input[name="title"]', 'Partner usage per key'); await p.click('#peek form[data-form="new2"] [type="submit"]');
128
+ ok('N2 an unanchored create is refused on the page', await p.evaluate(() => /Choose what it counts toward/.test(document.querySelector('#formM').textContent)));
129
+ await p.selectOption('#peek select[name="anchor"]', 'health:tech'); await p.click('#peek form[data-form="new2"] [type="submit"]');
118
130
  const made = await toastIs(/created in/);
119
131
  const recs = fs.readdirSync(path.join(team, 'planning', 'initiatives'));
120
132
  ok('N3 Create writes an ask, its accept and a new initiative record, as the console does', !!made && recs.some((f) => /partner-usage/.test(f)) && lines('boards.jsonl').some((l) => l.kind === 'ask' && l.line === 'Partner usage per key'), made + ' / ' + recs.join());
133
+ await until(() => p.evaluate(() => !!document.querySelector('#peek .bd-qc')));
134
+ await closeAll();
121
135
 
122
- /* M move and Undo, from the panel's ⋯ */
123
- ok('M1 the initiative actions offer the next stage, hold, cancel and archive', await acts('pa-one') && await p.evaluate(() => { const L = [...document.querySelectorAll('#peek .bd-ai b')].map((b) => b.textContent); return /^Move to /.test(L[0]) && L.includes('Put on hold') && L.includes('Cancel') && L.includes('Archive'); }), await p.evaluate(() => document.querySelector('#peek').textContent));
136
+ /* M move and Undo, from the panel's ⋯ (BdActions) */
137
+ ok('M1 the row menu offers the next stage with how much is ready, hold, cancel and archive', await acts('pa-one') && await p.evaluate(() => { const L = [...document.querySelectorAll('#bdPop [data-rowact] span:first-of-type')].map((b) => b.textContent); return /^Move to /.test(L[0]) && L.includes('Hold') && L.includes('Cancel') && L.includes('Archive'); }), await p.evaluate(() => document.querySelector('#bdPop').textContent));
138
+ await p.keyboard.press('Escape');
139
+ ok('M2 Escape closes the menu and gives the focus back to the ⋯ button', await until(() => p.evaluate(() => document.querySelector('#bdPop').hidden && document.activeElement.dataset.pk === 'acts')));
124
140
  await p.keyboard.press('Escape');
125
- ok('M2 Escape closes the actions and gives the focus back to the row', await until(() => p.evaluate(() => document.querySelector('#peek').hidden && !!document.activeElement.closest('#ibBody'))));
141
+ ok('M2 a second Escape closes the panel and gives the focus back to the row', await until(() => p.evaluate(() => document.querySelector('#peek').hidden && !!document.activeElement.closest('#ibBody'))));
126
142
  const from = ready.model.initiatives.list.rows.find((r) => r.id === 'pa-one').acts.stage;
127
- await acts('pa-one'); await p.click('#peek .bd-ai[data-k^="mv:"]');
143
+ await acts('pa-one'); await p.click('#bdPop [data-rowact^="mv:"]');
128
144
  const mv = await toastIs(/^Moved to/);
129
145
  ok('M3 Move records one move line and says what it recorded', !!mv && lines('boards.jsonl').filter((l) => l.kind === 'move' && l.id === 'pa-one').length === 1, mv);
130
146
  await p.click('#bdToast .bd-undo');
131
147
  ok('M4 Undo writes the move back', !!(await toastIs(new RegExp('Back in ' + from))) && lines('boards.jsonl').filter((l) => l.kind === 'move' && l.id === 'pa-one').pop().to === from);
148
+ await closeAll();
132
149
 
133
- /* L hold, resume, cancel, reopen, archive, restore */
134
- await acts('pa-one'); await p.click('#peek .bd-ai[data-k="hold"]'); await peekOn('Put on hold');
135
- await p.fill('#peek textarea[name="why"]', 'Waiting for the Q1 budget'); await p.check('#peek input[name="back"][value="two"]'); await p.click('#peek form[data-form="hold"] [type="submit"]');
150
+ /* L hold, resume, cancel, reopen, archive, restore: each at once, with Undo */
151
+ await acts('pa-one'); await p.click('#bdPop [data-rowact="hold"]');
136
152
  const hl = await until(() => lines('lifecycle.jsonl').find((l) => l.initiative_id === 'pa-one' && l.state === 'on-hold'));
137
- ok('L1 Put on hold records one on-hold line with the reason and a check-back day', !!hl && hl.reason === 'Waiting for the Q1 budget' && /^\d{4}-\d{2}-\d{2}$/.test(hl.back || ''), JSON.stringify(hl) + ' ' + await p.evaluate(() => (document.querySelector('#formM') || {}).textContent));
153
+ ok('L1 Hold records one on-hold line at once, with a check-back day 30 days on, and Undo', !!hl && /^\d{4}-\d{2}-\d{2}$/.test(hl.back || '') && Math.round((Date.parse(hl.back) - Date.now()) / 86400000) >= 29 && !!(await toastIs(/On hold · .* check back/)), JSON.stringify(hl));
154
+ await closeAll();
138
155
  ok('L2 the row then says On hold', await until(async () => { const t = await p.evaluate(() => { const b = document.querySelector('#ibBody .ini2[data-key="board:pa-one"]'); return b ? b.textContent : ''; }); return /On hold/.test(t); }, 30000));
139
156
  await acts('pa-one');
140
- ok('L2 Resume is offered and the moves are not', await p.evaluate(() => !!document.querySelector('#peek .bd-ai[data-k="resume"]') && !document.querySelector('#peek .bd-ai[data-k^="mv:"]')));
141
- await p.click('#peek .bd-ai[data-k="resume"]');
157
+ ok('L2 Resume is offered and the moves are not', await p.evaluate(() => !!document.querySelector('#bdPop [data-rowact="resume"]') && !document.querySelector('#bdPop [data-rowact^="mv:"]')));
158
+ await p.click('#bdPop [data-rowact="resume"]');
142
159
  ok('L3 Resume records an active line', await until(() => { const L = lines('lifecycle.jsonl').filter((l) => l.initiative_id === 'pa-one'); return L.length && L[L.length - 1].state === 'active'; }));
160
+ await closeAll();
143
161
  await until(() => p.evaluate(() => { const b = document.querySelector('#ibBody .ini2[data-key="board:pa-one"]'); return b && !/On hold/.test(b.textContent); }), 30000);
144
- await acts('pa-one'); await p.click('#peek .bd-ai[data-k="cancel"]'); await peekOn('Cancel the initiative');
145
- await p.click('#peek form[data-form="cancel"] [type="submit"]');
146
- ok('L4 Cancel waits for a reason', await p.evaluate(() => /Pick a reason/.test(document.querySelector('#formM').textContent)) && !lines('lifecycle.jsonl').some((l) => l.initiative_id === 'pa-one' && l.state === 'cancelled'));
147
- await p.check('#peek input[name="why"][value="Not worth it now"]'); await p.click('#peek form[data-form="cancel"] [type="submit"]');
148
- ok('L4 Cancel records a cancelled line with the reason', await until(() => lines('lifecycle.jsonl').some((l) => l.initiative_id === 'pa-one' && l.state === 'cancelled' && l.reason === 'Not worth it now')));
149
- // re-pointed for the Agreed design: the track's footer carries only the fold and the sort (AgBoard), so the count moved to the ⋯ menu's item
162
+ await acts('pa-one'); await p.click('#bdPop [data-rowact="cancel"]');
163
+ ok('L4 Cancel asks why, with the same chips as Decline, and records nothing yet', !!(await popOn(/Why cancel .*Out of scope.*Already planned.*Not now.*Other/)) && !lines('lifecycle.jsonl').some((l) => l.initiative_id === 'pa-one' && l.state === 'cancelled'));
164
+ await p.click('#bdPop [data-why="Not now"]'); await p.click('#bdPop [data-rowact="cancel-go"]');
165
+ ok('L4 Cancel records a cancelled line with the reason', await until(() => lines('lifecycle.jsonl').some((l) => l.initiative_id === 'pa-one' && l.state === 'cancelled' && l.reason === 'Not now')));
150
166
  ok('L5 the row leaves the track and the ⋯ menu\'s Cancelled and archived item counts it', await until(() => p.evaluate(() => !document.querySelector('#ibBody .bt-l[data-row="board:pa-one"]') && /1 cancelled/.test((document.querySelector('#bdGone') || {}).textContent || '')), 30000));
167
+ await closeAll();
151
168
  await p.click('#moreBtn'); await p.click('#bdGone'); await peekOn('Cancelled and archived');
152
- ok('L6 a cancelled initiative offers Reopen only', await p.evaluate(() => [...document.querySelectorAll('#peek .bd-ar [data-act]')].map((b) => b.dataset.act).join() === 'reopen'));
153
- await p.click('#peek [data-act="reopen"]');
169
+ ok('L6 a cancelled initiative offers Reopen only', await p.evaluate(() => [...document.querySelectorAll('#peek .bd-gr [data-rowact]')].map((b) => b.dataset.rowact).join() === 'reopen'));
170
+ await p.click('#peek .bd-gr [data-rowact="reopen"]');
154
171
  ok('L6 Reopen records an active line', await until(() => { const L = lines('lifecycle.jsonl').filter((l) => l.initiative_id === 'pa-one'); return L[L.length - 1].state === 'active'; }));
172
+ await closeAll();
155
173
  await until(() => listed('pa-one'), 30000);
156
- await acts('pa-one'); await p.click('#peek .bd-ai[data-k="archive"]'); await peekOn('Archive the initiative');
157
- await p.check('#peek input[name="why"][value="Duplicate"]'); await p.fill('#peek textarea[name="note"]', 'Same as the CSV export'); await p.click('#peek form[data-form="archive"] [type="submit"]');
158
- ok('L7 Archive records one archive line with the reason', await until(() => lines('boards.jsonl').some((l) => l.kind === 'ini-archive' && l.id === 'pa-one' && l.archived === true && l.reason === 'Duplicate: Same as the CSV export')));
174
+ await acts('pa-one'); await p.click('#bdPop [data-rowact="archive"]');
175
+ ok('L7 Archive records one archive line at once, with no reason asked', await until(() => lines('boards.jsonl').some((l) => l.kind === 'ini-archive' && l.id === 'pa-one' && l.archived === true)));
159
176
  ok('L8 the ⋯ menu\'s item counts it as archived', await until(() => p.evaluate(() => /1 archived/.test((document.querySelector('#bdGone') || {}).textContent || '')), 30000));
160
177
  await p.click('#bdToast .bd-undo');
161
178
  ok('L9 Undo restores it with a restore line', await until(() => lines('boards.jsonl').some((l) => l.kind === 'ini-archive' && l.id === 'pa-one' && l.archived === false)));
162
179
  ok('L10 none of the presses opened the old dialog', await noDlg());
163
180
 
164
- /* I the Board's expand link: the initiative is a layout inside Home (premium-agreed-design). Its stage moves and lifecycle presses are in the Overview */
181
+ /* I the Board's expand link: the initiative is a layout inside Home (premium-agreed-design). Its stage moves and lifecycle presses are in the Overview's
182
+ Stage view; the card moves a stage with Move and Back (premium-uncovered-features, canvas InStage) */
165
183
  const I = await open('/premium-initiative.html?id=pa-one&ws=' + encodeURIComponent(B.ws) + '&board=' + encodeURIComponent(B.id));
166
184
  const ip = I.page;
167
185
  const landed = await until(() => ip.evaluate(() => { const q = new URLSearchParams(location.search); return location.pathname === '/premium.html' && q.get('ini') === 'pa-one' && !!q.get('ws') && !!q.get('board') && !!document.querySelector('.hm-card [data-hm-ov]'); }), 60000);
168
186
  ok('I0 the expand link lands on Home with the initiative selected, ws and board kept', !!landed, await ip.evaluate(() => location.href));
169
187
  await ip.click('.hm-card [data-hm-ov]');
188
+ await until(() => ip.evaluate(() => !!document.querySelector('#czViewer [data-hi-view="stage"]')), 60000);
189
+ await ip.click('#czViewer [data-hi-view="stage"]');
170
190
  const bar = await until(() => ip.evaluate(() => { const v = document.querySelector('#czViewer:not([hidden])'); if (!v || !v.querySelector('[data-ov-move]')) return null; const cur = v.querySelector('[data-ov-move][aria-pressed="true"]'); return { moves: [...v.querySelectorAll('[data-ov-move]')].map((x) => x.dataset.ovMove), cur: cur ? cur.dataset.ovMove : '', life: [...v.querySelectorAll('[data-ov-life]')].map((x) => x.dataset.ovLife) }; }), 60000);
171
191
  ok('I1 the Overview offers the stages, the current one pressed, and the lifecycle presses', !!bar && bar.moves.length > 1 && !!bar.cur && bar.moves.indexOf(bar.cur) < bar.moves.length - 1 && bar.life.join() === 'on-hold,cancelled', JSON.stringify(bar) + ' ' + (await ip.evaluate(() => (document.querySelector('#czViewer .cz-vw-body') || {}).innerText || 'no Viewer')).slice(0, 400));
172
192
  const n0 = lines('boards.jsonl').filter((l) => l.kind === 'move').length;
@@ -180,6 +200,22 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
180
200
  await ip.click('#czViewer [data-ov-life-no]');
181
201
  ok('I3 Not now takes the question back', await until(() => ip.evaluate(() => !document.querySelector('#czViewer #ovWhy') && !!document.querySelector('#czViewer [data-ov-life="on-hold"]'))));
182
202
  await ip.keyboard.press('Escape');
203
+ // the card: Back always asks for a reason, and the move line carries it (InStage)
204
+ const back = await until(() => ip.evaluate(() => !!document.querySelector('.hm-card [data-hi-back]')), 30000);
205
+ ok('I4 the card has Move to the next stage and Back', back && await ip.evaluate(() => /^Move to /.test((document.querySelector('.hm-card [data-hi-move]') || {}).textContent || '')));
206
+ if (back) {
207
+ const m0 = lines('boards.jsonl').filter((l) => l.kind === 'move').length;
208
+ await ip.click('.hm-card [data-hi-back]');
209
+ const asked = await until(() => ip.evaluate(() => { const d = document.querySelector('.hi-pop[role="dialog"]'); return d ? { go: d.querySelector('[data-hi-go]').disabled, chips: d.querySelectorAll('[data-hi-why]').length } : null; }));
210
+ ok('I4 Back asks why first: Move back waits for a reason and records nothing yet', !!asked && asked.go === true && asked.chips === 4 && lines('boards.jsonl').filter((l) => l.kind === 'move').length === m0, JSON.stringify(asked));
211
+ await ip.click('.hi-pop [data-hi-why="New research"]'); await ip.fill('.hi-pop #hiWhy', 'Interviews changed the scope');
212
+ await ip.click('.hi-pop [data-hi-go]');
213
+ ok('I4 Move back records one move line with the reason as its why', await until(() => { const L = lines('boards.jsonl').filter((l) => l.kind === 'move'); const x = L[L.length - 1]; return L.length === m0 + 1 && x.id === 'pa-one' && x.to === bar.cur && x.why === 'Back: New research. Interviews changed the scope'; }), JSON.stringify(lines('boards.jsonl').filter((l) => l.kind === 'move').slice(-1)));
214
+ ok('I4 the Undo toast shows after the move', await until(() => ip.evaluate(() => { const t = document.querySelector('#hiToast'); return !!t && !t.hidden && /moved to/.test(t.textContent) && !!t.querySelector('[data-hi-undo]'); })));
215
+ await until(() => ip.evaluate(() => !!document.querySelector('.hm-card [data-hi-auto]')), 30000);
216
+ await ip.click('.hm-card [data-hi-auto]');
217
+ ok('I5 the Moves on by itself switch is a file-mode record of the initiative', await until(() => lines('initiative-layout.jsonl').some((l) => l.kind === 'auto' && l.initiative === 'pa-one' && l.on === false)) && await until(() => ip.evaluate(() => (document.querySelector('.hm-card [data-hi-auto]') || {}).getAttribute && document.querySelector('.hm-card [data-hi-auto]').getAttribute('aria-checked') === 'false')));
218
+ }
183
219
 
184
220
  /* S the PMOS-self board: the model says self, the page offers no move and no New initiative */
185
221
  {
@@ -189,17 +225,17 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
189
225
  await S.page.reload();
190
226
  await until(() => S.page.evaluate(() => document.querySelectorAll('#ibBody .ini2').length > 0));
191
227
  await S.page.click('#chAsks');
192
- ok('S1 the PMOS-self board names the router in its asks panel and hides New initiative', await until(() => S.page.evaluate(() => /pmos-router/.test(document.querySelector('#peek').textContent) && document.querySelector('#newIni').hidden)));
228
+ ok('S1 the PMOS-self board names the router in its asks popover and hides New initiative', await until(() => S.page.evaluate(() => /pmos-router/.test((document.querySelector('#bdPop') || {}).textContent || '') && document.querySelector('#newIni').hidden)));
193
229
  await S.page.keyboard.press('Escape');
194
230
  await S.page.click('#ibBody .ini2'); await until(() => S.page.evaluate(() => !!document.querySelector('#peek [data-pk="acts"]'))); await S.page.click('#peek [data-pk="acts"]');
195
- ok('S2 its actions have no move', await until(() => S.page.evaluate(() => { const x = document.querySelector('#peek .bd-alist'); return x && !x.querySelector('[data-k^="mv:"]') && !!x.querySelector('[data-k="hold"]'); })));
231
+ ok('S2 its actions have no move', await until(() => S.page.evaluate(() => { const x = document.querySelector('#bdPop'); return x && !x.hidden && !x.querySelector('[data-rowact^="mv:"]') && !!x.querySelector('[data-rowact="hold"]'); })));
196
232
  await S.ctx.close();
197
233
  }
198
234
 
199
235
  /* P the POST allow-list and the refusals */
200
236
  const all = P.posts.concat(I.posts);
201
237
  const other = all.filter((x) => !ALLOWED.test(x.path) && x.path !== '/api/briefing-premium/seen'); // an opened popup's record (popup context slice 11, R1) is not a press
202
- ok('P1 the pages post only to the asks, move, lifecycle and archive routes', all.length > 10 && !other.length, JSON.stringify(other));
238
+ ok('P1 the pages post only to the asks, move, lifecycle, archive and initiative-layout routes', all.length > 10 && !other.length, JSON.stringify(other));
203
239
  const noNonce = await post('/api/boards/move', { id: 'fx-bare', to: ready.model.board.stages[1] }, { 'Content-Type': 'application/json', Origin: BASE });
204
240
  const lifeNo = await post('/api/lifecycle', { initiative_id: 'fx-bare', state: 'on-hold' }, { 'Content-Type': 'application/json', Origin: BASE });
205
241
  ok('P2 a press without the launch nonce is refused', noNonce.status === 403 && lifeNo.status === 403, JSON.stringify([noNonce.status, lifeNo.status]));
@@ -212,7 +248,7 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
212
248
  const f = await S.page.evaluate(() => ({ wide: document.documentElement.scrollWidth > innerWidth + 1, small: [...document.querySelectorAll('#ibBody .ini2, #chAsks, #newIni')].filter((b) => b.offsetParent && (b.getBoundingClientRect().width < 44 || b.getBoundingClientRect().height < 44)).map((b) => b.className + ':' + Math.round(b.getBoundingClientRect().width) + 'x' + Math.round(b.getBoundingClientRect().height)) }));
213
249
  ok('F1 at 390 px there is no sideways scroll and every new control is at least 44 px', !f.wide && !f.small.length, JSON.stringify(f));
214
250
  await S.page.click('#ibBody .ini2'); await until(() => S.page.evaluate(() => !!document.querySelector('#peek [data-pk="acts"]'))); await S.page.click('#peek [data-pk="acts"]');
215
- const mi = await until(() => S.page.evaluate(() => { const L = [...document.querySelectorAll('#peek .bd-ai')]; return L.length ? L.every((b) => b.getBoundingClientRect().height >= 44) && document.documentElement.scrollWidth <= innerWidth + 1 : null; }));
251
+ const mi = await until(() => S.page.evaluate(() => { const L = [...document.querySelectorAll('#bdPop.sheet:not([hidden]) .bd-mi')]; return L.length ? L.every((b) => b.getBoundingClientRect().height >= 44) && document.documentElement.scrollWidth <= innerWidth + 1 : null; }));
216
252
  ok('F2 the action rows are 44 px tall and the open sheet adds no sideways scroll', !!mi);
217
253
  await S.ctx.close();
218
254
  }
@@ -1,8 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  'use strict';
3
3
  /* premium-briefing-depth-test.js — Around you (initiative premium-briefing-depth; planning/prd/premium-briefing-depth-prd.md R1 to R9).
4
- * Re-pointed by premium-agreed-design: the Briefing card and its dialogs are gone; Around you is Home's minimal card in the Viewer
5
- * (home-around.js, "Waiting for design"), opened from the place menu's More. Each row opens its own view in the same card, with Back.
4
+ * Re-pointed by premium-agreed-design: the Briefing card and its dialogs are gone. Re-pointed again by premium-uncovered-features (canvas
5
+ * HmAround): Around you is gone too. New for you (cozy-news.js, from the place menu) holds the mentions, the digests and the prep line, and
6
+ * its "Where the rest went" rows open the old views (home-around.js), each with Back to New for you. Data freshness is Sources (cozy-sources.js).
7
+ * The row summaries of the old card are gone with it; each view's own line (.ar-say) carries the count.
6
8
  * A real server on a scratch repository (c3-scan-fixture.js: PMOS_DRIVER=off, so no agent
7
9
  * ever runs), with a driver ledger, a scan ledger and a brief of today that this suite seeds with the writers the product uses. The real page
8
10
  * presses the real routes. Only two presses are answered in the browser, because they start an agent: scan/now and sources/refresh. The
@@ -92,37 +94,35 @@ const GANTT = [
92
94
  await p.route('**/api/scan/now', (r) => json(r, { ok: true, scan: 'scan-00000000ff' }));
93
95
  await p.route('**/api/sources/refresh', (r) => json(r, { ok: true, started: 'session' }));
94
96
  await p.route('**/api/sources/refresh-all', (r) => json(r, { ok: true, joined: false, started: ['calendar'], already: [], failed: [], all: { started_at: new Date().toISOString(), reads: ['calendar'], derived: ['brief'], phase: 'read', done: false, steps: [{ id: 'calendar', label: 'Calendar', step: 'read', state: 'running' }, { id: 'brief', label: 'Morning briefing', step: 'derived', state: 'waiting' }] } }));
95
- /* Around you: the place menu's More, then Around you; the card reads its six sources */
97
+ /* New for you: the place menu, then New for you; it reads what is new and names where the rest went */
98
+ const REST = ['pulse', 'rep', 'prop', 'scan'];
96
99
  const openCard = async () => {
97
- await until(() => p.$('#czFab')); await p.click('#czFab'); await p.click('[data-cz-more]');
98
- await p.click('#hmMenu [role="menuitem"]:has-text("Around you")');
99
- await until(() => p.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) #aroundBody')));
100
- await until(() => p.evaluate(() => document.querySelector('#aroundCap') && document.querySelector('#aroundCap').textContent !== 'Reading' && !/Reading…/.test(document.querySelector('#aroundBody').textContent)), 30000);
100
+ await until(() => p.$('#czFab')); await p.click('#czFab'); await p.click('#czMenu [data-cz-news]');
101
+ await until(() => p.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) .ev-news [data-ev-rest]') && !document.querySelector('#czViewer .ev-news .ev-skelrow')), 30000);
101
102
  };
102
103
  await p.goto(`${F.BASE}/premium.html?ws=${encodeURIComponent(ws)}`);
103
104
  await until(() => p.evaluate(() => document.querySelectorAll('#hmList .hm-g').length > 0), 30000);
104
105
  posts.length = 0; // Home's own writes on load (its chat marks a conversation seen) are not Around you's; R8 counts from the card's opening
105
106
  await openCard();
106
- const rows = () => p.evaluate(() => Object.fromEntries([...document.querySelectorAll('#czViewer #aroundBody [data-bd]')].map((b) => [b.dataset.bd, { t: b.querySelector('.wtit').textContent, s: (b.querySelector('.ws') || {}).textContent || '', m: (b.querySelector('.wm') || {}).textContent || '' }])));
107
+ const say = () => p.evaluate(() => (document.querySelector('#czViewer .ar-say') || {}).textContent || '');
107
108
  const body = () => p.evaluate(() => (document.querySelector('#czViewer .cz-vw-body .bd-a') || {}).textContent || '');
108
- const open = async (k) => { await p.click(`#czViewer #aroundBody [data-bd="${k}"]`); await until(() => p.evaluate((x) => !!document.querySelector(`#czViewer .bd-a[data-bd-view="${x}"] *`), k)); };
109
- const close = async () => { await p.click('#czViewer [data-bda="back"]'); await until(() => p.evaluate(() => !!document.querySelector('#czViewer #aroundBody'))); };
109
+ // a view opens from its "Where the rest went" row when New for you names it; mentions are New for you's own rows, so their full view opens directly
110
+ const open = async (k) => {
111
+ const sel = `#czViewer .ev-news [data-ev-rest="${k}"]`; // p.click finds the row again if New for you redraws it between the look and the press
112
+ if (REST.includes(k) && await p.$(sel)) await p.click(sel); else await p.evaluate((x) => import('/pm/home-around.js').then((M) => M.openAround(x)), k);
113
+ await until(() => p.evaluate((x) => !!document.querySelector(`#czViewer .bd-a[data-bd-view="${x}"] *`), k));
114
+ };
115
+ const close = async () => { await p.click('#czViewer [data-bda="back"]'); await until(() => p.evaluate(() => !!document.querySelector('#czViewer .ev-news [data-ev-rest]'))); };
110
116
  const click = async (sel) => { await until(() => p.$(sel)); await p.click(sel); };
111
117
  const shotDir = process.env.BRIEFING_DEPTH_SHOTS;
112
118
  const shot = async (n) => { if (shotDir) { await sleep(700); fs.mkdirSync(shotDir, { recursive: true }); await p.screenshot({ path: path.join(shotDir, n + '.png') }); } };
113
119
 
114
- /* R: the card */
115
- const R0 = await rows();
116
- ok('R1 the card has six rows in the PRD order', Object.keys(R0).join() === 'prop,men,pulse,scan,rep,src', Object.keys(R0).join());
117
- ok('R2 agent proposals counts the three open proposals', /^3 agent proposals wait on you/.test(R0.prop.t) && R0.prop.m === '3', JSON.stringify(R0.prop));
118
- ok('R3 mentions names who waits, from the brief, and leaves out nothing it was not told', R0.men.t === 'Dana in Slack and Priya in Jira are waiting on your reply. 1 more is for your information.' && R0.men.m === 'Reply', JSON.stringify(R0.men));
119
- ok('R4 the pulse counts what the Calendar said', R0.pulse.t === 'Portfolio pulse: 1 late, 1 at risk' && /1 on plan · 3 with no plan date/.test(R0.pulse.s), JSON.stringify(R0.pulse));
120
- ok('R5 the scan row counts the waiting proposals', /^Horizon scan: \d+ proposals? waits? for you|^Horizon scan: \d+ proposals wait for you/.test(R0.scan.t) && /^\d+$/.test(R0.scan.m), JSON.stringify(R0.scan));
121
- ok('R6 the freshness row says it is not live', /not live/.test(R0.src.s) && !/up to date/i.test(R0.src.t + R0.src.s), JSON.stringify(R0.src));
122
- const cap = await p.evaluate(() => document.querySelector('#aroundCap').textContent);
123
- ok('R7 the caption counts the rows that wait', /^\d+ to look at$/.test(cap), cap);
124
- ok('R8 opening Around you wrote nothing', posts.length === 0, JSON.stringify(posts));
125
- ok('R9 Around you is marked Waiting for design', /Waiting for design/.test(await p.textContent('#czViewer')));
120
+ /* R: New for you, in place of the card */
121
+ const R0 = await p.evaluate(() => ({ rest: [...document.querySelectorAll('#czViewer .ev-news [data-ev-rest]')].map((b) => b.dataset.evRest), list: !!document.querySelector('#aroundBody, #aroundCap'), text: document.querySelector('#czViewer').textContent }));
122
+ ok('R1 New for you names where the rest of Around you went, one row each, and draws no Around you list', R0.rest.join() === REST.join() && !R0.list, JSON.stringify(R0.rest));
123
+ ok('R3 the mentions that wait are New for you\'s own rows', /Dana/.test(R0.text) && /Mentions/.test(R0.text), R0.text.slice(0, 300));
124
+ ok('R8 opening New for you wrote nothing', posts.length === 0, JSON.stringify(posts));
125
+ ok('R9 New for you is drawn to its design: no Waiting for design marker', !/Waiting for design/.test(R0.text));
126
126
  await shot('card-1280-light');
127
127
 
128
128
  /* A: agent proposals */
@@ -165,8 +165,9 @@ const GANTT = [
165
165
  const open1 = (await (await fetch(`${F.BASE}/api/driver/open?target_kind=initiative&ws=${ws}`)).json()).targets || {};
166
166
  ok('A9 the ledger no longer lists the three as open', !Object.values(open1).flat().some((x) => [P1, P2, P3].includes(x.id)), JSON.stringify(open1));
167
167
  await close();
168
- await until(() => rows().then((r) => /^No agent proposals wait/.test(r.prop.t)));
169
- ok('A10 the row now says no agent proposals wait', true);
168
+ await open('prop');
169
+ ok('A10 the view now says no proposal waits', await until(() => say().then((t) => /^No proposal waits for you/.test(t))), await say());
170
+ await close();
170
171
 
171
172
  /* M: mentions */
172
173
  await open('men');
@@ -193,8 +194,8 @@ const GANTT = [
193
194
  await click(`.bd-it[data-id="${M2}"] [data-bda="munread"]`);
194
195
  await until(() => posts.filter((x) => x.path === '/api/mentions/read').length === 2);
195
196
  ok('M8 Mark unread posts read:false', posts.filter((x) => x.path === '/api/mentions/read')[1].body.read === false);
197
+ ok('M9 the view names who waits again after Mark unread', await until(() => say().then((t) => /Dana in Slack and Priya in Jira are waiting/.test(t))), await say());
196
198
  await close();
197
- ok('M9 the row names who waits again after Mark unread', await until(() => rows().then((r) => /Dana in Slack and Priya in Jira are waiting/.test(r.men.t))), JSON.stringify((await rows()).men));
198
199
 
199
200
  /* P: portfolio pulse */
200
201
  await open('pulse');
@@ -246,37 +247,38 @@ const GANTT = [
246
247
  } else ok('S9 Scan now is off and says why', /switched off|cannot start|left/.test(await body()), await body());
247
248
  await close();
248
249
 
249
- /* F: data freshness */
250
- await open('src');
251
- const ft = await body();
252
- const srcRows = await p.evaluate(() => document.querySelectorAll('#czViewer .cz-vw-body .bd-src').length);
253
- ok('F1 the dialog lists the workspace\'s sources with their state and schedule', srcRows >= 3 && /Refresh/.test(ft) && /Sources are read on a schedule, not live/.test(ft) && !/up to date/i.test(ft), ft);
250
+ /* F: data freshness is Sources now (cozy-sources.js); the old view's key opens it */
251
+ await p.evaluate(() => import('/pm/home-around.js').then((M) => M.openAround('src')));
252
+ await until(() => p.evaluate(() => document.querySelectorAll('#czViewer .ev-src .ev-trow[data-src]').length > 0), 20000);
253
+ const ft = await p.evaluate(() => document.querySelector('#czViewer .ev-src').textContent);
254
+ const srcRows = await p.evaluate(() => document.querySelectorAll('#czViewer .ev-src .ev-trow[data-src]').length);
255
+ ok('F1 Sources lists the workspace\'s sources with when each was last read, and says it never posts', srcRows >= 3 && /Last read/.test(ft) && /never posts to them/.test(ft) && !/up to date/i.test(ft), ft);
254
256
  await shot('src-1280-light');
255
- const one = await p.evaluate(() => { const b = document.querySelector('#czViewer .cz-vw-body [data-bda="sfone"]'); return b ? b.dataset.id : null; });
256
- await click(`[data-bda="sfone"][data-id="${one}"]`);
257
- await until(() => posts.some((x) => x.path === '/api/sources/refresh'));
258
- const rf = posts.filter((x) => x.path === '/api/sources/refresh');
259
- ok('F2 Refresh posts one sources/refresh for that source', rf.length === 1 && rf[0].body.source === one && rf[0].body.ws === ws, JSON.stringify(rf));
260
- await until(() => p.evaluate(() => /agent session started|Rebuilding the facts/.test(document.querySelector('#czViewer .cz-vw-body .bd-a').textContent)));
261
- ok('F3 it says what it started', true);
262
- const all = await p.evaluate(() => { const b = document.querySelector('#czViewer .cz-vw-body [data-bda="sfall"]'); return b ? b.disabled : null; });
257
+ const one = await p.evaluate(() => { const b = document.querySelector('#czViewer .ev-src [data-ev-read]'); return b ? b.dataset.evRead : null; });
258
+ if (one) {
259
+ await click(`#czViewer .ev-src [data-ev-read="${one}"]`);
260
+ await until(() => posts.some((x) => x.path === '/api/sources/refresh'));
261
+ const rf = posts.filter((x) => x.path === '/api/sources/refresh');
262
+ ok('F2 Read again posts one sources/refresh for that source', rf.length === 1 && rf[0].body.source === one && rf[0].body.ws === ws, JSON.stringify(rf));
263
+ ok('F3 it says what it started', await until(() => p.evaluate(() => /agent session started|Reading it again/.test(document.querySelector('#czViewer .ev-src').textContent))));
264
+ } else ok('F2 no source is behind, so no row offers Read again', !/Read again/.test(ft.replace(/Read all again/g, '')), ft);
265
+ const all = await p.evaluate(() => { const b = document.querySelector('#czViewer .ev-src [data-ev-all]'); return b ? b.disabled : null; });
263
266
  if (all === false) {
264
267
  const n1 = posts.filter((x) => x.path === '/api/sources/refresh').length;
265
- await click('#czViewer .cz-vw-body [data-bda="sfall"]');
268
+ await click('#czViewer .ev-src [data-ev-all]');
266
269
  await until(() => posts.some((x) => x.path === '/api/sources/refresh-all'));
267
270
  const made = posts.filter((x) => x.path === '/api/sources/refresh-all');
268
- ok('F4 Refresh all posts one ordered run (the sources, then the Briefing), and no refresh of each source', made.length === 1 && made[0].body.ws === ws && posts.filter((x) => x.path === '/api/sources/refresh').length === n1, JSON.stringify(made));
269
- } else ok('F4 Refresh all is off when there is nothing to read', true);
270
- await close();
271
+ ok('F4 Read all again posts one ordered run (the sources, then the Briefing), and no refresh of each source', made.length === 1 && made[0].body.ws === ws && posts.filter((x) => x.path === '/api/sources/refresh').length === n1, JSON.stringify(made));
272
+ } else ok('F4 Read all again is off while a run is going', all === true, String(all));
273
+ await p.keyboard.press('Escape'); await until(() => p.evaluate(() => !document.querySelector('#czViewer:not([hidden])')));
271
274
 
272
275
  /* E: a source that fails is named, never shown empty */
273
276
  ganttFail = true;
274
277
  await p.evaluate(() => { document.dispatchEvent(new Event('visibilitychange')); });
275
278
  await p.reload();
276
279
  await openCard();
277
- const RE = await rows();
278
- ok('E1 a pulse that cannot be read says so, and does not read "nothing"', /^Portfolio pulse (could not be read|cannot be read|did not answer|failed)|could not be read/.test(RE.pulse.t) && !/nothing to compare/.test(RE.pulse.t), JSON.stringify(RE.pulse));
279
280
  await open('pulse');
281
+ ok('E1 a pulse that cannot be read says so, and does not read "nothing"', /could not be read/.test(await say()) && !/nothing to compare/.test(await body()), await say());
280
282
  ok('E2 its dialog names the failure', /could not be read|Portfolio pulse/.test(await body()) && await p.evaluate(() => !!document.querySelector('#czViewer .cz-vw-body .nodef.err')), await body());
281
283
  await close();
282
284
  ganttFail = false;
@@ -289,9 +291,8 @@ const GANTT = [
289
291
  repReply = { ok: true, ws, setups: [], asks: [], findings: FIND, finder: { cadence: 'daily', sources: {}, last_run: null, next_run: null } };
290
292
  await p.reload();
291
293
  await openCard();
292
- const RG = await rows();
293
- ok('G1 two findings make the row say so, with the count', /^2 reports found in your work/.test(RG.rep.t) && RG.rep.m === '2', JSON.stringify(RG.rep));
294
294
  await open('rep');
295
+ ok('G1 two findings make the view say so, with the count', /^2 reports were found in your work/.test(await say()), await say());
295
296
  const gb = await body();
296
297
  ok('G2 the dialog shows each finding with its why, its evidence and its confidence word', /Weekly status/.test(gb) && /every Friday for six weeks/.test(gb) && /Mail: Weekly status, 6 times/.test(gb) && /Calendar: Friday review/.test(gb) && /Likely/.test(gb) && /Not sure/.test(gb), gb);
297
298
  ok('G3 the buttons say what they record before they are pressed', /PMOS drafts only\. Nothing is sent\./.test(gb) && /will not raise it again/.test(gb) && !/Change first/.test(await p.evaluate(() => [...document.querySelectorAll('#czViewer .cz-vw-body .bd-a button')].map((b) => b.textContent).join('|'))), gb);
@@ -310,9 +311,8 @@ const GANTT = [
310
311
  repFail = true;
311
312
  await p.reload();
312
313
  await openCard();
313
- const R1f = await rows();
314
- ok('G7 one finding is named in the row', /^Report found: Quarterly review/.test(R1f.rep.t), JSON.stringify(R1f.rep));
315
314
  await open('rep');
315
+ ok('G7 one finding is named in the view', /^1 report was found/.test(await say()) && /Quarterly review/.test(await body()), await say());
316
316
  await click('#czViewer .cz-vw-body [data-bda="rset"]');
317
317
  ok('G8 a refused press shows the reason and keeps the finding', await until(async () => /no longer open/.test(await body()) && await p.evaluate(() => !!document.querySelector('#czViewer .cz-vw-body .nodef.err') && !!document.querySelector('#czViewer .cz-vw-body [data-bda="rset"]'))), await body());
318
318
  await close();
@@ -320,12 +320,13 @@ const GANTT = [
320
320
  repReply = { ok: true, ws, setups: [], asks: [], findings: [], finder: { cadence: 'off', sources: {}, last_run: null, next_run: null } };
321
321
  await p.reload();
322
322
  await openCard();
323
- const R0f = await rows();
324
- ok('G9 with none found and the finder off, the row says so and does not count as waiting', /finder is off/.test(R0f.rep.t) && R0f.rep.m === '', JSON.stringify(R0f.rep));
323
+ await open('rep');
324
+ ok('G9 with none found, the view says no report waits', /^No report waits for you/.test(await say()), await say());
325
+ await close();
325
326
  repReply = null;
326
327
 
327
328
  /* W: the POST allow-list */
328
- const allowed = new Set(['/api/mentions/read', '/api/pm-items/add', '/api/driver/keep', '/api/driver/return', '/api/driver/drop', '/api/scan/proposal', '/api/scan/now', '/api/scan/stop', '/api/sources/refresh', '/api/sources/refresh-all', '/api/report-setups/setup', '/api/report-setups/dismiss', '/api/briefing-premium/seen']); // seen: an opened popup's record (popup context slice 11, R1)
329
+ const allowed = new Set(['/api/mentions/read', '/api/pm-items/add', '/api/driver/keep', '/api/driver/return', '/api/driver/drop', '/api/scan/proposal', '/api/scan/now', '/api/scan/stop', '/api/sources/refresh', '/api/sources/refresh-all', '/api/report-setups/setup', '/api/report-setups/dismiss', '/api/briefing-premium/seen', '/api/news-for-you/seen']); // news-for-you/seen: closing New for you marks what it showed seen // seen: an opened popup's record (popup context slice 11, R1)
329
330
  const strays = posts.filter((x) => !allowed.has(x.path) && !/^\/api\/home-desk\//.test(x.path)); // /api/home-desk/*: Home's own chat (a conversation seen), not Around you
330
331
  ok('W1 every POST is one of the existing routes in the PRD', posts.length > 0 && strays.length === 0, JSON.stringify(strays));
331
332
  const fields = { '/api/driver/keep': ['ws', 'proposal'], '/api/driver/return': ['ws', 'proposal', 'note'], '/api/driver/drop': ['ws', 'proposal'], '/api/mentions/read': ['id', 'read'], '/api/pm-items/add': ['line'], '/api/scan/proposal': ['ws', 'id', 'action', 'why'], '/api/scan/now': ['ws'], '/api/sources/refresh': ['ws', 'source'], '/api/sources/refresh-all': ['ws'], '/api/report-setups/setup': ['ws', 'finding'], '/api/report-setups/dismiss': ['ws', 'finding', 'name'] };
@@ -334,7 +335,7 @@ const GANTT = [
334
335
  ok('W3 every GET the card made is a console route in the PRD', gets.filter((g) => !['/api/briefing-premium', '/api/brief-page', '/api/driver/open', '/api/calendar-views', '/api/scan/portfolio', '/api/report-setups', '/api/sources', '/api/pm-items', '/api/workspaces', '/api/products', '/api/state'].includes(g) && /around|depth|bd-/.test(g)).length === 0);
335
336
 
336
337
  /* the Scan now status on the scan row, from the server's own manual count */
337
- ok('RS1 the scan row says how many manual scans are left', / · (Scan now: \d+ of \d+ left today|Scan now is off here)$/.test(R0.scan.s), JSON.stringify(R0.scan));
338
+ ok('RS1 the scan view says how many manual scans are left, or why Scan now is off', /\d+ of \d+ manual scans left today|switched off|cannot start/.test(st), st);
338
339
 
339
340
  /* P: the prep ring over Today, counted from the meetings the brief page holds */
340
341
  const tm = (id, m, state, before) => ({ id, title: 'Meeting ' + id, start: iso(m), end: iso(m + 30), minutes: 30, people: [], initiative: null, prepared: false, before, state });
@@ -359,7 +360,7 @@ const GANTT = [
359
360
  await shot('card-390-light');
360
361
  const side = await p.evaluate(() => document.documentElement.scrollWidth - innerWidth);
361
362
  ok('L1 at 390 wide the page does not scroll sideways', side <= 0, String(side));
362
- const small = await p.evaluate(() => [...document.querySelectorAll('#aroundBody [data-bd]')].filter((b) => b.getBoundingClientRect().height < 44).map((b) => b.dataset.bd));
363
+ const small = await p.evaluate(() => [...document.querySelectorAll('#czViewer .ev-news [data-ev-rest]')].filter((b) => b.getBoundingClientRect().height < 44).map((b) => b.dataset.evRest));
363
364
  ok('L2 every row is 44 px tall at least', small.length === 0, small.join());
364
365
  await open('men');
365
366
  const wide = await p.evaluate(() => { const d = document.querySelector('#czViewer .cz-vw-body'); return [document.documentElement.scrollWidth - innerWidth, d.scrollWidth - d.clientWidth]; });
@@ -374,7 +375,7 @@ const GANTT = [
374
375
  await close().catch(() => {});
375
376
  const raw = await p.evaluate(() => { const c = getComputedStyle(document.querySelector('#czViewer')); return [c.backgroundColor, getComputedStyle(document.body).backgroundColor]; });
376
377
  ok('L4 in the dark theme the card has a background of its own', raw[0] !== 'rgba(0, 0, 0, 0)' && raw[0] !== raw[1] || raw[0] !== '', raw.join());
377
- const focus = await p.evaluate(() => { const b = document.querySelector('#aroundBody [data-bd]'); b.focus(); const c = getComputedStyle(b); return [c.outlineStyle, c.outlineWidth, c.boxShadow]; });
378
+ const focus = await p.evaluate(() => { const b = document.querySelector('#czViewer .ev-news [data-ev-rest]'); b.focus(); const c = getComputedStyle(b); return [c.outlineStyle, c.outlineWidth, c.boxShadow]; });
378
379
  ok('L5 a row shows a focus ring', focus[0] !== 'none' || focus[2] !== 'none', focus.join());
379
380
  /* K: the simple Agent proposals dialog at 390, light and dark, and with the phone keyboard open */
380
381
  const P4 = 'p-bbbbbbbb04', P5 = 'p-bbbbbbbb05';
@@ -56,7 +56,7 @@ const DASH = { kind: 'dashboard', proposal: { name: 'Partner growth', purpose: '
56
56
 
57
57
  /* premium-agreed-design: Home's chat (home-chat.js) draws the chip; a chart or dashboard opens in the Viewer card (cozy-viewer.js), whose kind line names it.
58
58
  * A chart is the design's metrics view (Main.dc.html viewer "metrics": stat tiles, then the readings with the newest in ember); its forms, Save and
59
- * Delete are the cozy part marked Waiting for design, and a confirm asks in the card ([data-ct="askyes"]). */
59
+ * Delete are its setup block, and a confirm asks in the card ([data-ct="askyes"]). */
60
60
  const look = () => {
61
61
  const vw = document.querySelector('#czViewer:not([hidden])');
62
62
  const pane = vw ? vw.querySelector('.vz[data-vw^="chart:"], .vz[data-vw^="dashboard:"]') : null;
@@ -82,7 +82,9 @@ const look = () => {
82
82
  const p = await ctx.newPage(); const errs = []; p.on('pageerror', (e) => errs.push(String(e)));
83
83
  await p.route('**/api/briefing-premium/thread?**', (r) => r.fulfill({ json: { ok: true, turns: [], session: 's-ch', goal: null } }));
84
84
  await p.route('**/api/sessions/conversation?**', (r) => r.fulfill({ json: { ok: true, state: 'conv', turn: 'pm', messages } }));
85
- await p.goto(BASE + url); // premium-agreed-design: /premium-chat.html opens Home, whose chat is docked on a desktop and is the page on a phone
85
+ // premium-agreed-design: /premium-chat.html opens Home, whose chat is docked on a desktop; on a phone the list is the page (premium-uncovered-features
86
+ // HmPhone), so the address names the conversation and it opens as the page (HmPhone2)
87
+ await p.goto(BASE + url + (width < 761 && url === '/premium-chat.html' ? '?about=chat:charts' : ''));
86
88
  await until(() => p.evaluate(() => !!document.querySelector('#hmLog [data-report-open]')));
87
89
  await sleep(500);
88
90
  return { p, ctx, errs };
@@ -43,7 +43,7 @@ const look = () => {
43
43
  return { tab: vw ? 'out' : 'chat', shut: !gp, layer: false, out: vw ? Math.round(vw.getBoundingClientRect().width) : 0, vh: innerHeight,
44
44
  cardInChat: !!document.querySelector('#hmLog .gcard'), chip: (document.querySelector('#hmLog [data-goal-open]') || {}).textContent || null,
45
45
  smart: !!document.querySelector('#hmLog .smart'), start: !!document.querySelector('#hmLog [data-goal="start"]'),
46
- tabs: gp ? ['Goal'] : [], on: vw ? (vw.querySelector('.cz-vw-kind') || {}).textContent || null : null,
46
+ tabs: gp ? ['Goal'] : [], on: vw ? (vw.querySelector('.cz-vw-kind') || vw.querySelector('.cz-vw-title') || {}).textContent || null : null, // a kind that repeats the title is not drawn
47
47
  pane: gp ? gp.textContent.replace(/\s+/g, ' ').trim() : null, stop: !!document.querySelector('#czViewer [data-goal="stop"]'),
48
48
  peek: peek && !peek.hidden ? peek.textContent.trim() : null,
49
49
  railOff: !document.querySelector('nav.rail'), wide: document.documentElement.scrollWidth > innerWidth + 1 };