create-pmos 0.535.0 → 0.537.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/package.json +27 -41
  2. package/payload/KIT-VERSION +1 -1
  3. package/payload/planning/evals/eval-calibration.md +1 -1
  4. package/payload/planning/okrs/health-budgets.md +1 -1
  5. package/payload/state/discoveries.md +1 -1
  6. package/workspace/board-programs-test.js +18 -13
  7. package/workspace/board-publish-ui-test.js +1 -1
  8. package/workspace/board-shared-ui-test.js +3 -3
  9. package/workspace/board-workflows-test.js +26 -32
  10. package/workspace/briefing-premium-board-test.js +34 -29
  11. package/workspace/changelog.json +26 -0
  12. package/workspace/fixtures/board-workflows-facts.js +7 -1
  13. package/workspace/guide/board.md +12 -1
  14. package/workspace/guide/programs.md +2 -2
  15. package/workspace/guide/reports.md +11 -1
  16. package/workspace/lib/report-engine.js +27 -6
  17. package/workspace/lib/report-library.js +1 -1
  18. package/workspace/lib/report-orders.js +218 -0
  19. package/workspace/lib/route-modules.js +1 -0
  20. package/workspace/lib/routes-report-flow.js +1 -1
  21. package/workspace/lib/routes-report-orders.js +161 -0
  22. package/workspace/package-lock.json +2 -2
  23. package/workspace/package.json +1 -1
  24. package/workspace/premium-vw-jira-test.js +1 -1
  25. package/workspace/public/pm/bd-acts.js +16 -11
  26. package/workspace/public/pm/bd-publish.js +1 -1
  27. package/workspace/public/pm/bd-wf.js +5 -28
  28. package/workspace/public/pm/cozy-board.css +64 -31
  29. package/workspace/public/pm/cozy-vw-rp.css +40 -0
  30. package/workspace/public/pm/premium-board.js +85 -52
  31. package/workspace/public/pm/premium-report-read.js +90 -9
  32. package/workspace/public/pm/readonly.js +1 -1
  33. package/workspace/public/pm/report-orders-ui.js +115 -0
  34. package/workspace/public/premium-board.html +27 -30
  35. package/workspace/skills/report-write.skill +1 -1
  36. package/workspace/test-lists/report-orders.json +11 -0
@@ -0,0 +1,115 @@
1
+ /* pm/report-orders-ui.js — the orders of a report draft in the report Viewer (batch 27 item 16; main canvas TpA, TpD, TpE). Pure html builders;
2
+ * premium-report-read.js holds the state and the presses (data-r="ord|…") and reads GET /api/report-orders (lib/routes-report-orders.js).
3
+ * The app says "order", never "template".
4
+ *
5
+ * rowHtml(S, o) the order line in the summary: the order's name as a chip (zero is silence for the standard order), the grid icon that
6
+ * opens the gallery (a draft), the bookmark (save as my order), Undo while its day lasts, and the next cycle's order
7
+ * assHtml(S, o) the one ✦ under the slide: Claude's pick (✕ · grid · ✓ redraft) | "Redrafting in …" | after the PM edited an order,
8
+ * "You changed this order … Save it as yours?" (✕ · bookmark). Nothing to say → ''.
9
+ * galHtml(S, G, o) the gallery: Now, then Mine, then the seven PMOS orders, each with the pictures of its first four layouts and its slide
10
+ * count; My slides; a pressed card shows its slides, its parts, what it adds or drops, and ✓ (Redraft in this order, or
11
+ * Use from the next cycle on an agreed outline). Rename and Delete on Mine only.
12
+ * S = the GET answer · G = { sel, i, ren } · o = { esc, ic, slideCard, pics(id) → [slide] | null, now: [slide], busy, hidden: Set, issued }
13
+ */
14
+
15
+ const keyOf = (S, k) => k + ':' + (S && S.slot) + ':' + ((S && S.pick && S.pick.id) || (S && S.now && S.now.id) || '');
16
+ export const hideKey = keyOf;
17
+ const words = (L) => (L.length <= 1 ? L.join('') : L.slice(0, -1).join(', ') + ' and ' + L[L.length - 1]);
18
+ const ALWAYS = new Set(['overview', 'sources']);
19
+ /** "adds Why, Scope and People; drops The week" (pure). */
20
+ export function diffWords(d) {
21
+ const a = (d && d.adds) || [], r = (d && d.drops) || [];
22
+ if (!a.length && !r.length) return 'Same parts as your draft.';
23
+ return 'Compared with your draft: ' + [a.length ? 'adds ' + words(a) : '', r.length ? 'drops ' + words(r) : ''].filter(Boolean).join('; ') + '.';
24
+ }
25
+ const btn = (o, act, icon, label, cls = '') => `<button type="button" class="rp-tl vz-hv ro-ib${cls}" data-r="${o.esc(act)}" aria-label="${o.esc(label)}" title="${o.esc(label)}"${o.busy ? ' disabled' : ''}>${o.ic(icon, 16)}</button>`;
26
+
27
+ /** The order line under the summary. */
28
+ export function rowHtml(S, o) {
29
+ if (!S || !S.ok) return '';
30
+ const e = o.esc, n = S.now || {}, out = [];
31
+ const named = n.kind !== 'standard';
32
+ if (!o.issued) out.push(`<button type="button" class="rp-mc ro-chip" data-r="ord|gal" aria-label="${e(named ? n.name + ': see the orders' : 'See the orders')}" title="See the orders">${o.ic('grid', 14)}${named ? e(n.name) + (n.edited ? ', edited' : '') : ''}</button>`);
33
+ else if (named) out.push(`<span class="rp-mc ro-chip">${o.ic('grid', 14)}${e(n.name)}</span>`);
34
+ if (S.next) out.push(`<span class="rp-mc ro-next">Next cycle: ${e(S.next.name)}</span>`);
35
+ if (S.engine) out.push(btn(o, 'ord|save', 'mark', 'Save as my order'));
36
+ if (S.undo && S.undo.state !== 'drafting' && !o.issued) out.push(btn(o, 'ord|undo', 'undo', 'Undo the redraft'));
37
+ return `<div class="rp-mcs ro-row">${out.join('')}</div>`;
38
+ }
39
+
40
+ const parts = (o, list, adds, cls) => list.filter((p) => !ALWAYS.has(p.layout)).map((p) => `<span class="ro-pt${adds && adds.includes(p.part) ? ' add' : ''}${cls || ''}">${o.esc(p.part)}</span>`).join('');
41
+ /** The one ✦ under the slide. */
42
+ export function assHtml(S, o) {
43
+ if (!S || !S.ok || o.issued) return '';
44
+ const e = o.esc, h = o.hidden || new Set();
45
+ const U = S.undo;
46
+ if (U && U.state !== 'done' && U.order) {
47
+ const late = U.state === 'late';
48
+ return `<div class="ro-ass" role="status"><p><b class="ro-st" aria-hidden="true">✦</b> ${late ? 'The redraft in the ' + e(U.order.name) + ' order has not landed yet.' : 'Redrafting in the ' + e(U.order.name) + ' order.'}</p>`
49
+ + `<p class="ro-note">${late ? 'Undo puts the draft back as it was.' : 'It takes a few minutes. Every reading stays; the new draft shows here when it lands.'}</p></div>`;
50
+ }
51
+ if (S.pick && !h.has(keyOf(S, 'pick'))) {
52
+ const ord = (S.orders || []).find((x) => x.id === S.pick.id);
53
+ if (!ord) return '';
54
+ return `<div class="ro-ass" role="group" aria-label="Claude's pick"><p><b class="ro-st" aria-hidden="true">✦</b> The ${e(ord.name)} order fits this report's question.</p>`
55
+ + `<p class="ro-pts">${parts(o, ord.parts, S.pick.adds)}${(S.pick.drops || []).map((x) => `<span class="ro-pt cut">${e(x)}</span>`).join('')}</p>`
56
+ + `<p class="ro-note">Blue is added${(S.pick.drops || []).length ? ', struck through is dropped' : ''}. Every reading stays.</p>`
57
+ + `<div class="ro-acts">${btn(o, 'ord|hide|pick', 'x', 'Not now')}${btn(o, 'ord|open|' + ord.id, 'grid', 'See it with the other orders')}${btn(o, 'ord|apply|' + ord.id, 'check', 'Redraft in this order', ' rp-pri')}</div></div>`;
58
+ }
59
+ const n = S.now || {};
60
+ if (S.engine && n.kind === 'order' && n.edited && !h.has(keyOf(S, 'edit'))) {
61
+ const c = n.changes || {}, said = [(c.drops || []).length ? 'dropped ' + words(c.drops.map((x) => '“' + x + '”')) : '', (c.adds || []).length ? 'added ' + words(c.adds.map((x) => '“' + x + '”')) : ''].filter(Boolean).join(', ');
62
+ return `<div class="ro-ass" role="group" aria-label="Save your order"><p><b class="ro-st" aria-hidden="true">✦</b> You changed the ${e(n.name)} order${said ? ': ' + e(said) : ''}. Save it as yours?</p>`
63
+ + `<p class="ro-pts">${parts(o, n.parts, c.adds)}</p><p class="ro-note">It saves the parts and their slide layouts. Not the numbers or the words.</p>`
64
+ + `<div class="ro-acts">${btn(o, 'ord|hide|edit', 'x', 'Not now')}${btn(o, 'ord|save', 'mark', 'Save as my order', ' rp-pri')}</div></div>`;
65
+ }
66
+ return '';
67
+ }
68
+
69
+ /** Up to four pictures of an order's layouts (real slides, drawn small). Until they are read: grey boxes. */
70
+ function pics(o, L, n = 4) {
71
+ if (!L) return `<span class="ro-pics" aria-hidden="true">${'<span class="ro-pic ro-wait"></span>'.repeat(n)}</span>`;
72
+ return `<span class="ro-pics" aria-hidden="true">${L.slice(0, n).map((s) => `<span class="ro-pic">${o.slideCard(s, true)}</span>`).join('')}</span>`;
73
+ }
74
+ const more = (n) => n + (n === 1 ? ' slide' : ' slides') + (n > 4 ? ' · +' + (n - 4) + ' more' : '');
75
+ function cardHtml(S, o, c) {
76
+ const e = o.esc, mark = c.now ? '<span class="ro-tag">Now</span>' : c.mine ? '<span class="ro-tag">Mine</span>' : S.pick && S.pick.id === c.id ? '<span class="ro-tag ro-star" aria-label="Claude\'s pick">✦</span>' : '';
77
+ return `<button type="button" class="ro-card${c.now ? ' now' : ''}" data-r="ord|open|${e(c.id)}"${c.now ? ' aria-current="true"' : ''}>${pics(o, c.now ? o.now : o.pics(c.id))}`
78
+ + `<span class="ro-cn">${mark}<b>${e(c.name)}</b></span><small>${more(c.n)}</small></button>`;
79
+ }
80
+ /** The gallery (TpD), or one order pressed open. */
81
+ export function galHtml(S, G, o) {
82
+ if (!S || !S.ok) return '<p class="vz-empty" role="status">Reading the orders.</p>';
83
+ const e = o.esc;
84
+ const close = `<button type="button" class="rp-tl vz-hv ro-ib" data-r="ord|close" aria-label="Close the orders" title="Close">${o.ic('x', 16)}</button>`;
85
+ if (G.sel) return detailHtml(S, G, o);
86
+ const n = S.now || {};
87
+ const head = S.now.kind === 'agreed'
88
+ ? `<p class="ro-note">Your readers agreed this order${n.since ? ' when the ' + e(n.since) + ' report went out' : ''}. A pick here is used from the next cycle; today's draft stays as agreed.</p>`
89
+ : S.pick ? `<p class="ro-note"><b class="ro-st" aria-hidden="true">✦</b> The ${e((S.orders.find((x) => x.id === S.pick.id) || {}).name || '')} order fits this report's question. Press a card to see it, or pick another.</p>` : '';
90
+ const cards = [{ id: 'now', now: true, name: n.name, n: (o.now || []).length || n.parts.length }].concat(S.orders.filter((x) => x.mine), S.orders.filter((x) => !x.mine));
91
+ const sl = (S.slides || []).length ? `<p class="rp-lbl">My slides</p><div class="ro-slides">${S.slides.map((s) => `<button type="button" class="ro-sl" data-r="ord|open|${e(s.id)}">${pics(o, o.pics(s.id), 1)}<small>${e(s.name)}</small></button>`).join('')}</div>` : '';
92
+ return `<div class="ro-gal" role="region" aria-label="Orders"><div class="ro-gh"><b>Orders</b>${close}</div>${head}`
93
+ + `<div class="ro-grid">${cards.map((c) => cardHtml(S, o, c)).join('')}</div>${sl}`
94
+ + `<p class="ro-note">An order is a default order of slides. The writer keeps every reading and may add or drop a part.</p></div>`;
95
+ }
96
+ function detailHtml(S, G, o) {
97
+ const e = o.esc;
98
+ const isNow = G.sel === 'now';
99
+ const slide = (S.slides || []).find((x) => x.id === G.sel);
100
+ const ord = isNow ? { id: 'now', name: S.now.name, n: (o.now || []).length, parts: S.now.parts } : slide ? { id: slide.id, name: slide.name, n: 1, parts: [{ part: slide.part, layout: slide.layout }], mine: true, slide: true } : S.orders.find((x) => x.id === G.sel);
101
+ if (!ord) return '';
102
+ const L = isNow ? o.now : o.pics(ord.id);
103
+ const i = Math.max(0, Math.min(G.i || 0, L ? L.length - 1 : 0));
104
+ const big = L && L[i] ? `<div class="vz-slide ro-big">${o.slideCard(L[i], false)}</div>` : '<div class="vz-slide ro-big"><span class="ro-pic ro-wait"></span></div>';
105
+ const strip = L && L.length > 1 ? `<div class="vz-thumbs rp-thumbs ro-strip" role="group" aria-label="Slides">${L.map((s, j) => `<button type="button" class="vz-th rp-th" data-r="ord|at|${j}"${j === i ? ' aria-current="true"' : ''} aria-label="Slide ${j + 1}: ${e(s.h)}"><span>${o.slideCard(s, true)}</span></button>`).join('')}</div>` : '';
106
+ const agreed = S.now.kind === 'agreed';
107
+ const sub = isNow ? 'Now' : ord.slide ? 'My slide · its layout only' : (ord.mine ? 'Mine · ' : '') + more(ord.n).split(' · ')[0] + (ord.sub ? ' · ' + ord.sub : '');
108
+ const diff = isNow || ord.slide ? '' : `<p class="ro-note">${e(diffWords(ord))}${agreed ? ' From the next cycle: today\'s draft stays as agreed.' : ' Every reading stays.'}</p>`;
109
+ const ren = G.ren ? `<div class="ro-ren"><label class="vz-lab" for="roName">Name</label><input id="roName" data-r="ord-name" value="${e(G.ren)}" maxlength="80"><button type="button" class="rp-tl vz-hv ro-ib rp-pri" data-r="ord|renok|${e(ord.id)}" aria-label="Keep this name" title="Keep this name"${o.busy ? ' disabled' : ''}>${o.ic('check', 16)}</button></div>` : '';
110
+ const acts = [btn(o, 'ord|back', 'prev', 'Back to the orders')];
111
+ if (ord.mine) acts.push(btn(o, 'ord|del|' + ord.id, 'bin', 'Delete'), btn(o, 'ord|ren|' + ord.id, 'pen', 'Rename'));
112
+ if (!isNow && !ord.slide && !o.issued) acts.push(btn(o, 'ord|apply|' + ord.id, 'check', agreed ? 'Use from the next cycle' : 'Redraft in this order', ' rp-pri'));
113
+ return `<div class="ro-gal ro-one" role="region" aria-label="${e(ord.name)}"><div class="ro-gh"><span><b>${e(ord.name)}</b><small>${e(sub)}</small></span></div>${big}${strip}`
114
+ + `<p class="ro-pts">${ord.parts.map((p, j) => `<span class="ro-pt${!isNow && j === i ? ' on' : ''}">${e(p.part)}</span>`).join('')}</p>${diff}${ren}<div class="ro-acts">${acts.join('')}</div></div>`;
115
+ }
@@ -22,54 +22,51 @@
22
22
  are the side panel below (initiative premium-agreed-design). -->
23
23
  <main class="stage cz-panel bd-main" id="stage">
24
24
  <h1 class="vh">Board</h1>
25
- <!-- the toolbar (AgBoard): the product picker; the view toggle, Find, Filter, the bell, New initiative and ⋯. On a phone (AgBoardPhone):
26
- the picker, "Board", Find, Filter, one view button and New initiative (BdPhone). -->
25
+ <!-- the toolbar in ONE row (batch 28 item 3, canvas BhA), the same pieces in the same order on a phone and a desktop: the product picker, the
26
+ view, what needs a look, then Find, the tune button and a quiet blue New. A desktop has the room, so the four views and the span stay visible
27
+ and Group, Sort, Filter and Shared are their own buttons; a phone puts the views, the span and Shared behind the view button, and Group, Sort,
28
+ Filter and the Jira read behind the tune button. No workflow chips: the Board does not pick a workflow (bd-wf.js). -->
27
29
  <div class="bd-hd">
28
30
  <div id="crumbHost" class="bd-pickw"></div>
29
- <!-- a phone's span picker on the timeline (TsCPhone, TsCPhoneSpan): the span buttons become one picker beside the product picker -->
30
- <span class="bd-grpw2 bd-spw" id="bdSpanPick" hidden></span>
31
- <span class="bd-title" aria-hidden="true">Board</span>
31
+ <!-- a phone's view button (BhA): the four views, the span on the timeline, Shared with me -->
32
+ <span class="bd-grpw2 bd-vieww bd-show-s" id="bdVieww"><button type="button" class="bd-chip bd-vbtn" id="bdView" aria-haspopup="true" aria-expanded="false" aria-controls="bdViewMenu" aria-label="View. Change view" title="View"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M9 6h11M9 12h11M9 18h11M4.5 6h.01M4.5 12h.01M4.5 18h.01"/></svg><svg class="bd-chv" viewBox="0 0 24 24" aria-hidden="true"><path d="M7 10l5 5 5-5"/></svg></button><span class="bd-grpm bd-viewm" id="bdViewMenu" role="group" aria-label="View" hidden></span></span>
33
+ <div class="bd-seg bd-views" id="ibTabs" role="group" aria-label="View">
34
+ <button type="button" data-v="list" aria-pressed="false" title="List: every initiative, one row each">List</button>
35
+ <button type="button" data-v="stages" aria-pressed="false" title="By stage: a column for each stage">By stage</button>
36
+ <button type="button" data-v="track" aria-pressed="true" title="Stage track: each initiative on its stages">Track</button>
37
+ <button type="button" data-v="time" aria-pressed="false" title="Timeline: each initiative on its dates">Timeline</button>
38
+ </div>
39
+ <!-- the span picker (batch 24 item 7, canvas BbB): one chip that opens Sprint to 5 yr; a desktop timeline only (a phone has it in the view button) -->
40
+ <span class="bd-grpw2 bd-spw" id="bdSpans" role="group" aria-label="Span" hidden></span>
41
+ <!-- what needs a look: one pill of dots and numbers; on a desktop timeline the legend behind (i) and the sprints and releases -->
42
+ <div class="bd-chipset" id="bdChipset"></div>
32
43
  <div class="bd-tools">
33
- <div class="bd-seg bd-views" id="ibTabs" role="group" aria-label="View">
34
- <button type="button" class="bd-ib" data-v="stages" aria-pressed="false" aria-label="By stage: a column for each stage" title="By stage: a column for each stage"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M4 4h4v16H4zM10 4h4v10h-4zM16 4h4v13h-4z"/></svg></button>
35
- <button type="button" class="bd-ib" data-v="track" aria-pressed="true" aria-label="Stage track: each initiative on its stages" title="Stage track: each initiative on its stages"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M3 5h18v4H3zM3 11h18v4H3zM3 17h12v3H3z"/></svg></button>
36
- <button type="button" class="bd-ib" data-v="time" aria-pressed="false" aria-label="Timeline: each initiative on its dates" title="Timeline: each initiative on its dates"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M4 6h9M8 12h11M6 18h7"/></svg></button>
37
- <button type="button" class="bd-ib" data-v="list" aria-pressed="false" aria-label="List: every initiative, one row each" title="List: every initiative, one row each"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M9 6h11M9 12h11M9 18h11M4.5 6h.01M4.5 12h.01M4.5 18h.01"/></svg></button>
38
- </div>
44
+ <!-- the Jira read as Adler's face (desktop; a phone has it in the tune sheet) -->
45
+ <span class="bd-jiraw bd-hide-s" id="bdJiraw"></span>
46
+ <button type="button" class="bd-ib" id="bdFind" aria-label="Find an initiative or work-item" title="Find an initiative or work-item" aria-haspopup="dialog"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M11 4a7 7 0 1 0 0 14a7 7 0 1 0 0-14M20 20l-4-4"/></svg></button>
39
47
  <!-- the grouping (PgBoard, PgBoardProduct): programs first, or By product; shown only when a program holds an initiative of this board -->
40
48
  <span class="bd-grpw2 bd-hide-s" id="bdGrpw" hidden></span>
41
- <span class="bd-vr bd-hide-s"></span>
42
- <button type="button" class="bd-ib" id="bdFind" aria-label="Find an initiative or work-item" title="Find an initiative or work-item" aria-haspopup="dialog"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M11 4a7 7 0 1 0 0 14a7 7 0 1 0 0-14M20 20l-4-4"/></svg></button>
43
- <button type="button" class="bd-ib bd-show-s" id="bdView" aria-label="Change view" title="Change view"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M3 5h18v4H3zM3 11h18v4H3zM3 17h12v3H3z"/></svg></button>
49
+ <button type="button" class="bd-ib bd-hide-s" id="bdSort" data-so-btn aria-haspopup="menu" aria-label="Sort. Now: My order" title="Sort · My order"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M7 4v16M4 17l3 3 3-3M13 6h8M13 12h6M13 18h4"/></svg></button>
50
+ <!-- Filter on a desktop; on a phone the tune button: group, sort, filter and the Jira read, with a dot when something needs a look -->
51
+ <button type="button" class="bd-ib" id="bdFilter" aria-label="Filter by owner, category or sprint" title="Filter by owner, category or sprint" aria-haspopup="dialog"><svg class="bd-icf" viewBox="0 0 24 24" aria-hidden="true"><path d="M4 5h16l-6 8v6l-4-2v-4z"/></svg><svg class="bd-ict" viewBox="0 0 24 24" aria-hidden="true"><path d="M4 7h9M17 7h3M4 17h3M11 17h9M15 5v4M9 15v4"/></svg><i class="bd-pip bd-tune-pip" hidden></i></button>
44
52
  <!-- the timeline's columns (batch 19 item 5, StsA8Board): which show beside the names; a desktop timeline only -->
45
53
  <span class="bd-grpw2" id="bdColsw" hidden><button type="button" class="bd-ib" id="bdCols" aria-haspopup="true" aria-expanded="false" aria-controls="bdColsMenu" aria-label="Columns" title="Columns"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M4 5h16v14H4zM10 5v14M15 5v14"/></svg></button><span class="bd-grpm bd-colm" id="bdColsMenu" role="group" aria-labelledby="bdColsH" hidden></span></span>
46
- <button type="button" class="bd-ib" id="bdSort" data-so-btn aria-haspopup="menu" aria-label="Sort. Now: My order" title="Sort · My order"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M7 4v16M4 17l3 3 3-3M13 6h8M13 12h6M13 18h4"/></svg></button>
47
- <button type="button" class="bd-ib" id="bdFilter" aria-label="Filter by owner, kind or sprint" title="Filter by owner, kind or sprint" aria-haspopup="dialog"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M4 5h16l-6 8v6l-4-2v-4z"/></svg></button>
54
+ <!-- Shared (initiative board-publish): the boards shared with you; pressed again, back to the initiatives -->
55
+ <button type="button" class="bd-chip bd-shb bd-hide-s" id="tabShared" aria-pressed="false" aria-controls="cShared">Shared <span class="n" id="nShared"></span></button>
48
56
  <button type="button" class="bd-ib bd-hide-s" id="bdBell" aria-label="Notifications" title="Notifications" aria-haspopup="dialog"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M6 16v-5a6 6 0 0 1 12 0v5l2 2H4zM10 21h4"/></svg></button>
49
57
  <button type="button" class="bd-ib bd-hide-s" id="bdPublish" aria-label="Publish a read-only copy of the board" title="Publish a read-only copy" aria-haspopup="dialog" aria-expanded="false" hidden><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M12 15V4M8 8l4-4 4 4M5 13v5a2 2 0 0 0 2 2h10a2 2 0 0 0 2-2v-5"/></svg><span class="bpn" hidden></span></button>
50
- <button type="button" class="bd-ib solid" id="newIni" aria-label="New program or initiative" title="New program or initiative" aria-haspopup="menu"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M12 5v14M5 12h14"/></svg></button>
58
+ <button type="button" class="bd-ib bd-new" id="newIni" aria-label="New program or initiative" title="New program or initiative" aria-haspopup="menu"><svg viewBox="0 0 24 24" aria-hidden="true"><path d="M12 5v14M5 12h14"/></svg></button>
51
59
  <div class="tools tools-top"><span class="vh" id="snap" role="status">Reading the board</span></div>
52
60
  </div>
53
61
  </div>
54
- <!-- the tabs (Initiatives, Shared; batch 24 item 7 took Documents off: an initiative's Documents fold and Search's Documents filter reach them),
55
- the span picker and the chips: sprint and release, This sprint, one pill for new asks, late, at risk, blocked and idle, the legend behind (i), Jira as Adler -->
56
- <div class="bd-chiprow">
57
- <div class="bd-tabs" role="tablist" aria-label="Board">
58
- <button type="button" role="tab" class="bd-tab" id="tabIni" aria-selected="true" aria-controls="cIni">Initiatives <span class="n" id="nIni"></span></button>
59
- <button type="button" role="tab" class="bd-tab" id="tabShared" aria-selected="false" aria-controls="cShared">Shared <span class="n" id="nShared"></span></button>
60
- </div>
61
- <!-- the span picker (batch 24 item 7, canvas BbB): one chip that opens Sprint to 5 yr; the timeline only -->
62
- <span class="bd-grpw2 bd-spw" id="bdSpans" role="group" aria-label="Span" hidden></span>
63
- <div class="bd-chipset" id="bdChipset"></div>
64
- </div>
65
62
 
66
- <section class="bd-sec" id="cIni" role="tabpanel" aria-labelledby="tabIni">
63
+ <section class="bd-sec" id="cIni" aria-labelledby="hIni">
67
64
  <h2 class="vh" id="hIni">Initiatives</h2>
68
65
  <div id="bdShowing" hidden></div>
69
66
  <!-- the skeleton until the board is read (page-open-speed, SpD): grey rows shaped like programs and initiatives, no names, no counts -->
70
67
  <div id="ibBody"><div class="ls-bd" aria-hidden="true"><div class="ls-bh"><i class="ls-sk ls-w40"></i><span class="ls-stg"><i class="ls-sk"></i><i class="ls-sk"></i><i class="ls-sk"></i><i class="ls-sk"></i><i class="ls-sk"></i><i class="ls-sk"></i><i class="ls-sk"></i><i class="ls-sk"></i></span><i class="ls-sk ls-w30"></i></div><div class="ls-br pg"><i class="ls-sk ls-w60"></i><span></span><i class="ls-sk ls-w55"></i></div><div class="ls-br"><i class="ls-sk ls-w75"></i><div class="ls-trk"><i class="ls-tdot"></i><i class="ls-tdot on"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i></div><i class="ls-sk ls-w70"></i></div><div class="ls-br"><i class="ls-sk ls-w75"></i><div class="ls-trk"><i class="ls-tdot"></i><i class="ls-tdot on"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i></div><i class="ls-sk ls-w70"></i></div><div class="ls-br pg"><i class="ls-sk ls-w60"></i><span></span><i class="ls-sk ls-w55"></i></div><div class="ls-br"><i class="ls-sk ls-w75"></i><div class="ls-trk"><i class="ls-tdot"></i><i class="ls-tdot on"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i></div><i class="ls-sk ls-w70"></i></div><div class="ls-br pg"><i class="ls-sk ls-w60"></i><span></span><i class="ls-sk ls-w55"></i></div><div class="ls-br"><i class="ls-sk ls-w75"></i><div class="ls-trk"><i class="ls-tdot"></i><i class="ls-tdot on"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i><i class="ls-tdot"></i></div><i class="ls-sk ls-w70"></i></div></div></div>
71
68
  </section>
72
- <section class="bd-sec" id="cShared" role="tabpanel" aria-labelledby="tabShared" hidden></section>
69
+ <section class="bd-sec" id="cShared" aria-label="Shared with me" hidden></section>
73
70
 
74
71
  <!-- the help frame: what finishes each step (the step heads open it) -->
75
72
  <div class="bd-pop bd-pop-xw" id="popSteps" role="dialog" aria-labelledby="hSteps" hidden></div>
@@ -33,7 +33,7 @@ Procedure:
33
33
  5. Choose the outline for these readers and this question. Any sections, any titles, any order.
34
34
  - A recurring report keeps `agreed_outline`, the sections of its last issued issue. Add a section only when a finding needs one, drop one only when it would be empty, and say so in `outline_note` (one line).
35
35
  - `earlier_outline` is the shape of an issue written before the engine (the old fixed frame). It is an example, not an agreement: keep what served the readers.
36
- - `template` is set when the PM started the report from a report template (`pmos report make <id> --template <name>`; `pmos report library --json` lists them). Its `outline` is a default order of parts, each with its slide layout: use it as the starting outline, retitle each part as a finding, and add or drop a part when the findings say so. An agreed outline wins over a template.
36
+ - `template` is set when the PM started the report from a report template (`pmos report make <id> --template <name>`; `pmos report library --json` lists them). Its `outline` is a default order of parts, each with its slide layout: use it as the starting outline, retitle each part as a finding, and add or drop a part when the findings say so. An agreed outline wins over a template, except when `template.chosen` is true: the PM picked that order for this cycle, so use it, and read `earlier_outline` as an example only. The template can also be an order the PM saved (its id starts with `mine-`) or one the PM applied from the report's orders; it reads the same way.
37
37
  - Each section title is a finding, not a label: "Sign-up stalls before submit", not "Sign-up". Reading only the titles tells the story.
38
38
  - Shapes other reports took, as examples and never a menu: a decision (the lean · the options and what each costs · what could reverse it · your call); a watch (today against yesterday and the week · the drop that moved most · why); a stakeholder update (are the dates on track · what each team needs and by when · open decisions · what could stop it); a review (the summary for decision · the outcomes by segment · the challenges and answers · method); did-it-work (what was promised · what we got · the verdict).
39
39
  6. Write `<slot>.report.json` (in a scratch file, then `pmos report write <id> --from <file>`):
@@ -0,0 +1,11 @@
1
+ {
2
+ "_comment": "Batch 27 item 16: apply an order to a report draft (the ✦ pick, the orders gallery's state and pictures, the redraft in the report's own session, Undo for one day, the next cycle's order on an agreed outline) and my saved orders and slides (per-user ledger). Node only.",
3
+ "modules": [
4
+ "report-orders.test.js",
5
+ "report-orders-page.test.mjs"
6
+ ],
7
+ "seconds": {
8
+ "report-orders.test.js": 2,
9
+ "report-orders-page.test.mjs": 1
10
+ }
11
+ }