@creator-notes/cnotes 0.93.1 → 0.94.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/.claude-plugin/plugin.json +1 -1
- package/dist/commands/canvas.d.ts.map +1 -1
- package/dist/commands/canvas.js +207 -40
- package/dist/commands/canvas.js.map +1 -1
- package/dist/lib/canvas-layout.d.ts +15 -0
- package/dist/lib/canvas-layout.d.ts.map +1 -1
- package/dist/lib/canvas-layout.js +26 -0
- package/dist/lib/canvas-layout.js.map +1 -1
- package/dist/mcp-server.js +77 -36
- package/dist/mcp-server.js.map +1 -1
- package/package.json +1 -1
- package/skills/cnotes/SKILL.md +1 -1
- package/skills/cnotes/references/canvas-layout.md +33 -2
- package/skills/cnotes/references/canvas.md +21 -11
- package/skills/cnotes/references/operations.md +1 -1
|
@@ -74,17 +74,18 @@ cnotes canvas archive <canvasId>
|
|
|
74
74
|
cnotes canvas unarchive <canvasId>
|
|
75
75
|
|
|
76
76
|
# Add nodes. Which element to use: canvas-elements.md. To put several cards on a canvas,
|
|
77
|
-
# use `canvas place` (canvas-layout.md): it packs them overlap-free.
|
|
78
|
-
#
|
|
79
|
-
#
|
|
80
|
-
|
|
77
|
+
# use `canvas place` (canvas-layout.md): it packs them overlap-free. The single adds below
|
|
78
|
+
# go through the same solver when you omit --x/--y (clear of everything), and INTO a
|
|
79
|
+
# section with --section SECTION-<n> (the section arranges itself around the new card).
|
|
80
|
+
# --x/--y is the raw escape hatch: no collision check, it only warns after the fact.
|
|
81
|
+
cnotes canvas add-node <canvasId> --note <noteId> [--section SECTION-<n>] # NOTE nodes only
|
|
81
82
|
# text = free-form markdown on the canvas (wire type: richtext): headings, emphasis,
|
|
82
83
|
# images, and `[NOTE-12: Title](relationship:verb)` mentions, which render as chips.
|
|
83
84
|
# No background unless you pass --color. A heading is `--content '# Q1 Goals'`.
|
|
84
|
-
cnotes canvas add-text <canvasId> --content "<markdown>" [--size small|medium|large] [--color "<hex>"] [--
|
|
85
|
-
cnotes canvas add-text <canvasId> --content-file <path.md> [--size small|medium|large] [--color "<hex>"] [--
|
|
85
|
+
cnotes canvas add-text <canvasId> --content "<markdown>" [--size small|medium|large] [--color "<hex>"] [--section SECTION-<n>] # inline (short only)
|
|
86
|
+
cnotes canvas add-text <canvasId> --content-file <path.md> [--size small|medium|large] [--color "<hex>"] [--section SECTION-<n>]
|
|
86
87
|
cnotes canvas add-richtext ... # DEPRECATED alias of add-text (identical flags). Use add-text.
|
|
87
|
-
# THE BOX IS DERIVED, NOT CHOSEN.
|
|
88
|
+
# THE BOX IS DERIVED, NOT CHOSEN. If you pick x/y, the server still picks the size. WIDTH is the
|
|
88
89
|
# --size preset: small 560px, medium 1120px, large 1680px. HEIGHT follows the content,
|
|
89
90
|
# including after `canvas update-text` changes the copy. So both halves bite: columns
|
|
90
91
|
# pitched for a small card while the items are medium overlap by 460px each, and longer
|
|
@@ -99,17 +100,19 @@ cnotes canvas add-richtext ... # DEPRECATED alias of add-text (identical flags
|
|
|
99
100
|
# as "layout is fine" after a size bump or a content change.
|
|
100
101
|
# A list is a collection of member notes (--notes); --description is a one-line frame.
|
|
101
102
|
# N distinct things = N notes first, then --notes ID1,ID2,ID3 (canvas-elements.md).
|
|
102
|
-
cnotes canvas add-list <canvasId> --description "<markdown>" [--notes <id1,id2,...>] [--view list|grid] [--
|
|
103
|
-
cnotes canvas add-link <canvasId> --target <otherCanvasId> [--
|
|
103
|
+
cnotes canvas add-list <canvasId> --description "<markdown>" [--notes <id1,id2,...>] [--view list|grid] [--section SECTION-<n>]
|
|
104
|
+
cnotes canvas add-link <canvasId> --target <otherCanvasId> [--section SECTION-<n>]
|
|
104
105
|
# section = a NAMED REGION frame (Miro-style). Renders behind content; dragging the frame
|
|
105
106
|
# carries whatever sits inside it. Mints SECTION-<n>: mention [[SECTION-<n>]] from a note
|
|
106
107
|
# body to deep-link readers to that region. Name like a place ("Shaping", "Open Questions").
|
|
107
108
|
# Returns the displayId — surface it. Frames are NOT collision obstacles: content is placed
|
|
108
109
|
# INTO them (canvas get returns sectionNodes with bounds).
|
|
109
110
|
# PREFERRED: --notes creates the frame WITH those notes laid out inside it in one call
|
|
110
|
-
# (grid, frame sizes itself around them, collision-aware — no coordinate math).
|
|
111
|
+
# (grid, frame sizes itself around them, collision-aware — no coordinate math). Such a
|
|
112
|
+
# section is ARRANGED: it re-lays itself out as cards are added, edited or removed, until
|
|
113
|
+
# a card is moved by hand (canvas-layout.md, "Arranged sections").
|
|
111
114
|
cnotes canvas add-section <canvasId> --name "<title>" --notes <id1,id2,...> [--columns <n>] [--color "<hex>"]
|
|
112
|
-
cnotes canvas add-section <canvasId> --name "<title>" [--
|
|
115
|
+
cnotes canvas add-section <canvasId> --name "<title>" [--width <n>] [--height <n>] # empty frame, solver-placed
|
|
113
116
|
|
|
114
117
|
# Resize / rename / move / recolor an EXISTING frame, IN PLACE. Takes the SECTION-<n>
|
|
115
118
|
# display id. ALWAYS use this to grow a frame around new content — deleting and
|
|
@@ -131,6 +134,13 @@ cnotes canvas place <canvasId> --spec ./layout.json
|
|
|
131
134
|
cnotes canvas place <canvasId> --spec-stdin # JSON from stdin
|
|
132
135
|
cnotes canvas place <canvasId> --spec-inline '<short JSON>' # for tiny specs only
|
|
133
136
|
|
|
137
|
+
# Tidy a section: lay out what is already inside it, size the frame to fit, keep it arranged.
|
|
138
|
+
# The fix for a section whose cards overlap or spill past the frame (canvas status lists both).
|
|
139
|
+
cnotes canvas arrange <canvasId> --section SECTION-90
|
|
140
|
+
cnotes canvas arrange <canvasId> --section SECTION-90 --stop # back to freeform, nothing moves
|
|
141
|
+
# Put more cards into a section: appended to its layout, the frame re-arranges
|
|
142
|
+
cnotes canvas place <canvasId> --spec ./cards.json --into SECTION-90
|
|
143
|
+
|
|
134
144
|
# Reflow EXISTING nodes (mixed kinds) into a section — preferred over bulk-move + update-section
|
|
135
145
|
cnotes canvas arrange <canvasId> --section SECTION-90 \
|
|
136
146
|
--nodes '[{"nodeId":"<id>","nodeType":"canvas"},{"nodeId":"NOTE-3","nodeType":"note"}]' \
|
|
@@ -44,7 +44,7 @@ cnotes types show Insight # or pull from .typeRubrics in the begin response
|
|
|
44
44
|
|
|
45
45
|
# 2. Do the work. Every cnotes write here attaches to the run automatically.
|
|
46
46
|
cnotes notes create --notes '[ ... ]'
|
|
47
|
-
cnotes canvas add-text <canvasId> --content '# Q1'
|
|
47
|
+
cnotes canvas add-text <canvasId> --content '# Q1'
|
|
48
48
|
cnotes canvas place <canvasId> --spec /tmp/q1.json
|
|
49
49
|
cnotes canvas add-edge <canvasId> --source <a> --target <b> --label "depends on"
|
|
50
50
|
|