create-pmos 0.589.0 → 0.591.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 +27 -27
- 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-initiative-test.js +3 -0
- package/workspace/changelog.json +26 -0
- package/workspace/guide/home.md +1 -13
- package/workspace/home-other-product-test.js +2 -1
- package/workspace/home-railcard-test.js +2 -0
- package/workspace/live-pill-round-test.js +2 -2
- package/workspace/milestone-suggest-test.js +4 -5
- package/workspace/package-lock.json +2 -2
- package/workspace/package.json +1 -1
- package/workspace/panels-test.js +2 -1
- package/workspace/program-order-test.js +2 -1
- package/workspace/public/pm/home-app.js +4 -2
- package/workspace/public/pm/home-list.js +17 -1
- package/workspace/public/pm/home-today.js +20 -14
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-pmos",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.591.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": {
|
|
@@ -33,6 +33,32 @@
|
|
|
33
33
|
"audit"
|
|
34
34
|
],
|
|
35
35
|
"pmosChanges": [
|
|
36
|
+
{
|
|
37
|
+
"v": "0.591.0",
|
|
38
|
+
"at": "2026-11-17T14:18:25.456Z",
|
|
39
|
+
"f": 4,
|
|
40
|
+
"prs": [
|
|
41
|
+
{
|
|
42
|
+
"n": 1328,
|
|
43
|
+
"t": "Home's list shows only rows with a call; the rest fold to N more",
|
|
44
|
+
"s": "Home's list shows only rows with a call; the rest fold to N more",
|
|
45
|
+
"k": "new"
|
|
46
|
+
}
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"v": "0.590.0",
|
|
51
|
+
"at": "2026-11-17T13:19:36.782Z",
|
|
52
|
+
"f": 4,
|
|
53
|
+
"prs": [
|
|
54
|
+
{
|
|
55
|
+
"n": 1326,
|
|
56
|
+
"t": "Take Your move and Waiting on others back out of Home's list",
|
|
57
|
+
"s": "Take Your move and Waiting on others back out of Home's list",
|
|
58
|
+
"k": "imp"
|
|
59
|
+
}
|
|
60
|
+
]
|
|
61
|
+
},
|
|
36
62
|
{
|
|
37
63
|
"v": "0.589.0",
|
|
38
64
|
"at": "2026-11-17T11:57:51.177Z",
|
|
@@ -272,32 +298,6 @@
|
|
|
272
298
|
"k": "new"
|
|
273
299
|
}
|
|
274
300
|
]
|
|
275
|
-
},
|
|
276
|
-
{
|
|
277
|
-
"v": "0.571.0",
|
|
278
|
-
"at": "2026-11-16T04:26:43.356Z",
|
|
279
|
-
"f": 4,
|
|
280
|
-
"prs": [
|
|
281
|
-
{
|
|
282
|
-
"n": 1303,
|
|
283
|
-
"t": "The factory merges behind a guardrail, and rolls out behind a flag",
|
|
284
|
-
"s": "The factory merges behind a guardrail, and rolls out behind a flag",
|
|
285
|
-
"k": "new"
|
|
286
|
-
}
|
|
287
|
-
]
|
|
288
|
-
},
|
|
289
|
-
{
|
|
290
|
-
"v": "0.570.0",
|
|
291
|
-
"at": "2026-11-15T17:32:20.370Z",
|
|
292
|
-
"f": 4,
|
|
293
|
-
"prs": [
|
|
294
|
-
{
|
|
295
|
-
"n": 1302,
|
|
296
|
-
"t": "The real build engine for Full SDLC (launch simulation W7)",
|
|
297
|
-
"s": "The real build engine for Full SDLC (launch simulation W7)",
|
|
298
|
-
"k": "new"
|
|
299
|
-
}
|
|
300
|
-
]
|
|
301
301
|
}
|
|
302
302
|
]
|
|
303
303
|
}
|
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-11-
|
|
5
|
+
generated: {by: process:create-pmos, at: "2026-11-17T14:18:22Z"}
|
|
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-11-
|
|
5
|
+
generated: {by: process:create-pmos, at: "2026-11-17T14:18:22Z"}
|
|
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-11-
|
|
5
|
+
generated: {by: process:create-pmos, at: "2026-11-17T14:18:22Z"}
|
|
6
6
|
status: stable
|
|
7
7
|
---
|
|
8
8
|
|
|
@@ -115,6 +115,9 @@ const WRITES = /^\/api\/(?:boards\/(?:move|tasks\/(?:add|state))|lifecycle|core-
|
|
|
115
115
|
await R.ctx.close();
|
|
116
116
|
}
|
|
117
117
|
ok('I1 the console is not linked from Home', await p.evaluate(() => ![...document.querySelectorAll('a[href]')].some((a) => /console(\.html)?/.test(a.getAttribute('href')))));
|
|
118
|
+
// Home shows only the rows with a call (home-nav-rows-with-a-call): "N more" opens the board's other initiatives in place
|
|
119
|
+
await p.evaluate(() => document.querySelectorAll('#hmList .hv-fold[aria-expanded="false"]').forEach((b) => b.click()));
|
|
120
|
+
await until(() => p.evaluate(() => !!document.querySelector('#hmList [data-hm-sel="i:partner-rate-limits"]')));
|
|
118
121
|
const sib = await p.evaluate(() => [...document.querySelectorAll('#hmList [data-hm-sel^="i:"]')].map((b) => b.dataset.hmSel));
|
|
119
122
|
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));
|
|
120
123
|
await p.click('#hmList [data-hm-sel="i:partner-rate-limits"]');
|
package/workspace/changelog.json
CHANGED
|
@@ -1,4 +1,30 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"v": "0.591.0",
|
|
4
|
+
"at": "2026-11-17T14:18:25.456Z",
|
|
5
|
+
"f": 4,
|
|
6
|
+
"prs": [
|
|
7
|
+
{
|
|
8
|
+
"n": 1328,
|
|
9
|
+
"t": "Home's list shows only rows with a call; the rest fold to N more",
|
|
10
|
+
"s": "Home's list shows only rows with a call; the rest fold to N more",
|
|
11
|
+
"k": "new"
|
|
12
|
+
}
|
|
13
|
+
]
|
|
14
|
+
},
|
|
15
|
+
{
|
|
16
|
+
"v": "0.590.0",
|
|
17
|
+
"at": "2026-11-17T13:19:36.782Z",
|
|
18
|
+
"f": 4,
|
|
19
|
+
"prs": [
|
|
20
|
+
{
|
|
21
|
+
"n": 1326,
|
|
22
|
+
"t": "Take Your move and Waiting on others back out of Home's list",
|
|
23
|
+
"s": "Take Your move and Waiting on others back out of Home's list",
|
|
24
|
+
"k": "imp"
|
|
25
|
+
}
|
|
26
|
+
]
|
|
27
|
+
},
|
|
2
28
|
{
|
|
3
29
|
"v": "0.589.0",
|
|
4
30
|
"at": "2026-11-17T11:57:51.177Z",
|
package/workspace/guide/home.md
CHANGED
|
@@ -35,9 +35,9 @@ Home, the Board, Insights and the Viewer use one typeface, Plus Jakarta Sans, wi
|
|
|
35
35
|
- A program with no open initiative yet still shows, with "No initiatives yet" or "No open initiatives". A program shows only when it holds work of a ticked product. Home reads again when you come back to its tab, so a program made on the Board shows at once.
|
|
36
36
|
- 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. When the product has chats of its own (the product's chat and its new sessions), the header has the same pill as an initiative row: press it to see them, and **+** starts a new session in the product. These chats are not under **Not in an initiative**. A program header has the same pill for the program's own chats, and **+** starts a new session in the program. The chat then shows the program or the product as its scope, not **Loose**. 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. This is the same for every product in the list: Home stays on the workspace you opened it on. For another product, the weekly update and the metrics review open that product's own Home in a new tab. An initiative of another product opens from that product's own board, and its chat works in that product's workspace. This is also true for a new initiative that an agent made with `pmos initiative new` and that is not on the board's Now list yet: it opens with its title, stage and tasks.
|
|
37
37
|
- 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.
|
|
38
|
+
- A product or a program shows only the initiatives that are your call: a blue dot, a next step for you, or a session that waits on you. The product's own next steps and the initiative open in the Viewer always show. The other initiatives fold into one line, **N more**. When a folded initiative has a running session, the line says so, for example **3 more · 1 running**. Press it to open the folded rows in place. They stay open, also after a reload, until you press **Fewer**.
|
|
38
39
|
- **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.
|
|
39
40
|
- **Mine**, **Kept** and **Done** are in the filter icon's menu, on a desktop only. **Mine** shows only what waits on you, under the heading **Waiting on you**.
|
|
40
|
-
- The weekly update and a program's milestone changes show once, in **Your move** at the top of the list. They are not rows in the list below it.
|
|
41
41
|
- Every group stays open or closed after you reload the page.
|
|
42
42
|
- On a desktop, the chat has a header line with the open item's name and where it sits (its initiative, product or program).
|
|
43
43
|
- The microphone in the chat box turns what you say into text. Nothing is sent until you press send.
|
|
@@ -45,18 +45,6 @@ Home, the Board, Insights and the Viewer use one typeface, Plus Jakarta Sans, wi
|
|
|
45
45
|
|
|
46
46
|
## Your move
|
|
47
47
|
|
|
48
|
-
### The top of Home
|
|
49
|
-
|
|
50
|
-
The top of Home's list says what is yours first, then who you wait on. When there is nothing to say, the top shows nothing.
|
|
51
|
-
|
|
52
|
-
- **Your move** shows the calls that always wait for you, in the same order as Good morning. Each row's quiet line starts with its kind: Message, Move the team reads, Your call, Blocked, Verdict, New request, Merge, or Delete or spend. An agreed meeting action that nobody owns is **Your call**: "Commerce workaround needs an owner". At most 5 show. The fold line under them says what it hides, for example "2 more · new request: Approve the intake and 1 other". Press it to see all of them, and **Show fewer** to close them.
|
|
53
|
-
- **Waiting on others** lists what someone else owes you. A row shows only when there is a real person: a meeting-note action that someone else owns, a Jira issue assigned to someone else with no update for 5 days or more on an initiative in Build, or a message you sent that has no reply. A row shows who, where it comes from, since when and how long.
|
|
54
|
-
- After 3 days, PMOS drafts one nudge for a row and puts it in the outbox: "Nudge drafted · goes as a Jira comment only when you send it from the Viewer". Press ↗ to open it in the Viewer. There, **Send**, **Edit** and **Not now** act on it. **Not now** hides the nudge until 09:00 the next day. Nothing is sent from the list. When no channel is connected, Send says so and offers **Copy**.
|
|
55
|
-
- A row leaves Waiting on others with a line, never in silence: "Faye replied on MSD-4388", "MSD-2 is done", or that PMOS no longer sees it. These lines stay for 7 days.
|
|
56
|
-
- Under them, one quiet line says what PMOS did since yesterday, with Undo, and one line says how the rest stands, for example "Everything else is on track · 8 initiatives in 3 products". It says "on track" only when every open initiative is on track.
|
|
57
|
-
|
|
58
|
-
Your move is the one inbox. Every ask that needs you waits here, in PMOS's order: an outcome check past its date, grill findings, changes from your meetings and programs, a reply you owe in Mentions, a draft in the outbox, a key result with no reading, Lab findings that fit no initiative, and what PMOS proposes on each initiative.
|
|
59
|
-
|
|
60
48
|
- **At most 5 show.** The rest are under **Can wait**, in the same order. Nothing is dropped.
|
|
61
49
|
- **One press per initiative.** An initiative's proposals are one row, for example "Checkout: 6 changes to keep" with "3 dates, 2 names, 1 link" under it. Press it to see them grouped as Dates, Names, Done and Links. ✓ keeps all of them, with one Undo for the batch. ✕ drops them, then offers three reasons and **Say why**. A proposal that needs your own check keeps its own ✓ and ✕. **See every change** opens the full list on the initiative.
|
|
62
50
|
- **An ask expires after 14 days with no answer.** PMOS leaves it as it was and writes why in the initiative's History. Your move says it once: "2 asks expired after 14 days with no answer." Dates computed from your tasks never expire: PMOS reads them again each time.
|
|
@@ -71,7 +71,8 @@ const model = () => { const m = IP.build(F.facts()); return { ...m, id: ID, key:
|
|
|
71
71
|
await page.goto(BASE + '/premium.html?ws=idpf');
|
|
72
72
|
const row = `#hmList [data-hm-sel="i:${ID}"]`;
|
|
73
73
|
const listed = await until(async () => {
|
|
74
|
-
|
|
74
|
+
// a closed group opens; "N more" opens the rows with no call (home-nav-rows-with-a-call)
|
|
75
|
+
await page.evaluate(() => document.querySelectorAll('#hmList [data-hm-pg][aria-expanded="false"], #hmList .hv-fold[aria-expanded="false"]').forEach((b) => b.click())).catch(() => {});
|
|
75
76
|
return page.evaluate((s) => { const b = document.querySelector(s); return !!b && !!b.offsetParent; }, row);
|
|
76
77
|
}, 40000);
|
|
77
78
|
ok('O0 Home on IDPF lists the Microsites initiative in the Microsites group', listed);
|
|
@@ -160,6 +160,8 @@ const BF = require('./fixtures/board-premium-facts.js');
|
|
|
160
160
|
const c4 = await until(() => card(A.page));
|
|
161
161
|
ok('C2 a product\'s card: its name opens the product; no milestone', !!c4 && /, a product$/.test(c4.head) && !c4.ms, JSON.stringify(c4));
|
|
162
162
|
await shot(A.page, 'card-product-1440');
|
|
163
|
+
// Home shows only the rows with a call (home-nav-rows-with-a-call): the card folds the rest into "N more", which opens them in place
|
|
164
|
+
if (await A.page.$('#hmList .hv-rc .hv-fold[aria-expanded="false"]')) { await A.page.click('#hmList .hv-rc .hv-fold[aria-expanded="false"]'); await until(() => A.page.$('#hmList .hv-rc .hv-rcb .hv-r.ini .hm-rm')); }
|
|
163
165
|
const pick = await A.page.evaluate(() => { const b = document.querySelector('#hmList .hv-rc .hv-rcb .hv-r.ini:not(.sel) .hm-rm'); return b ? { id: b.dataset.hmSel, t: b.querySelector('.hm-rt b').textContent } : null; });
|
|
164
166
|
if (pick) {
|
|
165
167
|
await A.page.click(`#hmList .hv-rc .hm-rm[data-hm-sel="${pick.id}"]`);
|
|
@@ -77,9 +77,9 @@ const ASKS = () => RUNNING().concat([{ id: 'b', name: 'Redistribute plan items',
|
|
|
77
77
|
ok('L2 its name still says what it holds and its key', l2 && /^What you work on now: 2 running\. Open \(Ctrl J\)$/.test(l2.label), l2 && l2.label);
|
|
78
78
|
await shot(page, 'pill-running');
|
|
79
79
|
|
|
80
|
-
/* L3 */
|
|
80
|
+
/* L3 (the pill's background eases over 0.2 s, so wait for it to settle before reading it) */
|
|
81
81
|
live = ASKS(); await kick();
|
|
82
|
-
const l3 = await until(() => page.evaluate(() => { const l = document.getElementById('czLive'); return l && l.classList.contains('asks') ? { text: l.textContent.trim(), bg: getComputedStyle(l).backgroundColor, card: getComputedStyle(document.body).getPropertyValue('--cz-card') } : null; }));
|
|
82
|
+
const l3 = await until(() => page.evaluate(() => { const l = document.getElementById('czLive'); return l && l.classList.contains('asks') && !/255, 255, 255/.test(getComputedStyle(l).backgroundColor) ? { text: l.textContent.trim(), bg: getComputedStyle(l).backgroundColor, card: getComputedStyle(document.body).getPropertyValue('--cz-card') } : null; }));
|
|
83
83
|
ok('L3 PMOS asks: the pill turns blue, with the count', l3 && l3.text === '3' && !/255, 255, 255/.test(l3.bg), JSON.stringify(l3));
|
|
84
84
|
await shot(page, 'pill-asks');
|
|
85
85
|
|
|
@@ -146,13 +146,12 @@ const withReview = (open, o = {}) => F.programs().map((p) => ({ ...p, ...(o.empt
|
|
|
146
146
|
|
|
147
147
|
/* ── M: Home's Your move ── */
|
|
148
148
|
const M = await open({ home: true });
|
|
149
|
-
// the program's milestone changes
|
|
149
|
+
// the program's milestone changes lead its card on Home (batch 14 item 4)
|
|
150
150
|
await until(() => M.page.evaluate(() => !!document.querySelector('[data-hm-prog]')), 10000);
|
|
151
|
-
const hm = await until(() => M.page.evaluate(() => { const
|
|
152
|
-
ok('M Home\'s
|
|
153
|
-
ok('M said once: the program\'s card has no milestone line of its own', await M.page.evaluate(() => !document.querySelector('[data-hm-sel="ms:project-ascent"]')));
|
|
151
|
+
const hm = await until(() => M.page.evaluate(() => { const b = document.querySelector('[data-hm-sel="ms:project-ascent"]'); return b ? [...b.querySelectorAll('b, em')].map((x) => x.textContent.trim()).join(' · ') : null; }), 10000);
|
|
152
|
+
ok('M Home\'s program card has one line for its milestone changes, first', hm === '3 milestone changes · Pilot live to Dec 2', String(hm));
|
|
154
153
|
if (hm) {
|
|
155
|
-
await M.page.click(
|
|
154
|
+
await M.page.click('[data-hm-sel="ms:project-ascent"]');
|
|
156
155
|
ok('M a tap opens the program, where the changes lead its proposals', !!(await until(() => M.page.evaluate(() => { const b = document.querySelector('#czViewer [data-pv="props"]'); if (b && b.getAttribute('aria-expanded') !== 'true') b.click(); return !!document.querySelector('#czViewer .pv-props .msg-r'); }), 8000)));
|
|
157
156
|
}
|
|
158
157
|
// batch 16: on a desktop the greeting opens Your day in the Viewer, as on a phone; the calendar is under ⋯
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pmos-workspace",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.591.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.591.0",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@anthropic-ai/sdk": "^1.3.0",
|
package/workspace/package.json
CHANGED
package/workspace/panels-test.js
CHANGED
|
@@ -62,7 +62,8 @@ process.on('unhandledRejection', (e) => { console.error(e); finish(1); });
|
|
|
62
62
|
await T.waitForServer(BASE);
|
|
63
63
|
browser = await chromium.launch({ executablePath: exe });
|
|
64
64
|
|
|
65
|
-
const open = async ({ w = 1440, h = 900, dark = false, ctx = null, q = '', at = '/premium.html', ready = () => !!window.czPanels && document.querySelectorAll('#hmList .hv-r.ini .hm-rm').length > 2 } = {}) => {
|
|
65
|
+
const open = async ({ w = 1440, h = 900, dark = false, ctx = null, q = '', at = '/premium.html', ready = () => { document.querySelectorAll('#hmList .hv-fold[aria-expanded="false"]').forEach((b) => b.click()); return !!window.czPanels && document.querySelectorAll('#hmList .hv-r.ini .hm-rm').length > 2; } } = {}) => {
|
|
66
|
+
// Home shows only the rows with a call (home-nav-rows-with-a-call): the default ready opens every folded group, so the rows this suite drags are there
|
|
66
67
|
ctx = ctx || await browser.newContext({ viewport: { width: w, height: h }, colorScheme: dark ? 'dark' : 'light' });
|
|
67
68
|
const page = await ctx.newPage();
|
|
68
69
|
const errors = [];
|
|
@@ -132,7 +132,8 @@ const routePrograms = async (page) => {
|
|
|
132
132
|
await routePrograms(page);
|
|
133
133
|
const am = new Date(); am.setHours(10, 0, 0, 0); await page.clock.setFixedTime(am);
|
|
134
134
|
await page.goto(BASE + '/premium.html?theme=light');
|
|
135
|
-
|
|
135
|
+
// Home shows only the rows with a call (home-nav-rows-with-a-call): open the program's "N more" so every row of its order shows
|
|
136
|
+
await until(() => page.evaluate(() => { document.querySelectorAll('#hmList .hv-g.prg .hv-fold[aria-expanded="false"]').forEach((b) => b.click()); return !!document.querySelector('#hmList .hv-g.prg [data-po-id]') && document.body.dataset.hmTop === '1'; }), 20000);
|
|
136
137
|
return { ctx, page, errors };
|
|
137
138
|
};
|
|
138
139
|
const hkids = (p) => p.evaluate(() => [...document.querySelectorAll('#hmList .hv-g.prg [data-po-id]')].map((r) => r.dataset.poId));
|
|
@@ -233,7 +233,9 @@ async function load() {
|
|
|
233
233
|
loadGrillNews();
|
|
234
234
|
// the top of Home (A′): the ranked list's own reads and Waiting on others, after the first draw so they never hold the list up
|
|
235
235
|
document.body.dataset.hmTop = '0';
|
|
236
|
-
|
|
236
|
+
// the top of Home is off until a new design is agreed (Wawan 2026-11-17: the list stays navigation). GET /api/waiting is not read, so no
|
|
237
|
+
// nudge is drafted in the background.
|
|
238
|
+
readMove().catch(() => {}).then(() => { document.body.dataset.hmTop = '1'; });
|
|
237
239
|
// the boards of the other products Home reads, each its own closed group: read after the list is drawn, so a slow one never holds it up
|
|
238
240
|
const others = await Promise.all(otherProducts(D).map((a) => getRetry('/api/board-premium?ws=' + encodeURIComponent(a.ws), 4).then((r) => (r && r.ok && r.model ? { ws: a.ws, name: a.name, model: r.model } : null))));
|
|
239
241
|
const got = others.filter(Boolean);
|
|
@@ -364,7 +366,7 @@ function homeListHtml() {
|
|
|
364
366
|
// a group is open until the PM folds it; another product starts folded; "Not in an initiative" starts folded on a phone (HvAC, HvACDesk)
|
|
365
367
|
const pOpen = (g) => (g.key in S.pg ? !!S.pg[g.key] : g.kind === 'loose' ? !isPhone() : g.kind === 'program' || g.primary || M.products.length === 1);
|
|
366
368
|
// the top of Home (A′, HmA2): Your move from the same ranked list Good morning reads (rankMove + callKindOf), then Waiting on others
|
|
367
|
-
const T =
|
|
369
|
+
const T = null; // the top of Home (A′, HmA2) is off: the list is navigation only (Wawan 2026-11-17); topOf(M) draws it again
|
|
368
370
|
S.topHtml = T ? TOP.topHtml(T) : ''; // drawn into its own node (drawTopNode), so a late read changes the top, never the rows under it
|
|
369
371
|
const sel = S.sel || (S.ini && S.ini !== 'product' ? 'i:' + S.ini : null);
|
|
370
372
|
S.lo = { sel, ses: S.ses, restOpen: (k) => S.rest.has(k), pin: S.pin, phone: false }; // the folded rail's card draws Home's rows with these
|
|
@@ -211,6 +211,21 @@ export function programGroups(D, groups, products, o, now) {
|
|
|
211
211
|
return out;
|
|
212
212
|
}
|
|
213
213
|
|
|
214
|
+
/** Which initiative rows a group draws (home-nav-rows-with-a-call, board HmMany C): only the ones with a call (the blue dot, row.turn),
|
|
215
|
+
* the open one always, every row once the PM pressed "N more" (open). The rest fold into one line. rows: in the group's order.
|
|
216
|
+
* { shown, more, running, fewer }: running counts the working sessions in the folded rows; fewer: the open group has rows to fold back. */
|
|
217
|
+
export function foldRows(rows, o = {}) {
|
|
218
|
+
const sel = o.sel;
|
|
219
|
+
const isSel = (r) => !!sel && (r.id === sel || (r.kids || []).some((k) => k.id === sel));
|
|
220
|
+
const call = (r) => !!r.turn || isSel(r);
|
|
221
|
+
const shown = o.open ? rows.slice() : rows.filter(call);
|
|
222
|
+
const hid = o.open ? [] : rows.filter((r) => !call(r));
|
|
223
|
+
const running = hid.reduce((n, r) => n + (r.kids || []).filter((k) => k.kind === 'session' && k.state === 'working').length, 0);
|
|
224
|
+
return { shown, more: hid.length, running, fewer: !!o.open && rows.some((r) => !call(r)) };
|
|
225
|
+
}
|
|
226
|
+
/** The fold line: "3 more", or "3 more · 1 running" when a folded row has a running session. */
|
|
227
|
+
export const foldLabel = (more, running) => more + ' more' + (running ? ' · ' + running + ' running' : '');
|
|
228
|
+
|
|
214
229
|
/* ── the list ── */
|
|
215
230
|
/** The next steps Home shows: one on a cancelled, done or archived initiative is moot, so it neither brings that initiative back to Home
|
|
216
231
|
* nor falls to "Not in an initiative" (batch 14 item 3). A session that waits on the PM stays. */
|
|
@@ -259,7 +274,8 @@ export function homeList(D, o = {}) {
|
|
|
259
274
|
// the product's own next steps (its weekly update, a decision with no initiative) sit under its header, before the initiatives
|
|
260
275
|
const flat = mineNeeds.filter((x) => !x.ini || !ids.has(x.ini)).filter((x) => !x.needSession).map((x) => ({ ...x, flat: true, hint: bareHint(x) }));
|
|
261
276
|
const turnN = inis.filter((x) => x.turn).length + flat.length;
|
|
262
|
-
|
|
277
|
+
// only the rows with a call show (home-nav-rows-with-a-call, board HmMany C): a running session, a meeting or a late task alone folds
|
|
278
|
+
const shown = inis.filter((x) => x.turn);
|
|
263
279
|
// the product's own chats (its heading's chat and its new sessions) sit in the header's pill, as an initiative's sit in its row's
|
|
264
280
|
const kids = (D.sessions || []).filter((s) => listed(s) && isProductChat(keyOfSession(s), p)).map((s) => sessionRow(s, D.desk && D.desk.roles)).sort((a, b) => (RANK[b.state] || 0) - (RANK[a.state] || 0));
|
|
265
281
|
groups.push({ key: 'p:' + p.key, kind: 'product', product: p, name: p.name, kids, initials: p.initials, tone: p.tone, primary: !!p.primary, goals: p.goals, flat, inis: shown, rest: inis.filter((x) => !shown.includes(x)),
|
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
* press that home-app.js handles. Text from the records goes through esc(). */
|
|
12
12
|
|
|
13
13
|
import { STEPS } from './premium-initiative-head.js';
|
|
14
|
-
import { whenOf } from './home-list.js';
|
|
14
|
+
import { whenOf, foldRows, foldLabel } from './home-list.js';
|
|
15
15
|
import { chipHtml } from './cozy-pick.js'; // the one product picker Home, Board and Insights share (batch 12 item 5)
|
|
16
16
|
import { ringHtml } from './home-line.js';
|
|
17
17
|
import { gripHtml, sugHtml } from './prog-order.js'; // a program's order: the grip and ✦ (canvas RoADrag, RoAPhone)
|
|
@@ -178,24 +178,24 @@ function productHtml(g, o) {
|
|
|
178
178
|
if (!open) return `${sec}${head}</section>`;
|
|
179
179
|
return `${sec}${head}<div class="hv-card">${productBody(g, o, true)}</div></section>`;
|
|
180
180
|
}
|
|
181
|
-
/** A
|
|
182
|
-
|
|
181
|
+
/** A fold line under a group (home-nav-rows-with-a-call): "N more" (· N running) opens the folded rows in place, "Fewer" folds them back. */
|
|
182
|
+
function foldHtml(key, F) {
|
|
183
|
+
return F.more > 0 ? `<button type="button" class="hv-fold" data-hm-rest="${esc(key)}" aria-expanded="false" aria-label="${F.more} more ${F.more === 1 ? 'initiative' : 'initiatives'} with nothing for you${F.running ? ', ' + F.running + ' running' : ''}. Show"><span class="hv-mk"></span>${foldLabel(F.more, F.running)}${svg(P.chevD, 16)}</button>`
|
|
184
|
+
: F.fewer ? `<button type="button" class="hv-fold" data-hm-rest="${esc(key)}" aria-expanded="true"><span class="hv-mk"></span>Fewer${svg(P.chevU, 16)}</button>` : '';
|
|
185
|
+
}
|
|
186
|
+
/** A product's rows: its own next steps, then only the initiatives with a call, the open one always shown; the rest fold to "N more".
|
|
187
|
+
* po: the grip arranges them (the list); the folded rail's card shows the same rows without it. */
|
|
183
188
|
function productBody(g, o, po) {
|
|
184
189
|
const pinned = (x) => (o.pin.has(x.key) ? 0 : 1);
|
|
185
190
|
// say it once (home-your-move-waiting): the weekly update leaves the list while Your move at the top of Home holds it
|
|
186
191
|
const held = o.held && o.held.update ? (r) => r.kind === 'update' : () => false;
|
|
187
192
|
const flat = g.flat.filter((r) => !held(r)).slice().sort((a, b) => pinned(a) - pinned(b)).map((r) => rowHtml(r, o)).join('');
|
|
188
|
-
const QUIET = 3;
|
|
189
|
-
const restAll = o.restOpen(g.key);
|
|
190
193
|
// the open initiative always shows, wherever the PM's order puts it (batch 14 item 8)
|
|
191
|
-
const
|
|
192
|
-
const more = g.rest.length - rest.length;
|
|
194
|
+
const F = foldRows(g.inis.concat(g.rest), { open: o.restOpen(g.key), sel: o.sel });
|
|
193
195
|
// the product's initiatives are one list the grip arranges, shared with the Board (batch 14 item 8)
|
|
194
|
-
const inis =
|
|
195
|
-
const body = flat + (po ? `<div class="po-list" data-po-list="@${esc(prodKey(g.name))}">${inis}</div>` : inis)
|
|
196
|
-
|
|
197
|
-
: restAll && g.rest.length > QUIET ? `<button type="button" class="hv-fold" data-hm-rest="${esc(g.key)}" aria-expanded="true"><span class="hv-mk"></span>Fewer${svg(P.chevU, 16)}</button>` : '');
|
|
198
|
-
return g.inis.length + rest.length + g.flat.length ? body : `<p class="hm-none">${g.primary ? 'No initiative is open on this board.' : 'Nothing is open here.'}</p>`;
|
|
196
|
+
const inis = F.shown.map((r) => iniHtml(r, { ...o, gk: g.key }, po)).join('');
|
|
197
|
+
const body = flat + (po ? `<div class="po-list" data-po-list="@${esc(prodKey(g.name))}">${inis}</div>` : inis) + foldHtml(g.key, F);
|
|
198
|
+
return F.shown.length + F.more + g.flat.length ? body : `<p class="hm-none">${g.primary ? 'No initiative is open on this board.' : 'Nothing is open here.'}</p>`;
|
|
199
199
|
}
|
|
200
200
|
/** A program's group (canvas PgHomePhone, PgHomeDesk): above the products. Its header: the program tile, the name, the next milestone's
|
|
201
201
|
* diamond with its date and one small diamond per initiative it waits on (filled when that initiative is past the Deliver milestone), a chevron.
|
|
@@ -225,11 +225,17 @@ function msHtml(g) {
|
|
|
225
225
|
/** A program's rows: its milestone row first, then its initiatives, under a product sub-heading when they come from two or more products. */
|
|
226
226
|
function programBody(g, o, po) {
|
|
227
227
|
const many = g.subs.length > 1;
|
|
228
|
-
|
|
228
|
+
// the same rule as a product's (home-nav-rows-with-a-call): only the rows with a call, the rest fold into one line under the program
|
|
229
|
+
const open = o.restOpen(g.key), F = { more: 0, running: 0, fewer: false };
|
|
230
|
+
const body = g.subs.map((x) => {
|
|
231
|
+
const f = foldRows(x.inis, { open, sel: o.sel });
|
|
232
|
+
F.more += f.more; F.running += f.running; F.fewer = F.fewer || f.fewer;
|
|
233
|
+
if (!f.shown.length) return '';
|
|
234
|
+
const inis = f.shown.map((r) => iniHtml(r, { ...o, gk: g.key }, po)).join(''); return `${many ? `<div class="hv-psub" role="heading" aria-level="3"><span class="hv-st2 t${x.tone}" aria-hidden="true">${esc(x.initials)}</span>${esc(x.name)}</div>` : ''}${po ? `<div class="po-list" data-po-list="${esc(g.program.id)}">${inis}</div>` : inis}`; }).join('');
|
|
229
235
|
// the program's milestone changes that wait on the PM lead its card (batch 14 item 4: they were only in Your day, which a desktop no longer has)
|
|
230
236
|
// say it once (home-your-move-waiting): the milestone changes leave the card while Your move at the top of Home holds them
|
|
231
237
|
const msr = g.msRow && !(o.held && o.held.programs && o.held.programs.has(g.program.id)) ? `<div class="hm-r hv-r${o.sel === g.msRow.id ? ' sel' : ''}" data-id="${esc(g.msRow.id)}"><button type="button" class="hm-rm" data-hm-sel="${esc(g.msRow.id)}" aria-label="${esc(g.msRow.hint)}. Waits on you. Open the program"><span class="hv-mk"><span class="hv-d" aria-hidden="true"></span></span><span class="hm-rt"><b>${esc(g.msRow.hint)}</b></span></button></div>` : '';
|
|
232
|
-
return msr + (body || `<p class="hm-none">${(g.program.members || []).length ? 'No open initiatives' : 'No initiatives yet'}. Open the program to move some in.</p>`);
|
|
238
|
+
return msr + (body || F.more ? body + foldHtml(g.key, F) : `<p class="hm-none">${(g.program.members || []).length ? 'No open initiatives' : 'No initiatives yet'}. Open the program to move some in.</p>`);
|
|
233
239
|
}
|
|
234
240
|
/** Which group holds what is open (o.sel: a row id, or 'i:<initiative>'): the folded rail marks that group's tile (batch 18 item 14, FlA4After).
|
|
235
241
|
* Nothing in a group is open: null. */
|