create-pmos 0.601.0 → 0.603.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 +33 -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/changelog.json +32 -0
- package/workspace/guide/agent-capabilities.md +7 -7
- package/workspace/guide/home.md +2 -2
- package/workspace/guide/statuses.md +12 -1
- package/workspace/lib/initiative-chat.js +3 -0
- package/workspace/lib/initiative-premium.js +1 -0
- package/workspace/lib/live-round.js +30 -8
- package/workspace/lib/proto-runtime.js +39 -5
- package/workspace/lib/routes-lab.js +10 -6
- package/workspace/package-lock.json +2 -2
- package/workspace/package.json +1 -1
- package/workspace/public/pm/cozy-proto.css +66 -17
- package/workspace/public/pm/cozy-proto.js +224 -56
- package/workspace/public/pm/home-chat.js +4 -0
- package/workspace/public/pm/ini-tasks.js +6 -2
- package/workspace/public/pm/ini-view-model.js +20 -4
- package/workspace/public/pm/ini-view.css +4 -0
- package/workspace/public/pm/premium-initiative-head.js +1 -1
- package/workspace/public/pm/stage-line.js +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "create-pmos",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.603.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,38 @@
|
|
|
33
33
|
"audit"
|
|
34
34
|
],
|
|
35
35
|
"pmosChanges": [
|
|
36
|
+
{
|
|
37
|
+
"v": "0.603.0",
|
|
38
|
+
"at": "2026-11-18T08:33:37.110Z",
|
|
39
|
+
"f": 4,
|
|
40
|
+
"prs": [
|
|
41
|
+
{
|
|
42
|
+
"n": 1345,
|
|
43
|
+
"t": "Timeline bars and axis labels start on their day, under the Today line",
|
|
44
|
+
"s": "Timeline bars and axis labels start on their day, under the Today line",
|
|
45
|
+
"k": "fix"
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"n": 1346,
|
|
49
|
+
"t": "A finished initiative's lateness counts to when it finished, not today",
|
|
50
|
+
"s": "A finished initiative's lateness counts to when it finished, not today",
|
|
51
|
+
"k": "fix"
|
|
52
|
+
}
|
|
53
|
+
]
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
"v": "0.602.0",
|
|
57
|
+
"at": "2026-11-18T08:21:52.461Z",
|
|
58
|
+
"f": 4,
|
|
59
|
+
"prs": [
|
|
60
|
+
{
|
|
61
|
+
"n": 1344,
|
|
62
|
+
"t": "Prototype like Figma: pages, screens, layers, an inspector, and Play with the flow beside it",
|
|
63
|
+
"s": "Prototype like Figma: pages, screens, layers, an inspector, and Play with the flow beside it",
|
|
64
|
+
"k": "new"
|
|
65
|
+
}
|
|
66
|
+
]
|
|
67
|
+
},
|
|
36
68
|
{
|
|
37
69
|
"v": "0.601.0",
|
|
38
70
|
"at": "2026-11-18T07:30:23.248Z",
|
|
@@ -290,32 +322,6 @@
|
|
|
290
322
|
"k": "fix"
|
|
291
323
|
}
|
|
292
324
|
]
|
|
293
|
-
},
|
|
294
|
-
{
|
|
295
|
-
"v": "0.583.0",
|
|
296
|
-
"at": "2026-11-17T04:07:38.209Z",
|
|
297
|
-
"f": 4,
|
|
298
|
-
"prs": [
|
|
299
|
-
{
|
|
300
|
-
"n": 1316,
|
|
301
|
-
"t": "Answer Claude Code's add-directory trust prompt for PMOS's own chat-files folder",
|
|
302
|
-
"s": "Answer Claude Code's add-directory trust prompt for PMOS's own chat-files folder",
|
|
303
|
-
"k": "fix"
|
|
304
|
-
}
|
|
305
|
-
]
|
|
306
|
-
},
|
|
307
|
-
{
|
|
308
|
-
"v": "0.582.0",
|
|
309
|
-
"at": "2026-11-17T02:50:44.770Z",
|
|
310
|
-
"f": 4,
|
|
311
|
-
"prs": [
|
|
312
|
-
{
|
|
313
|
-
"n": 1313,
|
|
314
|
-
"t": "The meeting companion offers a live round (live round W2)",
|
|
315
|
-
"s": "The meeting companion offers a live round (live round W2)",
|
|
316
|
-
"k": "new"
|
|
317
|
-
}
|
|
318
|
-
]
|
|
319
325
|
}
|
|
320
326
|
]
|
|
321
327
|
}
|
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-18T08:33:34Z"}
|
|
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-18T08:33:34Z"}
|
|
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-18T08:33:34Z"}
|
|
6
6
|
status: stable
|
|
7
7
|
---
|
|
8
8
|
|
package/workspace/changelog.json
CHANGED
|
@@ -1,4 +1,36 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"v": "0.603.0",
|
|
4
|
+
"at": "2026-11-18T08:33:37.110Z",
|
|
5
|
+
"f": 4,
|
|
6
|
+
"prs": [
|
|
7
|
+
{
|
|
8
|
+
"n": 1345,
|
|
9
|
+
"t": "Timeline bars and axis labels start on their day, under the Today line",
|
|
10
|
+
"s": "Timeline bars and axis labels start on their day, under the Today line",
|
|
11
|
+
"k": "fix"
|
|
12
|
+
},
|
|
13
|
+
{
|
|
14
|
+
"n": 1346,
|
|
15
|
+
"t": "A finished initiative's lateness counts to when it finished, not today",
|
|
16
|
+
"s": "A finished initiative's lateness counts to when it finished, not today",
|
|
17
|
+
"k": "fix"
|
|
18
|
+
}
|
|
19
|
+
]
|
|
20
|
+
},
|
|
21
|
+
{
|
|
22
|
+
"v": "0.602.0",
|
|
23
|
+
"at": "2026-11-18T08:21:52.461Z",
|
|
24
|
+
"f": 4,
|
|
25
|
+
"prs": [
|
|
26
|
+
{
|
|
27
|
+
"n": 1344,
|
|
28
|
+
"t": "Prototype like Figma: pages, screens, layers, an inspector, and Play with the flow beside it",
|
|
29
|
+
"s": "Prototype like Figma: pages, screens, layers, an inspector, and Play with the flow beside it",
|
|
30
|
+
"k": "new"
|
|
31
|
+
}
|
|
32
|
+
]
|
|
33
|
+
},
|
|
2
34
|
{
|
|
3
35
|
"v": "0.601.0",
|
|
4
36
|
"at": "2026-11-18T07:30:23.248Z",
|
|
@@ -195,16 +195,16 @@ Not proven yet: the compare view's Production and Design columns stay left out u
|
|
|
195
195
|
You can ask to see an idea at any moment: alone while you work on an initiative, or with stakeholders in the room. It works like design work with Claude Code: you say what you want, PMOS makes or changes the one prototype, the Viewer shows it, and the chat says what changed.
|
|
196
196
|
|
|
197
197
|
1. **Ask in the initiative's chat.** Say, for example, "prototype this" or "mock this up". PMOS starts one prototype at once. Nothing to press. It opens in the Viewer beside the chat as soon as it opens and renders in a headless browser, in about a minute. The chat answers with a **Version 1** tag and says what was made and for whom. Tap a Version tag to show that version again.
|
|
198
|
-
2. **The Viewer is one canvas.**
|
|
199
|
-
- **
|
|
200
|
-
- **
|
|
201
|
-
- **Page copy
|
|
202
|
-
-
|
|
198
|
+
2. **The Viewer is one canvas, like a design tool.** The prototype is in the middle, at its own size. Three panels sit around it:
|
|
199
|
+
- **Pages, screens and layers** (left). A page is one format or page of the prototype, for example "One Raffles Place LED". A page has screens: its states, for example "Default" and "Sponsor sold". Layers lists the blocks of the screen shown. Tap a screen to show it, or tap a layer to select it. Press [ to hide or show this panel.
|
|
200
|
+
- **Exact values** (right): the inspector for the selected layer. Set its text, font, size, weight, line height, letter spacing, colour, fill, corner, padding and alignment. The prototype changes at once. PMOS keeps the change with the version, and the next version keeps it. The chat shows one quiet line, for example "You set Temperature to 56px · Bold. Kept as yours." The undo press in the panel clears that layer's changes. Press ] to hide or show the inspector.
|
|
201
|
+
- **Page copy, The flow and Who does what**: one press each in the toolbar, closed by default. One opens at a time, in the inspector's place. Page copy lists every word on the screen: edit a line in place. The flow shows screens as cards, decisions as diamonds and branches to the other scenarios: tap a screen to see it, or a side branch to play that scenario. Who does what is a swimlane with arrows between the steps. A press with a dot, or a panel that says **Updated**, is what the last version changed.
|
|
202
|
+
- Zoom out, zoom in and fit are in the toolbar. The design opens on the latest version: the toolbar says **Latest · version n**.
|
|
203
203
|
3. **Change it in one sentence.** For example, "make the alert orange". PMOS makes the next version of the prototype and its flow, swimlane and copy, and the chat says what changed, then "Also updated: step 3, the swimlane and the copy". ‹ › in the toolbar walks the versions. On an older version, **Back to latest** returns, and **Continue from version n** makes your next change start from that version.
|
|
204
|
-
4. **
|
|
204
|
+
4. **Select, then say.** Select (V) is on when the Viewer opens. Tap a block in the prototype, or a layer in the list. It is selected in both places, its exact values show in the inspector, and it goes into the chat box as a chip, for example "Temperature". Your next sentence changes that block. Sliders that the version offers for it (spacing, corner radius, colour) show under the prototype.
|
|
205
205
|
5. **Comment.** Press Comment (C) and tap an element. Write the comment, then send it to PMOS as the next change, or keep it for the team. A kept comment stays pinned, with **Make this change** beside it.
|
|
206
206
|
6. **Draw or attach an image.** Press Draw (D), sketch over the prototype, then attach the sketch. It goes with your next message. An image you attach does the same. PMOS builds from it (its layout, hierarchy and colours) unless your words say otherwise, for example "only the colours".
|
|
207
|
-
7. **Play.** Press Play to run the prototype
|
|
207
|
+
7. **Play.** Press Play to run the prototype through a path of the flow. It shows only the prototype, with no design notes. Pick where it plays: on a phone, on a desktop, or at its own size. The flow sits beside it: pick a path, and tap a step to go there. ← and → move a step, and so do the arrows under the prototype. On a screen with taps, tap where the user would tap; a tap that misses shows where to tap. Restart is under the prototype. Stop (Esc) goes back to the design.
|
|
208
208
|
8. **Several versions only when you ask.** Say "show me 3 ways" (or "two options"). PMOS picks that many directions and shows them in a tray. Tap one to preview it, then keep it (✓) or close the tray (✕).
|
|
209
209
|
9. **The initiative's prototype.** The newest version made from the chat is the initiative's prototype. It is the one entry under **Prototype & design** on the initiative page (above Documents), and the **Prototype** line on its Experiment card. Both open it in the Viewer. Older rounds stay in the Viewer's history, not on the page. Your edits in the Viewer are part of that version. Earlier versions stay in ‹ ›. PMOS never keeps a round by itself. A round of several ways, or one started from a terminal (a test), becomes the prototype only when you keep it with ✓ in the Viewer; the grill then runs once on it. ✕ drops a round, and you can say why.
|
|
210
210
|
10. **The chat knows the prototype.** Every message in the initiative's chat tells PMOS which version is current, where its files are, and the one command that makes the next version. So "Improve the prototype based on the PRD" or "Rebuild A from this list" makes the next version in the Viewer. When no version is current yet, the chat gets the list of recent versions with the command to continue each one (`--of <round>`), and asks you which one if it is not clear. The chat never writes a loose HTML file.
|
package/workspace/guide/home.md
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
type: Guide
|
|
3
3
|
title: "Home: your list, the chat, the Viewer, My work, documents and people"
|
|
4
4
|
description: "Home's list, Mentions, Your day, the chat and the Viewer; My work; documents and their copies; People; and the suggested next prompt."
|
|
5
|
-
timestamp: 2026-11-
|
|
5
|
+
timestamp: 2026-11-18
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Home
|
|
@@ -119,7 +119,7 @@ Press an initiative's name in the list, or open `?ini=<id>`. The list stays as i
|
|
|
119
119
|
- **Set a Jira ticket's dates.** Press the dates of a Jira ticket in the List, or drag its bar on the Timeline, as you do for a task. PMOS keeps the start and due days and shows them in place of the sprint end. Jira does not change. The status and the name stay Jira's.
|
|
120
120
|
- **Tasks** show one row (one group) for each stage of the workflow, in order. Finished stages and later stages are never merged into one row; they start folded, and the current stage and any stage with a late task start open.
|
|
121
121
|
- **Change a task where it is.** In the List, press a task's name. The row opens in place: change the name (Enter saves), the status, and the dates. Only one row is open at a time. Esc closes it. The ⋯ after the dates has **Milestone** (or **Make it a plain task**), **Move to a stage**, **Open the task card** and **Delete task**. A milestone has one date: its due day. Each change shows **Undo**.
|
|
122
|
-
- In the List, a task's full name always shows: a long name wraps onto more lines. A short prefix such as "Bus shelter:" stays in the name, in grey. The dates show at the right. In a narrow panel or on a phone, the dates show under the name. On a computer, the Timeline's name column wraps a long name too, and its row grows; on a phone, each title stays on one line above its bar. A task with no dates shows no date; open the row to set them.
|
|
122
|
+
- In the List, a task's full name always shows: a long name wraps onto more lines. A short prefix such as "Bus shelter:" stays in the name, in grey. The dates show at the right. In a narrow panel or on a phone, the dates show under the name. On a computer, the Timeline's name column wraps a long name too, and its row grows; on a phone, each title stays on one line above its bar. On the Timeline, the blue Today line is your own day, from the clock of your device. Each bar starts on its start day and ends on its due day: a task that starts today starts at the Today line, and a bar, its grid line and its date at the top always meet on the same day. A task with no dates shows no date; open the row to set them.
|
|
123
123
|
- **Add a task to a stage.** Press **+** on an open stage. The field opens at the top of that stage, with one row of chips under it. **Stage** is the stage you pressed + on; press it to pick another stage of the workflow. **Task** can change to **Milestone**: the box becomes ◇ and **Date** takes one day. **Dates** and **Owner** are optional; with no owner, the task is yours. Enter adds the task and keeps the field open for the next one. Esc closes the field.
|
|
124
124
|
- **Move a task between stages.** On a computer, drag the grip at the left of a row. On a phone, press and hold the task's name, then drag. Drop it on a stage name to put it last in that stage, or between two rows to put it there. The status and the dates do not change. The message shows **Undo**.
|
|
125
125
|
- A linked Jira ticket opens in place too. Its name and status stay Jira's ("In Progress in Jira · read 4 min ago"). Its dates can change, and it can be a milestone. It has no **Delete**.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
type: Guide
|
|
3
3
|
title: "Statuses, the lifecycle and workflows"
|
|
4
4
|
description: "What each status means, the stages every initiative goes through, and the workflows of Settings › Workspaces › Workflows."
|
|
5
|
-
timestamp: 2026-11-
|
|
5
|
+
timestamp: 2026-11-18
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
# Statuses, the lifecycle and workflows
|
|
@@ -37,6 +37,17 @@ To read the same table in the app, choose **status** in the list, then **what do
|
|
|
37
37
|
- **On hold**, **Closed** and **Cancelled** come from your latest line in `lifecycle.jsonl`.
|
|
38
38
|
- **Unknown** appears when the trunk history or a ledger cannot be read. The detail gives the reason.
|
|
39
39
|
|
|
40
|
+
## Days over and days late
|
|
41
|
+
|
|
42
|
+
While an initiative is open, its card counts from its planned finish (the latest due date of its tasks) to today: **12 days left**, **ends today** or **145 days over**.
|
|
43
|
+
|
|
44
|
+
When it is finished, the count stops. Finished means it is in the last stage of its workflow (for example Closed or Done). The card then compares the planned finish with the day the work finished. That day is the end of its last Done task. If no Done task has a date, it is the day the initiative moved into its last stage.
|
|
45
|
+
|
|
46
|
+
- If it finished on or before the planned finish, the card shows no count. It says **Done** with the day it finished.
|
|
47
|
+
- If it finished after the planned finish, the card says **Finished N days late**. This number does not grow.
|
|
48
|
+
|
|
49
|
+
Closing an initiative late does not make it late. To clear the badge, do not change dates. The dates are the record.
|
|
50
|
+
|
|
40
51
|
## What you can change by hand
|
|
41
52
|
|
|
42
53
|
You can hold, close, cancel or reopen an initiative. Each action writes one line to `lifecycle.jsonl` with your reason. A held, closed or cancelled initiative leaves the board and stops gating. Reopen puts it back. The detail lists every change.
|
|
@@ -55,6 +55,9 @@ function rule(info, id) {
|
|
|
55
55
|
'There is one kind of task: the ones the PM sees in the initiative\'s Tasks section. The stage card\'s To finish entries and the older breakdown items are tasks too. '
|
|
56
56
|
+ 'A task\'s state is To do, In progress, Done, Won\'t do or Archived. The Tasks section groups the tasks under the stages of this initiative\'s workflow: a task\'s group is its place in the breakdown, never its state. When the PM asks to add, close, group or change a task, '
|
|
57
57
|
+ `do it yourself, never send the PM to the Board: \`pmos task add ${ini} "<title>" [--stage <stage>] [--due YYYY-MM-DD]\` adds one, \`pmos task list ${ini}\` names them all, \`pmos task state <task> [<task> …] --to "<state>" --why "<what shows it>"\` sets their state and \`pmos task set <task> [<task> …] --stage <stage>|none\` groups them (it also takes --due, --start, --owner, --notes; none clears a date). \`pmos task remove <task> [<task> …]\` deletes a task added by mistake when the PM asks; work that stopped is Archived instead. Never use \`pmos item add\` for new work, and never change tasks to move the initiative.`,
|
|
58
|
+
// batch 31 (Wawan 2026-11-18): the chat offered to rewrite a closed initiative's dates to clear "145 days over"; the count was the page's bug
|
|
59
|
+
'The "N days over" badge counts from the planned finish (the latest due of its tasks). While the initiative is open it counts to today. Once it is in its workflow\'s last stage (Closed, Done) it counts to when the work really finished: the end of its last Done task, else the day it moved into that stage. On time, the badge goes away and the card says Done with that date; late, it reads "Finished N days late" and that number never grows. '
|
|
60
|
+
+ 'Never change a date, a task or the stage to clear or shorten the badge: the dates are the record. When the PM asks why it shows, explain this rule.',
|
|
58
61
|
'The Board timeline draws one bar per initiative, from the earliest start to the latest due of its tasks. An initiative with no dated task has no bar. Every stage shows there, Monitor and Evaluate included. Use these rules when the PM asks why an initiative is not on the timeline.',
|
|
59
62
|
`A stage's document fills its card only through \`pmos coredoc write --scope initiative:${ini} --key wf-<stage key> --file <path>\` (the stage keys are in \`pmos workflow of ${ini}\`). It is a draft the PM issues on the page. A file written under planning/ is not linked to a card.`,
|
|
60
63
|
);
|
|
@@ -68,6 +68,7 @@ function build(f) {
|
|
|
68
68
|
statusLabel: status ? (STATUS_LABEL[status] || cap1(status)) : null, tone: status === 'on track' || status === 'done' ? 'ok' : bad ? (status === 'late' ? 'bad' : 'warn') : 'mut',
|
|
69
69
|
meta: [board.name || '', row.owner || '', row.end ? 'planned finish ' + shortDate(row.end) : ''].filter(Boolean),
|
|
70
70
|
stage: row.stage || null, stageNote: row.stageSource === 'derived' ? 'derived by the workflow engine' : null,
|
|
71
|
+
closed: !!row.closed, // batch 31: in its workflow's last stage, so a passed planned finish is not over (premium-initiative-head.js)
|
|
71
72
|
oneStage: row.oneStage || null, // W1: the one stage and what set it (lib/one-stage.js); the stage card and the chip draw it
|
|
72
73
|
strip: { names, seg: names.map((n, j) => (j < cur ? 'p' : j === cur ? 'n' : '')), cur: cur >= 0 ? cur : null },
|
|
73
74
|
};
|
|
@@ -242,11 +242,12 @@ function promptOf(o) {
|
|
|
242
242
|
} else if (o.alone) L.push('', 'This is the one version the PM sees: make the plainest honest version of the idea, not a showcase.');
|
|
243
243
|
else L.push('', `Your direction, ${o.key}: ${one(o.title, 200)}. Other runs take the other directions: keep yours clearly different.`);
|
|
244
244
|
if (o.point && (o.point.el || o.point.label)) L.push('', `The PM pointed at one element: ${o.point.el ? 'data-el="' + one(o.point.el, 60) + '"' : ''}${o.point.label ? ' ("' + one(o.point.label, 80) + '")' : ''}. Their words are about that element: change it, and only what must follow from it.`);
|
|
245
|
-
const ed = o.edits || {}, ec = Object.entries(ed.copy || {}), ev = Object.entries(ed.vars || {});
|
|
246
|
-
if (ec.length || ev.length) {
|
|
245
|
+
const ed = o.edits || {}, ec = Object.entries(ed.copy || {}), ev = Object.entries(ed.vars || {}), es = Object.entries(ed.styles || {});
|
|
246
|
+
if (ec.length || ev.length || es.length) {
|
|
247
247
|
L.push('', 'The PM edited the last version in place. Keep these exactly, unless their words change them:');
|
|
248
248
|
for (const [k, v] of ec.slice(0, 40)) L.push(`- the text of data-copy="${k}": ${one(v, 200)}`);
|
|
249
249
|
for (const [k, v] of ev.slice(0, 20)) L.push(`- the CSS variable ${k}: ${one(v, 40)} (set it in :root)`);
|
|
250
|
+
for (const [k, v] of es.slice(0, 30)) L.push(`- the style of data-el="${k}": ${Object.entries(v).map(([p, x]) => STYLE_OK[p][0] + ': ' + x).join('; ')} (write it in the page's CSS for that element)`);
|
|
250
251
|
}
|
|
251
252
|
// the design sprint's good practice, silent (Wawan 2026-11-17: "the design sprint runs in silent"): a target user, one question, real
|
|
252
253
|
// content, Goldilocks fidelity. Never a step the PM has to fill in.
|
|
@@ -257,8 +258,9 @@ function promptOf(o) {
|
|
|
257
258
|
' - One self-contained HTML page: inline CSS only, no script, no network, no image files. Real draft copy, never lorem ipsum or a placeholder.',
|
|
258
259
|
` - In <head>, one line for the PM: <meta name="pmos-changed" content="…"> with ONE short sentence of what ${o.base ? 'you changed' : 'you made and for whom'}, in plain words, under 140 characters.`,
|
|
259
260
|
' - Each screen is a <section data-screen="<id>" data-label="<screen name>">; the first one is where the user starts. PMOS shows one screen at a time.',
|
|
261
|
+
' - When several screens are states of one page or format (default, sponsor sold, rain alert), give each data-page="<that page\'s name>": the PM sees them as one page with its screens.',
|
|
260
262
|
' - What the user taps to move on carries data-go="<screen id>" (a button, a row, a link with href="#<screen id>").',
|
|
261
|
-
' - Every
|
|
263
|
+
' - Every visible block the PM may select and restyle (each heading, line of text, card, list, button, image, region) carries data-el="<short-id>" and data-label="<its name in plain words>".',
|
|
262
264
|
' - Every piece of visible text the PM may edit is in an element with data-copy="<key>" (unique keys, kebab-case, the text only inside it).',
|
|
263
265
|
' - Spacing, corner radius and colour warmth read CSS custom properties set in :root (for example --gap, --radius, --accent), so a slider can change them.',
|
|
264
266
|
' - Pin it to the viewport: the main card is max-width 390px and width 100%, nothing wider than the screen, no horizontal scroll at 390px. At desk width it sits centred.',
|
|
@@ -367,15 +369,35 @@ function partsAt(abs) {
|
|
|
367
369
|
const l = lanesOf(rd('lanes.json'), { screens: out.flow ? new Set(out.flow.screens.map((x) => x.id)) : null }); if (!l.error) out.lanes = l;
|
|
368
370
|
const t = tweaksOf(rd('tweaks.json')); if (!t.error && t.tweaks.length) out.tweaks = t;
|
|
369
371
|
const c = rd('copy.json'); if (isObj(c)) out.copy = c;
|
|
370
|
-
const e = editsOf(rd('edits.json')); if (Object.keys(e.copy).length || Object.keys(e.vars).length) out.edits = e;
|
|
372
|
+
const e = editsOf(rd('edits.json')); if (Object.keys(e.copy).length || Object.keys(e.vars).length || Object.keys(e.styles).length) out.edits = e;
|
|
371
373
|
return out;
|
|
372
374
|
}
|
|
373
|
-
/**
|
|
375
|
+
/** The inspector's fields (design "Prototype like Figma", Wawan "build" 2026-11-18): the key edits.json keeps, the CSS property it sets,
|
|
376
|
+
* and what a value may look like. */
|
|
377
|
+
const STYLE_OK = {
|
|
378
|
+
family: ['font-family', /^[A-Za-z0-9 ,"'-]{1,80}$/], size: ['font-size', /^\d{1,3}(\.\d{1,2})?px$/], weight: ['font-weight', /^[1-9]00$/],
|
|
379
|
+
line: ['line-height', /^\d(\.\d{1,2})?$/], spacing: ['letter-spacing', /^-?\d{1,2}(\.\d{1,2})?px$/], color: ['color', /^#[0-9a-f]{6}$/i],
|
|
380
|
+
fill: ['background-color', /^(#[0-9a-f]{6}|transparent)$/i], corner: ['border-radius', /^\d{1,3}px$/], padding: ['padding', /^\d{1,3}px( \d{1,3}px)?$/],
|
|
381
|
+
align: ['text-align', /^(left|center|right)$/],
|
|
382
|
+
};
|
|
383
|
+
/** PURE. edits.json (the PM's in-place copy edits, tweaks and inspector styles, POST /api/lab/edit) →
|
|
384
|
+
* { copy: { key: text }, vars: { --var: value }, styles: { el: { field: value } } } (fields: STYLE_OK). A bad field or value is left out. */
|
|
374
385
|
function editsOf(j) {
|
|
375
|
-
const copy = {}, vars = {};
|
|
386
|
+
const copy = {}, vars = {}, styles = {};
|
|
376
387
|
if (isObj(j) && isObj(j.copy)) for (const [k, v] of Object.entries(j.copy).slice(0, 80)) if (/^[A-Za-z0-9][A-Za-z0-9_.-]{0,59}$/.test(k) && typeof v === 'string') copy[k] = one(v, 300);
|
|
377
388
|
if (isObj(j) && isObj(j.vars)) for (const [k, v] of Object.entries(j.vars).slice(0, 12)) if (/^--[a-z][a-z0-9-]{0,40}$/i.test(k) && /^-?\d{1,4}(\.\d{1,3})?(px|rem|em|%|deg)?$/.test(String(v))) vars[k] = String(v);
|
|
378
|
-
|
|
389
|
+
if (isObj(j) && isObj(j.styles)) for (const [el, ps] of Object.entries(j.styles).slice(0, 60)) {
|
|
390
|
+
if (!/^[A-Za-z0-9][A-Za-z0-9_-]{0,59}$/.test(el) || !isObj(ps)) continue;
|
|
391
|
+
const o = {};
|
|
392
|
+
for (const [k, v] of Object.entries(ps)) if (STYLE_OK[k] && typeof v === 'string' && STYLE_OK[k][1].test(v)) o[k] = v;
|
|
393
|
+
if (Object.keys(o).length) styles[el] = o;
|
|
394
|
+
}
|
|
395
|
+
return { copy, vars, styles };
|
|
396
|
+
}
|
|
397
|
+
/** PURE. What one element's styles say, for the chat and the prompt: "56px · Bold · #FFFFFF". */
|
|
398
|
+
function styleWords(ps) {
|
|
399
|
+
const W = { 100: 'Thin', 200: 'Extra light', 300: 'Light', 400: 'Regular', 500: 'Medium', 600: 'Semibold', 700: 'Bold', 800: 'Extra bold', 900: 'Black' };
|
|
400
|
+
return Object.entries(ps || {}).map(([k, v]) => (k === 'weight' ? W[v] || v : k === 'size' || k === 'color' ? v : k + ' ' + v)).join(' · ');
|
|
379
401
|
}
|
|
380
402
|
|
|
381
403
|
/** The one sentence a version says about itself: <meta name="pmos-changed" content="…"> in its head, or ''. */
|
|
@@ -716,5 +738,5 @@ function stopRound(id) { return inst ? inst.stop(id) : { ok: false, error: NOT_R
|
|
|
716
738
|
function status() { return inst ? inst.status() : []; }
|
|
717
739
|
|
|
718
740
|
module.exports = { JOB, ORIGIN, STALL_MS, progressOf, KEYS, DEFAULT_DIRECTIONS, ONE_DIRECTION, PARTS, FROM, marksOf, intentOf, parseDirs, askOf, waiting, baseOf, currentOf: PR.currentOf, contextOf, scaffoldOf, promptOf, saidOf, roundLine,
|
|
719
|
-
flowOf, lanesOf, tweaksOf, copyOf, changesOf, partsAt, editsOf,
|
|
741
|
+
flowOf, lanesOf, tweaksOf, copyOf, changesOf, partsAt, editsOf, styleWords, STYLE_OK,
|
|
720
742
|
create, install, round, startNow, proposeNow, cancel, stopRound, dropCard, running, status };
|
|
@@ -7,8 +7,9 @@
|
|
|
7
7
|
* data-screen one screen shows at a time; the first is the start data-go a tap moves to that screen
|
|
8
8
|
* data-el what the PM can point at, comment on or tap in Play data-label its name in plain words
|
|
9
9
|
* data-copy text the Page copy card edits in place :root vars what Tweaks change
|
|
10
|
-
* Parent → frame { pmos: 1, t }: mode (view | point | comment | play), screen, copy, copyAll, vars, hint, sel, pins.
|
|
11
|
-
* Frame → parent { pmos: 1, t }: ready (screens, els, copy), screen, point
|
|
10
|
+
* Parent → frame { pmos: 1, t }: mode (view | point | comment | play), screen, copy, copyAll, vars, styles (the inspector's, all of them), hint, sel, pins.
|
|
11
|
+
* Frame → parent { pmos: 1, t }: ready (screens with their data-page, els with their screen and copy key, copy), screen, point (with looks: the
|
|
12
|
+
* selected element's current styles), looks (after styles), pin, tap.
|
|
12
13
|
*
|
|
13
14
|
* withRuntime(html) → html with the runtime's <script> before </body> (or at the end) */
|
|
14
15
|
function runtime() {
|
|
@@ -32,7 +33,36 @@ function runtime() {
|
|
|
32
33
|
post({ t: 'screen', id: on.getAttribute('data-screen') });
|
|
33
34
|
};
|
|
34
35
|
var elOf = function (n) { return n && n.closest ? n.closest('[data-el]') : null; };
|
|
35
|
-
var info = function (e) {
|
|
36
|
+
var info = function (e) {
|
|
37
|
+
if (!e) return { el: '', label: '' };
|
|
38
|
+
var sc = e.closest('[data-screen]'), cp = e.hasAttribute('data-copy') ? e : e.querySelector('[data-copy]');
|
|
39
|
+
return { el: e.getAttribute('data-el') || '', label: e.getAttribute('data-label') || (e.textContent || '').trim().slice(0, 40), screen: sc ? sc.getAttribute('data-screen') || '' : '', copy: cp ? cp.getAttribute('data-copy') || '' : '' };
|
|
40
|
+
};
|
|
41
|
+
// the inspector (design "Prototype like Figma"): what the selected element looks like now, as the values it edits
|
|
42
|
+
var CSS = { family: 'font-family', size: 'font-size', weight: 'font-weight', line: 'line-height', spacing: 'letter-spacing', color: 'color', fill: 'background-color', corner: 'border-radius', padding: 'padding', align: 'text-align' };
|
|
43
|
+
var hex = function (c) { var m = /rgba?\((\d+),\s*(\d+),\s*(\d+)(?:,\s*([\d.]+))?\)/.exec(c || ''); if (!m) return c || ''; if (m[4] === '0') return 'transparent'; return '#' + [m[1], m[2], m[3]].map(function (x) { return ('0' + Number(x).toString(16)).slice(-2); }).join(''); };
|
|
44
|
+
var looks = function (e) {
|
|
45
|
+
var cs = getComputedStyle(e), o = {}, fs = parseFloat(cs.fontSize) || 16, bg = e, fill = 'transparent';
|
|
46
|
+
o.family = (cs.fontFamily || '').split(',')[0].replace(/["']/g, '').trim();
|
|
47
|
+
o.size = Math.round(fs) + 'px'; o.weight = String(Math.round((parseInt(cs.fontWeight, 10) || 400) / 100) * 100);
|
|
48
|
+
o.line = cs.lineHeight === 'normal' ? '1.2' : String(Math.round((parseFloat(cs.lineHeight) / fs) * 100) / 100);
|
|
49
|
+
o.spacing = cs.letterSpacing === 'normal' ? '0px' : Math.round(parseFloat(cs.letterSpacing) * 10) / 10 + 'px';
|
|
50
|
+
o.color = hex(cs.color); o.fill = hex(cs.backgroundColor);
|
|
51
|
+
// the colour picker needs a colour: a see-through fill shows what is behind it
|
|
52
|
+
while (bg && fill === 'transparent') { fill = hex(getComputedStyle(bg).backgroundColor); bg = bg.parentElement; }
|
|
53
|
+
o.fillPick = /^#/.test(fill) ? fill : '#ffffff';
|
|
54
|
+
o.corner = Math.round(parseFloat(cs.borderTopLeftRadius) || 0) + 'px'; o.padding = Math.round(parseFloat(cs.paddingTop) || 0) + 'px ' + Math.round(parseFloat(cs.paddingLeft) || 0) + 'px';
|
|
55
|
+
o.align = /center|right/.test(cs.textAlign) ? cs.textAlign : 'left';
|
|
56
|
+
return o;
|
|
57
|
+
};
|
|
58
|
+
var styled = [];
|
|
59
|
+
var applyStyles = function (all) {
|
|
60
|
+
styled.forEach(function (x) { x.e.style.removeProperty(x.p); }); styled = [];
|
|
61
|
+
Object.keys(all || {}).forEach(function (id) {
|
|
62
|
+
var e = document.querySelector('[data-el="' + String(id).replace(/[^A-Za-z0-9_-]/g, '') + '"]'); if (!e) return;
|
|
63
|
+
Object.keys(all[id] || {}).forEach(function (k) { var p = CSS[k]; if (!p) return; e.style.setProperty(p, String(all[id][k]), 'important'); styled.push({ e: e, p: p }); });
|
|
64
|
+
});
|
|
65
|
+
};
|
|
36
66
|
var hov = null;
|
|
37
67
|
document.addEventListener('mouseover', function (ev) {
|
|
38
68
|
if (mode !== 'point' && mode !== 'comment') return;
|
|
@@ -41,7 +71,7 @@ function runtime() {
|
|
|
41
71
|
}, true);
|
|
42
72
|
document.addEventListener('click', function (ev) {
|
|
43
73
|
var e = elOf(ev.target), go = ev.target.closest && ev.target.closest('[data-go],a[href^="#"]');
|
|
44
|
-
if (mode === 'point') { ev.preventDefault(); ev.stopPropagation(); if (!e) return; sel(e.getAttribute('data-el')); var i = info(e); i.t = 'point'; post(i); return; }
|
|
74
|
+
if (mode === 'point') { ev.preventDefault(); ev.stopPropagation(); if (!e) return; sel(e.getAttribute('data-el')); var i = info(e); i.t = 'point'; i.looks = looks(e); post(i); return; }
|
|
45
75
|
if (mode === 'comment') {
|
|
46
76
|
ev.preventDefault(); ev.stopPropagation();
|
|
47
77
|
var h = Math.max(1, document.documentElement.scrollHeight), w = Math.max(1, document.documentElement.clientWidth), c = info(e);
|
|
@@ -85,12 +115,16 @@ function runtime() {
|
|
|
85
115
|
(m.els || []).forEach(function (id) { var e = document.querySelector('[data-el="' + String(id).replace(/[^A-Za-z0-9_-]/g, '') + '"]'); if (e) e.classList.add('pmos-hint'); });
|
|
86
116
|
setTimeout(function () { Array.prototype.forEach.call(document.querySelectorAll('.pmos-hint'), function (x) { x.classList.remove('pmos-hint'); }); }, 1600);
|
|
87
117
|
} else if (m.t === 'sel') sel(m.el);
|
|
118
|
+
else if (m.t === 'styles') {
|
|
119
|
+
applyStyles(m.styles);
|
|
120
|
+
var se = document.querySelector('.pmos-sel'); if (se) post({ t: 'looks', el: se.getAttribute('data-el') || '', looks: looks(se) });
|
|
121
|
+
}
|
|
88
122
|
else if (m.t === 'pins') pins(m.pins);
|
|
89
123
|
});
|
|
90
124
|
var start = function () {
|
|
91
125
|
var all = screens(); if (all.length) all[0].classList.add('pmos-on');
|
|
92
126
|
var copy = {}; Array.prototype.forEach.call(document.querySelectorAll('[data-copy]'), function (x) { var k = x.getAttribute('data-copy'); if (!(k in copy)) copy[k] = (x.textContent || '').trim(); });
|
|
93
|
-
post({ t: 'ready', screens: all.map(function (s) { return { id: s.getAttribute('data-screen'), label: s.getAttribute('data-label') || '' }; }),
|
|
127
|
+
post({ t: 'ready', screens: all.map(function (s) { return { id: s.getAttribute('data-screen'), label: s.getAttribute('data-label') || '', page: s.getAttribute('data-page') || '' }; }),
|
|
94
128
|
els: Array.prototype.map.call(document.querySelectorAll('[data-el]'), function (e) { return info(e); }), copy: copy });
|
|
95
129
|
};
|
|
96
130
|
if (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', start); else start();
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
* Prototype by chatting (initiative live-round-iterative): the compare view of a live round carries its version's companions as data
|
|
19
19
|
* (data: { flow, lanes, copy, tweaks, edits }, lib/live-round.js partsAt) and the initiative's comments; GET /api/lab/specimen with rt=1
|
|
20
20
|
* adds the canvas runtime (lib/proto-runtime.js) inside the same sandbox, so the canvas can point, pin, play and edit through postMessage.
|
|
21
|
-
* POST /api/lab/edit { ws, file, copy?: { key: text }, vars?: { --var: value } } → { ok } the PM's in-place copy edits and
|
|
21
|
+
* POST /api/lab/edit { ws, file, copy?: { key: text }, vars?: { --var: value }, styles?: { el: { prop: value } | null } } → { ok } the PM's in-place copy edits, tweaks and inspector styles,
|
|
22
22
|
* kept with the version (edits.json next to it); the next version reads them
|
|
23
23
|
* POST /api/lab/comment { ws, ini, file, el?, label?, text, x?, y?, send? } → { ok, id } a comment pinned to an element (send: it was
|
|
24
24
|
* sent to PMOS as the next change; else it is kept for the team)
|
|
@@ -204,12 +204,16 @@ const WRITES = {
|
|
|
204
204
|
const abs = liveFile(ctx, body.file); if (!abs) return fail(ctx, res, 404, 'That version is not in the live round folder');
|
|
205
205
|
const LR = require('./live-round.js'), f = require('path').join(require('path').dirname(abs), 'edits.json');
|
|
206
206
|
let was = {}; try { was = JSON.parse(fs.readFileSync(f, 'utf8')); } catch { was = {}; }
|
|
207
|
-
const add = LR.editsOf({ copy: body.copy, vars: body.vars }), old = LR.editsOf(was);
|
|
208
|
-
|
|
207
|
+
const add = LR.editsOf({ copy: body.copy, vars: body.vars, styles: body.styles }), old = LR.editsOf(was);
|
|
208
|
+
// inspector styles merge per element; { el: null } (the layer's undo) drops that element's styles
|
|
209
|
+
const styles = { ...old.styles };
|
|
210
|
+
for (const [el, ps] of Object.entries(add.styles)) styles[el] = { ...(styles[el] || {}), ...ps };
|
|
211
|
+
if (body.styles && typeof body.styles === 'object') for (const [el, ps] of Object.entries(body.styles)) if (ps === null) delete styles[el];
|
|
212
|
+
const next = { copy: { ...old.copy, ...add.copy }, vars: { ...old.vars, ...add.vars }, styles };
|
|
209
213
|
try { fs.writeFileSync(f, JSON.stringify(next, null, 1)); } catch { return fail(ctx, res, 500, 'The edit was not saved'); }
|
|
210
214
|
// the edits are part of the version the initiative is at (2026-11-18: they lived only in edits.json): its kept line says so, once per
|
|
211
215
|
// new line edited (not on every key press)
|
|
212
|
-
const n0 = Object.keys(old.copy).length + Object.keys(old.vars).length, n1 = Object.keys(next.copy).length + Object.keys(next.vars).length;
|
|
216
|
+
const n0 = Object.keys(old.copy).length + Object.keys(old.vars).length + Object.keys(old.styles).length, n1 = Object.keys(next.copy).length + Object.keys(next.vars).length + Object.keys(next.styles).length;
|
|
213
217
|
if (n1 > n0) try { keptEdited(dir, String(body.file), next, g); } catch { /* edits.json holds them */ }
|
|
214
218
|
ctx.json(res, { ok: true, edits: next });
|
|
215
219
|
return true;
|
|
@@ -247,8 +251,8 @@ function keptEdited(dir, file, ed, g) {
|
|
|
247
251
|
}
|
|
248
252
|
const cur = ini ? PR.currentOf(F, ini) : null;
|
|
249
253
|
if (!cur || cur.file !== file) return;
|
|
250
|
-
const nc = Object.keys(ed.copy).length, nv = Object.keys(ed.vars).length;
|
|
251
|
-
const what = [nc ? nc + (nc === 1 ? ' line of copy' : ' lines of copy') : '', nv ? nv + (nv === 1 ? ' tweak' : ' tweaks') : ''].filter(Boolean).join(' and ');
|
|
254
|
+
const nc = Object.keys(ed.copy).length, nv = Object.keys(ed.vars).length, ns = Object.keys(ed.styles || {}).length;
|
|
255
|
+
const what = [nc ? nc + (nc === 1 ? ' line of copy' : ' lines of copy') : '', nv ? nv + (nv === 1 ? ' tweak' : ' tweaks') : '', ns ? ns + (ns === 1 ? ' restyled layer' : ' restyled layers') : ''].filter(Boolean).join(' and ');
|
|
252
256
|
const AF = require('./artefacts.js'), by = (g.actor && /^(pm|agent):/.test(String(g.actor.by || ''))) ? g.actor : { by: 'agent:live-round' };
|
|
253
257
|
AF.set(AF.file(dir), { scope: 'experiment:' + ini, artefact: 'specimens', field: 'kept', text: `Version ${cur.n}, with your edits in the Viewer (${what}): ${cur.said || cur.title || ''} (${LAB.specimenUrl(file)})`.slice(0, 600), sources: [{ label: 'live round', ref: LAB.specimenUrl(file) }] }, by);
|
|
254
258
|
}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pmos-workspace",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.603.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.603.0",
|
|
10
10
|
"license": "MIT",
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@anthropic-ai/sdk": "^1.3.0",
|
package/workspace/package.json
CHANGED
|
@@ -34,10 +34,32 @@
|
|
|
34
34
|
|
|
35
35
|
/* the canvas */
|
|
36
36
|
.pc-vp { overflow: auto; border-radius: 16px; background-color: var(--cz-well); background-image: radial-gradient(var(--cz-hair) 1px, transparent 1px); background-size: 16px 16px; padding: 14px; min-height: 420px; }
|
|
37
|
-
.pc-
|
|
38
|
-
.pc-
|
|
39
|
-
.pc-
|
|
40
|
-
.pc-
|
|
37
|
+
.pc-dbody { display: flex; gap: 10px; align-items: stretch; min-height: 420px; }
|
|
38
|
+
.pc-dbody > .pc-vp { flex: 1; min-width: 0; }
|
|
39
|
+
.pc-leftw:empty, .pc-rightw:empty { display: none; }
|
|
40
|
+
.pc-board { display: flex; justify-content: center; align-items: flex-start; width: max-content; min-width: 100%; }
|
|
41
|
+
|
|
42
|
+
/* design mode: Pages > Screens > Layers on the left, Exact values on the right (canvas FpA); both hide */
|
|
43
|
+
.pc-left, .pc-insp, .pc-side { display: flex; flex-direction: column; gap: 2px; padding: 6px 0 10px; border: 1px solid var(--cz-hair); border-radius: 16px; background: var(--cz-card); overflow: auto; max-height: 72vh; }
|
|
44
|
+
.pc-left { width: 210px; }
|
|
45
|
+
.pc-insp { width: 270px; gap: 0; }
|
|
46
|
+
.pc-lh { display: flex; align-items: center; gap: 6px; min-height: 36px; padding: 6px 6px 2px 14px; font-size: var(--fs-badge); font-weight: var(--fw-strong); letter-spacing: .06em; text-transform: uppercase; color: var(--cz-ink3); }
|
|
47
|
+
.pc-lh span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
|
|
48
|
+
.pc-lh .pc-ib { border-color: transparent; background: transparent; }
|
|
49
|
+
.pc-lrow { display: block; width: 100%; min-height: 32px; padding: 6px 14px; border: 0; background: transparent; text-align: left; font: inherit; font-size: var(--fs-meta); line-height: var(--lh-meta); color: var(--cz-ink2); cursor: pointer; }
|
|
50
|
+
.pc-lrow.in { padding-left: 26px; }
|
|
51
|
+
.pc-lrow:hover { background: var(--cz-well); }
|
|
52
|
+
.pc-lrow[aria-pressed="true"] { background: var(--cz-bluebg); color: var(--cz-blueink); font-weight: var(--fw-strong); }
|
|
53
|
+
.pc-left .pc-hint, .pc-insp > .pc-hint { padding: 4px 14px; }
|
|
54
|
+
.pc-isec { display: flex; flex-direction: column; gap: 6px; padding: 8px 14px; border-top: 1px solid var(--cz-hair); }
|
|
55
|
+
.pc-isec:first-of-type { border-top: 0; }
|
|
56
|
+
.pc-isec > b { font-size: var(--fs-badge); font-weight: var(--fw-strong); letter-spacing: .06em; text-transform: uppercase; color: var(--cz-ink3); }
|
|
57
|
+
.pc-ir { display: grid; grid-template-columns: 84px 1fr; align-items: center; gap: 8px; font-size: var(--fs-meta); color: var(--cz-ink2); }
|
|
58
|
+
.pc-ir input, .pc-ir select { min-width: 0; width: 100%; height: 32px; padding: 0 8px; border: 1px solid var(--cz-hair); border-radius: 8px; background: var(--cz-card); color: var(--cz-ink); font: inherit; font-size: var(--fs-meta); }
|
|
59
|
+
.pc-ir input[type="color"] { padding: 2px; cursor: pointer; }
|
|
60
|
+
.pc-two { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
|
|
61
|
+
.pc-ifoot { margin: 0; display: flex; align-items: center; gap: 8px; padding: 10px 8px 0 14px; border-top: 1px solid var(--cz-hair); font-size: var(--fs-meta); line-height: var(--lh-meta); color: var(--cz-ink3); }
|
|
62
|
+
.pc-ifoot .pc-ib { margin-left: auto; }
|
|
41
63
|
.pc-card { display: flex; flex-direction: column; gap: 8px; padding: 14px; border: 1px solid var(--cz-hair); border-radius: 16px; background: var(--cz-card); min-width: 0; }
|
|
42
64
|
.pc-card h3 { margin: 0; display: flex; align-items: center; gap: 8px; font-size: var(--fs-row); font-weight: var(--fw-strong); line-height: var(--lh-row); }
|
|
43
65
|
.pc-upd { display: inline-flex; align-items: center; height: 20px; padding: 0 8px; border-radius: 999px; background: var(--cz-okbg); color: var(--cz-ok); font-size: var(--fs-badge); font-weight: var(--fw-strong); line-height: var(--lh-badge); }
|
|
@@ -60,9 +82,9 @@
|
|
|
60
82
|
.pc-dev { position: relative; }
|
|
61
83
|
.pc-dev.phone { width: 300px; padding: 10px; border-radius: 34px; background: var(--cz-ink); }
|
|
62
84
|
.pc-dev.phone .pc-frame { height: 600px; border-radius: 26px; }
|
|
63
|
-
.pc-dev.desktop { width:
|
|
85
|
+
.pc-dev.desktop { width: 900px; padding: 26px 0 0; border-radius: 12px; background: var(--cz-well2, var(--cz-well)); border: 1px solid var(--cz-hair); }
|
|
64
86
|
.pc-dev.desktop::before { content: ''; position: absolute; left: 12px; top: 10px; width: 36px; height: 8px; border-radius: 4px; background: radial-gradient(circle at 4px 4px, var(--cz-hair) 3.5px, transparent 4px) 0 0 / 14px 8px repeat-x; }
|
|
65
|
-
.pc-dev.desktop .pc-frame { height:
|
|
87
|
+
.pc-dev.desktop .pc-frame { height: 560px; border-radius: 0 0 12px 12px; }
|
|
66
88
|
.pc-frame { position: relative; overflow: hidden; background: var(--cz-c-ffffff); }
|
|
67
89
|
.pc-frame iframe { display: block; width: 100%; height: 100%; border: 0; background: var(--cz-c-ffffff); }
|
|
68
90
|
.pc-frame .pc-none { padding: 20px; }
|
|
@@ -119,7 +141,7 @@
|
|
|
119
141
|
.pc-chip[aria-pressed="true"] { background: var(--cz-bluebg); color: var(--cz-blueink); border-color: transparent; }
|
|
120
142
|
|
|
121
143
|
/* the page copy: a side panel over the canvas, behind the toolbar's Page copy press (closed by default) */
|
|
122
|
-
.pc-side {
|
|
144
|
+
.pc-side { width: min(420px, 100%); padding: 14px; gap: 8px; }
|
|
123
145
|
.pc-side h3 { display: flex; align-items: center; gap: 8px; }
|
|
124
146
|
.pc-side h3 .pc-ib { margin-left: auto; width: 28px; height: 28px; }
|
|
125
147
|
.pc .pc-ib.upd { position: relative; }
|
|
@@ -132,18 +154,45 @@
|
|
|
132
154
|
.pc-cr [contenteditable]:hover { background: var(--cz-well); }
|
|
133
155
|
.pc-cr.ch [contenteditable] { box-shadow: inset 2px 0 0 var(--cz-ok); }
|
|
134
156
|
|
|
135
|
-
/* Play */
|
|
136
|
-
.pc-play { position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; gap: 10px; padding: 10px; border-radius: 16px; background: var(--cz-
|
|
137
|
-
.pc-
|
|
138
|
-
.pc-
|
|
139
|
-
.pc-
|
|
140
|
-
.pc-
|
|
141
|
-
.pc-
|
|
142
|
-
.pc-
|
|
143
|
-
.pc-
|
|
157
|
+
/* Play (canvas FpC): the prototype bare, the device switch, the flow beside it as steps */
|
|
158
|
+
.pc-play { position: absolute; inset: 0; z-index: 5; display: flex; flex-direction: column; gap: 10px; padding: 10px; border-radius: 16px; background: var(--cz-ink); color: var(--cz-onsolid); }
|
|
159
|
+
.pc-play .pc-ib { background: transparent; border-color: transparent; color: var(--cz-onsolid); }
|
|
160
|
+
.pc-play .pc-ib.blue { background: var(--cz-blue); color: var(--cz-ink); }
|
|
161
|
+
.pc-play .pc-grp { background: rgba(255, 255, 255, .08); }
|
|
162
|
+
.pc-play .pc-grp .pc-ib[aria-pressed="true"], .pc-play .pc-ib[aria-pressed="true"] { background: rgba(255, 255, 255, .16); color: var(--cz-onsolid); box-shadow: none; }
|
|
163
|
+
.pc-pbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
|
|
164
|
+
.pc-pbar b { font-weight: var(--fw-strong); }
|
|
165
|
+
.pc-pbar small { font-size: var(--fs-meta); opacity: .7; }
|
|
166
|
+
.pc-pmain { flex: 1; min-height: 0; display: flex; gap: 12px; }
|
|
167
|
+
.pc-pstage { flex: 1; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 10px; }
|
|
168
|
+
.pc-pstage .pc-hint { color: var(--cz-onsolid); opacity: .6; text-align: center; }
|
|
169
|
+
.pc-pframe { flex: 1; min-height: 0; width: 100%; display: flex; justify-content: center; }
|
|
170
|
+
.pc-pframe iframe { border: 0; background: var(--cz-c-ffffff); height: 100%; min-height: 420px; }
|
|
171
|
+
.pc-pframe.phone iframe { width: 390px; border-radius: 26px; box-shadow: 0 0 0 10px var(--cz-ink2); margin: 10px; }
|
|
172
|
+
.pc-pframe.desktop iframe { width: min(1280px, 100%); border-radius: 12px; }
|
|
173
|
+
.pc-pframe.own iframe { width: 100%; border-radius: 6px; }
|
|
174
|
+
.pc-pctl { display: inline-flex; align-items: center; gap: 6px; padding: 4px; border-radius: 14px; background: rgba(255, 255, 255, .08); }
|
|
175
|
+
.pc-pctl > span { min-width: 120px; text-align: center; font-size: var(--fs-meta); font-variant-numeric: tabular-nums; }
|
|
176
|
+
.pc-pflow { width: 300px; flex: none; display: flex; flex-direction: column; gap: 8px; padding: 6px 10px 10px; border-radius: 14px; background: rgba(255, 255, 255, .06); overflow: auto; }
|
|
177
|
+
.pc-pflow .pc-lh { color: var(--cz-onsolid); opacity: .7; padding-left: 4px; }
|
|
178
|
+
.pc-psel select { width: 100%; height: 40px; padding: 0 10px; border-radius: 10px; border: 1px solid rgba(255, 255, 255, .16); background: rgba(255, 255, 255, .06); color: var(--cz-onsolid); font: inherit; font-size: var(--fs-meta); }
|
|
179
|
+
.pc-psel option { color: var(--cz-ink); }
|
|
180
|
+
.pc-vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
|
|
181
|
+
.pc-pflow .pc-bar2 { background: rgba(255, 255, 255, .12); }
|
|
182
|
+
.pc-psteps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 2px; }
|
|
183
|
+
.pc-pst { display: flex; align-items: center; gap: 10px; width: 100%; min-height: 44px; padding: 6px 8px; border: 0; border-radius: 10px; background: transparent; color: var(--cz-onsolid); font: inherit; font-size: var(--fs-meta); text-align: left; cursor: pointer; }
|
|
184
|
+
.pc-pst:hover { background: rgba(255, 255, 255, .06); }
|
|
185
|
+
.pc-pst.on { background: rgba(255, 255, 255, .14); }
|
|
186
|
+
.pc-pst.done { opacity: .7; }
|
|
187
|
+
.pc-pn { width: 22px; height: 22px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: var(--fs-badge); background: rgba(255, 255, 255, .12); }
|
|
188
|
+
.pc-pst.on .pc-pn { background: var(--cz-blue); color: var(--cz-ink); }
|
|
189
|
+
.pc-pst.done .pc-pn { background: var(--cz-okbg); color: var(--cz-ok); }
|
|
144
190
|
|
|
145
191
|
@media (max-width: 760px) {
|
|
146
|
-
.pc-
|
|
192
|
+
.pc-dbody { flex-direction: column; }
|
|
193
|
+
.pc-left, .pc-insp, .pc-side { width: 100%; max-height: none; }
|
|
194
|
+
.pc-pmain { flex-direction: column; }
|
|
195
|
+
.pc-pflow { width: 100%; }
|
|
147
196
|
.pc .pc-ib { width: 44px; height: 44px; }
|
|
148
197
|
.pc-dev.desktop { width: 100%; }
|
|
149
198
|
.pc-pframe.phone iframe { width: 100%; box-shadow: none; margin: 0; }
|