drafted 1.17.14 → 1.17.16
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/mcp/server.mjs +7 -2
- package/package.json +1 -1
package/mcp/server.mjs
CHANGED
|
@@ -2328,7 +2328,7 @@ tool('comment', {
|
|
|
2328
2328
|
action: z.enum(['list', 'add', 'resolve', 'reopen', 'delete']).describe('list: read comments (paginated). add: post a comment or a reply. resolve/reopen: flip a comment\'s state. delete: remove one.'),
|
|
2329
2329
|
target: z.string().optional().describe('[list, add] The frame: a path (/projects/<project>/<layer>/<lane>/<file>), a frame URL, or a frame UUID. Required for add. For list, omit it to read the whole project.'),
|
|
2330
2330
|
projectId: z.string().optional().describe('[list] Project to read when no target is given — UUID, slug, or /projects/<name>. Defaults to the session\'s bound project.'),
|
|
2331
|
-
body: z.string().optional().describe('[add] The comment text. Be specific and actionable: quote what you mean and say what should change. Prefix with [MUST] / [NICE] / [Q] so a reviewer can triage.'),
|
|
2331
|
+
body: z.string().optional().describe('[add] The comment text. Be specific and actionable: quote what you mean and say what should change. Prefix with [MUST] / [NICE] / [Q] so a reviewer can triage. To notify a person, put their EMAIL ADDRESS after an @ — "@sam@acme.com". A bare "@sam" only works when exactly one person on the frame has that local-part; when two do, it is ignored rather than guessed at.'),
|
|
2332
2332
|
replyTo: z.string().optional().describe('[add] Comment UUID this replies to. A reply cannot carry its own anchor — it inherits the thread\'s.'),
|
|
2333
2333
|
anchorRef: z.string().optional().describe('[add] CSS selector for the element this comment is about, e.g. "h1" or ".email-body > p:nth-of-type(3)". The frame must load /vendor/frame-guide.js (markdown and HTML content frames get it automatically). Without it the comment lands on the whole frame.'),
|
|
2334
2334
|
anchorText: z.string().optional().describe('[add] The text of the anchored element, stored as a snapshot. Supply it whenever you pass anchorRef: a selector is an nth-of-type path that breaks when the frame is re-authored, and this snapshot is the only way to re-find what you meant.'),
|
|
@@ -2812,7 +2812,12 @@ tool('fs', 'Navigate Drafted like a local filesystem. An org is the top folder:
|
|
|
2812
2812
|
// OKF boundary rule: /a/b.md ≡ a/b — strip a trailing .md so both spellings work.
|
|
2813
2813
|
const canonPath = wikiPath.replace(/\.md$/, '');
|
|
2814
2814
|
const existing = await api('GET', `/api/wiki/page?path=${encodeURIComponent(canonPath)}`, undefined, orgHeader).catch(() => null);
|
|
2815
|
-
|
|
2815
|
+
// Send ONLY { path, content }. An explicit `type`/`title` outranks the
|
|
2816
|
+
// content preamble server-side (PATCH semantics), so defaulting them
|
|
2817
|
+
// here silently forced every MCP-created page to type "Page" and a
|
|
2818
|
+
// path-segment title, discarding the author's frontmatter. The server
|
|
2819
|
+
// lifts both from the preamble and falls back to the path segment.
|
|
2820
|
+
const body = { path: canonPath, content };
|
|
2816
2821
|
const result = existing
|
|
2817
2822
|
? await api('PUT', `/api/wiki/page?path=${encodeURIComponent(canonPath)}`, { content }, orgHeader)
|
|
2818
2823
|
: await api('POST', '/api/wiki/pages', body, orgHeader);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "drafted",
|
|
3
|
-
"version": "1.17.
|
|
3
|
+
"version": "1.17.16",
|
|
4
4
|
"description": "Drafted — visual thinking surface for humans and AI agents. Renders HTML, markdown, images, and code as frames on a zoomable canvas, with MCP tools for AI agents and real-time sync for humans.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|