create-pmos 0.415.0 → 0.417.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.
- package/package.json +25 -25
- package/payload/KIT-VERSION +2 -2
- package/payload/planning/evals/eval-calibration.md +1 -1
- package/payload/planning/okrs/health-budgets.md +1 -1
- package/payload/state/discoveries.md +1 -1
- package/payload/state/log.md +1 -1
- package/workspace/briefing-premium-adddoc-test.js +3 -3
- package/workspace/briefing-premium-board-test.js +72 -43
- package/workspace/briefing-premium-doc-edit-test.js +2 -2
- package/workspace/briefing-premium-initiative-test.js +19 -22
- package/workspace/briefing-premium-insights-test.js +28 -17
- package/workspace/changelog.json +24 -0
- package/workspace/core-docs-workflow-test.js +1 -1
- package/workspace/guide/workflows.md +4 -3
- package/workspace/ini-workflow-test.js +11 -11
- package/workspace/lib/board-premium.js +7 -2
- package/workspace/lib/board-trail.js +6 -1
- package/workspace/lib/engine/boards.js +8 -2
- package/workspace/lib/initiative-chat.js +4 -3
- package/workspace/lib/initiative-premium.js +5 -3
- package/workspace/lib/insights-premium.js +9 -1
- package/workspace/lib/pmos-verbs.js +1 -1
- package/workspace/lib/route-modules.js +1 -0
- package/workspace/lib/routes-boards.js +73 -6
- package/workspace/lib/routes-live.js +53 -0
- package/workspace/lib/task-cli.js +88 -24
- package/workspace/lib/task-items.js +3 -1
- package/workspace/lib/workflow-cli.js +10 -4
- package/workspace/milestone-suggest-test.js +2 -1
- package/workspace/package-lock.json +2 -2
- package/workspace/package.json +1 -1
- package/workspace/premium-board-actions-test.js +12 -8
- package/workspace/premium-chat-report-tab-test.js +13 -5
- package/workspace/premium-core-doc-issue-test.js +1 -1
- package/workspace/premium-report-read-test.js +66 -51
- package/workspace/premium-vw-backlog-test.js +3 -3
- package/workspace/premium-vw-doc-test.js +3 -3
- package/workspace/premium-vw-item-test.js +4 -4
- package/workspace/premium-vw-jira-test.js +14 -13
- package/workspace/premium-vw-slides-test.js +7 -5
- package/workspace/program-panel-test.js +1 -1
- package/workspace/public/pm/bd-ini-panel.js +68 -230
- package/workspace/public/pm/cozy-insights.css +15 -0
- package/workspace/public/pm/cozy-live-pill.css +48 -0
- package/workspace/public/pm/cozy-live-pill.js +141 -0
- package/workspace/public/pm/cozy-viewer.js +4 -3
- package/workspace/public/pm/cozy-vw-rp.css +48 -0
- package/workspace/public/pm/home-app.js +45 -8
- package/workspace/public/pm/home-chat.js +5 -2
- package/workspace/public/pm/home-ini.js +57 -22
- package/workspace/public/pm/home-task.js +16 -5
- package/workspace/public/pm/ini-view-model.js +277 -0
- package/workspace/public/pm/ini-view.css +122 -0
- package/workspace/public/pm/ini-view.js +180 -0
- package/workspace/public/pm/live-model.js +104 -0
- package/workspace/public/pm/ov-view.css +44 -0
- package/workspace/public/pm/premium-board.js +15 -16
- package/workspace/public/pm/premium-insights.js +61 -35
- package/workspace/public/pm/premium-report-read.js +74 -50
- package/workspace/public/pm/premium-report-tab.js +36 -15
- package/workspace/public/pm/premium-shell.js +1 -1
- package/workspace/public/pm/premium-vw-item-model.js +6 -3
- package/workspace/public/pm/premium-vw-item.js +25 -6
- package/workspace/public/pm/premium-vw-jira.js +17 -15
- package/workspace/public/pm/rp-parts.js +75 -12
- package/workspace/public/pm/task-card.css +24 -49
- package/workspace/public/pm/task-card.js +90 -64
- package/workspace/public/pm/tk-view.css +21 -0
- package/workspace/public/pm/tk-view.js +216 -0
- package/workspace/public/pm/wf-page.js +2 -0
- package/workspace/server.js +24 -1
- package/workspace/stage-card-test.js +49 -41
- package/workspace/task-card-test.js +83 -38
- package/workspace/test-files.json +3 -1
- package/workspace/test-lists/bd-ini-panel.json +3 -3
- package/workspace/tk-tasks-test.js +3 -3
- package/workspace/public/pm/bd-ini-model.js +0 -81
- package/workspace/public/pm/cozy-rec-pill.css +0 -12
- package/workspace/public/pm/cozy-rec-pill.js +0 -46
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-pmos",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.417.0",
|
|
4
4
|
"description": "Scaffold the PMOS portable kit — run the PMOS product-management workflow (initiative → lane-fit spec → contract → build → three gates, with work-type lanes for features, research, maintenance, incidents, and content) entirely inside your own repo, with all state as git-versioned files. Includes `workflow-sweep`, which audits the state every board derives from and separates real defects from work you simply have not done. `create-pmos workspace` also installs + launches the local Terminal Workspace GUI. No database, no network, no telemetry.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"bin": {
|
|
@@ -32,6 +32,30 @@
|
|
|
32
32
|
"audit"
|
|
33
33
|
],
|
|
34
34
|
"pmosChanges": [
|
|
35
|
+
{
|
|
36
|
+
"v": "0.417.0",
|
|
37
|
+
"at": "2026-10-26T01:02:52.959Z",
|
|
38
|
+
"f": 2,
|
|
39
|
+
"prs": [
|
|
40
|
+
{
|
|
41
|
+
"n": 1053,
|
|
42
|
+
"t": "Stage moves land on the stage asked for (hotfix)",
|
|
43
|
+
"s": "Pmos workflow move and Board drops land on the Product feature stage you ask for, by key, by name, or by number, even when the board merges two stages into one column."
|
|
44
|
+
}
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"v": "0.416.0",
|
|
49
|
+
"at": "2026-10-26T00:23:58.708Z",
|
|
50
|
+
"f": 2,
|
|
51
|
+
"prs": [
|
|
52
|
+
{
|
|
53
|
+
"n": 1050,
|
|
54
|
+
"t": "Sixth testing feedback batch (items 1–5)",
|
|
55
|
+
"s": "Sixth testing feedback batch (items 1–5)"
|
|
56
|
+
}
|
|
57
|
+
]
|
|
58
|
+
},
|
|
35
59
|
{
|
|
36
60
|
"v": "0.415.0",
|
|
37
61
|
"at": "2026-10-25T15:54:44.873Z",
|
|
@@ -252,30 +276,6 @@
|
|
|
252
276
|
"s": "Rebuild Home, Viewer, Board and Insights to the Agreed design"
|
|
253
277
|
}
|
|
254
278
|
]
|
|
255
|
-
},
|
|
256
|
-
{
|
|
257
|
-
"v": "0.397.0",
|
|
258
|
-
"at": "2026-10-22T20:10:19.514Z",
|
|
259
|
-
"f": 2,
|
|
260
|
-
"prs": [
|
|
261
|
-
{
|
|
262
|
-
"n": 1011,
|
|
263
|
-
"t": "The premium pages follow the Agreed design",
|
|
264
|
-
"s": "The premium pages follow the Agreed design"
|
|
265
|
-
}
|
|
266
|
-
]
|
|
267
|
-
},
|
|
268
|
-
{
|
|
269
|
-
"v": "0.396.0",
|
|
270
|
-
"at": "2026-10-22T10:57:02.235Z",
|
|
271
|
-
"f": 2,
|
|
272
|
-
"prs": [
|
|
273
|
-
{
|
|
274
|
-
"n": 1010,
|
|
275
|
-
"t": "Use the width and a larger type on large screens",
|
|
276
|
-
"s": "Use the width and a larger type on large screens"
|
|
277
|
-
}
|
|
278
|
-
]
|
|
279
279
|
}
|
|
280
280
|
]
|
|
281
281
|
}
|
package/payload/KIT-VERSION
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
kernel-source: pmos@
|
|
2
|
-
assembled: 2026-10-
|
|
1
|
+
kernel-source: pmos@4510c3e0
|
|
2
|
+
assembled: 2026-10-26
|
|
3
3
|
mode: vendor
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
type: Reference
|
|
3
3
|
title: "Eval calibration log"
|
|
4
4
|
description: "Append-only record of every PM override of an evaluator verdict."
|
|
5
|
-
generated: {by: process:create-pmos, at: "2026-10-
|
|
5
|
+
generated: {by: process:create-pmos, at: "2026-10-26T01:02:49Z"}
|
|
6
6
|
status: stable
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
type: Reference
|
|
3
3
|
title: "Health budgets"
|
|
4
4
|
description: "Closed registry of health-budget anchors (D59), edited only by the PM."
|
|
5
|
-
generated: {by: process:create-pmos, at: "2026-10-
|
|
5
|
+
generated: {by: process:create-pmos, at: "2026-10-26T01:02:49Z"}
|
|
6
6
|
status: stable
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
type: Reference
|
|
3
3
|
title: "Discoveries and friction log"
|
|
4
4
|
description: "Append-only record of what runs discovered and where the process rubbed."
|
|
5
|
-
generated: {by: process:create-pmos, at: "2026-10-
|
|
5
|
+
generated: {by: process:create-pmos, at: "2026-10-26T01:02:49Z"}
|
|
6
6
|
status: stable
|
|
7
7
|
---
|
|
8
8
|
|
package/payload/state/log.md
CHANGED
|
@@ -35,7 +35,7 @@ const CUSTOM = [
|
|
|
35
35
|
const PAGES = {
|
|
36
36
|
board: { file: '/premium-board.html', api: '**/api/board-premium*', scope: 'board:w1', mk: (custom) => BP.build(BF.facts({ custom })), ready: '#ibBody .ini2', btn: '#addDoc', qs: '?theme=' },
|
|
37
37
|
// the initiative is a layout inside Home (premium-agreed-design): Add a document is in its Overview, a minimal form in the Viewer (Waiting for design)
|
|
38
|
-
initiative: { file: '/premium.html', api: '**/api/initiative-premium*', scope: 'initiative:self-serve-v2', mk: (custom) => IP.build(IF.facts({ custom })), ready: '
|
|
38
|
+
initiative: { file: '/premium.html', api: '**/api/initiative-premium*', scope: 'initiative:self-serve-v2', mk: (custom) => IP.build(IF.facts({ custom })), ready: '#czViewer .iv-sc', btn: '#czViewer [data-hi-v="docs"]', qs: '?ini=self-serve-v2&ws=w1&board=w1&theme=' },
|
|
39
39
|
};
|
|
40
40
|
|
|
41
41
|
(async () => {
|
|
@@ -59,7 +59,7 @@ const PAGES = {
|
|
|
59
59
|
await page.route('**/api/briefing-premium/**', (r) => r.fulfill({ contentType: 'application/json', body: JSON.stringify({ ok: true, turns: [], working: false }) }));
|
|
60
60
|
await page.goto(BASE + P.file + P.qs + theme);
|
|
61
61
|
let up = await until(() => page.evaluate((s) => !!document.querySelector(s), P.ready), 20000);
|
|
62
|
-
if (up && kind === 'initiative') { await page.click('#czViewer .
|
|
62
|
+
if (up && kind === 'initiative') { await page.click('#czViewer [data-cz-vw="more"]').then(() => page.click('.cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("All tasks"))')); /* the initiative's page (canvas HbC): its + drills into Tasks */ await docsView(page); up = await until(() => page.evaluate((s) => !!document.querySelector(s), P.btn), 20000); } // the Overview holds the button
|
|
63
63
|
if (up && P.file === '/premium-board.html') await page.click(w <= 720 ? '#chDocs' : '#tabDocs'); // a phone reaches the documents from its Docs chip // the Agreed design shows the documents on the Documents tab (premium-agreed-design)
|
|
64
64
|
return { ctx, page, errors, posts, up, calls: () => calls, setCustom: (c) => { current = c; }, reply: (a) => { reply = a; } };
|
|
65
65
|
};
|
|
@@ -69,7 +69,7 @@ const PAGES = {
|
|
|
69
69
|
// Documents is shell A (XvADocs): Add a document is under its ⋯, with Group by and Show
|
|
70
70
|
async function addDoc(page) { await page.click('#czViewer [data-cz-vw="more"]'); await page.click('#czViewer .cz-vw-menu button:has-text("Add a document")'); }
|
|
71
71
|
// the initiative's page (canvas HbC): its Documents' "Show all N" drills into the Documents view
|
|
72
|
-
async function docsView(page) { if (await until(() => page.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')), 20000)) await (async (pg) => { if (await pg.$('#czViewer [data-hi-v="page"] [data-
|
|
72
|
+
async function docsView(page) { if (await until(() => page.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')), 20000)) await (async (pg) => { if (await pg.$('#czViewer [data-hi-v="page"] [data-iv-docs]')) await pg.click('#czViewer [data-iv-docs]'); else if (await pg.$('#czViewer [data-hi-view="docs"]')) await pg.click('#czViewer [data-hi-view="docs"]'); else await viaMore(pg, 'Documents'); })(page); }
|
|
73
73
|
|
|
74
74
|
/* the Board (premium-uncovered-features, BdDocs): the Documents tab is a table with an Add a document form in the side panel;
|
|
75
75
|
the same route, the same fields, the same refusals */
|
|
@@ -24,6 +24,16 @@ const FT = require('./fixtures/board-premium-trail.js');
|
|
|
24
24
|
|
|
25
25
|
const BASE = T.BASE;
|
|
26
26
|
const sleep = (ms) => new Promise((r) => setTimeout(r, ms));
|
|
27
|
+
/* SHOTS_1B=<dir>: the Viewer as it is now, light and dark, at 1440 and 390 wide (batch 6 item 1b's screenshots); the page is put back after. */
|
|
28
|
+
const four = async (p, name) => {
|
|
29
|
+
const dir = process.env.SHOTS_1B; if (!dir) return;
|
|
30
|
+
const vp = p.viewportSize();
|
|
31
|
+
for (const [w, h, tag] of [[1440, 900, 'desktop'], [390, 844, 'phone']]) for (const sch of ['light', 'dark']) {
|
|
32
|
+
await p.setViewportSize({ width: w, height: h }); await p.emulateMedia({ colorScheme: sch }); await new Promise((r) => setTimeout(r, 350));
|
|
33
|
+
await p.screenshot({ path: require('path').join(dir, `${name}-${tag}-${sch}.png`) });
|
|
34
|
+
}
|
|
35
|
+
await p.setViewportSize(vp); await p.emulateMedia({ colorScheme: null }); await new Promise((r) => setTimeout(r, 250));
|
|
36
|
+
};
|
|
27
37
|
const until = async (fn, ms = 10000, step = 100) => { const t0 = Date.now(); for (;;) { const v = await fn(); if (v) return v; if (Date.now() - t0 > ms) return v; await sleep(step); } };
|
|
28
38
|
const results = [];
|
|
29
39
|
const ok = (name, cond, extra = '') => { results.push({ name, cond: !!cond }); console.log(`${cond ? '✓' : '✗'} ${name}${!cond && extra !== '' ? ' — ' + extra : ''}`); };
|
|
@@ -39,6 +49,21 @@ const finish = async (code) => {
|
|
|
39
49
|
process.on('unhandledRejection', (e) => { console.error(e); finish(1); });
|
|
40
50
|
|
|
41
51
|
const mk = (o) => BP.build(F.facts(o));
|
|
52
|
+
/* the ONE initiative view (feedback batch 6 items 1 and 3, pm/ini-view.js) as the Viewer shows it, read in the page; null while it is not up */
|
|
53
|
+
const IVREAD = () => {
|
|
54
|
+
const v = document.querySelector('#czViewer'), iv = v && !v.hidden && v.querySelector('.iv'); if (!iv) return null;
|
|
55
|
+
const tx = (sel, root = iv) => { const e = root.querySelector(sel); return e ? e.textContent.replace(/\s+/g, ' ').trim() : null; };
|
|
56
|
+
const sc = iv.querySelector('.iv-sc'), c = window.czViewer && window.czViewer.current(), r = v.getBoundingClientRect();
|
|
57
|
+
return { t: tx('.cz-vw-title', v), kind: c && c.kind, line: tx('.iv-s1 b'), right: tx('.iv-s1 .iv-r'), why: tx('.iv-why'), meta: tx('.iv-meta'), wfi: (iv.querySelector('.iv-meta .wfi') || {}).title || null,
|
|
58
|
+
primary: (iv.querySelector('[data-iv-primary]') || {}).dataset ? (iv.querySelector('[data-iv-primary]') || { dataset: {} }).dataset.ivPrimary || null : null,
|
|
59
|
+
stage: sc && tx('.iv-sch b', sc), where: sc && tx('.iv-sch .iv-r', sc), no: sc && tx('.iv-sch .iv-no', sc),
|
|
60
|
+
bars: sc ? [...sc.querySelectorAll('.iv-lad i')].map((i) => i.className).join('|') : '', titles: sc ? [...sc.querySelectorAll('.iv-lad i')].map((i) => i.title) : [],
|
|
61
|
+
aria: sc && sc.querySelector('.iv-lad') ? sc.querySelector('.iv-lad').getAttribute('aria-label') : null, dates: sc && tx('.iv-dl', sc), next: sc && tx('.iv-nx', sc),
|
|
62
|
+
tasks: tx('.iv-th'), secs: [...iv.querySelectorAll('.iv-ws')].map((b) => b.textContent.replace(/\s+/g, ' ').trim()), tks: [...iv.querySelectorAll('[data-iv-ticket]')].map((e) => e.dataset.ivTicket).join(),
|
|
63
|
+
rows: [...iv.querySelectorAll('.iv-tr')].map((e) => e.textContent.replace(/\s+/g, ' ').trim()), q: [...iv.querySelectorAll('.iv-q')].map((e) => e.textContent), empty: !!iv.querySelector('.iv-empty'),
|
|
64
|
+
folds: [...iv.querySelectorAll('.iv-fr b, .czs-row b')].map((b) => b.textContent), body: v.querySelector('.cz-vw-body').textContent.replace(/\s+/g, ' '),
|
|
65
|
+
ask: v.querySelectorAll('.cz-vw-body input, .cz-vw-body textarea').length, disc: !!v.querySelector('[data-cz-vw="discuss"]'), w: Math.round(r.width), side: Math.round(innerWidth - r.right) < 40 };
|
|
66
|
+
};
|
|
42
67
|
|
|
43
68
|
(async () => {
|
|
44
69
|
const exe = findBrowser();
|
|
@@ -131,38 +156,33 @@ const mk = (o) => BP.build(F.facts(o));
|
|
|
131
156
|
const k = await q.evaluate(() => { const r = document.querySelector('.bt-l[data-row="board:usage-billing"]'); return { cls: r.querySelector('.bt-cells > div').className, n: r.querySelectorAll('.bt-cells > div.k').length }; });
|
|
132
157
|
ok('B1 a step the row was moved past is a hollow "Skipped" ring', /\bk\b/.test(k.cls) && k.n === 1, JSON.stringify(k));
|
|
133
158
|
await q.click('.bt-l[data-row="board:usage-billing"] .bt-nm');
|
|
134
|
-
/* re-pointed (
|
|
135
|
-
const sk = await until(() => q.evaluate(
|
|
136
|
-
ok('B1 the panel hatches the skipped step
|
|
159
|
+
/* re-pointed (batch 6 item 1, the one view): the ladder keeps the skipped step in its place, hatched, and its title says so */
|
|
160
|
+
const sk = await until(() => q.evaluate(IVREAD));
|
|
161
|
+
ok('B1 the panel hatches the skipped step on the ladder', !!sk && sk.bars.split('|')[0] === 'skip' && sk.titles[0] === 'Triage · skipped', JSON.stringify(sk && [sk.bars, sk.titles]));
|
|
137
162
|
await R.ctx.close();
|
|
138
163
|
}
|
|
139
164
|
{
|
|
140
|
-
/* XipB (
|
|
141
|
-
* progress source once, on the status line; the stage card names the CURRENT Tender stage
|
|
142
|
-
* Product feature steps, never "No
|
|
143
|
-
*
|
|
165
|
+
/* XipB, re-pointed to the ONE view (batch 6 items 1 and 3, OvIniA): an initiative on its own workflow (a Tender). The status and the one
|
|
166
|
+
* sentence why; the progress source once, on the status line; the stage card names the CURRENT Tender stage, "5 of 7" from the ladder over
|
|
167
|
+
* the seven Tender stages (never the eight Product feature steps, never "No stage on record"); the dates line (the old Plan card) says the
|
|
168
|
+
* days over; the next stage last; no breakdown draws the workflow's sections dashed */
|
|
144
169
|
const ST = [['triage', 'Triage'], ['requirements', 'Requirements and criteria'], ['issue', 'Issue tender'], ['bids', 'Bid evaluation'], ['poc', 'Technical POC'], ['award', 'Award decision', true], ['signed', 'Contract signed', true]];
|
|
145
170
|
const tdr = { wf: { id: 'tender', name: 'Tender', icon: 'doc' }, wfStage: { key: 'poc', name: 'Technical POC', cat: 'doing', milestone: false, n: 5, of: 7 },
|
|
146
171
|
wfStages: ST.map(([key, name, ms], i) => ({ key, name, cat: i ? 'doing' : 'todo', milestone: !!ms, status: i < 4 ? 'done' : i === 4 ? 'current' : 'next' })) };
|
|
147
172
|
const f = F.facts(); f.rows = f.rows.map((r) => (r.id === 'usage-billing' ? { ...r, title: 'Tender new CIAM', status: 'late', owner: 'wawan', start: '2026-04-23', end: '2026-08-11', progress: 0.53, ...tdr } : r));
|
|
148
173
|
const R = await open({ model: BP.build(f) }), q = R.page;
|
|
149
174
|
await q.click('.bt-l[data-row="board:usage-billing"] .bt-nm');
|
|
150
|
-
const td = await until(() => q.evaluate(
|
|
151
|
-
return { line: v.querySelector('.czs-line > span:not(.czs-dot):not(.czs-r)').textContent, right: (v.querySelector('.czs-line .czs-r') || {}).textContent, why: (v.querySelector('.czs-p') || {}).textContent, meta: v.querySelector('.czs-meta').textContent, wfi: (v.querySelector('.czs-meta .wfi') || {}).title,
|
|
152
|
-
stage: sc.querySelector('.xv-ch b').textContent, where: (sc.querySelector('.xv-ch .r') || {}).textContent, bars: [...sc.querySelectorAll('.xv-stg i')].map((i) => i.className).join('|'), aria: sc.querySelector('.xv-stg').getAttribute('aria-label'),
|
|
153
|
-
none: (sc.querySelector('.xv-none') || {}).textContent, add: sc.querySelector('a.xv-add') ? { label: sc.querySelector('a.xv-add').getAttribute('aria-label'), text: sc.querySelector('a.xv-add').textContent.trim(), href: sc.querySelector('a.xv-add').getAttribute('href') } : null,
|
|
154
|
-
next: (sc.querySelector('.cz-sli.tail') || {}).textContent, body: v.querySelector('.cz-vw-body').textContent,
|
|
155
|
-
marks: pl ? [...pl.querySelectorAll('[data-pl]')].map((e) => e.dataset.pl + ':' + e.textContent) : null, lg: pl ? [...pl.querySelectorAll('.xv-lg span')].map((e) => e.textContent) : null, secs: [...v.querySelectorAll('.czs-row b')].map((b) => b.textContent) }; }));
|
|
175
|
+
const td = await until(() => q.evaluate(IVREAD));
|
|
156
176
|
ok('XipB a Tender initiative: Late, the one sentence why from the record, the progress said once as typed in by hand, the owner and the Tender workflow', !!td && td.line === 'Late' && /^The plan ended Aug 11(, 2026)?, \d+ days ago, and Tender new CIAM is in Technical POC\.$/.test(td.why) && td.right === '53% done · typed in by hand' && /wawan ?· ?Tender$/.test(td.meta) && td.wfi === 'Tender', JSON.stringify(td));
|
|
157
|
-
ok('XipB the stage card is the Tender stage: "Technical POC", 5 of 7, the seven Tender stages with Technical POC current and ◆ on the last two', !!td && td.stage === 'Technical POC' &&
|
|
158
|
-
ok('XipB
|
|
159
|
-
ok('XipB the Plan card
|
|
177
|
+
ok('XipB the stage card is the Tender stage: "Technical POC", 5 of 7 on the ladder, the seven Tender stages with Technical POC current and ◆ on the last two', !!td && td.stage === 'Technical POC' && td.no === '5' && td.bars === 'done|done|done|done|now|next ms|next ms' && td.aria === 'Stage 5 of 7 of Tender: Technical POC. Next stage: Award decision.' && !/No st(ep|age) on record/.test(td.body), JSON.stringify(td && [td.stage, td.no, td.bars, td.aria]));
|
|
178
|
+
ok('XipB the next stage is the card\'s last line; no breakdown draws the seven Tender sections dashed, with Technical POC marked now', !!td && /^Award decision ?Next stage/.test(td.next || '') && td.empty && /Technical POC · now/.test(td.body), JSON.stringify(td && [td.next, td.empty]));
|
|
179
|
+
ok('XipB the dates line (the old Plan card) says the plan and the overrun; no Jira date; the progress number is said once', !!td && /^Apr 23 ?Aug 11 end · \d+ days over$/.test(td.dates || '') && !/Jira:/.test(td.dates) && (td.body.match(/53%/g) || []).length === 1 && !td.folds.includes('Dates and trend'), JSON.stringify(td && [td.dates, td.folds]));
|
|
160
180
|
if (process.env.PMOS_SHOTS) await q.screenshot({ path: path.join(process.env.PMOS_SHOTS, 'ini-tender-1440.png') });
|
|
161
181
|
await R.ctx.close();
|
|
162
182
|
if (process.env.PMOS_SHOTS) {
|
|
163
183
|
for (const [w, h, theme, name] of [[1440, 900, 'dark', 'ini-tender-1440-dark.png'], [390, 844, 'dark', 'ini-tender-390-dark.png']]) {
|
|
164
184
|
const P = await open({ model: BP.build(f), w, h, theme }); await P.page.evaluate(() => { const b = [...document.querySelectorAll('[data-key="board:usage-billing"], [data-row="board:usage-billing"] button')].find((x) => x.offsetParent); if (b) b.click(); });
|
|
165
|
-
await until(() => P.page.evaluate(() => !!document.querySelector('#czViewer .
|
|
185
|
+
await until(() => P.page.evaluate(() => !!document.querySelector('#czViewer .iv-sc'))); await sleep(300);
|
|
166
186
|
await P.page.screenshot({ path: path.join(process.env.PMOS_SHOTS, name) }); await P.ctx.close();
|
|
167
187
|
}
|
|
168
188
|
}
|
|
@@ -182,19 +202,26 @@ const mk = (o) => BP.build(F.facts(o));
|
|
|
182
202
|
await q.click('.bt-l[data-row="board:sso-partners"] .bt-nm');
|
|
183
203
|
/* re-pointed (viewer-shell-a, XvABoard): the initiative opens in the Viewer's shell A, floating over the page's right edge: the summary card,
|
|
184
204
|
* the stage bar, then the folding rows. The Ask box is gone; Discuss in chat and ⋯ take its presses */
|
|
185
|
-
const pk = await until(() => q.evaluate(
|
|
186
|
-
|
|
187
|
-
|
|
205
|
+
const pk = await until(() => q.evaluate(IVREAD).then((x) => (x && x.kind === 'Initiative' ? x : null)));
|
|
206
|
+
const sel = await q.evaluate(() => ({ sel: !!document.querySelector('.bt-l.sel[data-row="board:sso-partners"]'), dlg: !!document.querySelector('#dlg.on'), peek: !document.querySelector('#peek'), record: !!document.querySelector('#czViewer [data-pk="record"]') }));
|
|
207
|
+
ok('B1 a row opens the initiative in the Viewer, floating at 560 px over the right edge, not the old dialog, and the row is marked', !!pk && pk.t === 'SSO for partners' && pk.w === 560 && pk.side && sel.peek && !sel.dlg && !sel.record && sel.sel, JSON.stringify([pk, sel]));
|
|
208
|
+
/* re-pointed (the one view): the meta is the owner and the workflow, each fact once; the progress source is the right of the status line */
|
|
188
209
|
ok('B1 the summary says the status once (the release date is not said again), the owner and the workflow, and when Jira was read', !!pk && pk.line === 'Ships Nov 4' && /Lee ?· ?Product feature$/.test(pk.meta) && pk.wfi === 'Product feature' && !/day|owner|Deliver/.test(pk.meta) && /^Jira · \d+ days? ago$/.test(pk.right), JSON.stringify(pk && [pk.line, pk.meta, pk.right]));
|
|
189
|
-
|
|
190
|
-
|
|
210
|
+
/* re-pointed (batch 6 rules 1, 4 and 11): the card says where it is (6 of 8 on the ladder) and how much of Deliver's tickets are done; the
|
|
211
|
+
* tickets themselves are said once, as Deliver's section in Tasks, blocked first, with "N of M done in Jira" */
|
|
212
|
+
ok('B1 the stage card names the stage (Deliver, 6 on the ladder of eight, ◆ on Deliver and Evaluate) and how many tickets are done; Deliver\'s section lists the open tickets, blocked first, with the done count', !!pk && pk.bars.split('|').length === 8 && pk.bars.split('|')[5] === 'now ms' && /ms$/.test(pk.bars.split('|')[7]) && pk.stage === 'Deliver' && pk.no === '' && /^1 of 4 done in Jira/.test(pk.where || '') && pk.tks.split(',')[0] === 'SSO-12' && pk.tks.split(',').sort().join() === 'SSO-12,SSO-14,SSO-15' && /SSO-12 SAML errors ?Blocked by PLAT-88/.test(pk.body) && pk.q.some((x) => /^1 of 4 done in Jira/.test(x)) && !pk.folds.includes('Dates and trend'), JSON.stringify(pk && [pk.stage, pk.where, pk.bars, pk.tks, pk.q, pk.folds]));
|
|
213
|
+
ok('B1 what PMOS has no record of is not drawn: no Linked row, no Drafted row, no Jira-differs row', !!pk && !pk.folds.includes('Linked') && !pk.folds.includes('Drafted in PMOS') && !pk.folds.includes('Jira differs from the PRD'), JSON.stringify(pk && pk.folds));
|
|
191
214
|
ok('B1 there is no ask box; Discuss in chat sits in the header', !!pk && pk.ask === 0 && pk.disc, JSON.stringify(pk));
|
|
192
215
|
if (process.env.PMOS_SHOTS) await q.screenshot({ path: path.join(process.env.PMOS_SHOTS, 'ini-deliver-1280.png') });
|
|
193
216
|
const n0 = R.posts.length; await vwMore(q, 'Read Jira again');
|
|
194
217
|
ok('B1 Read Jira again under ⋯ reads Jira through the Jira source\'s own refresh, and says so', await until(() => R.posts.slice(n0).some((x) => x.path === '/api/sources/refresh' && x.body.source === 'jira' && x.body.ws === 'w1')) && await until(() => q.evaluate(() => /Reading Jira again/.test(document.querySelector('#bdToast').textContent))), JSON.stringify(R.posts.slice(n0)));
|
|
195
|
-
await q.click('#czViewer [data-
|
|
196
|
-
const tk = await until(() => q.evaluate(() => { const v = document.querySelector('#czViewer'), t = v && v.querySelector('.cz-vw-title'); return t && /SSO-12/.test(t.textContent) ? { t: t.textContent, back: !!v.querySelector('[data-cz-vw="back"]'), line: v.querySelector('.czs-line').textContent,
|
|
197
|
-
|
|
218
|
+
await q.click('#czViewer [data-iv-ticket="SSO-12"]');
|
|
219
|
+
const tk = await until(() => q.evaluate(() => { const v = document.querySelector('#czViewer'), t = v && v.querySelector('.cz-vw-title'), b = v && v.querySelector('.tkv'); return t && /SSO-12/.test(t.textContent) && b ? { t: t.textContent, back: !!v.querySelector('[data-cz-vw="back"]'), line: (v.querySelector('.czs-line') || {}).textContent || '', right: (v.querySelector('.czs-line .czs-r') || {}).textContent || '', sprint: (v.querySelector('[data-tkv-f="sprint"]') || {}).textContent, foot: (v.querySelector('.tkv .ovf .foot') || {}).textContent, where: (v.querySelector('.tkv .ovw') || {}).textContent, body: v.querySelector('.cz-vw-body').textContent.replace(/\s+/g, ' '), pri: !!v.querySelector('.czs-pri'), jira: (v.querySelector('.ovft a') || {}).href } : null; }));
|
|
220
|
+
/* re-pointed (batch 6 item 1b, canvas OvViewers "Jira ticket"): the one ticket Viewer. What blocks it leads; the facts are plain text with
|
|
221
|
+
* "Jira owns these"; there is no primary (Open in Jira sits at the foot); the where row names the initiative and its Build stage */
|
|
222
|
+
ok('B1 V1 a ticket opens as a drill-in in the one ticket Viewer: blocked by PLAT-88 and what it holds up (the sprint end, the release), the facts Jira owns, where it sits, Open in Jira at the foot', !!tk && tk.t === 'SSO-12 SAML errors' && tk.back && /^Blocked by PLAT-88/.test(tk.line) && /^Jira · /.test(tk.right)
|
|
223
|
+
&& /If it is not fixed by Oct 23, the end of Sprint 24, v2\.4 on Nov 4 slips\./.test(tk.body) && tk.sprint === 'Sprint 24' && /Jira owns these\. They change only in Jira\./.test(tk.foot) && /^SSO for partners/.test(tk.where || '') && !tk.pri && /browse\/SSO-12/.test(tk.jira || ''), JSON.stringify(tk));
|
|
224
|
+
await four(q, 'ticket');
|
|
198
225
|
await q.click('#czViewer [data-cz-vw="back"]');
|
|
199
226
|
ok('B1 the ticket\'s Back goes to the initiative', await until(async () => (await vwTitle(q)) === 'SSO for partners'));
|
|
200
227
|
await q.keyboard.press('Escape');
|
|
@@ -248,10 +275,12 @@ const mk = (o) => BP.build(F.facts(o));
|
|
|
248
275
|
const y = await q.evaluate(() => { const r = document.querySelector('.bt-l[data-row="board:sso-partners"]'); return { st: r.querySelector('.cs').textContent, dot: r.querySelector('.sc.c .cz-dot').className, tone: r.querySelector('.cs').className }; });
|
|
249
276
|
ok('B1 a Deliver row whose tickets are all done waits on you: "Your sign-off · v2.4", in blue', y.st === 'Your sign-off · v2.4' && /\byou\b/.test(y.dot) && /m-info/.test(y.dot) && /s-you/.test(y.tone), JSON.stringify(y));
|
|
250
277
|
await q.click('.bt-l[data-row="board:sso-partners"] .bt-nm');
|
|
251
|
-
/* re-pointed (
|
|
252
|
-
const nb = await until(() => q.evaluate(
|
|
253
|
-
|
|
254
|
-
ok('B1
|
|
278
|
+
/* re-pointed (the one view, rule 9): what waits on you leads the summary card, with the sign-off as its one icon-only primary; the status moves to the meta line */
|
|
279
|
+
const nb = await until(() => q.evaluate(IVREAD));
|
|
280
|
+
const pri = await q.evaluate(() => [...document.querySelectorAll('#czViewer [data-iv-primary]')].map((b) => ({ act: b.dataset.ivPrimary, label: b.getAttribute('aria-label'), text: b.textContent.trim() })));
|
|
281
|
+
ok('B1 the panel puts the sign-off first, with the sign-off as the one icon-only primary', !!nb && nb.line === 'Waits on you' && /sign-off can wait|Every release ticket is done/.test(nb.why || '') && pri.length === 1 && pri[0].act === 'page' && pri[0].label === 'Your sign-off · v2.4' && pri[0].text === '', JSON.stringify([nb && [nb.line, nb.why], pri]));
|
|
282
|
+
await Promise.all([q.waitForURL(/[?&]ini=sso-partners/, { timeout: 8000 }).catch(() => {}), q.click('#czViewer [data-iv-primary]')]);
|
|
283
|
+
ok('B1 signing off goes to the initiative\'s page on Home, where the sign-off is', /\/premium\.html\?.*\bini=sso-partners/.test(q.url()), q.url());
|
|
255
284
|
await R.ctx.close();
|
|
256
285
|
}
|
|
257
286
|
|
|
@@ -300,12 +329,11 @@ const mk = (o) => BP.build(F.facts(o));
|
|
|
300
329
|
ok('B6 the timeline\'s first head opens "The longer the span, the higher the grouping", with the spans and the example themes', await until(() => p.evaluate(() => !document.querySelector('#popRules').hidden && /The longer the span, the higher the grouping/.test(document.querySelector('#popRules').textContent) && document.querySelectorAll('#popRules .bd-tbl4 .bd-tr').length === 5 && document.querySelectorAll('#popRules .bd-tbl3 .bd-tr').length === 5)));
|
|
301
330
|
await p.keyboard.press('Escape');
|
|
302
331
|
await p.click('#ibBody .tg-n[data-key="board:partner-rate-limits"]');
|
|
303
|
-
/* re-pointed (
|
|
304
|
-
*
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
ok('B6 an initiative on the timeline opens in the Viewer: the stage card names Plan over the eight steps, the Plan card draws the plan dates, no empty rows', !!tp && tp.t === 'Partner API rate limits' && tp.stage === 'Plan' && tp.seg === 8 && tp.cur === 2 && tp.right === '18% done · typed in by hand' && !!tp.marks && /^start:Sep 20(, 2026)?$/.test(tp.marks[0]) && tp.marks.some((x) => /^end:Nov 30(, 2026)? plan end$/.test(x)) && tp.marks.some((x) => x === 'today:Today') && !tp.marks.some((x) => /^jira/.test(x)) && tp.lg.join('|') === 'Your plan|Today' && !tp.secs.includes('Dates and trend') && !tp.secs.includes('Linked') && tp.w === 560, JSON.stringify(tp));
|
|
332
|
+
/* re-pointed (the one view, item 3): the timeline opens the same initiative in the Viewer as every other view. The stage card names the step
|
|
333
|
+
* over the eight; the old Plan card is the dates line (start, plan end, days left; no Jira date without a Jira forecast); the progress says
|
|
334
|
+
* where it comes from; Dates and trend is gone */
|
|
335
|
+
const tp = await until(() => p.evaluate(IVREAD).then((x) => (x && x.kind === 'Initiative' ? x : null)));
|
|
336
|
+
ok('B6 an initiative on the timeline opens in the Viewer: the stage card names Plan over the eight steps, the dates line draws the plan dates, no empty rows', !!tp && tp.t === 'Partner API rate limits' && tp.stage === 'Plan' && tp.bars.split('|').length === 8 && tp.bars.split('|').indexOf('now') === 2 && tp.right === '18% done · typed in by hand' && /^Sep 20(, 2026)? ?Nov 30(, 2026)? end · \d+ days left$/.test(tp.dates || '') && !/Jira:/.test(tp.dates) && !tp.folds.includes('Dates and trend'), JSON.stringify(tp && [tp.stage, tp.bars, tp.right, tp.dates, tp.folds]));
|
|
309
337
|
await p.click('#czViewer [data-cz-vw="more"]'); await sleep(80);
|
|
310
338
|
const tm = await p.evaluate(() => [...document.querySelectorAll('.cz-vw-menu [role="menuitem"]')].map((b) => b.textContent.trim()));
|
|
311
339
|
ok('B6 ⋯ holds the timeline panel\'s actions first (move, hold, cancel or archive; the plan dates), then Open in full, link and copy', tm[0] === 'Move, hold, cancel or archive' && tm[1] === 'Change the plan dates' && tm.includes('Open in full') && tm.includes('Copy link') && tm.includes('Copy as text'), JSON.stringify(tm));
|
|
@@ -419,20 +447,21 @@ const mk = (o) => BP.build(F.facts(o));
|
|
|
419
447
|
ok('T the output counts its parts from the records and names the next one', ub.prog === '2 of 6 parts' && ub.line === 'Next: Evidence' && pr.prog === '1 of 4 parts' && pr.line === 'Next: Timeline', JSON.stringify([ub, pr]));
|
|
420
448
|
ok('T what waits on you comes first, in blue', rf.st === 'Your verdict' && /s-you/.test(rf.stc), JSON.stringify(rf));
|
|
421
449
|
await q.click('.bt-l[data-row="board:self-serve-v2"] .bt-nm');
|
|
422
|
-
/* re-pointed (
|
|
423
|
-
const pk = await until(() => q.evaluate(() => { const v = document.querySelector('#czViewer'); if (!v || v.hidden || !v.querySelector('[data-czs-id="drafted"]')) return null; const sec = (id) => { const x = v.querySelector(`[data-czs-id="${id}"]`); return x ? { n: (x.querySelector('.czs-n') || {}).textContent || '', body: (x.querySelector('.czs-body') || {}).textContent.replace(/\s+/g, ' ').trim() } : null; }; return { meta: v.querySelector('.
|
|
424
|
-
ok('T
|
|
450
|
+
/* re-pointed (the one view): the same records, in the stage card's day clock, the ladder, Linked (a fold of the view) and the Board's own rows */
|
|
451
|
+
const pk = await until(() => q.evaluate(() => { const v = document.querySelector('#czViewer'); if (!v || v.hidden || !v.querySelector('[data-czs-id="drafted"]') || !v.querySelector('.iv')) return null; const sec = (id) => { const x = v.querySelector(`[data-czs-id="${id}"]`); return x ? { n: (x.querySelector('.czs-n') || {}).textContent || '', body: (x.querySelector('.czs-body') || {}).textContent.replace(/\s+/g, ' ').trim() } : null; }; return { meta: v.querySelector('.iv-meta').textContent, where: (v.querySelector('.iv-sch .iv-r') || {}).textContent, stage: (v.querySelector('.iv-sch b') || {}).textContent, stt: (v.querySelector('.iv-lad i.now') || {}).title, drafted: sec('drafted'), wt: sec('drift') }; }));
|
|
452
|
+
ok('T the stage card says where it stands and the day in the stage of the usual days; the ladder marks the stage now', !!pk && pk.stage === 'Build' && /day 18 of ~14$/.test(pk.where || '') && !/day|usually/.test(pk.meta) && pk.stt === 'Build · now', JSON.stringify(pk && [pk.stage, pk.where, pk.meta, pk.stt]));
|
|
425
453
|
if (process.env.PMOS_SHOTS) await q.screenshot({ path: path.join(process.env.PMOS_SHOTS, 'ini-build-1280.png') });
|
|
426
454
|
ok('T tickets drafted in PMOS and not in Jira are listed, and go to Jira only through your Commit', !!pk && pk.drafted.n === '1' && /^V\.4 ?Resend the invite after 48 hours ?not in Jira ?They go to Jira only through your Commit\.$/.test(pk.drafted.body), JSON.stringify(pk && pk.drafted));
|
|
427
455
|
ok('T a ticket pushed from an older PRD is flagged as PRD drift', !!pk && !!pk.wt && /^ONB-31 was pushed from an older PRD/.test(pk.wt.body), JSON.stringify(pk && pk.wt));
|
|
428
|
-
|
|
429
|
-
await q.
|
|
430
|
-
|
|
456
|
+
await q.click('#czViewer [data-iv-fold="linked"]');
|
|
457
|
+
const lk = await until(() => q.evaluate(() => { const c = [...document.querySelectorAll('#czViewer .iv-chips .iv-chip')]; return c.length ? { lk: c.map((e) => e.textContent.replace(/\s+/g, ' ').trim()), prd: (document.querySelector('#czViewer .iv-chips [data-iv-doc]') || {}).dataset, dep: (c.find((x) => /Waits on/.test(x.textContent)) || {}).title } : null; }));
|
|
458
|
+
ok('T the links are the record\'s own: PRD and rubric paths, the epic, and the dependency with where it stands', !!lk && /^PRD( v\d+)?$/.test(lk.lk[0]) && lk.lk.slice(1).join('|') === 'Rubric|Waits on SSO for partners|Epic ONB-1' && lk.prd && lk.prd.ivDoc === 'planning/prd/self-serve-v2.md' && /SSO for partners: Deliver/.test(lk.dep || ''), JSON.stringify(lk));
|
|
459
|
+
await q.click('#czViewer .iv-chips [data-iv-doc="planning/prd/self-serve-v2.md"]');
|
|
431
460
|
ok('T a linked document opens in the Viewer, as its text', await until(() => q.evaluate(() => { const v = document.querySelector('#czViewer'); return !!v && !v.hidden && /New teams stall at the invite step/.test(v.textContent); })));
|
|
432
461
|
await q.keyboard.press('Escape'); await sleep(150);
|
|
433
462
|
if (await vwOn(q)) { await q.keyboard.press('Escape'); await sleep(150); }
|
|
434
|
-
await q.click('.bt-l[data-row="board:sso-partners"] .bt-nm'); await until(() => vwOn(q, 'Initiative')); await q.click('#czViewer [data-
|
|
435
|
-
ok('T the ticket counts its subtasks from the Jira reading', await until(() => q.evaluate(() => { const x = document.querySelector('#czViewer [data-czs-id="sub"]'); if (!x) return false; const t = x.textContent.replace(/\s+/g, ' '); return (x.querySelector('.czs-n') || {}).textContent === '1 of 3' && /1
|
|
463
|
+
await q.click('.bt-l[data-row="board:sso-partners"] .bt-nm'); await until(() => vwOn(q, 'Initiative')); await q.click('#czViewer [data-iv-ticket="SSO-12"]');
|
|
464
|
+
ok('T the ticket counts its subtasks from the Jira reading (the Subtasks fold: "1 of 3 done")', await until(() => q.evaluate(() => { const x = document.querySelector('#czViewer [data-czs-id="sub"]'); if (!x) return false; const t = x.textContent.replace(/\s+/g, ' '); return (x.querySelector('.czs-n') || {}).textContent === '1 of 3 done' && (x.querySelector('.czs-body') ? /1 done, 2 open/.test(t) : true) && !document.querySelector('#czViewer .seg5'); })));
|
|
436
465
|
await q.keyboard.press('Escape'); await vwShut(q);
|
|
437
466
|
/* the long spans: themes from the trail, the Group control, milestones */
|
|
438
467
|
await view(q, 'time'); await spanTo(q, 'year');
|
|
@@ -77,8 +77,8 @@ const prop = (o) => Object.assign({ id: 'prop-a', state: 'proposed', prompt: 'ad
|
|
|
77
77
|
await page.route('**/api/docs?*', (r) => r.fulfill({ contentType: 'application/json', body: JSON.stringify({ ok: true, docs: [{ path: PATH, links: [] }] }) }));
|
|
78
78
|
await page.goto(BASE + '/premium.html?ini=self-serve-v2&ws=w1&theme=' + theme);
|
|
79
79
|
// the initiative's page in the Viewer (canvas HbC): its Documents' "Show all N" opens every document there
|
|
80
|
-
await until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-
|
|
81
|
-
await page.click('#czViewer [data-
|
|
80
|
+
await until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-iv-docs]')), 15000);
|
|
81
|
+
await page.click('#czViewer [data-iv-docs]');
|
|
82
82
|
await until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]')), 15000);
|
|
83
83
|
await page.click('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]'); // the PRD opens as a page
|
|
84
84
|
await until(() => page.evaluate(() => document.querySelector('.vwdoc .cf') && document.querySelector('.vwdoc .vwside')));
|
|
@@ -72,7 +72,7 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
72
72
|
const V = '#czViewer:not([hidden])';
|
|
73
73
|
// ready: the initiative's page is open in the Viewer (canvas HbC), its kind line from the board's row (kind · anchor) and, when the
|
|
74
74
|
// initiative reads, its card from the record (the ladder). Before the record reads, the page says it is reading.
|
|
75
|
-
async function ready(page, full = true) { return until(() => page.evaluate((f) => /·/.test((document.querySelector('#czViewer:not([hidden]) .cz-vw-kind') || {}).textContent || '') && (!f || (!!document.querySelector('#czViewer .
|
|
75
|
+
async function ready(page, full = true) { return until(() => page.evaluate((f) => /·/.test((document.querySelector('#czViewer:not([hidden]) .cz-vw-kind') || {}).textContent || '') && (!f || (!!document.querySelector('#czViewer .iv-sc') && !!((document.querySelector('#czViewer .iv-sch > b') || {}).textContent || '').trim())), full), 30000); }
|
|
76
76
|
const txt = (p, s) => p.evaluate((q) => ((document.querySelector(q) || {}).textContent || '').replace(/\s+/g, ' ').trim(), s);
|
|
77
77
|
// the Overview opens on Tasks; a phone keeps the Tasks, Documents and Stage switch, and in shell A on a desktop the other views sit under ⋯ (XvATasks); view names the one to show
|
|
78
78
|
const LABEL = { tasks: 'Tasks', docs: 'Documents', stage: 'Stage' };
|
|
@@ -89,14 +89,14 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
89
89
|
}
|
|
90
90
|
const s = await until(() => p.evaluate((v) => { const o = document.querySelector(v); if (!o) return null; if (o.querySelector('[data-hi-v="page"]')) return 'ok'; return /could not be read/.test(o.textContent) ? 'err' : null; }, V), 30000);
|
|
91
91
|
if (s !== 'ok') return !!s;
|
|
92
|
-
await p.click(
|
|
92
|
+
await p.click('#czViewer [data-cz-vw="more"]').then(() => p.click('.cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("All tasks"))'));
|
|
93
93
|
await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="tasks"]'), V));
|
|
94
94
|
if (view && view !== 'tasks') await show(p, view);
|
|
95
95
|
return true; };
|
|
96
96
|
const writes = (X) => X.posts.filter((x) => WRITES.test(x.path));
|
|
97
97
|
|
|
98
98
|
const A = await open(), p = A.page;
|
|
99
|
-
ok('0 Home opens the initiative\'s page in the Viewer; the list stays the list, with its row selected (HbCDesk)', A.up && await p.evaluate(() => new URLSearchParams(location.search).get('ini') === 'self-serve-v2' && !!document.querySelector('#czViewer .
|
|
99
|
+
ok('0 Home opens the initiative\'s page in the Viewer; the list stays the list, with its row selected (HbCDesk)', A.up && await p.evaluate(() => new URLSearchParams(location.search).get('ini') === 'self-serve-v2' && !!document.querySelector('#czViewer .iv-sc') && !document.querySelector('#hmList .iv-sc') && document.querySelector('#hmList [data-hm-sel="i:self-serve-v2"]').getAttribute('aria-current') === 'true'));
|
|
100
100
|
|
|
101
101
|
/* I1 place */
|
|
102
102
|
{
|
|
@@ -119,23 +119,20 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
119
119
|
ok('I1 Menu > Home closes the page and clears the selection, without a reload', await until(() => p.evaluate(() => window.__noReload === 1 && !document.querySelector('#czViewer:not([hidden])') && !document.querySelector('#hmList .sel, #hmList [aria-current="true"]') && /^Message Claude$/.test(document.querySelector('#hmIn').placeholder))));
|
|
120
120
|
await p.goto(BASE + '/premium.html?ini=self-serve-v2&ws=w1&board=w1&theme=light'); await ready(p);
|
|
121
121
|
|
|
122
|
-
/* I3 header
|
|
123
|
-
const card = await p.evaluate(() => { const c = document.querySelector('#czViewer .
|
|
124
|
-
return { kind: d('#czViewer .cz-vw-kind'), title: d('#czVwTitle'), stage: q('.
|
|
122
|
+
/* I3 header and the ONE view (batch 6 items 1 and 3: the Board's panel draws the same; stage-card-test.js holds the stage card's behaviour) */
|
|
123
|
+
const card = await p.evaluate(() => { const c = document.querySelector('#czViewer .iv-sc'), iv = document.querySelector('#czViewer .iv'); const q = (s, r = c) => ((r.querySelector(s) || {}).textContent || '').replace(/\s+/g, ' ').trim(), d = (s) => ((document.querySelector(s) || {}).textContent || '').trim();
|
|
124
|
+
return { kind: d('#czViewer .cz-vw-kind'), title: d('#czVwTitle'), stage: q('.iv-sch > b'), where: q('.iv-sch .iv-r'), bars: c.querySelectorAll('.iv-lad i').length, now: c.querySelectorAll('.iv-lad i.now').length, tail: q('.iv-nx'), ms: !!c.querySelector('.iv-nx .iv-nd.ms'),
|
|
125
|
+
pri: iv.querySelectorAll('[data-iv-primary]').length, cta: !!iv.querySelector('[data-hm-cta]'), tasks: q('.iv-th', iv), empty: !!iv.querySelector('.iv-empty'), secs: [...iv.querySelectorAll('.iv-ws b')].map((b) => b.textContent), meta: q('.iv-meta', iv) }; });
|
|
125
126
|
ok('I3 the page\'s header names the initiative, its workflow and its anchor (D99)', card.title === 'Self-serve onboarding v2' && /^Product feature · \S/.test(card.kind), JSON.stringify(card));
|
|
126
127
|
ok('I3 the card shows the stage the workflow engine derives, with one bar a step and the current one marked', card.stage === 'Build' && card.bars === 8 && card.now === 1, JSON.stringify(card));
|
|
127
|
-
ok('I1 the
|
|
128
|
-
ok('I1 the card ends on the next stage
|
|
129
|
-
|
|
130
|
-
await p.click('.hm-card [data-hm-done]');
|
|
131
|
-
ok('I1 the done items open from their summary row', await until(() => p.evaluate(() => document.querySelector('.hm-card [data-hm-done]').getAttribute('aria-expanded') === 'true')));
|
|
132
|
-
}
|
|
133
|
-
ok('I3 Deliver is a milestone: the card\'s last node carries the ◆ mark before it (Agreed design AgInitAgents)', await p.evaluate(() => !!document.querySelector('.hm-card .cz-sli.tail .cz-ms')));
|
|
128
|
+
ok('I1 the summary leads with at most one primary; the card holds no step list; Tasks is the WBS by stage', card.pri <= 1 && !card.cta && /^Tasks/.test(card.tasks) && (card.secs.length > 0 || card.empty) && !/pull request|builder agent/i.test(card.secs.join(' ')), JSON.stringify(card));
|
|
129
|
+
ok('I1 the card ends on the next stage', /^Deliver/.test(card.tail), JSON.stringify(card));
|
|
130
|
+
ok('I3 Deliver is a milestone: the next stage carries the ◆ mark (Agreed design AgInitAgents)', card.ms, JSON.stringify(card));
|
|
134
131
|
ok('I1 the card wrote nothing on its own', writes(A).length === 0, JSON.stringify(writes(A)));
|
|
135
132
|
|
|
136
|
-
/* I7 documents: the page's Documents
|
|
137
|
-
ok('I7 the page holds Documents with its count
|
|
138
|
-
await p.click(`${V} [data-
|
|
133
|
+
/* I7 documents: the page's Documents is a fold row with the count; a press drills into them all (OvIniA) */
|
|
134
|
+
ok('I7 the page holds Documents with its count; the list holds no Files or documents group', await until(() => p.evaluate((v) => { const g = document.querySelector(v + ' [data-iv-docs]'); return !!g && /^Documents ?\d+$/.test(g.textContent.replace(/\s+/g, ' ').trim()) && !document.querySelector('#hmList section.hm-g[aria-label="Files"], #hmList [data-iv-docs]'); }, V)));
|
|
135
|
+
await p.click(`${V} [data-iv-docs]`);
|
|
139
136
|
await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-ov-open="planning/prd/self-serve-v2-prd.md"]'), V), 15000);
|
|
140
137
|
await p.click(`${V} [data-ov-open="planning/prd/self-serve-v2-prd.md"]`);
|
|
141
138
|
ok('I7 a file opens as its page in the Viewer, not a dialog', await until(() => p.evaluate((v) => !!document.querySelector(v + ' .obody.vw[data-vw="doc:planning/prd/self-serve-v2-prd.md"]') && !(document.querySelector('#dlg') && !!document.querySelector('#dlg.on')), V), 15000));
|
|
@@ -143,14 +140,14 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
143
140
|
/* I4 the Overview */
|
|
144
141
|
const i4 = await overview(p, null) && await p.evaluate((v) => /Tasks/.test(document.querySelector('#czViewer .cz-vw-kind').textContent) && !document.querySelector(v + ' [data-hi-view]') && !document.querySelector(v + ' .hx-wait'), V);
|
|
145
142
|
const i4m = await moreLabels(p);
|
|
146
|
-
ok('I4
|
|
143
|
+
ok('I4 All tasks under ⋯ opens the initiative\'s Tasks, with Documents and Stage under ⋯ on a desktop (XvATasks), and no Waiting for design marker', i4 && ['Group tasks by', 'Documents', 'Stage', 'Open the full record'].every((l) => i4m.includes(l)), JSON.stringify(i4m));
|
|
147
144
|
const tk = await p.evaluate((v) => { const o = document.querySelector(v); return { tasks: [...o.querySelectorAll('[data-ov-tkrow]')].map((r) => r.dataset.ovTkrow).sort(), checks: [...o.querySelectorAll('button[data-hi-chk]')].map((b) => b.dataset.hiChk).sort() }; }, V);
|
|
148
145
|
await p.click('#czViewer [data-cz-vw="back"]');
|
|
149
146
|
ok('I4 ← from Tasks comes back to the page (HbCDrill)', await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="page"]'), V)));
|
|
150
|
-
ok('I4 the card has no Overview tile: the chat box on the page talks about the initiative (stage card D)', await p.evaluate((v) => !document.querySelector(v + ' .
|
|
147
|
+
ok('I4 the card has no Overview tile: the chat box on the page talks about the initiative (stage card D)', await p.evaluate((v) => !document.querySelector(v + ' .iv [data-hm-ov]') && /^Message Claude about Self-serve onboarding v2/.test(document.querySelector('#hmIn').placeholder), V));
|
|
151
148
|
const pm = await moreLabels(p);
|
|
152
|
-
ok('I4 the page\'s ⋯ holds the stage switch, the stakeholder, the program, the Board and the record, then hold and cancel last (HbCMore)', ['Moves on by itself', 'Add a stakeholder', 'Turn into a program', 'Open on the Board', 'The record', 'Put on hold', 'Cancel the initiative'].every((l) => pm.includes(l)) && pm[pm.length - 1] === 'Cancel the initiative', JSON.stringify(pm));
|
|
153
|
-
await p.click(
|
|
149
|
+
ok('I4 the page\'s ⋯ holds the stage switch, the stakeholder, the program, the Board and the record, then hold and cancel last (HbCMore)', ['All tasks', 'Moves on by itself', 'Add a stakeholder', 'Turn into a program', 'Open on the Board', 'The record', 'Put on hold', 'Cancel the initiative'].every((l) => pm.includes(l)) && pm[pm.length - 1] === 'Cancel the initiative', JSON.stringify(pm));
|
|
150
|
+
await p.click('#czViewer [data-cz-vw="more"]').then(() => p.click('.cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("All tasks"))'));
|
|
154
151
|
await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="tasks"]'), V));
|
|
155
152
|
await show(p, 'stage');
|
|
156
153
|
const st = await p.evaluate((v) => { const o = document.querySelector(v); return { moves: [...o.querySelectorAll('[data-ov-move]')].map((b) => b.dataset.ovMove), cur: (o.querySelector('[data-ov-move][aria-pressed="true"]') || {}).textContent, life: [...o.querySelectorAll('[data-ov-life]')].map((b) => b.dataset.ovLife) }; }, V);
|
|
@@ -264,8 +261,8 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
264
261
|
const tok = (v) => { const x = document.createElement('i'); x.style.setProperty('background-color', 'var(' + v + ')'); document.body.appendChild(x); const c = getComputedStyle(x).backgroundColor; x.remove(); return c; };
|
|
265
262
|
const cs = (s) => { const e = document.querySelector(s); return e ? getComputedStyle(e) : null; };
|
|
266
263
|
const fab = document.querySelector('#czFab'), fr = fab && fab.getBoundingClientRect();
|
|
267
|
-
const c = document.querySelector('.
|
|
268
|
-
return { font: cs('body').fontFamily, cta: (cs('
|
|
264
|
+
const c = document.querySelector('#czViewer .iv-sc').getBoundingClientRect();
|
|
265
|
+
return { font: cs('body').fontFamily, cta: (cs('#czViewer .iv-go') || {}).backgroundColor, ctaAlt: !document.querySelector('#czViewer .iv-go'), solid: tok('--cz-solid'), blue: tok('--cz-blue'), well: tok('--cz-well'), card: tok('--cz-card'), box: cs('#czViewer .iv-sc').backgroundColor, rad: parseFloat(cs('#czViewer .iv-sc').borderTopLeftRadius), fab: fr ? [Math.round(fr.width), Math.round(fr.height)] : null, over: document.documentElement.scrollWidth - innerWidth, cardW: Math.round(c.width) };
|
|
269
266
|
});
|
|
270
267
|
const d = [];
|
|
271
268
|
if (!/^Nunito/.test(g.font)) d.push('font ' + g.font);
|