sketchframe 0.0.0-stage → 0.5.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/LICENSE +21 -0
- package/README.md +48 -2
- package/dist/sketchframe-mcp.cjs +1186 -0
- package/dist/sketchframe.cjs +1563 -0
- package/package.json +47 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Isaac Shea
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,49 @@
|
|
|
1
|
-
#
|
|
1
|
+
# sketchframe
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Read `.sketchframe` design files from the command line or an MCP server.
|
|
4
|
+
Sketchframes are exported from Sketch by the
|
|
5
|
+
[Sketchframe plugin](https://github.com/zaccomode/sketchframe): a rendered
|
|
6
|
+
preview of a frame plus its full design tree, for handing designs to AI
|
|
7
|
+
agents.
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npx sketchframe outline Checkout.sketchframe
|
|
11
|
+
npx sketchframe node Checkout.sketchframe Header/Title
|
|
12
|
+
npx sketchframe crop Checkout.sketchframe n12 -o title.png
|
|
13
|
+
npx sketchframe mcp # the MCP server, on stdio
|
|
14
|
+
npx sketchframe init # set a repository up for Claude Code
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
| Command | MCP tool | What it gives |
|
|
18
|
+
|---|---|---|
|
|
19
|
+
| `list [dir]` | `list_sketchframes` | The `.sketchframe` files under a directory |
|
|
20
|
+
| `outline <file> [node] [--depth N]` | `get_outline` | A compact tree of names, types, positions, sizes and ids |
|
|
21
|
+
| `node <file> <node> [--depth N]` | `get_node` | One layer's subtree with styles resolved, its tokens and annotations |
|
|
22
|
+
| `crop <file> [node] [-o out.png] [--padding N]` | `get_screenshot` | The preview, or one layer's region of it, as a PNG |
|
|
23
|
+
| `tokens <file>` | `get_tokens` | Color tokens, shared styles and reused style values |
|
|
24
|
+
| `annotations <file>` | `get_annotations` | Designers' notes, with their layers |
|
|
25
|
+
| `code <file> <node>` | `get_code` | An HTML/CSS starting point for a layer |
|
|
26
|
+
| `cat <file>` | | A stable text rendering, for `git diff` |
|
|
27
|
+
| `extract <file> <dir>`, `pack <dir> <file>` | | Convert between the archive and a folder |
|
|
28
|
+
| `init [dir]` | | Write `.mcp.json`, the Claude skill and `.gitattributes` |
|
|
29
|
+
| `skill` | | Print the Claude skill |
|
|
30
|
+
|
|
31
|
+
No dependencies, no native modules and no macOS tools: it runs anywhere
|
|
32
|
+
Node 18+ does, including Claude Code on the web.
|
|
33
|
+
|
|
34
|
+
See [docs/agents.md](https://github.com/zaccomode/sketchframe/blob/main/docs/agents.md)
|
|
35
|
+
for setting a repository up, and
|
|
36
|
+
[docs/FORMAT.md](https://github.com/zaccomode/sketchframe/blob/main/docs/FORMAT.md)
|
|
37
|
+
for the format.
|
|
38
|
+
|
|
39
|
+
## Development
|
|
40
|
+
|
|
41
|
+
```bash
|
|
42
|
+
npm install
|
|
43
|
+
npm run typecheck
|
|
44
|
+
npm test
|
|
45
|
+
npm run build # dist/sketchframe.cjs and dist/sketchframe-mcp.cjs
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
The format and the operations live in [`packages/core`](../core), which the
|
|
49
|
+
VS Code extension shares.
|