create-pmos 0.616.0 → 0.618.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 +51 -45
- 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 +2 -1
- package/workspace/changelog.json +92 -1941
- package/workspace/extension/README.md +13 -1
- package/workspace/extension/panel.js +7 -5
- package/workspace/guide/layout.md +9 -4
- package/workspace/guide/notes.md +17 -3
- package/workspace/lib/board-premium.js +1 -0
- package/workspace/lib/board-trail.js +3 -1
- package/workspace/lib/core-docs.js +1 -1
- package/workspace/lib/engine/boards.js +2 -2
- package/workspace/lib/meeting-focus.js +40 -8
- package/workspace/lib/okr-goals.js +2 -1
- package/workspace/lib/routes-boards.js +20 -4
- package/workspace/lib/routes-brief-page.js +6 -2
- package/workspace/lib/routes-meeting-focus.js +3 -1
- package/workspace/lib/status-when.js +15 -2
- package/workspace/package-lock.json +2 -2
- package/workspace/package.json +1 -1
- package/workspace/premium-board-actions-test.js +1 -0
- package/workspace/public/pm/bd-work.css +5 -4
- package/workspace/public/pm/buddy-core.js +166 -0
- package/workspace/public/pm/buddy-press.js +66 -0
- package/workspace/public/pm/cozy-buddy.css +52 -0
- package/workspace/public/pm/cozy-buddy.js +115 -0
- package/workspace/public/pm/cozy-day-pick.css +9 -8
- package/workspace/public/pm/cozy-home.css +54 -2
- package/workspace/public/pm/cozy-pop-work.css +29 -0
- package/workspace/public/pm/cozy-pop-work.js +151 -13
- package/workspace/public/pm/cozy-popup.css +6 -1
- package/workspace/public/pm/cozy-popup.js +26 -7
- package/workspace/public/pm/cozy-rec-now.js +35 -4
- package/workspace/public/pm/cozy-rec-tab.js +5 -1
- package/workspace/public/pm/cozy-status-when.js +17 -2
- package/workspace/public/pm/cozy-task-pop.css +34 -0
- package/workspace/public/pm/cozy-task-pop.js +199 -0
- package/workspace/public/pm/cozy-today-app.js +13 -1
- package/workspace/public/pm/cozy-today-model.js +5 -2
- package/workspace/public/pm/cozy-today-page.css +6 -0
- package/workspace/public/pm/cozy-today-view.js +7 -3
- package/workspace/public/pm/home-app.js +8 -2
- package/workspace/public/pm/home-chat.js +13 -7
- package/workspace/public/pm/home-data.js +31 -1
- package/workspace/public/pm/home-ini.js +7 -1
- package/workspace/public/pm/page-chat.js +1 -1
- package/workspace/public/pm/premium-board.js +18 -4
- package/workspace/public/pm/premium-meeting.js +2 -2
- package/workspace/public/pm/rec-tab-core.js +5 -2
- package/workspace/public/premium-buddy.html +27 -0
- package/workspace/server.js +1 -1
- package/workspace/test-lists/chat-turns.json +9 -0
- package/workspace/test-lists/meeting-buddy.json +9 -0
|
@@ -20,7 +20,19 @@ After you update PMOS, press the reload arrow on the extension's card in `chrome
|
|
|
20
20
|
|
|
21
21
|
## The Meet panel
|
|
22
22
|
|
|
23
|
-
Open a Meet call, for example `meet.google.com/abc-defg-hij`. The panel shows at the bottom right of the call. It
|
|
23
|
+
Open a Meet call, for example `meet.google.com/abc-defg-hij`. The panel shows at the bottom right of the call. It is the PMOS meeting buddy, and only you see it. It finds the meeting on your PMOS calendar by the Meet link in the invite, then by the title of the tab, then by the meeting that is under way now. If none fits, the panel lists today's meetings to pick from.
|
|
24
|
+
|
|
25
|
+
While PMOS listens to the meeting, the panel shows:
|
|
26
|
+
|
|
27
|
+
- The topic the room is on and the minutes left, and one line on what is being said now.
|
|
28
|
+
- **Filed**: the decisions, actions and open questions PMOS heard. Each has **Undo**, which takes it out of the notes.
|
|
29
|
+
- **Context**: the initiative or the link behind a topic that came up, with a button that opens it.
|
|
30
|
+
- A time nudge, once, when 10 minutes or less are left and a topic is not covered yet.
|
|
31
|
+
- A line you can post in the call chat. **Copy** puts it on the clipboard and you paste it. PMOS never posts to the call or its chat.
|
|
32
|
+
- "Others not told yet", with a line that tells the call PMOS is taking notes, until you copy it.
|
|
33
|
+
- A line to ask PMOS quietly. The answer shows in the panel.
|
|
34
|
+
|
|
35
|
+
When PMOS is not listening, the panel has a play button. It opens the PMOS recording tab on this meeting, and Chrome asks which tab to share: pick the call and tick tab sound. **Fold** shrinks the panel to a pill, and the same button opens it again. When PMOS does not answer, the panel says "PMOS is not running at <address>" and links to the options.
|
|
24
36
|
|
|
25
37
|
## Add a page to a report design
|
|
26
38
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* panel.js — the page the content script frames over a Meet call (panel.html).
|
|
2
2
|
* It reads the PMOS address from chrome.storage.sync (pmosAddress, default http://localhost:7433) and asks whether anything answers there.
|
|
3
|
-
* When PMOS answers, the page becomes one frame: ${address}/
|
|
3
|
+
* When PMOS answers, the page becomes one frame: ${address}/premium-buddy.html?meet=…&mtitle=… (the meeting buddy, initiative meeting-buddy; the
|
|
4
|
+
* console address it framed before was removed and opened Home). When it does not,
|
|
4
5
|
* the page says where it looked and links to the options. Nothing else is fetched. The frame's { pmosFocus } message (fold or open, no data) is passed
|
|
5
6
|
* up to the content script. */
|
|
6
7
|
(function () {
|
|
@@ -28,7 +29,7 @@
|
|
|
28
29
|
function answers(addr) {
|
|
29
30
|
var ctl = typeof AbortController === 'function' ? new AbortController() : null;
|
|
30
31
|
var t = ctl ? setTimeout(function () { ctl.abort(); }, CHECK_MS) : null;
|
|
31
|
-
return fetch(addr + '/
|
|
32
|
+
return fetch(addr + '/premium-buddy.html', { mode: 'no-cors', cache: 'no-store', signal: ctl ? ctl.signal : undefined })
|
|
32
33
|
.then(function (r) { if (t) clearTimeout(t); return r; }, function (e) { if (t) clearTimeout(t); throw e; });
|
|
33
34
|
}
|
|
34
35
|
function showMissing(addr) {
|
|
@@ -42,11 +43,12 @@
|
|
|
42
43
|
msg.appendChild(a);
|
|
43
44
|
msg.appendChild(document.createTextNode('.'));
|
|
44
45
|
}
|
|
46
|
+
/** The buddy page's address for this call. */
|
|
47
|
+
function buddySrc(addr) { return addr + '/premium-buddy.html?' + new URLSearchParams({ meet: meet, mtitle: title }).toString(); }
|
|
45
48
|
function showFrame(addr) {
|
|
46
|
-
var q = new URLSearchParams({ focus: 'now', pop: '1', meet: meet, mtitle: title });
|
|
47
49
|
frame = document.createElement('iframe');
|
|
48
|
-
frame.title = 'PMOS meeting
|
|
49
|
-
frame.src = addr
|
|
50
|
+
frame.title = 'PMOS meeting buddy';
|
|
51
|
+
frame.src = buddySrc(addr);
|
|
50
52
|
frameOrigin = new URL(addr).origin;
|
|
51
53
|
msg.remove();
|
|
52
54
|
document.body.appendChild(frame);
|
|
@@ -82,7 +82,8 @@ On a computer, an initiative you open from Home, Board or Intelligence opens in
|
|
|
82
82
|
- The chat's title chooses the session. It shows your sessions, newest first, each with the work it is about and its state: **Waits for you**, **PMOS is working**, or when you last used it. **New session** starts another session about the same work. **All sessions** shows the full list with a search box, and the popup stays open.
|
|
83
83
|
- The stop icon on a live session ends it at once. **Session ended** shows with **Undo** for a few seconds, and the session moves to **Earlier**.
|
|
84
84
|
- The chat icon opens the popup on the session that waits for you, or else the newest. The left side shows that session's work, or the list of sessions when it is about no work.
|
|
85
|
-
- The
|
|
85
|
+
- The chat's top bar has the session, one quiet line under it that says what the chat is about, ⋯ and ×. ⋯ has **Open work beside the page** (it keeps work beside the page instead, as before; press it again in the popup to go back, and PMOS keeps this choice on this computer), **Hide the chat**, **Sessions** and, while the session is live, **End session**.
|
|
86
|
+
- The chat reads as on a phone: messages only, without names or times on each one. Each answer shows in full, and the small notes and steps before it fold into one line, for example "Worked 6 steps · 20 s"; press it to see them. Copy, Retry and Make it a task show on the newest answer. The box is one row: +, the words, the microphone and send.
|
|
86
87
|
- Beside the page, a panel you slide off the edge is put away. The round Live button above the chat icon then shows, and its first row brings the panel back. Otherwise the chat icon holds your sessions, and there is no Live button.
|
|
87
88
|
|
|
88
89
|
A phone keeps its own layout. A shared read-only Board has no popup.
|
|
@@ -92,11 +93,15 @@ A phone keeps its own layout. A shared read-only Board has no popup.
|
|
|
92
93
|
The work side has three parts, top to bottom.
|
|
93
94
|
|
|
94
95
|
- **Overview.** Three short lines from the initiative's own records: **Problem**, **Goal** (with the goal it serves, by name) and **Done when**. A line with no record says **Not written yet.** and offers a draft with ✓ and ✕. Press a line to change it; it saves when you leave the field, with **Undo**. Then one line on where it stands, **PMOS suggests** (at most three, each with ✓ and ✕), and **Details ›** for the facts: Stage, Status, Start, Target end, Next milestone, Goal, Product, Program, Workflow and Open. A fact with no value is not shown. Goal, Product, Program and Next milestone are in the link colour and open their thing; the others are plain text. An initiative that is closed or done but has open tasks shows one suggestion: **Close them** or **Reopen**.
|
|
95
|
-
- **Work breakdown.**
|
|
96
|
+
- **Work breakdown.** The stages are one row: the initiative's own steps, with its bar on the timeline. Press a stage to see its dates. The first line is its action: **Move to** another stage, or **Mark … done** on the stage now; after the press it asks when it happened. A done stage has a tick. Under the stages, **Tasks** is one list with the Backlog's own columns and groups (Jira ticket, Epic, Who, Due, State), this initiative's tasks only. A task has no stage. Press a task's name to open it on top. The four-corners icon shows each task with its date and bar on the timeline. **Open in Backlog** opens Work › Backlog on this initiative. When the task list cannot be read, the older view below shows instead.
|
|
97
|
+
- **Work breakdown, the older view.** Each stage is a row that folds and says how much is done, for example "3 of 9 done". Only the stage in progress opens by itself. In a long stage you see the late tasks, the tasks in progress and the next five, then **N more tasks**. Done tasks fold to one line, and the stages after the next one fold to one row. **Not in a stage** is one folded row at the end; open it to see its tasks (PMOS remembers this for each initiative), or press ✓ on its suggestion to put them in the stage in progress, with **Undo**. The timeline is on the right, with **Today** on it. Drag the grip between the columns and the timeline to make the timeline wider or narrower; a double press puts it back. Choose its span (Quarter to Full) beside the tune icon, which shows or hides columns. The four-corners icon gives the breakdown the whole popup. Type in the last row of a stage to add a task; the **Task** choice beside it makes the next one a milestone.
|
|
96
98
|
- **Status.** Press a task's status and pick the new one. **When did this happen?** shows under the list, with **Today** chosen: press the status again, or Enter, to keep today. Press **Yesterday**, or **Pick a date**, when the work moved earlier than you noted it. A day in the future, or a day before the task's previous move, cannot be picked. The toast says both days, for example "Done on 14 Nov, noted today.", with **Undo**.
|
|
99
|
+
- **Open the task.** The ↗ on a row, or **Open the task** in its ⋯, opens a small popup on top: Task or Milestone, the name (press it to rename), status, dates, owner and notes. Its status asks **When did this happen?** too. ↑ and ↓ go to the task before or after it, and ⋯ has **Make it a milestone** and **Archive**, with **Undo**. Escape, × or a press outside closes only the small popup, and the task's row lights for a moment.
|
|
97
100
|
- **Dates.** Press a task's date. **Task | Milestone** on top turns it into a milestone (one Date) or back into a task (Start and Due). Write a day as "15 Oct 2026", or press the calendar icon. The row's ⋯ also has **Make it a milestone** and **Open the task**.
|
|
98
101
|
- **Artefacts.** One row for each kind, such as PRD, Prototype brief or Minutes, with its newest file. **Version** shows when there are more, and opens the earlier ones. When one kind has several different files, one suggestion above the table offers to merge them into one artefact for each kind; nothing is deleted. A document opens as the document page, read from the initiative's own product. When it cannot be read, the page says why, with **Retry**. A link opens in a new tab. The last row adds a file, a link or a new document.
|
|
99
102
|
|
|
103
|
+
**Moving a stage** asks **When did this happen?** in the same way, on the Board's Stage menu and on the initiative's stage buttons. A stage move cannot be dated before the initiative's previous move, and the stage's days count from the day you pick.
|
|
104
|
+
|
|
100
105
|
**Ask PMOS** is hidden until you want it, so the work takes the whole popup. It shows by itself when you had it open on the same item in the last 24 hours, or when a session about the item works or waits for you (a dot on the round **Ask PMOS** button). Press that button, or Ctrl or Cmd J, to show or hide it.
|
|
101
106
|
|
|
102
107
|
Press a suggestion's words to open it as its own page: ✓ and ✕, why PMOS suggests it, what changes, what PMOS read and **Ask PMOS about this**. ← goes back to the same place. A suggestion about one task shows under that task, never twice.
|
|
@@ -149,7 +154,7 @@ The notes of a held meeting look the same wherever you open them: a short summar
|
|
|
149
154
|
|
|
150
155
|
## Goals
|
|
151
156
|
|
|
152
|
-
**Goals** in the navigation answers "Am I on track? What do I do?" for the products you chose at the top left. The product choice and each product's heading show the product's name, such as IDPF, not the name of its folder. It reads your OKR file as one hierarchy: the North Star, then each objective with its key results, the levers behind them and the initiatives that move them.
|
|
157
|
+
**Goals** in the navigation answers "Am I on track? What do I do?" for the products you chose at the top left. The product choice and each product's heading show the product's name, such as IDPF, not the name of its folder. When a key result waits on a source, Goals names the tool, such as Confluence, and not a page number. It reads your OKR file as one hierarchy: the North Star, then each objective with its key results, the levers behind them and the initiatives that move them.
|
|
153
158
|
|
|
154
159
|
1. The card at the top is the North Star. When PMOS drafted one, press the tick to approve it or the cross to drop it. You can undo either for a moment.
|
|
155
160
|
2. Each key result shows its reading against its target and the days left. A grey dot and a dash mean nothing reads it yet: the line under it says what it waits on. PMOS never shows a number it did not read.
|
|
@@ -182,7 +187,7 @@ A chat on a phone uses the full width of the screen:
|
|
|
182
187
|
|
|
183
188
|
- **The top bar** has ← on the left, the chat's name with one line under it, and **⋯** on the right. The line says what the chat is about: the initiative, the number of files and the number of pull requests. Something with none is left out. With nothing to show, the line says where your messages go. Tap the line to open a sheet with the initiative, its newest files (and **All files**), its pull requests and **Sends to**, where you change where your messages go.
|
|
184
189
|
- **⋯** opens the menu under the top bar. **Waiting on you** and **Live now** are at the top of it when something is there. A blue dot on ⋯ means that something waits on you. A chat has no round menu button.
|
|
185
|
-
- **The messages** have no picture and no name or time line. Copy, Retry and Make a
|
|
190
|
+
- **The messages** have no picture and no name or time line. Copy, Retry and Make it a task are under the newest message. To see them under an older message, touch and hold that message.
|
|
186
191
|
- **The message box** is one row: **+**, the text, the microphone and send. It stays at the bottom of the screen while you scroll.
|
|
187
192
|
|
|
188
193
|
## First run
|
package/workspace/guide/notes.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
type: Guide
|
|
3
3
|
title: "Notes: record a meeting, and present while it records"
|
|
4
4
|
description: "Record a meeting on this machine, the notes caught and checked, presenting while it records, and the Chrome extension over Google Meet."
|
|
5
|
-
timestamp: 2026-11-
|
|
5
|
+
timestamp: 2026-11-19
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Notes
|
|
@@ -15,6 +15,7 @@ Every button in the recording tab and in the note is an icon. Hold the pointer o
|
|
|
15
15
|
|
|
16
16
|
- **A meeting on your calendar.** Open it from Your day or the calendar in Home, and press **Record** in its card in the Viewer. The note is linked to the event and keeps its context.
|
|
17
17
|
- **No meeting on the calendar.** Press **+** at the top of Home's list, then **Recording**. PMOS starts an untitled note.
|
|
18
|
+
- **Join and record with one press.** A meeting on Today's agenda with a Meet, Zoom or Teams link has a play icon. Press it: the browser opens the call, and PMOS opens the recording tab with the call's app already chosen. The browser still asks you to pick the tab to share, with one press. If the browser blocks the second tab, PMOS listens in the page instead and says so.
|
|
18
19
|
|
|
19
20
|
Either way PMOS opens the recording tab, or brings it forward when it is already open, and starts to listen. The tab's bar has **Highlight the last 30 seconds**, **Pause** and **Stop** while it records, and **Resume** and **Stop** while it is paused. With a shared screen it also has the eye icon that pauses the screenshots.
|
|
20
21
|
|
|
@@ -471,7 +472,7 @@ The calendar is in Home: press the calendar icon in Your day's header. A meeting
|
|
|
471
472
|
|
|
472
473
|
#### Add the extension
|
|
473
474
|
|
|
474
|
-
The PMOS Chrome extension shows a small panel over a Google Meet call, so you do not need to switch to the PMOS tab. The panel is
|
|
475
|
+
The PMOS Chrome extension shows a small panel over a Google Meet call, so you do not need to switch to the PMOS tab. The panel is the meeting buddy, described below. Only you see it. It is not part of the screen you share. The extension reads the address and the title of the Meet tab only. It does not read the call's audio or captions, and it talks only to the PMOS on your computer.
|
|
475
476
|
|
|
476
477
|
To add the extension:
|
|
477
478
|
|
|
@@ -481,4 +482,17 @@ To add the extension:
|
|
|
481
482
|
|
|
482
483
|
PMOS must run while you use the panel. The extension looks for PMOS at `http://localhost:7433`. If `pmos` started on another port, open the extension's **Options**, type that address and press **Save**, then reload the Meet tab.
|
|
483
484
|
|
|
484
|
-
To use it, open a Meet call. The panel shows at the bottom right of the call, and not on the Meet home page. PMOS finds the meeting on your calendar by the Meet link in the invite. If no invite has that link, it uses the title of the tab, and then the meeting that is under way now (from 10 minutes before the start to 10 minutes after the end). If none fits, the panel says "No meeting right now" and lists today's meetings. Press the one this call is. **Fold** shrinks the panel to a pill that shows the head only, and the same button opens it again.
|
|
485
|
+
To use it, open a Meet call. The panel shows at the bottom right of the call, and not on the Meet home page. PMOS finds the meeting on your calendar by the Meet link in the invite. If no invite has that link, it uses the title of the tab, and then the meeting that is under way now (from 10 minutes before the start to 10 minutes after the end). If none fits, the panel says "No meeting right now" and lists today's meetings. Press the one this call is. **Fold** shrinks the panel to a pill that shows the head only, and the same button opens it again. If PMOS does not answer, the panel says "PMOS is not running at" and the address, with a link to the Options.
|
|
486
|
+
|
|
487
|
+
#### The meeting buddy
|
|
488
|
+
|
|
489
|
+
The panel over Meet is PMOS's meeting buddy. Only you see it. The same card shows in the recording tab's Now panel as **PMOS heard**.
|
|
490
|
+
|
|
491
|
+
- **The head** says if PMOS listens: **Not listening**, **Paused**, the topic the room is on (**Topic 2 of 4**), or **Listening · others not told yet**. When PMOS does not listen yet, press the play icon in the panel to start the recording tab.
|
|
492
|
+
- **Tell the room.** Until you tell the others that PMOS listens, the buddy shows one line you can say or paste in the call chat, with a copy icon. Copy it, or press ✗ to hide it for this meeting.
|
|
493
|
+
- **Time nudge.** With 10 minutes or less left, the buddy says which topics are not covered yet, once. Press ✗ to hide it.
|
|
494
|
+
- **Filed.** The last decisions, next steps and questions PMOS wrote into your notes. Press the undo icon to take one out of the notes. **Undo** in the message puts it back.
|
|
495
|
+
- **Context.** Up to two links PMOS found for the topic now, for example the initiative or a document. They open in a new tab.
|
|
496
|
+
- **A draft for the call chat.** Sometimes PMOS drafts one short message for the call chat, for example a link the room asked for. PMOS never posts it: press the copy icon and paste it yourself, or press ✗.
|
|
497
|
+
- **Ask PMOS.** Type a question in the box at the bottom. The answer shows in the panel only.
|
|
498
|
+
|
|
@@ -193,6 +193,7 @@ function actsOf(r, boardNames) {
|
|
|
193
193
|
stages: own, stage: (lib ? r.wfStage.name : r.stage) || null, life,
|
|
194
194
|
reason: life ? clip(st.reason || '', 300) : '', back: life === 'hold' && st.back ? shortDate(st.back) : '', backDay: life === 'hold' && st.back ? String(st.back).slice(0, 10) : null,
|
|
195
195
|
...(life && st.at ? { since: shortDate(String(st.at).slice(0, 10)) } : {}),
|
|
196
|
+
...(r.movedOn ? { movedOn: r.movedOn } : {}), // a stage move is never dated before the last one (round 3 follow-up of point 18)
|
|
196
197
|
archived: r.archived ? { reason: clip(r.archived.reason || '', 300), into: r.archived.into ? (r.archived.intoTitle || r.archived.into) : null, ...(r.archived.into ? { intoId: r.archived.into } : {}), ...(r.archived.at ? { at: shortDate(String(r.archived.at).slice(0, 10)) } : {}) } : null,
|
|
197
198
|
};
|
|
198
199
|
}
|
|
@@ -33,6 +33,7 @@ const fs = require('fs');
|
|
|
33
33
|
const path = require('path');
|
|
34
34
|
const { execFileSync } = require('child_process');
|
|
35
35
|
const { repoScript } = require('./repo-script.js');
|
|
36
|
+
const SW = require('./status-when.js'); // a move's real day (round 3 follow-up of point 18)
|
|
36
37
|
|
|
37
38
|
const STAGES = ['triage', 'discover', 'plan', 'prioritize', 'build', 'deliver', 'monitor', 'evaluate'];
|
|
38
39
|
const LABEL = { triage: 'Triage', discover: 'Discover', plan: 'Plan', prioritize: 'Prioritize', build: 'Build', deliver: 'Deliver', monitor: 'Monitor', evaluate: 'Evaluate' };
|
|
@@ -175,7 +176,8 @@ function trail({ root, ids, rows = [], moves = [], now = Date.now(), io } = {})
|
|
|
175
176
|
for (let i = 0; i + 1 < L.length; i++) if (L[i + 1][1] !== L[i][1]) samples[L[i][0]].push(Math.max(0, Math.round((L[i + 1][1] - L[i][1]) / DAY)));
|
|
176
177
|
}
|
|
177
178
|
const byIni = new Map();
|
|
178
|
-
|
|
179
|
+
// a move the PM dated earlier counts from that day (round 3 follow-up of point 18): the stage durations and "since" read the real day
|
|
180
|
+
for (const m0 of moves) { if (!m0 || !m0.id || !m0.at) continue; const m = m0.happened ? { ...m0, at: SW.realAt(m0) } : m0; if (!byIni.has(m.id)) byIni.set(m.id, []); byIni.get(m.id).push(m); }
|
|
179
181
|
const wfOfRow = (id) => { const r = rowBy.get(id); return r && r.wf && r.wf.id && r.wf.id !== 'product-feature' ? r.wf.id : null; };
|
|
180
182
|
const other = {}; // workflow id → stage key → [days]
|
|
181
183
|
for (const [id, L] of byIni) {
|
|
@@ -427,7 +427,7 @@ function initiativeExtras(ctx, w) {
|
|
|
427
427
|
}
|
|
428
428
|
function lastMoveOf(folded, id) {
|
|
429
429
|
let at = null;
|
|
430
|
-
for (const m of (folded && folded.moves) || []) { if (m.id !== id) continue; const t = msOf(
|
|
430
|
+
for (const m of (folded && folded.moves) || []) { if (m.id !== id) continue; const t = msOf(require('./status-when.js').realAt(m)); if (Number.isFinite(t) && (at == null || t > at)) at = t; }
|
|
431
431
|
return at;
|
|
432
432
|
}
|
|
433
433
|
|
|
@@ -258,7 +258,7 @@ function fold(events) {
|
|
|
258
258
|
}
|
|
259
259
|
} else if (e.kind === 'move' && b && typeof e.id === 'string' && typeof e.to === 'string') {
|
|
260
260
|
stages.set(key(b, e.id), e.to);
|
|
261
|
-
moves.push({ at: e.at || null, by: e.by || null, board: b, id: e.id, from: e.from || null, to: e.to, why: e.why || '', warnings: Array.isArray(e.warnings) ? e.warnings : [], via: 'move' });
|
|
261
|
+
moves.push({ at: e.at || null, by: e.by || null, board: b, id: e.id, from: e.from || null, to: e.to, why: e.why || '', warnings: Array.isArray(e.warnings) ? e.warnings : [], via: 'move', ...(typeof e.happened === 'string' && e.happened ? { happened: e.happened } : {}) });
|
|
262
262
|
} else if (e.kind === 'assign' && typeof e.id === 'string' && typeof e.to === 'string') {
|
|
263
263
|
assigns.set(e.id, e.to);
|
|
264
264
|
} else if (e.kind === 'ask' && b && typeof e.ask === 'string' && !asks.has(e.ask)) {
|
|
@@ -356,7 +356,7 @@ function fold(events) {
|
|
|
356
356
|
left: isObj(e.moved) ? e.moved.from || null : null, landed: isObj(e.moved) ? e.moved.to || null : null });
|
|
357
357
|
if (isObj(e.moved) && typeof e.moved.to === 'string') {
|
|
358
358
|
stages.set(k, e.moved.to);
|
|
359
|
-
moves.push({ at: e.at || null, by: e.by || null, board: b, id: e.id, from: e.moved.from || null, to: e.moved.to, why: 'workflow changed', warnings: [], via: 'ini-wf', ...(isObj(e.map) && e.undo !== true ? { map: e.map } : {}) });
|
|
359
|
+
moves.push({ at: e.at || null, by: e.by || null, board: b, id: e.id, from: e.moved.from || null, to: e.moved.to, why: 'workflow changed', warnings: [], via: 'ini-wf', ...(isObj(e.map) && e.undo !== true ? { map: e.map } : {}), ...(typeof e.happened === 'string' && e.happened ? { happened: e.happened } : {}) });
|
|
360
360
|
}
|
|
361
361
|
} else if (e.kind === 'ini-end' && b && typeof e.id === 'string') {
|
|
362
362
|
const k = key(b, e.id);
|
|
@@ -13,6 +13,7 @@
|
|
|
13
13
|
* outLine(parsed, at) · moveLine(...) → the lines the state file takes
|
|
14
14
|
* shouldRun(now, state, note, opts) → { run, reason } the rules of when the companion may run
|
|
15
15
|
* pickNow(events, { now, meet, title }) → { ok, event, date, by } | { ok:false, status:404, error, choices } which meeting a Google Meet call is (the Chrome extension, c3-meet-extension)
|
|
16
|
+
* callLinkOf(event) → { url, app: 'meet'|'zoom'|'teams' } | null the address of the meeting's call (meeting-buddy: the play icon, the buddy)
|
|
16
17
|
*
|
|
17
18
|
* Nothing here reads a file or starts a process; lib/routes-meeting-focus.js does both.
|
|
18
19
|
*
|
|
@@ -36,7 +37,7 @@ const TAIL_MAX = 40; // and at most this many lines
|
|
|
36
37
|
const TOPICS_MAX = 30; // every invite line is kept; lib/agenda-topics.js shows them under 3 to 5 topics
|
|
37
38
|
const NOTES_MAX = 5;
|
|
38
39
|
const CHIPS_MAX = 4;
|
|
39
|
-
const RAISE_KINDS = Object.freeze(['check', 'follow-up', 'no-owner', 'show']);
|
|
40
|
+
const RAISE_KINDS = Object.freeze(['check', 'follow-up', 'no-owner', 'show', 'chat']); // chat: a line the PM may post in the call chat (meeting-buddy); a draft only
|
|
40
41
|
const RAISE_MAX = 2; // the Now panel shows at most this many prompts; a Show it? offer counts as one
|
|
41
42
|
const INI_ID = /^[A-Za-z0-9][A-Za-z0-9._-]{0,79}$/;
|
|
42
43
|
const FROM = Object.freeze(['talk', 'screen', 'prep', 'last']); // where an answer came from: the talk, the shared screen, the prep, last time
|
|
@@ -100,15 +101,22 @@ function capturedFrom(note) {
|
|
|
100
101
|
const sec = n.summary && n.summary.sections && typeof n.summary.sections === 'object' ? n.summary.sections : {};
|
|
101
102
|
const seen = { decision: new Set(), action: new Set(), question: new Set() };
|
|
102
103
|
const out = { decisions: [], actions: [], questions: [] };
|
|
103
|
-
|
|
104
|
+
// a bullet carries its id (meeting-buddy: Undo drops it through POST /api/notes/bullet), also when the summary listed the same text first
|
|
105
|
+
const byText = { decision: new Map(), action: new Map(), question: new Map() };
|
|
106
|
+
const put = (kind, key, item) => {
|
|
107
|
+
const k = norm(item.text); if (!k) return;
|
|
108
|
+
if (seen[kind].has(k)) { const had = byText[kind].get(k); if (had && item.bid && !had.bid) had.bid = item.bid; return; }
|
|
109
|
+
seen[kind].add(k); byText[kind].set(k, item); out[key].push(item);
|
|
110
|
+
};
|
|
111
|
+
const bidOf = (b) => (typeof b.id === 'string' && b.id ? { bid: b.id } : {});
|
|
104
112
|
for (const x of Array.isArray(sec.decisions) ? sec.decisions : []) put('decision', 'decisions', { text: str(x && x.text, 300) });
|
|
105
113
|
for (const x of Array.isArray(sec.actions) ? sec.actions : []) put('action', 'actions', { text: str(x && x.text, 300), owner: str(x && x.owner, 60) || null, due: str(x && x.due, 40) || null });
|
|
106
114
|
for (const x of Array.isArray(sec.questions) ? sec.questions : []) put('question', 'questions', { text: str(x && x.text, 300) });
|
|
107
115
|
for (const b of Array.isArray(n.bullets) ? n.bullets : []) {
|
|
108
116
|
if (!b || b.dropped || b.open || !b.text) continue;
|
|
109
|
-
if (b.cat === 'decision') put('decision', 'decisions', { text: str(b.text, 300) });
|
|
110
|
-
else if (b.cat === 'action') put('action', 'actions', { text: str(b.text, 300), owner: str(b.owner, 60) || null, due: str(b.due, 40) || null });
|
|
111
|
-
else if (b.cat === 'question') put('question', 'questions', { text: str(b.text, 300) });
|
|
117
|
+
if (b.cat === 'decision') put('decision', 'decisions', { text: str(b.text, 300), ...bidOf(b) });
|
|
118
|
+
else if (b.cat === 'action') put('action', 'actions', { text: str(b.text, 300), owner: str(b.owner, 60) || null, due: str(b.due, 40) || null, ...bidOf(b) });
|
|
119
|
+
else if (b.cat === 'question') put('question', 'questions', { text: str(b.text, 300), ...bidOf(b) });
|
|
112
120
|
}
|
|
113
121
|
return out;
|
|
114
122
|
}
|
|
@@ -190,6 +198,7 @@ function companionPrompt(input) {
|
|
|
190
198
|
} else {
|
|
191
199
|
L.push('Say what is being discussed, which topic the room is on, and add a note only when it helps the PM right now: an answer to a question the room asked, a fact to check, a decision forming, a time warning, a topic that came up, context behind a name that was said, or a follow-up. Stay quiet when nothing helps: an empty "notes" list is a good answer.');
|
|
192
200
|
L.push('In "raise", give at most ' + RAISE_MAX + ' things the PM should raise in the room now, each one short line: "check" when the screen and the talk differ (a date, a number, a name), "follow-up" when an action from last time is still open and nobody raised it, "no-owner" when the room agreed something and nobody owns it. An empty "raise" list is a good answer.');
|
|
201
|
+
L.push('Also in "raise", at most one "chat": a line the PM may want to post in the call chat in their own voice, only when it helps the room now (a commitment the PM just made, a link or a number the room asked for). Write it as the PM would type it. The PM copies it and posts it; you never post anything. An empty list is a good answer.');
|
|
193
202
|
L.push('Also in "raise", at most one "show": when the room names an idea that nobody can judge from words alone (a screen, a flow, a layout, a page, how something looks or moves), PMOS can make 3 quick specimens of it while the meeting goes on. Then "text" is one sentence of what to show, "title" names the idea in a few words, and "initiative" is the id of the initiative it belongs to when the brief or a reference above names it. Only offer it for an idea that is new in the talk and not offered before. Never for a decision, a number or a date.');
|
|
194
203
|
}
|
|
195
204
|
L.push('');
|
|
@@ -283,8 +292,8 @@ function parseCompanion(text) {
|
|
|
283
292
|
const topic = { current: str(t.current, 120) || null, add: (Array.isArray(t.add) ? t.add : []).map((x) => str(x, 120)).filter(Boolean).slice(0, 3) };
|
|
284
293
|
if (str(t.under, 80)) topic.under = str(t.under, 80);
|
|
285
294
|
const notes = (Array.isArray(o.notes) ? o.notes : []).map(noteOf).filter(Boolean).slice(0, NOTES_MAX);
|
|
286
|
-
let shows = 0; // one Show it? offer an answer, at most
|
|
287
|
-
const raise = (Array.isArray(o.raise) ? o.raise : []).map(raiseOf).filter(Boolean).filter((r) => r.kind !== 'show' || shows++ === 0).slice(0, RAISE_MAX);
|
|
295
|
+
let shows = 0, chats = 0; // one Show it? offer and one chat draft an answer, at most
|
|
296
|
+
const raise = (Array.isArray(o.raise) ? o.raise : []).map(raiseOf).filter(Boolean).filter((r) => (r.kind !== 'show' || shows++ === 0) && (r.kind !== 'chat' || chats++ === 0)).slice(0, RAISE_MAX);
|
|
288
297
|
if (!gist && !chips.length && !topic.current && !topic.add.length && !notes.length && !raise.length) return null;
|
|
289
298
|
return { gist, chips, topic, notes, raise };
|
|
290
299
|
}
|
|
@@ -433,4 +442,27 @@ function pickNow(events, { now = Date.now(), meet = '', title = '' } = {}) {
|
|
|
433
442
|
return { ok: false, status: 404, error: 'No meeting on the calendar fits this call.', choices };
|
|
434
443
|
}
|
|
435
444
|
|
|
436
|
-
|
|
445
|
+
/* ── the call's address (meeting-buddy) ───────────────────────────────────────────────────────────────────────────── */
|
|
446
|
+
|
|
447
|
+
const CALL_APPS = [
|
|
448
|
+
['meet', /^https:\/\/meet\.google\.com\/[a-z]{3}-[a-z]{4}-[a-z]{3}\b/i],
|
|
449
|
+
['zoom', /^https:\/\/(?:[a-z0-9-]+\.)?zoom\.us\/(?:j|my|w|s)\//i],
|
|
450
|
+
['teams', /^https:\/\/teams\.(?:microsoft|live)\.com\/(?:l\/meetup-join|meet)\//i],
|
|
451
|
+
];
|
|
452
|
+
/** The address of the meeting's call, from its links, its hangout link or a link in its location. The case of the address is kept.
|
|
453
|
+
* → { url, app: 'meet'|'zoom'|'teams' } | null. Only https addresses of those three count. Pure. */
|
|
454
|
+
function callLinkOf(e) {
|
|
455
|
+
if (!e || typeof e !== 'object') return null;
|
|
456
|
+
const texts = [].concat((Array.isArray(e.links) ? e.links : []).map((l) => (l && typeof l === 'object' ? l.url : l)), e.hangoutLink, e.hangout_link, e.meet_url, e.join, e.conference, e.location)
|
|
457
|
+
.filter((x) => typeof x === 'string');
|
|
458
|
+
for (const t of texts) {
|
|
459
|
+
for (const raw of t.match(/https:\/\/[^\s<>"')]+/gi) || []) {
|
|
460
|
+
const url = raw.replace(/[.,;]+$/, '');
|
|
461
|
+
const hit = CALL_APPS.find(([, re]) => re.test(url));
|
|
462
|
+
if (hit && url.length <= 400) return { url, app: hit[0] };
|
|
463
|
+
}
|
|
464
|
+
}
|
|
465
|
+
return null;
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
module.exports = { CATS, REF_TYPES, RAISE_KINDS, RAISE_MAX, FROM, MIN_GAP_MS, TAIL_MINUTES, TAIL_MAX, topicsFrom, tailOf, capturedFrom, screenOf, companionPrompt, parseCompanion, showIntent, showLine, foldState, outLine, moveLine, raiseLine, shouldRun, pickNow, meetTitle, callLinkOf, norm, str, off };
|
|
@@ -81,10 +81,11 @@ function needOf(source, host) {
|
|
|
81
81
|
if (/new relic/i.test(s)) return 'New Relic';
|
|
82
82
|
if (/servicenow/i.test(s)) return 'ServiceNow';
|
|
83
83
|
if (/\bjira\b/i.test(s)) return 'Jira';
|
|
84
|
+
if (/\bconfluence\b/i.test(s)) return 'Confluence'; // names, not ids: never "Confluence 3542351901"
|
|
84
85
|
const h = /\b([a-z0-9-]+(?:\.[a-z0-9-]+)+\.[a-z]{2,})(?:\/|\b)/i.exec(s);
|
|
85
86
|
if (h) return h[1];
|
|
86
87
|
if (/^\/[a-z]/i.test(s) && host) return host;
|
|
87
|
-
return clip(s, 60);
|
|
88
|
+
return clip(s.replace(/\s+(?:page\s+|id\s+)?#?\d{5,}\b.*$/i, '') || s, 60); // a long number is an id, not a name
|
|
88
89
|
}
|
|
89
90
|
/** The line under a key result's name: "60.2% → ≥ 70% by Dec 2026", from "Baseline: … Target: …" or the bolded numbers. */
|
|
90
91
|
function lineOf(text, due) {
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
* health budgets and domains a new initiative can anchor to (D59)
|
|
18
18
|
* POST /api/boards/create { ws, name, domain?, template } → { ok, board }
|
|
19
19
|
* POST /api/boards/workflow { ws, board, stages, moveRemoved?, sprints? } → { ok, board, moved }
|
|
20
|
-
* POST /api/boards/move { ws, board, id, to, why? }
|
|
20
|
+
* POST /api/boards/move { ws, board, id, to, why?, happened? } → { ok, row, warnings } happened: the day it really happened
|
|
21
21
|
* POST /api/boards/assign { ws, id, to } → { ok }
|
|
22
22
|
* POST /api/boards/asks/add { ws, board, line, source? } → { ok, ask, draft }
|
|
23
23
|
* POST /api/boards/asks/accept { ws, board, ask, title, lane, anchor, intent?, id?, kind? } → { ok, initiative, stage } (kind: product | sdlc | project, default product)
|
|
@@ -620,6 +620,8 @@ function boardRow(board, base, folded, lib) {
|
|
|
620
620
|
// a finished initiative is never late, at risk or without a signal: its last stage is the PM's own move (batch 26 item 5)
|
|
621
621
|
// …except a refuted outcome: its check said it did not work, and that stays at risk until the PM picks the next step (launch simulation W2)
|
|
622
622
|
if (row.closed && ['late', 'at risk', 'no signal'].includes(row.status) && !(row.signal && row.signal.from === 'outcome')) { row.status = 'on track'; row.signal = { from: 'pm', why: 'In its last stage', source: 'the workflow', readAt: new Date().toISOString() }; }
|
|
623
|
+
// the day of the last move: a stage move cannot be dated before it (round 3 follow-up of point 18)
|
|
624
|
+
{ const mf = SW.moveFloor(((folded && folded.moves) || []).filter((m) => m.board === board.id), base.id); if (mf) row.movedOn = mf; }
|
|
623
625
|
const w = [];
|
|
624
626
|
if (s.source === 'move') {
|
|
625
627
|
const last = [...folded.moves].reverse().find((m) => m.board === board.id && m.id === base.id);
|
|
@@ -1077,6 +1079,14 @@ function settingsOf(body, board) {
|
|
|
1077
1079
|
return { value: v };
|
|
1078
1080
|
}
|
|
1079
1081
|
|
|
1082
|
+
/** The day a stage move really happened (round 3 follow-up of point 18): null when the body gives none, else the checked day; a refusal
|
|
1083
|
+
* answers 400 and returns false. Never in the future, never before the initiative's previous move. */
|
|
1084
|
+
function stageHappened(ctx, res, body, folded, boardId) {
|
|
1085
|
+
if (body.happened == null || body.happened === '') return null;
|
|
1086
|
+
const e = SW.checkHappened(body.happened, { floor: SW.moveFloor(((folded && folded.moves) || []).filter((m) => m.board === boardId), body.id) });
|
|
1087
|
+
if (e) { fail(ctx, res, 400, e); return false; }
|
|
1088
|
+
return body.happened;
|
|
1089
|
+
}
|
|
1080
1090
|
const WONTDO_REASONS = ['budget', 'scope', 'another', 'other']; // No budget · Out of scope · Done another way · Other (WfAWontDo)
|
|
1081
1091
|
/** A move of an initiative that runs a library workflow (D99): `to` is a stage key or name of ITS workflow; the key is stored. */
|
|
1082
1092
|
function moveOnWorkflow(ctx, res, body, g, p, own) {
|
|
@@ -1095,7 +1105,9 @@ function moveOnWorkflow(ctx, res, body, g, p, own) {
|
|
|
1095
1105
|
const warnings = [];
|
|
1096
1106
|
for (let i = a + 1; i < b; i++) { const sk = before.wfStages[i]; if (sk && sk.status !== 'skipped' && sk.when.mode !== 'optional') warnings.push('Skipped ' + sk.name); }
|
|
1097
1107
|
if (!before.anchor) warnings.push('No anchor');
|
|
1098
|
-
|
|
1108
|
+
const happened = stageHappened(ctx, res, body, p.fr.folded, p.board.id);
|
|
1109
|
+
if (happened === false) return;
|
|
1110
|
+
append(p.file, g.actor, { kind: 'move', board: p.board.id, id: body.id, from: before.wfStage.key, to: t.key, why: body.why || '', warnings, ...(happened ? { happened } : {}) });
|
|
1099
1111
|
const f1 = foldOf(ctx, p.w), row = boardRow(p.board, b0, f1);
|
|
1100
1112
|
const made = stageTasks(p.file, f1, p.board, row, g.actor.by); // the new stage's To finish entries, as tasks
|
|
1101
1113
|
ctx.json(res, { ok: true, row, warnings, ...(made ? { tasksMade: made } : {}) });
|
|
@@ -1118,7 +1130,9 @@ function moveToProductStage(ctx, res, body, g, p, pf) {
|
|
|
1118
1130
|
const warnings = [];
|
|
1119
1131
|
for (let i = a + 1; i < b; i++) { const sk = before.wfStages[i]; if (sk && sk.status !== 'skipped' && (!sk.when || sk.when.mode !== 'optional')) warnings.push('Skipped ' + sk.name); }
|
|
1120
1132
|
if (!before.anchor) warnings.push('No anchor');
|
|
1121
|
-
|
|
1133
|
+
const happened = stageHappened(ctx, res, body, p.fr.folded, p.board.id);
|
|
1134
|
+
if (happened === false) return;
|
|
1135
|
+
append(p.file, g.actor, { kind: 'ini-wf', board: p.board.id, id: body.id, wf: wf.id, from: wf.id, moved: { from: before.wfStage.key, to: pf.key }, why: body.why ? String(body.why).trim() : '', ...(happened ? { happened } : {}) });
|
|
1122
1136
|
const f1 = foldOf(ctx, p.w), row = boardRow(p.board, b0, f1);
|
|
1123
1137
|
const made = stageTasks(p.file, f1, p.board, row, g.actor.by);
|
|
1124
1138
|
ctx.json(res, { ok: true, row, warnings, ...(made ? { tasksMade: made } : {}) });
|
|
@@ -1212,7 +1226,9 @@ const WRITES = {
|
|
|
1212
1226
|
if (!b0 || boardIdOf(b0, p.fr.boards, p.fr.folded, p.w) !== p.board.id) return fail(ctx, res, 404, `no initiative ${body.id} on this board`);
|
|
1213
1227
|
const before = boardRow(p.board, b0, p.fr.folded);
|
|
1214
1228
|
const warnings = B.moveWarnings(p.board, before, before.stage, body.to, { hasSpec: b0.hasSpec });
|
|
1215
|
-
|
|
1229
|
+
const happened = stageHappened(ctx, res, body, p.fr.folded, p.board.id);
|
|
1230
|
+
if (happened === false) return;
|
|
1231
|
+
append(p.file, g.actor, { kind: 'move', board: p.board.id, id: body.id, from: before.stage, to: body.to, why: body.why || '', warnings, ...(happened ? { happened } : {}) });
|
|
1216
1232
|
const row = boardRow(p.board, b0, foldOf(ctx, p.w));
|
|
1217
1233
|
ctx.json(res, { ok: true, row, warnings });
|
|
1218
1234
|
},
|
|
@@ -5,7 +5,8 @@
|
|
|
5
5
|
*
|
|
6
6
|
* READ ONLY, and built only from what PMOS already holds. Nothing is invented.
|
|
7
7
|
* today one row per meeting of the local day, in time order, from every calendar event the workspace holds (calendar-events.js readAll,
|
|
8
|
-
* the same source as /api/calendar-views): { id, title, start, end, minutes, people, initiative, prepared, before, state }.
|
|
8
|
+
* the same source as /api/calendar-views): { id, title, start, end, minutes, people, initiative, join?, app?, prepared, before, state }.
|
|
9
|
+
* join, app: the call's address and its app (meet, zoom or teams) when the meeting has one (meeting-buddy, lib/meeting-focus.js callLinkOf).
|
|
9
10
|
* prepared: [{ kind: 'prep'|'pm-note'|'note'|'last-note', text, id? }] what PMOS holds for the meeting (the agent's prep note,
|
|
10
11
|
* the PM's notes on the event, the note linked to it, the last note of an earlier occurrence). before: [{ id, title, due,
|
|
11
12
|
* done }] the PM's own open items that name the meeting (item.meeting_id or item.event_id equals the event id, or the title
|
|
@@ -54,6 +55,7 @@ function deferred(item, now, todayIso) {
|
|
|
54
55
|
return Number.isFinite(t) && t > now.getTime();
|
|
55
56
|
}
|
|
56
57
|
|
|
58
|
+
const callOf = (e) => { const c = require('./meeting-focus.js').callLinkOf(e); return c ? { join: c.url, app: c.app } : {}; };
|
|
57
59
|
/** The meetings of the local day. `notes` is an optional { findByEvent(ev), lastBefore(ev) } so the route can read the notes store. */
|
|
58
60
|
function todayAgenda(events, items, now, notes = {}) {
|
|
59
61
|
const todayIso = localDate(now);
|
|
@@ -76,7 +78,9 @@ function todayAgenda(events, items, now, notes = {}) {
|
|
|
76
78
|
return { id: e.id, title: e.title, start: s.toISOString(), end: new Date(endMs).toISOString(), startLocal: hhmm(s), minutes: Math.max(0, Math.round((endMs - s.getTime()) / 60000)),
|
|
77
79
|
people: Array.isArray(e.attendees) ? e.attendees.slice(0, 12) : [],
|
|
78
80
|
// the link the PM set on the meeting (lib/calendar-links.js, every occurrence of it) wins; Home's clean-up writes one (batch 13 item 3)
|
|
79
|
-
initiative: (notes.linkOf && notes.linkOf(e)) || e.initiative || null, ...(e.series ? { series: String(e.series).slice(0, 300) } : {}),
|
|
81
|
+
initiative: (notes.linkOf && notes.linkOf(e)) || e.initiative || null, ...(e.series ? { series: String(e.series).slice(0, 300) } : {}),
|
|
82
|
+
// the call's address (meeting-buddy): the play icon on Today's agenda opens it and starts the recording; Home's card shows Join
|
|
83
|
+
...callOf(e), prepared, before, _s: s.getTime(), _e: endMs };
|
|
80
84
|
});
|
|
81
85
|
let nextDone = false;
|
|
82
86
|
for (const r of rows) {
|
|
@@ -3,6 +3,8 @@
|
|
|
3
3
|
*
|
|
4
4
|
* GET /api/meeting-focus?event=<id>&date=YYYY-MM-DD[&ws=]
|
|
5
5
|
* → { ok, now_ms, event, brief, material, note, topics, current, runs, tail, captured, gist, chips, notes, raise, asks, companion }
|
|
6
|
+
* event.call is the meeting's call address ({ url, app } or null, lib/meeting-focus.js callLinkOf; meeting-buddy). Each caught item that
|
|
7
|
+
* came from a bullet carries its id (bid), so the buddy's Undo drops it with POST /api/notes/bullet.
|
|
6
8
|
* The meeting (the calendar read for that day), its brief (lib/calendar-layers.js briefOf), the note linked to it, the last
|
|
7
9
|
* minutes of that note's transcript with who said them, the decisions, actions and questions so far, and the companion's state.
|
|
8
10
|
* An unknown meeting is a 404. The read also starts the companion when lib/meeting-focus.js shouldRun says it may: the note
|
|
@@ -274,7 +276,7 @@ async function read(q, ctx) {
|
|
|
274
276
|
ok: true, now_ms: nowMs, date: day,
|
|
275
277
|
talk,
|
|
276
278
|
event: { id: ev.id, title: ev.title, at: ev.at, end: ev.end, attendees: [].concat(ev.attendees || ev.people || []).map((p) => (p && typeof p === 'object' ? p.name || p.id : p)).filter(Boolean).map(String),
|
|
277
|
-
initiative: ev.initiative || null, series: ev.series || null, purpose: ev.purpose || (brief && brief.purpose) || null, links },
|
|
279
|
+
initiative: ev.initiative || null, series: ev.series || null, purpose: ev.purpose || (brief && brief.purpose) || null, links, call: F.callLinkOf(ev) },
|
|
278
280
|
brief: brief || null,
|
|
279
281
|
material,
|
|
280
282
|
note: note ? { id: note.id, title: note.title || ev.title, state: note.state, recorded_from: note.recorded_from || null, lines: (note.transcript || []).length, sessions } : null,
|
|
@@ -6,7 +6,10 @@
|
|
|
6
6
|
* UTC day; one day of slack lets a person east of UTC say their own today), never before floor (the
|
|
7
7
|
* previous move's day, or the day the task was made)
|
|
8
8
|
* floorOf(t) → that floor for a folded PMOS task: the day of its last move (its happened, else its at), else its at
|
|
9
|
-
* lateDays(due, done) → whole days a Done came after its due day (0 when on time or a day is missing)
|
|
9
|
+
* lateDays(due, done) → whole days a Done came after its due day (0 when on time or a day is missing)
|
|
10
|
+
* realAt(m) → the time a move counts from: its at, or the end of its happened day when the PM said an earlier day
|
|
11
|
+
* (the end of the day keeps the order of the moves, since a move is never before the one before it)
|
|
12
|
+
* moveFloor(moves, id) → the floor for an initiative's stage move: the day of its last move (round 3 follow-up) */
|
|
10
13
|
const DAY_RE = /^\d{4}-\d{2}-\d{2}$/;
|
|
11
14
|
const DAY = 864e5;
|
|
12
15
|
const ms = (v) => { const m = /^(\d{4})-(\d{2})-(\d{2})/.exec(String(v || '')); return m ? Date.UTC(+m[1], +m[2] - 1, +m[3]) : null; };
|
|
@@ -33,4 +36,14 @@ function lateDays(due, done) {
|
|
|
33
36
|
const a = ms(due), b = ms(done);
|
|
34
37
|
return a == null || b == null || b <= a ? 0 : Math.round((b - a) / DAY);
|
|
35
38
|
}
|
|
36
|
-
|
|
39
|
+
function realAt(m) {
|
|
40
|
+
if (!m) return null;
|
|
41
|
+
const h = m.happened, a = m.at ? String(m.at) : '';
|
|
42
|
+
return h && DAY_RE.test(h) && h !== a.slice(0, 10) ? h + 'T23:59:59.999Z' : (m.at || null);
|
|
43
|
+
}
|
|
44
|
+
function moveFloor(moves, id) {
|
|
45
|
+
let v = null;
|
|
46
|
+
for (const m of moves || []) if (m && m.id === id) { const t = realAt(m); if (t && (!v || String(t) > v)) v = String(t); }
|
|
47
|
+
return v ? v.slice(0, 10) : null;
|
|
48
|
+
}
|
|
49
|
+
module.exports = { checkHappened, floorOf, lateDays, realAt, moveFloor, DAY_RE };
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pmos-workspace",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.618.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.618.0",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@anthropic-ai/sdk": "^1.3.0",
|
package/workspace/package.json
CHANGED
|
@@ -232,6 +232,7 @@ const ALLOWED = /^\/api\/(?:boards\/(?:asks\/(?:add|accept|decline)|move|archive
|
|
|
232
232
|
const n0 = lines('boards.jsonl').filter(isMove).length;
|
|
233
233
|
const next = bar ? bar.moves[bar.moves.indexOf(bar.cur) + 1] : '';
|
|
234
234
|
await ip.click(`#czViewer [data-ov-move="${next}"]`);
|
|
235
|
+
await ip.click('.hi-pop [data-sw="today"]'); // a stage move asks the day first (popup round 3 point 18f)
|
|
235
236
|
ok('I2 a stage press records one move line', await until(() => { const L = lines('boards.jsonl').filter(isMove); return L.length === n0 + 1 && L[L.length - 1].id === 'pa-one' && sameStage(toOf(L[L.length - 1]), next); }), JSON.stringify(lines('boards.jsonl').filter(isMove).slice(-1)));
|
|
236
237
|
ok('I2 the Overview then shows the new stage pressed', await until(() => ip.evaluate((n) => !!document.querySelector(`#czViewer [data-ov-move="${n}"][aria-pressed="true"]`), next)));
|
|
237
238
|
const lif0 = lines('lifecycle.jsonl').length;
|
|
@@ -124,10 +124,10 @@ body.bd-page.wk-on .bd-hd .bd-tools { margin-left: auto; }
|
|
|
124
124
|
/* the stage list under a Stage cell */
|
|
125
125
|
.wk-stm { position: fixed; z-index: 80; min-width: 168px; padding: 6px; border-radius: 12px; background: var(--cz-card); box-shadow: 0 8px 28px rgba(42, 46, 53, .18), inset 0 0 0 1px var(--cz-hair); display: grid; gap: 1px; font-family: var(--cz-sans); }
|
|
126
126
|
.wk-stm .h { font-size: var(--fs-badge); font-weight: var(--fw-strong); color: var(--cz-ink3); padding: 5px 8px 6px; }
|
|
127
|
-
.wk-stm button { all: unset; cursor: pointer; font-size: var(--fs-meta); color: var(--cz-ink); padding: 7px 8px; border-radius: 7px; display: flex; justify-content: space-between; gap: 14px; }
|
|
128
|
-
.wk-stm button:hover, .wk-stm button:focus-visible { background: var(--cz-well); }
|
|
129
|
-
.wk-stm button.on { font-weight: var(--fw-strong); background: var(--cz-well); }
|
|
130
|
-
.wk-stm button.on::after { content: '✓'; color: var(--cz-ink2); }
|
|
127
|
+
.wk-stm > button { all: unset; cursor: pointer; font-size: var(--fs-meta); color: var(--cz-ink); padding: 7px 8px; border-radius: 7px; display: flex; justify-content: space-between; gap: 14px; }
|
|
128
|
+
.wk-stm > button:hover, .wk-stm > button:focus-visible { background: var(--cz-well); }
|
|
129
|
+
.wk-stm > button.on { font-weight: var(--fw-strong); background: var(--cz-well); }
|
|
130
|
+
.wk-stm > button.on::after { content: '✓'; color: var(--cz-ink2); }
|
|
131
131
|
/* Work's rows in the shell's ⋯ menu (board 5 keeps them out of the view menu): a count or "on" sits at the right, small and grey */
|
|
132
132
|
.crmenu > .wk-xo .k { margin-left: auto; padding-left: 16px; font-size: var(--fs-meta); font-weight: var(--fw-regular); color: var(--cz-ink3); }
|
|
133
133
|
/* round 2 (Wawan, 2026-11-19): the Board's own bar sits in Work's track; the key says what it draws; the closed ones fold into one line */
|
|
@@ -190,3 +190,4 @@ body.bd-page.wk-on [id="bdFilter"] { position: relative; }
|
|
|
190
190
|
.wk-menu .wk-pl button.q:not(.on) { color: var(--cz-ink3); background: none; box-shadow: inset 0 0 0 1px var(--cz-hair); }
|
|
191
191
|
.wk-menu .wk-pl button em { font-style: normal; color: var(--cz-ink3); }
|
|
192
192
|
.wk-menu .wk-pl button.on em { color: inherit; opacity: .7; }
|
|
193
|
+
.wk-stm .wk-when { padding: 0 6px 4px; max-width: 280px; }
|