@marver-design/marver 0.33.0 → 0.35.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/CHANGELOG.md +57 -0
- package/README.md +1 -1
- package/dist/{anchor-check-KCe6WeRA.mjs → anchor-check-DREwCQiE.mjs} +1 -1
- package/dist/{build-4-k2XhhX.mjs → build-3AH123fe.mjs} +3 -3
- package/dist/cli.mjs +5 -8
- package/dist/{comments-C2SN1QdM.mjs → comments-C7NjFGgl.mjs} +14 -7
- package/dist/{daemon-CCDgagw2.mjs → daemon-BE-t9iU-.mjs} +2 -4
- package/dist/{dev-CJf5upVK.mjs → dev-Dw6mcoP8.mjs} +7 -7
- package/dist/{notes-CRAX4wgk.mjs → notes-CmfQ9604.mjs} +13 -4
- package/dist/{pdf-GGya_nI6.mjs → pdf-CkE4Ir2P.mjs} +3 -3
- package/dist/{plugin-Cm74UDfp.mjs → plugin-C6jEpbCx.mjs} +43 -34
- package/dist/{poster-BnuT9UyW.mjs → poster-d10h73z0.mjs} +1 -1
- package/dist/{publish-bakes-zHmPEOB5.mjs → publish-bakes-weNQnNqE.mjs} +2 -2
- package/dist/{recover-BpRQxBA7.mjs → recover-Dekpav7b.mjs} +1 -1
- package/dist/{shot-HZtclbOT.mjs → shot-Ct2FiEbu.mjs} +2 -2
- package/docs/boards-and-folders.md +1 -1
- package/docs/performance.md +4 -0
- package/docs/slides.md +8 -0
- package/package.json +1 -1
- package/src/client/const.ts +5 -0
- package/src/client/content/img-lod.ts +3 -1
- package/src/client/frame-host/inplace.ts +43 -0
- package/src/client/frame-host/main.tsx +10 -1
- package/src/client/shell/App.tsx +26 -18
- package/src/client/shell/LockedApp.tsx +6 -5
- package/src/client/shell/canvas/Canvas.tsx +50 -16
- package/src/client/shell/canvas/FrameNode.tsx +40 -7
- package/src/client/shell/canvas/admission.ts +138 -5
- package/src/client/shell/canvas/sleep.ts +258 -26
- package/src/client/shell/hash.ts +24 -0
- package/src/client/shell/jam-capture.ts +3 -2
- package/src/client/shell/notes.ts +11 -4
- package/src/client/shell/recorder.ts +1 -1
- package/src/client/shell/store.ts +63 -11
- package/templates/AGENTS-embedded.md +3 -3
- package/templates/AGENTS-studio.md +3 -3
- package/templates/instructions/iterate.md +1 -1
- package/templates/instructions/reference/deck-replicate.md +44 -0
- package/templates/instructions/slides.md +8 -0
|
@@ -69,14 +69,18 @@ export const clearNoteHeights = (): void => { noteHeights.clear() }
|
|
|
69
69
|
* the frames make way. An obstacle is another node's card, or its own note column (two columns
|
|
70
70
|
* running into each other cramp too) - the two rectangles, never their bounding box: the empty
|
|
71
71
|
* canvas under a card beside a long column is free. Missing nodes (a deleted frame's card, still
|
|
72
|
-
* drawn full size) block room but never host a note. `noteH` is the measured column extent
|
|
72
|
+
* drawn full size) block room but never host a note. `noteH` is the measured column extent - a pure lookup: it is
|
|
73
|
+
* asked once per node, when its room is first needed. */
|
|
73
74
|
export function notesCramped(
|
|
74
75
|
nodes: readonly { key: string; frame: string; x: number; y: number; w: number; h: number; missing?: boolean }[],
|
|
75
76
|
manifest: { frames: { id: string; scene: string; note?: string }[]; scenes: { name: string; note?: string }[] } | null,
|
|
76
77
|
noteH: (key: string) => number = noteHeight,
|
|
77
78
|
): boolean {
|
|
78
79
|
if (!manifest) return false
|
|
79
|
-
|
|
80
|
+
// asked at each note a board measures: an index of the manifest (the first entry of an id, as a find gives), not a scan per node
|
|
81
|
+
const byId = new Map<string, (typeof manifest.frames)[number]>()
|
|
82
|
+
for (const f of manifest.frames) if (!byId.has(f.id)) byId.set(f.id, f)
|
|
83
|
+
const entry = (id: string) => byId.get(id)
|
|
80
84
|
const live = nodes.filter((n) => !n.missing)
|
|
81
85
|
const hosts = new Set<string>()
|
|
82
86
|
for (const s of manifest.scenes) {
|
|
@@ -93,12 +97,15 @@ export function notesCramped(
|
|
|
93
97
|
const r = n.missing ? 0 : noteReserve(!!entry(n.frame)?.note, hosts.has(n.key))
|
|
94
98
|
return r ? { x0: n.x - r, x1: n.x, y0: n.y, y1: n.y + Math.max(n.h + NODE_HEADER, noteH(n.key)) } : null
|
|
95
99
|
}
|
|
100
|
+
// each node's room once, when first asked (not once per pair) - so noteH is asked once per node, at most
|
|
101
|
+
const rooms = new Map<N, R | null>()
|
|
102
|
+
const roomOf = (n: N): R | null => { let r = rooms.get(n); if (r === undefined) rooms.set(n, r = room(n)); return r }
|
|
96
103
|
return live.some((n) => {
|
|
97
|
-
const mine =
|
|
104
|
+
const mine = roomOf(n)
|
|
98
105
|
if (!mine) return false
|
|
99
106
|
return nodes.some((o) => {
|
|
100
107
|
if (o === n) return false
|
|
101
|
-
const theirs =
|
|
108
|
+
const theirs = roomOf(o)
|
|
102
109
|
return hit(mine, card(o)) || (!!theirs && hit(mine, theirs))
|
|
103
110
|
})
|
|
104
111
|
})
|
|
@@ -72,7 +72,7 @@ const lapsed = new Map<string, Load>()
|
|
|
72
72
|
let owner: Load | null = null
|
|
73
73
|
/** node key -> what its live document said (page-level: a reload of the same board keeps its documents) */
|
|
74
74
|
const tracks = new Map<string, Track>()
|
|
75
|
-
/** each node's geometry as last seen - numbers, not the node objects (
|
|
75
|
+
/** each node's geometry as last seen - numbers, not the node objects (a move is told by its numbers, whichever objects hold them) */
|
|
76
76
|
let baseline = new Map<string, { x: number; y: number; w: number; h: number }>()
|
|
77
77
|
const outbox = new Outbox()
|
|
78
78
|
/** a drag's or a resize's move record per node while it waits to be sent: the next pointermove adds to it */
|
|
@@ -588,6 +588,19 @@ export function settleRule(n: Node, manifest: Manifest | null): 'measure' | 'rea
|
|
|
588
588
|
if (!f) return 'missing'
|
|
589
589
|
return f.contentWidth && n.sizeMode !== 'device' && measures(f.id) ? 'measure' : 'ready'
|
|
590
590
|
}
|
|
591
|
+
/** The manifest's entry for a frame id - the first of that id, as a find gives - from an index built once per frames
|
|
592
|
+
* array (a manifest's arrays are replaced, never edited): every node's selectors look their frame up on each store
|
|
593
|
+
* update, and a canvas's manifest can hold thousands. */
|
|
594
|
+
const frameIndex = new WeakMap<FrameEntry[], Map<string, FrameEntry>>()
|
|
595
|
+
export function frameById(frames: FrameEntry[], id: string): FrameEntry | undefined {
|
|
596
|
+
let byId = frameIndex.get(frames)
|
|
597
|
+
if (!byId) {
|
|
598
|
+
byId = new Map()
|
|
599
|
+
for (const f of frames) if (!byId.has(f.id)) byId.set(f.id, f)
|
|
600
|
+
frameIndex.set(frames, byId)
|
|
601
|
+
}
|
|
602
|
+
return byId.get(id)
|
|
603
|
+
}
|
|
591
604
|
/** Did a measuring node open at a height already known (committed in _sizes.json, or measured earlier in this page)? */
|
|
592
605
|
export const knownHeight = (frameId: string, w: number): boolean => hasKnownHeight(frameId, Math.round(w))
|
|
593
606
|
/** What measureNode took: `fit` - the report was taken at the node's width `w` (applied, or its height already) - the
|
|
@@ -800,7 +813,33 @@ export const DISK_WON = 'board changed on disk - canvas layout reloaded'
|
|
|
800
813
|
/** What a board save says when the board was renamed or removed meanwhile: it is not created again. */
|
|
801
814
|
export const BOARD_GONE = 'this board was renamed or removed - not recreating it'
|
|
802
815
|
|
|
803
|
-
export const useStore = create<State>((
|
|
816
|
+
export const useStore = create<State>((rawSet, rawGet, storeApi) => {
|
|
817
|
+
// sh:theme-applied acks, batched: one store update for a switch's burst (112 acks were 0.8 s of the shell
|
|
818
|
+
// re-rendering, one update each). They are applied BEFORE the store's own actions read (get) or write (set), and
|
|
819
|
+
// before any setState from outside, so every state an action or a FUNCTIONAL setState acts on, carries or discards
|
|
820
|
+
// is the one acks written as they came would have made: only a run of acks with nothing else between them becomes
|
|
821
|
+
// one update. React reads through the store's own getState, unflushed: what the batch defers is that one re-render.
|
|
822
|
+
// The one way to break it: a writer outside the store that reads getState(), builds an OBJECT from it and writes it
|
|
823
|
+
// back (`setState({ nodes: getState().nodes.map(...) })`) overwrites a just-applied ack with its stale copy - write
|
|
824
|
+
// nodes from outside with the functional form (`setState((s) => ({ nodes: ... }))`); DEV says so once. Otherwise
|
|
825
|
+
// the acks land at the next animation frame (100 ms on a hidden page), by whichever timer comes first.
|
|
826
|
+
const acks: { pending: Map<string, string>; frame?: number; timer?: ReturnType<typeof setTimeout> } = { pending: new Map() }
|
|
827
|
+
const applyAcks = () => {
|
|
828
|
+
if (acks.frame !== undefined && typeof cancelAnimationFrame === 'function') cancelAnimationFrame(acks.frame)
|
|
829
|
+
clearTimeout(acks.timer)
|
|
830
|
+
acks.frame = acks.timer = undefined
|
|
831
|
+
if (!acks.pending.size) return
|
|
832
|
+
const mine = acks.pending
|
|
833
|
+
acks.pending = new Map()
|
|
834
|
+
rawSet((s) => ({ nodes: s.nodes.map((n) => { const t = mine.get(n.key); return t === undefined || t === n.themeOn ? n : { ...n, themeOn: t } }) }))
|
|
835
|
+
}
|
|
836
|
+
const set = ((partial: Parameters<typeof rawSet>[0], replace?: boolean) => { applyAcks(); rawSet(partial as never, replace as never) }) as typeof rawSet
|
|
837
|
+
const get: typeof rawGet = () => { applyAcks(); return rawGet() }
|
|
838
|
+
let warned = false
|
|
839
|
+
storeApi.setState = ((partial: Parameters<typeof rawSet>[0], replace?: boolean) => {
|
|
840
|
+
if (import.meta.env.DEV && !warned && acks.pending.size && partial && typeof partial === 'object' && 'nodes' in partial) { warned = true; console.error('[marver] setState({ nodes }) from outside while theme acks are pending: write nodes with the functional form, setState((s) => ({ nodes: ... })) - an object built from getState() overwrites them (store.ts)') }
|
|
841
|
+
set(partial as never, replace as never)
|
|
842
|
+
}) as typeof rawSet
|
|
804
843
|
let saveTimer: ReturnType<typeof setTimeout> | undefined
|
|
805
844
|
let saveChain: Promise<boolean> = Promise.resolve(true) // saves are serialized; responses only commit if the board is still active
|
|
806
845
|
let editRev = 0 // bumps per edit; a stale save response may never clear dirty over a newer edit
|
|
@@ -1471,9 +1510,15 @@ export const useStore = create<State>((set, get) => {
|
|
|
1471
1510
|
}
|
|
1472
1511
|
const live = new Set(m.frames.map((f) => f.id))
|
|
1473
1512
|
let retinted = false
|
|
1474
|
-
for (
|
|
1513
|
+
for (let i = 0; i < next.length; i++) {
|
|
1514
|
+
// a node the state on screen holds is never written: the one this pass changes is a copy (a subscriber told
|
|
1515
|
+
// before the set below - the pruning toast's - must read the state it was given, and a memo keyed by the
|
|
1516
|
+
// nodes array must hold: same array, same nodes)
|
|
1517
|
+
let n = next[i]
|
|
1518
|
+
const edit = (): Node => (i < nodes.length && n === nodes[i] ? (n = next[i] = { ...n }) : n)
|
|
1475
1519
|
const missing = !live.has(n.frame)
|
|
1476
1520
|
if (missing !== !!n.missing) {
|
|
1521
|
+
edit()
|
|
1477
1522
|
// a node whose frame just ARRIVED (the create-first choreography: the agent
|
|
1478
1523
|
// appends the board node before the manifest registers the file) was sized by
|
|
1479
1524
|
// the 390x844 GUESS - its real viewport is only knowable now. ONLY guessed
|
|
@@ -1496,16 +1541,16 @@ export const useStore = create<State>((set, get) => {
|
|
|
1496
1541
|
// (derived value: re-render yes, dirty/save no)
|
|
1497
1542
|
const f = m.frames.find((x) => x.id === n.frame)
|
|
1498
1543
|
const want = n.themeUser ?? f?.theme ?? get().viewTheme
|
|
1499
|
-
if (n.theme !== want) {
|
|
1544
|
+
if (n.theme !== want) { edit().theme = want; retinted = true }
|
|
1500
1545
|
// content-ness can change live (agent adds/removes the primitives): reconcile
|
|
1501
1546
|
// provenance or measurements are rejected / UI dims silently omitted from saves.
|
|
1502
1547
|
// Under an active device view the newcomer joins it as 'device' - a measurement
|
|
1503
1548
|
// must not override the preset the whole board is showing
|
|
1504
|
-
if (f?.contentWidth && !n.sizeMode) {
|
|
1505
|
-
if (!f?.contentWidth && n.sizeMode) { delete
|
|
1549
|
+
if (f?.contentWidth && !n.sizeMode) { edit().sizeMode = deviceView ? 'device' : 'auto'; retinted = true }
|
|
1550
|
+
if (!f?.contentWidth && n.sizeMode) { delete edit().sizeMode; retinted = true }
|
|
1506
1551
|
// an errored frame whose file IS in the fresh manifest gets one automatic retry
|
|
1507
1552
|
// on a rev-stamped URL - the "unknown frame id" dead end must self-heal (#20)
|
|
1508
|
-
if (!missing && n.status === 'error') { n.status = 'loading'; n.nav = (n.nav ?? 0) + 1; n.readyRetried = false; retinted = true }
|
|
1553
|
+
if (!missing && n.status === 'error') { edit(); n.status = 'loading'; n.nav = (n.nav ?? 0) + 1; n.readyRetried = false; retinted = true }
|
|
1509
1554
|
}
|
|
1510
1555
|
// auto boards prune deleted frames outright - "auto-managed" must manage both
|
|
1511
1556
|
// directions (friction log #15). Curated boards keep the explicit card.
|
|
@@ -1518,7 +1563,7 @@ export const useStore = create<State>((set, get) => {
|
|
|
1518
1563
|
toast(dropped === 1 ? 'removed 1 deleted frame' : `removed ${dropped} deleted frames`)
|
|
1519
1564
|
}
|
|
1520
1565
|
}
|
|
1521
|
-
// a guessed size corrected above
|
|
1566
|
+
// a guessed size corrected above is a move, seen when this set notifies the recorder
|
|
1522
1567
|
withCause('manifest', () => set((s) => ({
|
|
1523
1568
|
manifest: m,
|
|
1524
1569
|
nodes: changed || retinted ? [...final] : final,
|
|
@@ -1541,7 +1586,9 @@ export const useStore = create<State>((set, get) => {
|
|
|
1541
1586
|
scheduleSave()
|
|
1542
1587
|
},
|
|
1543
1588
|
|
|
1544
|
-
|
|
1589
|
+
// read from selectors (FrameNode, Comments) while React renders: the raw state - acks touch no manifest, and a
|
|
1590
|
+
// flush there would write the store mid-render
|
|
1591
|
+
frameFor(node) { const m = rawGet().manifest; return m ? frameById(m.frames, node.frame) : undefined },
|
|
1545
1592
|
|
|
1546
1593
|
moveNode(key, x, y) {
|
|
1547
1594
|
withCause('drag', () => set((s) => ({ nodes: s.nodes.map((n) => (n.key === key ? { ...n, x, y } : n)), dirty: true })))
|
|
@@ -1697,7 +1744,12 @@ export const useStore = create<State>((set, get) => {
|
|
|
1697
1744
|
else { scheduleSave(); roomForNotes(); recheckLayout() } // ...unless a note grew meanwhile, or a Doc changed size, under the restored rows
|
|
1698
1745
|
}) },
|
|
1699
1746
|
bumpRev(key) { set((s) => ({ nodes: s.nodes.map((n) => (n.key === key ? { ...n, rev: (n.rev ?? 0) + 1 } : n)) })) },
|
|
1700
|
-
setThemeOn(key, theme) {
|
|
1747
|
+
setThemeOn(key, theme) {
|
|
1748
|
+
acks.pending.set(key, theme) // the last of a key wins, as when each landed at once
|
|
1749
|
+
if (acks.frame !== undefined || acks.timer !== undefined) return
|
|
1750
|
+
if (typeof requestAnimationFrame === 'function') acks.frame = requestAnimationFrame(applyAcks)
|
|
1751
|
+
acks.timer = setTimeout(applyAcks, 100) // a hidden page draws no frames
|
|
1752
|
+
},
|
|
1701
1753
|
setStatus(key, status, error) {
|
|
1702
1754
|
// any real ready/error resets the one-shot retry allowance, so a later manual reload or a
|
|
1703
1755
|
// fresh manifest earns its own auto-retry again
|
|
@@ -1931,8 +1983,8 @@ export const useStore = create<State>((set, get) => {
|
|
|
1931
1983
|
set((s) => ({
|
|
1932
1984
|
viewTheme: theme,
|
|
1933
1985
|
nodes: s.nodes.map((n) => {
|
|
1934
|
-
const
|
|
1935
|
-
return { ...n, themeUser: undefined, theme:
|
|
1986
|
+
const t = (s.manifest ? frameById(s.manifest.frames, n.frame)?.theme : undefined) ?? theme
|
|
1987
|
+
return n.theme === t && n.themeUser === undefined ? n : { ...n, themeUser: undefined, theme: t } // by the index, not a scan per node
|
|
1936
1988
|
}),
|
|
1937
1989
|
dirty: true,
|
|
1938
1990
|
}))
|
|
@@ -44,7 +44,7 @@ file in design/instructions/ - they are short, strict, and part of this contract
|
|
|
44
44
|
| Review | before presenting anything | instructions/review.md |
|
|
45
45
|
| Boards | creating a board, choosing what ships | instructions/boards.md |
|
|
46
46
|
| Context | any question about what the product does or what is live; a behaviour change; a deploy; no `context/` yet | instructions/context.md |
|
|
47
|
-
| Slides | a deck is asked for; a PDF of a deck or of any board, a flow too (`npx marver pdf <board>`, then give back the path it prints); or `slide: true` frames exist | instructions/slides.md + design/slides.md |
|
|
47
|
+
| Slides | a deck is asked for; a PDF of a deck or of any board, a flow too (`npx marver pdf <board>`, then give back the path it prints); the deck replicated in another presentation tool (Google Slides, PowerPoint, Keynote, Canva...: native elements, never pictures of slides); or `slide: true` frames exist | instructions/slides.md + design/slides.md |
|
|
48
48
|
| Publish | deploying the canvas: gate, volume, accounts, invites | instructions/publish.md |
|
|
49
49
|
| Live Jam | responding to an `@marver` comment (a spawned job), or a "Live Jam: ... new request" message (below) - run `npx marver jam next`; on by default - confirm it names YOUR tool | instructions/jam.md |
|
|
50
50
|
|
|
@@ -311,10 +311,10 @@ The human reviews on the canvas, not in the chat - so the reply puts them there:
|
|
|
311
311
|
badges are noisy, ask - with the count per board it prints ("38 open: launch-plan 22,
|
|
312
312
|
checkout-compare 16 - resolve them?"). A frame on two boards counts on both. Only on a yes, and only for what
|
|
313
313
|
they said yes to: one board is `npx marver comments resolve --all --board <b>`, a folder
|
|
314
|
-
`--folder <f>`, a scene `--scene <s>`, everything `--canvas` (the only scope that also takes
|
|
314
|
+
`--folder <f>`, a scene `--scene <s>`, one frame `--frame <scene/frame>`, everything `--canvas` (the only scope that also takes
|
|
315
315
|
threads with no frame or on a frame that is gone; `--scene` takes its frames whether or not a board shows them). `--dry-run` counts first. Give them the `--undo` line it
|
|
316
316
|
prints. It never touches what Jam is working on, and the human has the same in every board,
|
|
317
|
-
folder and scene menu ("Resolve all comments") and on the Mac app's tab. Never on your own.
|
|
317
|
+
folder and scene menu ("Resolve all comments"), on a frame's row ("Resolve comments") and on the Mac app's tab. Never on your own.
|
|
318
318
|
- **Undo a resolve-all later.** The canvas's Undo notice lasts 10 seconds. After that, each run
|
|
319
319
|
is kept as `design/.local/comment-ops/<op>.json` (its `scope` and `at` say which; skip the
|
|
320
320
|
`.undo.json` files): `npx marver comments resolve --undo <op>` reopens each thread nothing
|
|
@@ -44,7 +44,7 @@ file in design/instructions/ - they are short, strict, and part of this contract
|
|
|
44
44
|
| Review | before presenting anything | instructions/review.md |
|
|
45
45
|
| Boards | creating a board, choosing what ships | instructions/boards.md |
|
|
46
46
|
| Context | any question about what the product does or what is live; a behaviour change; a deploy; no `context/` yet | instructions/context.md |
|
|
47
|
-
| Slides | a deck is asked for; a PDF of a deck or of any board, a flow too (`npx marver pdf <board>`, then give back the path it prints); or `slide: true` frames exist | instructions/slides.md + design/slides.md |
|
|
47
|
+
| Slides | a deck is asked for; a PDF of a deck or of any board, a flow too (`npx marver pdf <board>`, then give back the path it prints); the deck replicated in another presentation tool (Google Slides, PowerPoint, Keynote, Canva...: native elements, never pictures of slides); or `slide: true` frames exist | instructions/slides.md + design/slides.md |
|
|
48
48
|
| Publish | deploying the canvas: gate, volume, accounts, invites | instructions/publish.md |
|
|
49
49
|
| Live Jam | responding to an `@marver` comment (a spawned job), or a "Live Jam: ... new request" message (below) - run `npx marver jam next`; on by default - confirm it names YOUR tool | instructions/jam.md |
|
|
50
50
|
|
|
@@ -310,10 +310,10 @@ The human reviews on the canvas, not in the chat - so the reply puts them there:
|
|
|
310
310
|
badges are noisy, ask - with the count per board it prints ("38 open: launch-plan 22,
|
|
311
311
|
checkout-compare 16 - resolve them?"). A frame on two boards counts on both. Only on a yes, and only for what
|
|
312
312
|
they said yes to: one board is `npx marver comments resolve --all --board <b>`, a folder
|
|
313
|
-
`--folder <f>`, a scene `--scene <s>`, everything `--canvas` (the only scope that also takes
|
|
313
|
+
`--folder <f>`, a scene `--scene <s>`, one frame `--frame <scene/frame>`, everything `--canvas` (the only scope that also takes
|
|
314
314
|
threads with no frame or on a frame that is gone; `--scene` takes its frames whether or not a board shows them). `--dry-run` counts first. Give them the `--undo` line it
|
|
315
315
|
prints. It never touches what Jam is working on, and the human has the same in every board,
|
|
316
|
-
folder and scene menu ("Resolve all comments") and on the Mac app's tab. Never on your own.
|
|
316
|
+
folder and scene menu ("Resolve all comments"), on a frame's row ("Resolve comments") and on the Mac app's tab. Never on your own.
|
|
317
317
|
- **Undo a resolve-all later.** The canvas's Undo notice lasts 10 seconds. After that, each run
|
|
318
318
|
is kept as `design/.local/comment-ops/<op>.json` (its `scope` and `at` say which; skip the
|
|
319
319
|
`.undo.json` files): `npx marver comments resolve --undo <op>` reopens each thread nothing
|
|
@@ -199,7 +199,7 @@ The discipline:
|
|
|
199
199
|
Many open at once is the human's to clear, never yours: past ten open
|
|
200
200
|
(`npx marver marks` counts them per board), ask - and only on a yes run
|
|
201
201
|
`npx marver comments resolve --all --board <b>` (`--folder`, `--scene`,
|
|
202
|
-
`--canvas`; `--dry-run` counts first; it prints its `--undo`). It skips
|
|
202
|
+
`--frame`, `--canvas`; `--dry-run` counts first; it prints its `--undo`). It skips
|
|
203
203
|
every thread Jam is working on.
|
|
204
204
|
6. **A frame with open comments is load-bearing - never delete, rename, or
|
|
205
205
|
gut it.** Its threads are anchored to elements INSIDE it; restructure the
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Replicating a deck in a third-party tool
|
|
2
|
+
|
|
3
|
+
Run this when the human wants a Marver deck rebuilt in another presentation
|
|
4
|
+
tool, so other people can edit it and work on it together. It works in any
|
|
5
|
+
tool your session can drive through a good MCP or API: Google Slides,
|
|
6
|
+
PowerPoint (or a `.pptx` file you write), Keynote, Canva, and the like. Use
|
|
7
|
+
the human's own access, and say what you will create, and where, before you
|
|
8
|
+
create it. A PDF is not this (slides.md, "A deck as a PDF").
|
|
9
|
+
|
|
10
|
+
## The rule: native and atomic
|
|
11
|
+
|
|
12
|
+
Rebuild every slide from the tool's own components, one element at a time:
|
|
13
|
+
every text a text box, every shape a shape, every line a line (a divider or
|
|
14
|
+
rule too, even one the slide draws as a thin box), every table a table, every chart a chart (or the shapes and text that draw it), every
|
|
15
|
+
image an image. Never paste a picture of a slide, or of any part of one that
|
|
16
|
+
holds text, shapes or lines. A picture is only for what was a picture on the
|
|
17
|
+
slide already: a photo, an illustration. The test is simple: a colleague
|
|
18
|
+
clicks any word or shape and changes it.
|
|
19
|
+
|
|
20
|
+
Keep it one to one: the same positions, sizes, fonts, colours, line breaks
|
|
21
|
+
and stacking as the slide. Read them off the rendered slide (open it alone at
|
|
22
|
+
its stage size, `/__mv/frame/?id=<scene/frame>`, and measure), not from the
|
|
23
|
+
code. Scale every length to the tool's page, font sizes included. Group what
|
|
24
|
+
moves together, such as a card and its label. Copy each slide's speaker notes.
|
|
25
|
+
|
|
26
|
+
## The trap: text centred vertically
|
|
27
|
+
|
|
28
|
+
What you measure in the browser and what the tool draws place text
|
|
29
|
+
differently: the browser sets glyphs inside the line height, a slide tool
|
|
30
|
+
from the top of its box, after an inner padding you often cannot see. Text
|
|
31
|
+
lands too high or too low, and the layout no longer lines up.
|
|
32
|
+
|
|
33
|
+
So **anchor every text box to the middle**, put the box's centre on the
|
|
34
|
+
centre of the text you measured, and make the box a little taller than the
|
|
35
|
+
text. The text then sits where the slide had it, whatever the tool's padding
|
|
36
|
+
and font metrics. Keep the slide's line breaks and turn autofit off.
|
|
37
|
+
|
|
38
|
+
## Check it, then say what differs
|
|
39
|
+
|
|
40
|
+
Render each rebuilt slide in the tool and compare it with
|
|
41
|
+
`npx marver shot <scene/frame>`. Fix what moved. Then tell the human where
|
|
42
|
+
the deck is and anything that is not native or not exact: a picture you
|
|
43
|
+
kept and why, a font their readers must install, an effect the tool cannot
|
|
44
|
+
draw.
|
|
@@ -16,6 +16,7 @@ mechanics of how a slide plays. Take what serves the deck in front of you.
|
|
|
16
16
|
|---|---|
|
|
17
17
|
| reference/deck-story.md | intake is thin or rich, the room is senior, the slide list reads like a table of contents, or the words need work |
|
|
18
18
|
| reference/deck-layouts.md | a slide needs a composition and none comes - an idea bank, plus rebuilding an existing deck and chart craft |
|
|
19
|
+
| reference/deck-replicate.md | the deck is replicated in another presentation tool (Google Slides, PowerPoint, Keynote, Canva...) for others to edit |
|
|
19
20
|
| craft.md + its references | a slide's type, colour, layout or motion feels off - reference/typography.md, color.md, motion.md and slop.md hold for slides as for screens |
|
|
20
21
|
|
|
21
22
|
## What a slide is
|
|
@@ -349,6 +350,13 @@ size and time; each line under it names slides that need a look:
|
|
|
349
350
|
The PDF is the finished slide, as at rest: another reason every slide must
|
|
350
351
|
show its final composition without `data-sl-play` (Motion, above).
|
|
351
352
|
|
|
353
|
+
## A deck in another presentation tool
|
|
354
|
+
|
|
355
|
+
When the human wants the deck in Google Slides, PowerPoint, Keynote, Canva
|
|
356
|
+
or another tool with a good MCP or API, so others can edit it, rebuild it
|
|
357
|
+
there from native, atomic elements - never pictures of slides. Read
|
|
358
|
+
reference/deck-replicate.md before the first slide.
|
|
359
|
+
|
|
352
360
|
## design/slides.md - this project's deck look
|
|
353
361
|
|
|
354
362
|
The project's own file: the deck look (master, tones, type, mark, imagery,
|