create-pmos 0.406.0 → 0.407.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 +13 -18
- package/payload/KIT-VERSION +1 -1
- 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/workspace/briefing-premium-adddoc-test.js +4 -3
- package/workspace/briefing-premium-doc-edit-test.js +3 -5
- package/workspace/briefing-premium-initiative-test.js +46 -27
- package/workspace/changelog.json +12 -0
- package/workspace/guide/home.md +10 -4
- package/workspace/package-lock.json +2 -2
- package/workspace/package.json +1 -1
- package/workspace/premium-board-actions-test.js +2 -2
- package/workspace/premium-core-doc-issue-test.js +4 -1
- package/workspace/premium-vw-backlog-test.js +3 -3
- package/workspace/premium-vw-doc-test.js +4 -6
- package/workspace/premium-vw-item-test.js +1 -1
- package/workspace/premium-vw-jira-test.js +2 -2
- package/workspace/public/pm/bd-prog-panel.js +4 -3
- package/workspace/public/pm/cozy-home.css +5 -0
- package/workspace/public/pm/cozy-nav.js +4 -0
- package/workspace/public/pm/cozy-today.css +2 -0
- package/workspace/public/pm/cozy-viewer.js +24 -8
- package/workspace/public/pm/home-app.js +103 -59
- package/workspace/public/pm/home-ini.css +14 -0
- package/workspace/public/pm/home-ini.js +93 -81
- package/workspace/public/pm/home-today.js +7 -5
- package/workspace/public/premium.html +1 -1
- package/workspace/tk-tasks-test.js +2 -3
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-pmos",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.407.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,18 @@
|
|
|
32
32
|
"audit"
|
|
33
33
|
],
|
|
34
34
|
"pmosChanges": [
|
|
35
|
+
{
|
|
36
|
+
"v": "0.407.0",
|
|
37
|
+
"at": "2026-10-24T11:09:31.378Z",
|
|
38
|
+
"f": 2,
|
|
39
|
+
"prs": [
|
|
40
|
+
{
|
|
41
|
+
"n": 1037,
|
|
42
|
+
"t": "The list stays put; an initiative, program or product opens as a page in the Viewer",
|
|
43
|
+
"s": "The list stays put; an initiative, program or product opens as a page in the Viewer"
|
|
44
|
+
}
|
|
45
|
+
]
|
|
46
|
+
},
|
|
35
47
|
{
|
|
36
48
|
"v": "0.406.0",
|
|
37
49
|
"at": "2026-10-24T10:26:17.544Z",
|
|
@@ -269,23 +281,6 @@
|
|
|
269
281
|
"s": "Report templates reschedule and delete, drafts discard, issued reports stay"
|
|
270
282
|
}
|
|
271
283
|
]
|
|
272
|
-
},
|
|
273
|
-
{
|
|
274
|
-
"v": "0.387.0",
|
|
275
|
-
"at": "2026-10-21T15:59:17.829Z",
|
|
276
|
-
"f": 2,
|
|
277
|
-
"prs": [
|
|
278
|
-
{
|
|
279
|
-
"n": 998,
|
|
280
|
-
"t": "Remove a sample from a report's design",
|
|
281
|
-
"s": "Remove a sample from a report's design"
|
|
282
|
-
},
|
|
283
|
-
{
|
|
284
|
-
"n": 999,
|
|
285
|
-
"t": "Popup leads after each refresh, and a derived document's PRD section",
|
|
286
|
-
"s": "Popup leads after each refresh, and a derived document's PRD section"
|
|
287
|
-
}
|
|
288
|
-
]
|
|
289
284
|
}
|
|
290
285
|
]
|
|
291
286
|
}
|
package/payload/KIT-VERSION
CHANGED
|
@@ -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-24T11:09:28Z"}
|
|
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-24T11:09:28Z"}
|
|
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-24T11:09:28Z"}
|
|
6
6
|
status: stable
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -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') {
|
|
62
|
+
if (up && kind === 'initiative') { await page.click('#czViewer .hi-pgh [data-hi-addtask]'); /* 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
|
};
|
|
@@ -68,7 +68,8 @@ const PAGES = {
|
|
|
68
68
|
// the Overview opens on Tasks; Add a document is on its Documents view (premium-uncovered-features, canvas InDocs)
|
|
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-hi-open="docs"]')) await pg.click('#czViewer [data-hi-open="docs"]'); else if (await pg.$('#czViewer [data-hi-view="docs"]')) await pg.click('#czViewer [data-hi-view="docs"]'); else await viaMore(pg, 'Documents'); })(page); }
|
|
72
73
|
|
|
73
74
|
/* the Board (premium-uncovered-features, BdDocs): the Documents tab is a table with an Add a document form in the side panel;
|
|
74
75
|
the same route, the same fields, the same refusals */
|
|
@@ -145,7 +146,7 @@ const PAGES = {
|
|
|
145
146
|
ok(`${kind} A3 nothing else was posted`, A.posts.every((x) => x.path === '/api/custom-docs/add'));
|
|
146
147
|
ok(`${kind} A1 the form closes, the initiative is read again and its Overview comes back`, await until(() => A.calls() > calls0) && await until(() => p.evaluate(() => !document.querySelector('#czViewer #adT') && !!document.querySelector('#czViewer [data-hi-v="docs"]'))));
|
|
147
148
|
A.setCustom(CUSTOM.map((d) => Object.assign({}, d, { scope: P.scope }))); await p.reload();
|
|
148
|
-
await until(() => p.evaluate((s) => !!document.querySelector(s), P.ready), 20000); await p.click(P.ready); await docsView(p);
|
|
149
|
+
await until(() => p.evaluate((s) => !!document.querySelector(s), P.ready), 20000); if (!ini) await p.click(P.ready); await docsView(p);
|
|
149
150
|
await until(() => p.evaluate(() => !!document.querySelector('#czViewer [data-ov-doc="custom:cd-2"]')), 20000);
|
|
150
151
|
// a row: the title, its state pill, then what it is (when, who writes it, where it lives) and the link as text (InDocs)
|
|
151
152
|
// shell A (XvADocs): a row is one press, its title then one quiet line (when, who writes it, the state) and the link as text
|
|
@@ -76,11 +76,9 @@ const prop = (o) => Object.assign({ id: 'prop-a', state: 'proposed', prompt: 'ad
|
|
|
76
76
|
await page.route('**/api/docs/library*', (r) => r.fulfill({ contentType: 'application/json', body: JSON.stringify({ ok: true, kinds: [], files: [{ path: PATH, title: 'Self-serve PRD' }], edges: [] }) }));
|
|
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
|
-
|
|
80
|
-
await until(() => page.evaluate(() => !!document.querySelector('#
|
|
81
|
-
|
|
82
|
-
// the initiative's Core documents group (in place of the Files group, premium-uncovered-features InDocs) opens every document in the Viewer
|
|
83
|
-
await page.click('#hmList [data-hi-open="docs"]');
|
|
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-hi-open="docs"]')), 15000);
|
|
81
|
+
await page.click('#czViewer [data-hi-open="docs"]');
|
|
84
82
|
await until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]')), 15000);
|
|
85
83
|
await page.click('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]'); // the PRD opens as a page
|
|
86
84
|
await until(() => page.evaluate(() => document.querySelector('.vwdoc .cf') && document.querySelector('.vwdoc .vwside')));
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
'use strict';
|
|
3
3
|
/* briefing-premium-initiative-test.js — the initiative (initiative briefing-premium-initiative; planning/prd/briefing-premium-initiative-prd.md I1 to I12),
|
|
4
|
-
* re-pointed for premium-agreed-design
|
|
5
|
-
* /premium
|
|
6
|
-
* the
|
|
4
|
+
* re-pointed for premium-agreed-design and again for the Home list fix (canvas HbC): the initiative is a page in Home's Viewer
|
|
5
|
+
* (/premium.html?ini=<id>), the list stays the list, and the old /premium-initiative.html?id= link lands there. The page holds the stage card,
|
|
6
|
+
* three tasks and the documents that need a look; its + and "Show all N" drill into Tasks, Documents and Stage, with ← back to the page. What moved elsewhere has its own suite:
|
|
7
7
|
* a document's page premium-vw-doc-test.js, Add a document briefing-premium-adddoc-test.js, Issue it premium-core-doc-issue-test.js, the record and
|
|
8
8
|
* task views premium-vw-item-test.js, the Jira views premium-vw-jira-test.js. The old page's List / By stage / Timeline views, the document filter
|
|
9
9
|
* and search and the document sheet's tabs have no place in the Agreed design and are not drawn.
|
|
@@ -70,8 +70,9 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
70
70
|
return { ctx, page, errors, posts, up, calls: () => calls, setModel: (m) => { current = m; }, set: (a) => { answer = a; } };
|
|
71
71
|
};
|
|
72
72
|
const V = '#czViewer:not([hidden])';
|
|
73
|
-
// ready: the
|
|
74
|
-
|
|
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
|
+
// 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 .hm-card [data-hm-ov]') && !!((document.querySelector('#czViewer .hm-card .hm-lad b') || {}).textContent || '').trim())), full), 30000); }
|
|
75
76
|
const txt = (p, s) => p.evaluate((q) => ((document.querySelector(q) || {}).textContent || '').replace(/\s+/g, ' ').trim(), s);
|
|
76
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
|
|
77
78
|
const LABEL = { tasks: 'Tasks', docs: 'Documents', stage: 'Stage' };
|
|
@@ -80,16 +81,22 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
80
81
|
else { await p.click('#czViewer [data-cz-vw="more"]'); await until(() => p.evaluate(() => !!document.querySelector('#czViewer .cz-vw-menu'))); await p.click(`#czViewer .cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("${LABEL[view]}"))`); }
|
|
81
82
|
return until(() => p.evaluate((a) => !!document.querySelector(a[0] + ` [data-hi-v="${a[1]}"]`), [V, view])); };
|
|
82
83
|
const moreLabels = (p) => p.evaluate(async () => { const b = document.querySelector('#czViewer [data-cz-vw="more"]'); if (!b) return []; b.click(); await new Promise((r) => setTimeout(r, 50)); const m = document.querySelector('#czViewer .cz-vw-menu'); const out = m ? [...m.querySelectorAll('[role="menuitem"] span:first-of-type')].map((x) => x.textContent) : []; b.click(); return out; });
|
|
84
|
+
// the initiative's page first (its list row opens it again when something else is shown), then Tasks from the page's + (HbCDrill)
|
|
83
85
|
const overview = async (p, view = 'stage') => {
|
|
84
|
-
if (!(await p.evaluate(() =>
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
86
|
+
if (!(await p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="page"]'), V))) {
|
|
87
|
+
if (!(await p.evaluate(() => { const b = document.querySelector('#hmList [data-hm-sel="i:self-serve-v2"]'); return !!b && !!b.offsetParent; }))) await p.click('#hmNeeds');
|
|
88
|
+
await p.click('#hmList [data-hm-sel="i:self-serve-v2"]');
|
|
89
|
+
}
|
|
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
|
+
if (s !== 'ok') return !!s;
|
|
92
|
+
await p.click(`${V} .hi-pgh [data-hi-addtask]`);
|
|
93
|
+
await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="tasks"]'), V));
|
|
94
|
+
if (view && view !== 'tasks') await show(p, view);
|
|
95
|
+
return true; };
|
|
89
96
|
const writes = (X) => X.posts.filter((x) => WRITES.test(x.path));
|
|
90
97
|
|
|
91
98
|
const A = await open(), p = A.page;
|
|
92
|
-
ok('0 Home
|
|
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 .hm-card') && !document.querySelector('#hmList .hm-card') && document.querySelector('#hmList [data-hm-sel="i:self-serve-v2"]').getAttribute('aria-current') === 'true'));
|
|
93
100
|
|
|
94
101
|
/* I1 place */
|
|
95
102
|
{
|
|
@@ -99,20 +106,23 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
99
106
|
await R.ctx.close();
|
|
100
107
|
}
|
|
101
108
|
ok('I1 the console is not linked from Home', await p.evaluate(() => ![...document.querySelectorAll('a[href]')].some((a) => /console(\.html)?/.test(a.getAttribute('href')))));
|
|
102
|
-
await p.
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
await p.
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
await p.
|
|
109
|
-
|
|
109
|
+
const sib = await p.evaluate(() => [...document.querySelectorAll('#hmList [data-hm-sel^="i:"]')].map((b) => b.dataset.hmSel));
|
|
110
|
+
ok('I1 the list keeps the board\'s other initiatives beside the open one', ['i:self-serve-v2', 'i:partner-rate-limits'].every((k) => sib.includes(k)), JSON.stringify(sib));
|
|
111
|
+
await p.click('#hmList [data-hm-sel="i:partner-rate-limits"]');
|
|
112
|
+
{ const u = new URL(p.url()); ok('I1 another initiative\'s name opens its page on the same board', await until(() => p.evaluate(() => new URLSearchParams(location.search).get('ini') === 'partner-rate-limits' && document.querySelector('#czVwTitle').textContent.trim() === 'Partner API rate limits')) && u.searchParams.get('ws') === 'w1' && u.searchParams.get('board') === 'w1', p.url()); }
|
|
113
|
+
await p.goBack();
|
|
114
|
+
ok('I1 the browser\'s Back closes the page and leads back to all work', await until(() => p.evaluate(() => !new URLSearchParams(location.search).get('ini') && !document.querySelector('#czViewer:not([hidden])') && !document.querySelector('#hmList [aria-current="true"][data-hm-sel^="i:"]'))), p.url());
|
|
115
|
+
await p.evaluate(() => { window.__noReload = 1; });
|
|
116
|
+
await p.click('#hmList [data-hm-prodopen]');
|
|
117
|
+
ok('I1 a product heading\'s name opens the product in the Viewer with its goals and this week, and its own chat (HbCProduct)', await until(() => p.evaluate(() => { const v = document.querySelector('#czViewer:not([hidden])'); return !!v && /Product/.test((v.querySelector('.cz-vw-kind') || {}).textContent || '') && !!v.querySelector('section.hi-pg[aria-label="Goals"]') && !!v.querySelector('[data-hp="update"]') && /^Message Claude about /.test(document.querySelector('#hmIn').placeholder) && !!document.querySelector('#hmList .hv-prg.sel [data-hm-prodopen]'); })));
|
|
118
|
+
await p.click('#czFab'); await p.click('#czMenu a[aria-current="page"]');
|
|
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))));
|
|
110
120
|
await p.goto(BASE + '/premium.html?ini=self-serve-v2&ws=w1&board=w1&theme=light'); await ready(p);
|
|
111
121
|
|
|
112
122
|
/* I3 header: the card */
|
|
113
|
-
const card = await p.evaluate(() => { const c = document.querySelector('.hm-card'); const q = (s) => ((c.querySelector(s) || {}).textContent || '').replace(/\s+/g, ' ').trim();
|
|
114
|
-
return { kind:
|
|
115
|
-
ok('I3 the
|
|
123
|
+
const card = await p.evaluate(() => { const c = document.querySelector('#czViewer .hm-card'); const q = (s) => ((c.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'), turn: q('.hm-turn'), stage: q('.hm-br .st'), lad: q('.hm-lad'), cur: q('.hm-lad b'), bars: c.querySelectorAll('.hm-bars i').length, now: c.querySelectorAll('.hm-bars i.now').length, ckh: q('.hm-ckh'), items: [...c.querySelectorAll('.hm-it')].map((x) => x.textContent.replace(/\s+/g, ' ').trim()), then: q('.hm-then'), time: q('.hm-time'), cta: q('[data-hm-cta]') }; });
|
|
125
|
+
ok('I3 the page\'s header names the initiative, its lane and its anchor', card.title === 'Self-serve onboarding v2' && /^Feature · \S/.test(card.kind), JSON.stringify(card));
|
|
116
126
|
ok('I3 the card shows the stage the workflow engine derives, with the ladder\'s current step and one bar a step', /Build/.test(card.stage + card.cur) && card.bars === 8 && card.now === 1, JSON.stringify(card));
|
|
117
127
|
ok('I1 the card lists what finishes the step, says whose turn it is, and has one CTA', card.items.length > 0 && !!card.turn && !!card.cta && !/pull request|builder agent/i.test(card.items.join(' ')), JSON.stringify(card));
|
|
118
128
|
ok('I1 the card has the payoff line and the time in the stage when the record has them', (!card.then || /^Then:/.test(card.then)) && (card.then || card.time), JSON.stringify(card));
|
|
@@ -128,9 +138,9 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
128
138
|
ok('I3 it unfolds again', await until(() => p.evaluate(() => document.querySelector('.hm-card [data-hm-cfold]').getAttribute('aria-expanded') === 'true' && document.querySelectorAll('.hm-card .hm-it').length > 0)));
|
|
129
139
|
ok('I1 the card wrote nothing on its own', writes(A).length === 0, JSON.stringify(writes(A)));
|
|
130
140
|
|
|
131
|
-
/* I7 documents: the
|
|
132
|
-
ok('I7 the
|
|
133
|
-
await p.click(
|
|
141
|
+
/* I7 documents: the page's Documents shows the ones that need a look and "Show all N" drills into them all (HbCDesk, InDocs) */
|
|
142
|
+
ok('I7 the page holds Documents with its count and a Show all line; the list holds no Files or documents group', await until(() => p.evaluate((v) => { const g = document.querySelector(v + ' section.hi-pg[aria-label="Documents"]'); return !!g && /Documents/.test(g.textContent) && /^Show all \d+/.test((g.querySelector('[data-hi-open="docs"]') || {}).textContent || '') && !document.querySelector('#hmList section.hm-g[aria-label="Files"], #hmList [data-hi-open]'); }, V)));
|
|
143
|
+
await p.click(`${V} [data-hi-open="docs"]`);
|
|
134
144
|
await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-ov-open="planning/prd/self-serve-v2-prd.md"]'), V), 15000);
|
|
135
145
|
await p.click(`${V} [data-ov-open="planning/prd/self-serve-v2-prd.md"]`);
|
|
136
146
|
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));
|
|
@@ -138,8 +148,16 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
138
148
|
/* I4 the Overview */
|
|
139
149
|
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);
|
|
140
150
|
const i4m = await moreLabels(p);
|
|
141
|
-
ok('I4 the
|
|
151
|
+
ok('I4 the page\'s + 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));
|
|
142
152
|
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);
|
|
153
|
+
await p.click('#czViewer [data-cz-vw="back"]');
|
|
154
|
+
ok('I4 ← from Tasks comes back to the page (HbCDrill)', await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="page"]'), V)));
|
|
155
|
+
await p.click(`${V} .hm-card [data-hm-ov]`);
|
|
156
|
+
ok('I4 Overview with Claude types the ask into the chat box and sends nothing', await until(() => p.evaluate(() => /^Give me an overview of Self-serve onboarding v2/.test(document.querySelector('#hmIn').value))));
|
|
157
|
+
const pm = await moreLabels(p);
|
|
158
|
+
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));
|
|
159
|
+
await p.click(`${V} .hi-pgh [data-hi-addtask]`);
|
|
160
|
+
await until(() => p.evaluate((v) => !!document.querySelector(v + ' [data-hi-v="tasks"]'), V));
|
|
143
161
|
await show(p, 'stage');
|
|
144
162
|
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);
|
|
145
163
|
await show(p, 'docs');
|
|
@@ -260,7 +278,8 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
260
278
|
if (!g.ctaAlt && ![g.solid, g.blue].includes(g.cta)) d.push('cta ' + g.cta + ' want ' + g.solid + ' or ' + g.blue);
|
|
261
279
|
if (![g.well, g.card].includes(g.box) && !/rgba/.test(g.box)) d.push('card box ' + g.box);
|
|
262
280
|
if (g.rad < 12) d.push('card radius ' + g.rad);
|
|
263
|
-
|
|
281
|
+
// on a phone the initiative's page is the Viewer, full screen over the list: the floating menu waits under it (HbCPhone)
|
|
282
|
+
if (w > 760 && (!g.fab || g.fab[0] !== 56 || g.fab[1] !== 56)) d.push('fab ' + JSON.stringify(g.fab));
|
|
264
283
|
if (g.over > 0) d.push('sideways scroll ' + g.over);
|
|
265
284
|
ok(`I12 the initiative follows the Agreed design at ${w} px, ${th}: Nunito, the cozy card, the CTA, the floating menu`, d.length === 0, d.join(' ; '));
|
|
266
285
|
ok(`I12 no page error at ${w} px, ${th}`, R.errors.length === 0, R.errors.join(' | '));
|
package/workspace/changelog.json
CHANGED
|
@@ -1,4 +1,16 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"v": "0.407.0",
|
|
4
|
+
"at": "2026-10-24T11:09:31.378Z",
|
|
5
|
+
"f": 2,
|
|
6
|
+
"prs": [
|
|
7
|
+
{
|
|
8
|
+
"n": 1037,
|
|
9
|
+
"t": "The list stays put; an initiative, program or product opens as a page in the Viewer",
|
|
10
|
+
"s": "The list stays put; an initiative, program or product opens as a page in the Viewer"
|
|
11
|
+
}
|
|
12
|
+
]
|
|
13
|
+
},
|
|
2
14
|
{
|
|
3
15
|
"v": "0.406.0",
|
|
4
16
|
"at": "2026-10-24T10:26:17.544Z",
|
package/workspace/guide/home.md
CHANGED
|
@@ -13,8 +13,8 @@ Home is the page at `/premium.html`. It follows the Agreed design and the "Uncov
|
|
|
13
13
|
|
|
14
14
|
- The top line has **Good morning**, the product picker, the filter icon (on a desktop) and **New**. The line under it says how many items are yours, for example "4 are yours".
|
|
15
15
|
- Press **Good morning** to open **Your day**. Your day shows the date, the meetings of the day, **Your move** (the items that wait on you, with their count) and **This week** (the Weekly review). Your move shows only in Your day, not in the list.
|
|
16
|
-
- A **program** comes first, above the products. Its header shows the program icon, its name, the next milestone (◆ and the date) and how many of its initiatives are ready for that milestone. Inside it, the program's own tasks come first, then its initiatives under a small heading for each product. Each initiative shows once. Press the program's name to open the program
|
|
17
|
-
- Then the list is grouped by **product**. A product header shows a tile with the product's short name, the product name, one dot for each goal (green on track, amber off track) and a chevron. You set the short name in Settings.
|
|
16
|
+
- A **program** comes first, above the products. Its header shows the program icon, its name, the next milestone (◆ and the date) and how many of its initiatives are ready for that milestone. Inside it, the program's own tasks come first, then its initiatives under a small heading for each product. Each initiative shows once. Press the program's name to open the program in the Viewer. The chat then talks about the program. Press the chevron to close or open the group.
|
|
17
|
+
- Then the list is grouped by **product**. A product header shows a tile with the product's short name, the product name, one dot for each goal (green on track, amber off track) and a chevron. You set the short name in Settings. Press the product's name to open the product in the Viewer, with its goals and this week's update and metrics review. The chat then talks about the product.
|
|
18
18
|
- Each row is one line. A dot is a session: blue when it waits on you, a ring while it runs. A check box is a task: amber when it is late. The stage track on the right shows where the initiative is. A session that runs under an initiative shows indented under it. An initiative shows its 3 most urgent tasks, and **N more** shows the rest.
|
|
19
19
|
- **Not in an initiative** is one line at the end, with a blue dot, an amber square and a count. Press it to open the items that have no initiative.
|
|
20
20
|
- **Kept** and **Done** are in the filter icon's menu, on a desktop only.
|
|
@@ -25,12 +25,18 @@ Home is the page at `/premium.html`. It follows the Agreed design and the "Uncov
|
|
|
25
25
|
|
|
26
26
|
## An initiative
|
|
27
27
|
|
|
28
|
-
|
|
28
|
+
Press an initiative's name in the list, or open `?ini=<id>`. The list stays as it is and the initiative's row is selected. The chat talks about the initiative, and its page opens in the Viewer.
|
|
29
29
|
|
|
30
|
+
- The page's header shows the lane and the anchor, the name, **New session** (+), ⋯, Open wide and Close.
|
|
31
|
+
- The stage card shows the stage, the exit items, the next step and **Overview with Claude**. **Overview with Claude** types the question into the chat box. Nothing is sent until you press send.
|
|
32
|
+
- Under the card are the 3 most urgent tasks and the documents that need a look. **Show N more** opens all the tasks and **Show all N** opens all the documents. ← goes back to the page. A task or a document that you open from the page also has ← back to the page.
|
|
33
|
+
- ⋯ has **Moves on by itself**, **Move back a stage**, **Move to a stage**, **Add a stakeholder**, **Turn into a program**, **Open on the Board**, **The record**, **Put on hold** and **Cancel the initiative**.
|
|
34
|
+
- To go back to all work, press the browser's Back, or Menu > **Home**. Neither reloads the page. Close (×) closes the page but keeps the initiative's chat.
|
|
35
|
+
- If there is no room beside the chat, the Viewer shows on top of the chat. The list stays.
|
|
36
|
+
- On a phone the page fills the screen. **Message Claude about <name>** opens the chat.
|
|
30
37
|
- **Moves on by itself** is a switch, on by default. When every exit item is done, the stage moves to the next stage and a message shows **Undo**. A stage never moves by itself into a milestone (Deliver or Evaluate). This rule is a proposal that the PM has not confirmed yet.
|
|
31
38
|
- **Move to <next>** with open exit items asks first (**Move anyway**, with a note). **Back** always asks for a reason.
|
|
32
39
|
- **Tasks** in the Viewer can be grouped by stage, by groups that you name, by owner or by status. Drag a task to another group.
|
|
33
|
-
- **Core documents** in the list shows only the documents that need a look. **All documents** opens every document in the Viewer.
|
|
34
40
|
|
|
35
41
|
## Rename a program, an initiative or a task
|
|
36
42
|
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pmos-workspace",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.407.0",
|
|
4
4
|
"lockfileVersion": 3,
|
|
5
5
|
"requires": true,
|
|
6
6
|
"packages": {
|
|
7
7
|
"": {
|
|
8
8
|
"name": "pmos-workspace",
|
|
9
|
-
"version": "0.
|
|
9
|
+
"version": "0.407.0",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@xterm/addon-fit": "^0.11.0",
|
package/workspace/package.json
CHANGED
|
@@ -190,7 +190,7 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
|
|
|
190
190
|
const viaMore = async (pg, label) => { await pg.click('#czViewer:not([hidden]) [data-cz-vw="more"]'); await until(() => pg.evaluate(() => !!document.querySelector('#czViewer .cz-vw-menu'))); await pg.click(`#czViewer .cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("${label}"))`); }; // the Overview's other views, Open the full record and Sprint sit under ⋯ (XvATasks)
|
|
191
191
|
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);
|
|
192
192
|
ok('I0 the expand link lands on Home with the initiative selected, ws and board kept', !!landed, await ip.evaluate(() => location.href));
|
|
193
|
-
await ip.click('.
|
|
193
|
+
await ip.click('#czViewer .hi-pgh [data-hi-addtask]'); // the initiative's page (canvas HbC): its + drills into Tasks
|
|
194
194
|
await until(() => ip.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')), 60000);
|
|
195
195
|
await (async (pg) => { if (await pg.$('#czViewer [data-hi-view="stage"]')) await pg.click('#czViewer [data-hi-view="stage"]'); else await viaMore(pg, 'Stage'); })(ip);
|
|
196
196
|
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);
|
|
@@ -205,7 +205,7 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
|
|
|
205
205
|
ok('I3 a lifecycle press asks its reason inline, records nothing yet and opens no browser dialog', await until(() => ip.evaluate(() => !!document.querySelector('#czViewer #ovWhy'))) && lines('lifecycle.jsonl').length === lif0 && !(await ip.evaluate(() => { const d = document.querySelector('#dlg'); return !!(d && d.classList.contains('on')); })));
|
|
206
206
|
await ip.click('#czViewer [data-ov-life-no]');
|
|
207
207
|
ok('I3 Not now takes the question back', await until(() => ip.evaluate(() => !document.querySelector('#czViewer #ovWhy') && !!document.querySelector('#czViewer [data-ov-life="on-hold"]'))));
|
|
208
|
-
await ip.
|
|
208
|
+
await ip.click('#czViewer [data-cz-vw="back"]'); // ← from Stage: the initiative's page again (canvas HbCDrill)
|
|
209
209
|
// the card: Back always asks for a reason, and the move line carries it (InStage)
|
|
210
210
|
const back = await until(() => ip.evaluate(() => !!document.querySelector('.hm-card [data-hi-back]')), 30000);
|
|
211
211
|
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 || '')));
|
|
@@ -115,7 +115,10 @@ const BODY = '## Purpose\n\nWhy this board exists.\n\n## Scope\n\nWhat it covers
|
|
|
115
115
|
// Documents is shell A (XvADocs): its groups after the first are folded, so a row is unfolded before it is pressed
|
|
116
116
|
const unfold = (p, sel) => p.evaluate((q) => { const n = document.querySelector(q); const f = n && !n.offsetParent && n.closest('.czs-sec') && n.closest('.czs-sec').querySelector('[data-czs-fold]'); if (f) f.click(); }, sel);
|
|
117
117
|
const viaMore = async (pg, label) => { await pg.click('#czViewer:not([hidden]) [data-cz-vw="more"]'); await until(() => pg.evaluate(() => !!document.querySelector('#czViewer .cz-vw-menu'))); await pg.click(`#czViewer .cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("${label}"))`); }; // the Overview's other views, Open the full record and Sprint sit under ⋯ (XvATasks)
|
|
118
|
-
|
|
118
|
+
// the initiative's page (canvas HbC): its list row opens it again when the Viewer shows something else
|
|
119
|
+
const ovOpen = async (p) => { await until(() => p.evaluate(() => !!document.querySelector('#hmList [data-hm-sel^="i:"][aria-current="true"]')), 60000);
|
|
120
|
+
if (!(await p.$('#czViewer:not([hidden]) [data-hi-v="page"]'))) await p.click('#hmList [data-hm-sel^="i:"][aria-current="true"]');
|
|
121
|
+
await until(() => p.evaluate(() => !!document.querySelector('#czViewer .hi-pgh [data-hi-addtask]')), 60000); await p.click('#czViewer .hi-pgh [data-hi-addtask]'); // the initiative's page (canvas HbC): its + drills into Tasks
|
|
119
122
|
// the Overview opens on Tasks; the core documents are its Documents view (premium-uncovered-features, canvas InDocs)
|
|
120
123
|
if (await until(() => p.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')), 30000)) await (async (pg) => { if (await pg.$('#czViewer [data-hi-view="docs"]')) await pg.click('#czViewer [data-hi-view="docs"]'); else await viaMore(pg, 'Documents'); })(p); };
|
|
121
124
|
const I = await open('/premium-initiative.html' + iq), ip = I.page;
|
|
@@ -58,13 +58,13 @@ const SPRINTS = { ok: true, source: 'jira', readAt: '2026-10-19T09:00:00Z', velo
|
|
|
58
58
|
await page.goto(BASE + '/premium-initiative.html?id=self-serve-v2&ws=w1&board=w1&theme=' + theme);
|
|
59
59
|
// the Board's expand link lands on Home's initiative layout (premium-agreed-design); its Overview has the Sprint press, and the Viewer shows one item at a time
|
|
60
60
|
S.up = await until(() => page.evaluate(() => !!document.querySelector('.hm-card [data-hm-ov]') && !!window.__premiumViewer && !!window.__premiumVwJira), 20000);
|
|
61
|
-
if (S.up) {
|
|
61
|
+
if (S.up) { await (async (g) => { const P = '#czViewer:not([hidden]) [data-hi-v="page"]', r = '#hmList [data-hm-sel^="i:"][aria-current="true"]'; for (let i = 0; i < 4 && !(await g.$(P)) && (await g.$('#czViewer:not([hidden]) [data-cz-vw="back"]')); i++) { await g.click('#czViewer [data-cz-vw="back"]'); await g.waitForTimeout(150); } if (await g.$(P)) return; if (await g.$(r)) await g.click(r); else await g.reload(); await g.waitForSelector(P + ' .hi-pgh [data-hi-addtask]', { timeout: 30000 }); })(page); /* ← back to the initiative's page, else its row, else the address again (an initiative the list does not show) */ await page.click('#czViewer .hi-pgh [data-hi-addtask]'); /* the initiative's page (canvas HbC): its + drills into Tasks */ S.up = await until(() => page.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]'))); }
|
|
62
62
|
S.reads.length = 0;
|
|
63
63
|
return { page, ctx, S };
|
|
64
64
|
};
|
|
65
65
|
const viaMore = async (pg, label) => { await pg.click('#czViewer:not([hidden]) [data-cz-vw="more"]'); await until(() => pg.evaluate(() => !!document.querySelector('#czViewer .cz-vw-menu'))); await pg.click(`#czViewer .cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("${label}"))`); }; // the Overview's other views, Open the full record and Sprint sit under ⋯ (XvATasks)
|
|
66
66
|
const toSprint = async (page) => {
|
|
67
|
-
if (!(await page.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')))) {
|
|
67
|
+
if (!(await page.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')))) { await (async (g) => { const P = '#czViewer:not([hidden]) [data-hi-v="page"]', r = '#hmList [data-hm-sel^="i:"][aria-current="true"]'; for (let i = 0; i < 4 && !(await g.$(P)) && (await g.$('#czViewer:not([hidden]) [data-cz-vw="back"]')); i++) { await g.click('#czViewer [data-cz-vw="back"]'); await g.waitForTimeout(150); } if (await g.$(P)) return; if (await g.$(r)) await g.click(r); else await g.reload(); await g.waitForSelector(P + ' .hi-pgh [data-hi-addtask]', { timeout: 30000 }); })(page); /* ← back to the initiative's page, else its row, else the address again (an initiative the list does not show) */ await page.click('#czViewer .hi-pgh [data-hi-addtask]'); /* the initiative's page (canvas HbC): its + drills into Tasks */ }
|
|
68
68
|
await until(() => page.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]')), 5000);
|
|
69
69
|
await viaMore(page, 'Sprint');
|
|
70
70
|
return until(() => page.evaluate(() => !!document.querySelector('#czViewer .obody.vw[data-vw="sprint:w1"] [data-jbl]')), 5000);
|
|
@@ -87,7 +87,7 @@ const SPRINTS = { ok: true, source: 'jira', readAt: '2026-10-19T09:00:00Z', velo
|
|
|
87
87
|
ok('R10 Home loads the initiative with its Overview open', S.up);
|
|
88
88
|
ok('R10 the sprint view has "Open the backlog", and it opens the backlog in the Viewer', await openBacklog(page));
|
|
89
89
|
let s = await read(page);
|
|
90
|
-
ok('R10 the backlog is the Viewer\'s one item, and the initiative is still the
|
|
90
|
+
ok('R10 the backlog is the Viewer\'s one item, and the initiative is still the one open (the address and the chat name it)', s.on === 'backlog:w1' && await page.evaluate(() => new URLSearchParams(location.search).get('ini') === 'self-serve-v2' && /Self-serve onboarding v2/.test(document.querySelector('#hmIn').placeholder)), JSON.stringify(s.on));
|
|
91
91
|
ok('R10 the board is read with its workspace and board', S.reads.length >= 1 && S.reads.every((q) => /board=w1/.test(q) && /ws=w1/.test(q)), JSON.stringify(S.reads));
|
|
92
92
|
ok('R10 the open sprints first, then the Backlog, each with its tickets by key', JSON.stringify(s.secs) === '[["S 14",["P-1","P-2"]],["S 15",[]],["Backlog",["P-3","Q-2"]]]', JSON.stringify(s.secs));
|
|
93
93
|
ok('R10 it says what it leaves out and that Jira owns rank and sprint', /Only the tickets this board's initiatives pushed/.test(s.text) && /Ranking and moving between sprints happen in Jira/.test(s.text));
|
|
@@ -77,11 +77,9 @@ const prop = (o) => Object.assign({ id: 'prop-a', state: 'proposed', prompt: 'ad
|
|
|
77
77
|
return send({ ok: false, error: 'not in this test' }, 404);
|
|
78
78
|
});
|
|
79
79
|
await page.goto(BASE + '/premium.html?ini=self-serve-v2&ws=w1&theme=' + theme);
|
|
80
|
-
await until(() => page.evaluate(() => !!document.querySelector('
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
// the initiative's Core documents group (in place of the Files group, premium-uncovered-features InDocs) opens every document in the Viewer
|
|
84
|
-
await page.click('#hmList [data-hi-open="docs"]');
|
|
80
|
+
await until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-hi-open="docs"]')), 15000); // the initiative's page (canvas HbC)
|
|
81
|
+
// the page's Documents "Show all N" opens every document in the Viewer
|
|
82
|
+
await page.click('#czViewer [data-hi-open="docs"]');
|
|
85
83
|
await until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]')), 15000);
|
|
86
84
|
await page.click('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]'); // the PRD opens as a page
|
|
87
85
|
await until(() => page.evaluate(() => document.querySelector('.vwdoc .cf, .vwdoc .vwempty:not(:empty)') && !/Reading the file/.test(document.querySelector('.vwdoc').textContent)));
|
|
@@ -111,7 +109,7 @@ const prop = (o) => Object.assign({ id: 'prop-a', state: 'proposed', prompt: 'ad
|
|
|
111
109
|
ok('D9 Links show what it is built from and what uses it, from the document library', /Built from · 1.*Onboarding interviews/.test(await txt(p, V + ' .vwmp')) && /Used by · 1.*Self-serve rubric/.test(await txt(p, V + ' .vwmp')) && /Links 2/.test(await txt(p, V + ' .vwmore')));
|
|
112
110
|
await p.click(V + ' [data-vd="open:planning/evals/self-serve-v2-rubric.md"]');
|
|
113
111
|
ok('D9 a linked document opens as a page in the Viewer, in place of this one', await until(() => p.evaluate(() => !!document.querySelector('#czViewer .obody.vw[data-vw="doc:planning/evals/self-serve-v2-rubric.md"]'))));
|
|
114
|
-
await p.click('#
|
|
112
|
+
await (async (g) => { const P = '#czViewer:not([hidden]) [data-hi-v="page"]', r = '#hmList [data-hm-sel^="i:"][aria-current="true"]'; for (let i = 0; i < 4 && !(await g.$(P)) && (await g.$('#czViewer:not([hidden]) [data-cz-vw="back"]')); i++) { await g.click('#czViewer [data-cz-vw="back"]'); await g.waitForTimeout(150); } if (await g.$(P)) return; if (await g.$(r)) await g.click(r); else await g.reload(); await g.waitForSelector(P + ' .hi-pgh [data-hi-addtask]', { timeout: 30000 }); })(p); /* ← back to the initiative's page, else its row, else the address again (an initiative the list does not show) */ await p.click('#czViewer [data-hi-open="docs"]'); // back to the PRD: the initiative's row opens its page, and Documents opens it again
|
|
115
113
|
await until(() => p.evaluate(() => !!document.querySelector('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]')), 15000);
|
|
116
114
|
await p.click('#czViewer [data-ov-open="planning/prd/self-serve-v2-prd.md"]');
|
|
117
115
|
await until(() => p.evaluate(() => !!document.querySelector('#czViewer .obody.vw[data-vw="doc:planning/prd/self-serve-v2-prd.md"] .vwdoc .cf')));
|
|
@@ -52,7 +52,7 @@ process.on('unhandledRejection', (e) => { console.error(e); finish(1); });
|
|
|
52
52
|
return { page, ctx, S };
|
|
53
53
|
};
|
|
54
54
|
const viaMore = async (pg, label) => { await pg.click('#czViewer:not([hidden]) [data-cz-vw="more"]'); await until(() => pg.evaluate(() => !!document.querySelector('#czViewer .cz-vw-menu'))); await pg.click(`#czViewer .cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("${label}"))`); }; // the Overview's other views, Open the full record and Sprint sit under ⋯ (XvATasks)
|
|
55
|
-
const overview = async (page) => {
|
|
55
|
+
const overview = async (page) => { await (async (g) => { const P = '#czViewer:not([hidden]) [data-hi-v="page"]', r = '#hmList [data-hm-sel^="i:"][aria-current="true"]'; for (let i = 0; i < 4 && !(await g.$(P)) && (await g.$('#czViewer:not([hidden]) [data-cz-vw="back"]')); i++) { await g.click('#czViewer [data-cz-vw="back"]'); await g.waitForTimeout(150); } if (await g.$(P)) return; if (await g.$(r)) await g.click(r); else await g.reload(); await g.waitForSelector(P + ' .hi-pgh [data-hi-addtask]', { timeout: 30000 }); })(page); /* ← back to the initiative's page, else its row, else the address again (an initiative the list does not show) */ await page.click('#czViewer .hi-pgh [data-hi-addtask]'); /* the initiative's page (canvas HbC): its + drills into Tasks */ return until(() => page.evaluate(() => !!document.querySelector('#czViewer [data-cz-vw="more"]') && !!document.querySelector('#czViewer [data-ov-tk="task:t1"]'))); };
|
|
56
56
|
const cur = (page) => page.evaluate(() => { const p = document.querySelector('#czViewer:not([hidden]) .obody.vw'); return { on: p ? p.dataset.vw : null, title: (document.querySelector('#czVwTitle') || {}).textContent || '', n: document.querySelectorAll('#czViewer .obody.vw').length }; });
|
|
57
57
|
const paneTxt = (page, id) => page.evaluate((k) => { const p = document.querySelector(`#czViewer .obody.vw[data-vw="${CSS.escape(k)}"]`); return p ? p.textContent.replace(/\s+/g, ' ') : ''; }, id);
|
|
58
58
|
const INI = 'item:ini:self-serve-v2';
|
|
@@ -72,7 +72,7 @@ const TICKETS = {
|
|
|
72
72
|
const IMODEL = IP.build(IF.facts());
|
|
73
73
|
// Home's initiative layout (premium-agreed-design): the card's Overview has the Sprint press; the Viewer shows one item at a time
|
|
74
74
|
const viaMore = async (pg, label) => { await pg.click('#czViewer:not([hidden]) [data-cz-vw="more"]'); await until(() => pg.evaluate(() => !!document.querySelector('#czViewer .cz-vw-menu'))); await pg.click(`#czViewer .cz-vw-menu [role="menuitem"]:has(> span:first-child:text-is("${label}"))`); }; // the Overview's other views, Open the full record and Sprint sit under ⋯ (XvATasks)
|
|
75
|
-
const overview = async (pg) => {
|
|
75
|
+
const overview = async (pg) => { await (async (g) => { const P = '#czViewer:not([hidden]) [data-hi-v="page"]', r = '#hmList [data-hm-sel^="i:"][aria-current="true"]'; for (let i = 0; i < 4 && !(await g.$(P)) && (await g.$('#czViewer:not([hidden]) [data-cz-vw="back"]')); i++) { await g.click('#czViewer [data-cz-vw="back"]'); await g.waitForTimeout(150); } if (await g.$(P)) return; if (await g.$(r)) await g.click(r); else await g.reload(); await g.waitForSelector(P + ' .hi-pgh [data-hi-addtask]', { timeout: 30000 }); })(pg); /* ← back to the initiative's page, else its row, else the address again (an initiative the list does not show) */ await pg.click('#czViewer .hi-pgh [data-hi-addtask]'); /* the initiative's page (canvas HbC): its + drills into Tasks */ return until(() => pg.evaluate(() => !!document.querySelector('#czViewer:not([hidden]) [data-hi-v]'))); };
|
|
76
76
|
const openSprint = async (pg) => { if (!(await pg.$('#czViewer:not([hidden]) [data-hi-v]'))) await overview(pg); /* open() already showed the Overview */ await viaMore(pg, 'Sprint'); };
|
|
77
77
|
const open = async ({ w = 1280, h = 900, theme = 'light', sprints = SPRINTS, tickets = TICKETS } = {}) => {
|
|
78
78
|
const ctx = await browser.newContext({ viewport: { width: w, height: h }, colorScheme: theme });
|
|
@@ -138,7 +138,7 @@ const TICKETS = {
|
|
|
138
138
|
&& await p.evaluate(() => [...document.querySelectorAll('#czViewer .obody.vw a[href]')].every((a) => a.href === 'https://acme.atlassian.net/browse/PMOS-142' && a.target === '_blank' && /noopener/.test(a.rel))));
|
|
139
139
|
await p.click('#czViewer .obody.vw [data-jt="PMOS-152"]');
|
|
140
140
|
ok('K6 a linked ticket opens in its own tab', !!(await until(async () => { const t = await paneText(p, 'jira:PMOS-152'); return t && /Release to existing workspaces/.test(t) && /No sprint/.test(t); })));
|
|
141
|
-
|
|
141
|
+
await (async (g) => { const P = '#czViewer:not([hidden]) [data-hi-v="page"]', r = '#hmList [data-hm-sel^="i:"][aria-current="true"]'; for (let i = 0; i < 4 && !(await g.$(P)) && (await g.$('#czViewer:not([hidden]) [data-cz-vw="back"]')); i++) { await g.click('#czViewer [data-cz-vw="back"]'); await g.waitForTimeout(150); } if (await g.$(P)) return; if (await g.$(r)) await g.click(r); else await g.reload(); await g.waitForSelector(P + ' .hi-pgh [data-hi-addtask]', { timeout: 30000 }); })(p); /* ← back to the initiative's page, else its row, else the address again (an initiative the list does not show) */ await p.click('#czViewer .hi-pgh [data-hi-addtask]'); /* the initiative's page (canvas HbC): its + drills into Tasks */
|
|
142
142
|
const k7 = await until(() => p.evaluate((t0) => { const m = document.querySelector('#czViewer:not([hidden]) .cz-vw-body'); return m && m.textContent === t0 ? m.textContent : null; }, mainTxt));
|
|
143
143
|
ok('K7 the Overview comes back with its own facts, as before', !!k7, await p.evaluate(() => ((document.querySelector('#czViewer .cz-vw-body') || {}).textContent || '').slice(0, 300)));
|
|
144
144
|
ok('K8 the views read the two Jira routes only, and wrote nothing', A.posts.filter((x) => !/thread|note|seen/.test(x)).length === 0 && A.reads.every((r) => /^\/api\/(jira\/tickets|boards\/sprints)\?/.test(r)) && A.reads.some((r) => /jira\/tickets\?.*initiative=self-serve-v2/.test(r)), JSON.stringify([A.posts, A.reads]));
|
|
@@ -2,8 +2,9 @@
|
|
|
2
2
|
* shell A since the second kit (initiative viewer-shell-a, V9): the shell's header, summary card and folding rows in place of the panel's own
|
|
3
3
|
* head and tabs. The content is the same. The shell floats at 560 px over the page's right edge and does not push the page.
|
|
4
4
|
*
|
|
5
|
-
* mount(o) once, from premium-board.js. o: { M() the Board model, programs() GET /api/programs' programs, openIni(id, from) the
|
|
6
|
-
* of a row of this board, close() what the shell shows for the Board, reload() reads the programs again, say(msg) the
|
|
5
|
+
* mount(o) once, from premium-board.js or home-app.js. o: { M() the Board model, programs() GET /api/programs' programs, openIni(id, from) the
|
|
6
|
+
* initiative of a row of this board, close() what the shell shows for the Board, reload() reads the programs again, say(msg) the
|
|
7
|
+
* toast, drill? true keeps the program behind the initiative it opens, so ← comes back to it (Home, canvas HbCProg) }
|
|
7
8
|
*
|
|
8
9
|
* The panel opens on document `bd:program` { id, from? }. A program row of the Board ([data-prog]) and ?program=<id> (Home links there) send
|
|
9
10
|
* that event through pm/bd-prog.js openProgram, the one path that opens it.
|
|
@@ -387,7 +388,7 @@ async function press(b) {
|
|
|
387
388
|
else if (a === 'ms' || a === 'itasks') showRow(a);
|
|
388
389
|
else if (a === 'period') { O._perOpen = !O._perOpen; draw(true); }
|
|
389
390
|
else if (a === 'per' || a === 'early') { period = b.dataset.per; O._perOpen = false; draw(); const pb = VW.body() && VW.body().querySelector('[data-pp="period"]'); if (pb) pb.focus(); }
|
|
390
|
-
else if (a === 'ini') { const id = b.dataset.ini, from = document.querySelector(`#ibBody [data-prog="${CSS.escape(p.id)}"]`); VW.close(); O.openIni(id, from); }
|
|
391
|
+
else if (a === 'ini') { const id = b.dataset.ini, from = document.querySelector(`#ibBody [data-prog="${CSS.escape(p.id)}"]`); if (O.drill) VW.drill(); else VW.close(); O.openIni(id, from); }
|
|
391
392
|
else if (a === 'add') { adding = true; draw(); const i = VW.body() && VW.body().querySelector('.pp-add input'); if (i) i.focus(); }
|
|
392
393
|
else if (a === 'charter') openCharter(p);
|
|
393
394
|
else if (a === 'done') {
|
|
@@ -628,3 +628,8 @@ form.hm-box textarea { min-height: 48px; border: 0; background: none; resize: no
|
|
|
628
628
|
.hm-moved td { padding: 8px 0; border-bottom: 1px solid var(--cz-hair); }
|
|
629
629
|
.hm-moved td + td { padding-left: 12px; font-weight: 600; white-space: nowrap; }
|
|
630
630
|
@media (max-width: 760px) { .hm-kpis { grid-template-columns: 1fr; } }
|
|
631
|
+
/* the list stays when there is no room beside the chat (HbCNarrow): the Viewer lies over the chat, at most the room right of the list */
|
|
632
|
+
@media (min-width: 761px) {
|
|
633
|
+
body.cz-home.cz-vw-over .hm-vw { position: absolute; top: 16px; right: 16px; bottom: 16px; z-index: 5; }
|
|
634
|
+
body.cz-home.cz-vw-over .hm-vw .cz-vw { box-shadow: var(--cz-vlift); }
|
|
635
|
+
}
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
* Sources pm/cozy-sources.js: what PMOS reads and how old each reading is, in the Viewer
|
|
10
10
|
* Settings pm/cozy-settings.js: General, Connectors, Workspaces, Updates, What's new
|
|
11
11
|
* A page with features the design does not draw yet passes opts.more (Home): a quiet "More" row then follows Settings.
|
|
12
|
+
* A page that passes opts.here() runs it when its own place is pressed, in place of a reload (Home: Menu > Home closes the page that is open).
|
|
12
13
|
* The counts come from GET /api/news-for-you and GET /api/sources, read when the page opens and every two minutes while it is shown.
|
|
13
14
|
* Nothing here leads to the console, and nothing here writes but the theme (this device).
|
|
14
15
|
*/
|
|
@@ -95,6 +96,9 @@ export function mountNav(here, doc = document, opts = {}) {
|
|
|
95
96
|
// set() redraws the button's icon, so the pressed icon may be gone from the page by now: only a press still on the page closes the menu
|
|
96
97
|
doc.addEventListener('click', (e) => { if (!menu.hidden && e.target.isConnected && !w.contains(e.target)) set(false); });
|
|
97
98
|
menu.addEventListener('click', (e) => {
|
|
99
|
+
// the page you are on, pressed again: a page that passes opts.here goes back to its start without a reload (Home: the list, no page open)
|
|
100
|
+
const a = e.target.closest('a[aria-current="page"]');
|
|
101
|
+
if (a && opts.here && !e.metaKey && !e.ctrlKey && !e.shiftKey) { e.preventDefault(); set(false); opts.here(); return; }
|
|
98
102
|
const b = e.target.closest('button'); if (!b) return;
|
|
99
103
|
if (b.dataset.evTheme) { setTheme(b.dataset.evTheme, doc); return; }
|
|
100
104
|
set(false);
|
|
@@ -267,6 +267,8 @@ body.cz-home .hm-lsc { margin: 0 -12px; padding: 0 12px 4px; }
|
|
|
267
267
|
.hv-pt { display: flex; align-items: center; gap: 10px; min-width: 0; min-height: 44px; padding: 0 6px; border: 0; background: none; color: var(--cz-ink); cursor: pointer; font-family: var(--cz-sans); border-radius: 14px; }
|
|
268
268
|
.hv-pf { flex: 1; display: flex; align-items: center; justify-content: flex-end; gap: 6px; min-height: 44px; padding: 0 10px 0 6px; border: 0; background: none; cursor: pointer; font-family: var(--cz-sans); border-radius: 14px; }
|
|
269
269
|
.hv-pf .hv-cv { margin-left: 0; }
|
|
270
|
+
/* the heading whose program or product is open in the Viewer (HbCProg, HbCProduct): its name carries the selection, as a row does */
|
|
271
|
+
.hv-gh.hv-prg.sel .hv-pt { background: var(--cz-bluebg); }
|
|
270
272
|
.hv-msd { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; color: var(--cz-ink2); white-space: nowrap; }
|
|
271
273
|
.hv-msd.late { color: var(--cz-late); }
|
|
272
274
|
.hv-dm { display: block; width: 8px; height: 8px; border-radius: 2px; transform: rotate(45deg); background: var(--cz-c-6b4fa3); }
|