@muloka/figma-console-mcp 0.5.4 → 0.5.6
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/README.md +5 -4
- package/dist/apps/design-system-dashboard/mcp-app.html +26 -26
- package/dist/apps/token-browser/mcp-app.html +34 -34
- package/dist/core/http-request-guard.d.ts.map +1 -1
- package/dist/core/http-request-guard.js +12 -14
- package/dist/core/http-request-guard.js.map +1 -1
- package/dist/core/port-discovery.d.ts.map +1 -1
- package/dist/core/port-discovery.js +151 -52
- package/dist/core/port-discovery.js.map +1 -1
- package/dist/core/websocket-server.d.ts.map +1 -1
- package/dist/core/websocket-server.js +9 -1
- package/dist/core/websocket-server.js.map +1 -1
- package/dist/core/write-tools.d.ts +5 -1
- package/dist/core/write-tools.d.ts.map +1 -1
- package/dist/core/write-tools.js +113 -83
- package/dist/core/write-tools.js.map +1 -1
- package/dist/local.d.ts.map +1 -1
- package/dist/local.js +9 -2
- package/dist/local.js.map +1 -1
- package/figma-desktop-bridge/code.js +10 -2
- package/figma-desktop-bridge/ui.html +82 -8
- package/package.json +1 -1
- package/dist/cloudflare/apps/design-system-dashboard/scoring/accessibility.js +0 -277
- package/dist/cloudflare/apps/design-system-dashboard/scoring/component-metadata.js +0 -357
- package/dist/cloudflare/apps/design-system-dashboard/scoring/consistency.js +0 -341
- package/dist/cloudflare/apps/design-system-dashboard/scoring/coverage.js +0 -230
- package/dist/cloudflare/apps/design-system-dashboard/scoring/engine.js +0 -92
- package/dist/cloudflare/apps/design-system-dashboard/scoring/naming-semantics.js +0 -308
- package/dist/cloudflare/apps/design-system-dashboard/scoring/token-architecture.js +0 -349
- package/dist/cloudflare/apps/design-system-dashboard/scoring/types.js +0 -40
- package/dist/cloudflare/apps/design-system-dashboard/server.js +0 -159
- package/dist/cloudflare/apps/token-browser/server.js +0 -136
- package/dist/cloudflare/browser-manager.js +0 -157
- package/dist/cloudflare/core/accessibility-tools.js +0 -361
- package/dist/cloudflare/core/annotation-tools.js +0 -230
- package/dist/cloudflare/core/cloud-websocket-connector.js +0 -419
- package/dist/cloudflare/core/cloud-websocket-relay.js +0 -198
- package/dist/cloudflare/core/comment-tools.js +0 -292
- package/dist/cloudflare/core/config.js +0 -153
- package/dist/cloudflare/core/console-monitor.js +0 -427
- package/dist/cloudflare/core/deep-component-tools.js +0 -128
- package/dist/cloudflare/core/design-code-tools.js +0 -2793
- package/dist/cloudflare/core/design-system-manifest.js +0 -265
- package/dist/cloudflare/core/design-system-tools.js +0 -882
- package/dist/cloudflare/core/diagnose-tool.js +0 -100
- package/dist/cloudflare/core/diff/changelog-formatter.js +0 -275
- package/dist/cloudflare/core/diff/diff-engine.js +0 -334
- package/dist/cloudflare/core/diff/property-compare.js +0 -36
- package/dist/cloudflare/core/diff/version-cache.js +0 -74
- package/dist/cloudflare/core/enrichment/enrichment-service.js +0 -374
- package/dist/cloudflare/core/enrichment/index.js +0 -7
- package/dist/cloudflare/core/enrichment/relationship-mapper.js +0 -351
- package/dist/cloudflare/core/enrichment/style-resolver.js +0 -346
- package/dist/cloudflare/core/figjam-tools.js +0 -547
- package/dist/cloudflare/core/figma-api.js +0 -509
- package/dist/cloudflare/core/figma-connector.js +0 -7
- package/dist/cloudflare/core/figma-reconstruction-spec.js +0 -402
- package/dist/cloudflare/core/figma-style-extractor.js +0 -311
- package/dist/cloudflare/core/figma-tools.js +0 -3353
- package/dist/cloudflare/core/identity.js +0 -96
- package/dist/cloudflare/core/library-tools.js +0 -580
- package/dist/cloudflare/core/logger.js +0 -53
- package/dist/cloudflare/core/port-discovery.js +0 -935
- package/dist/cloudflare/core/resolve-package-root.js +0 -11
- package/dist/cloudflare/core/slides-tools.js +0 -714
- package/dist/cloudflare/core/slot-tools.js +0 -334
- package/dist/cloudflare/core/snippet-injector.js +0 -96
- package/dist/cloudflare/core/tokens/alias-resolver.js +0 -205
- package/dist/cloudflare/core/tokens/config.js +0 -294
- package/dist/cloudflare/core/tokens/dialect.js +0 -232
- package/dist/cloudflare/core/tokens/figma-converter.js +0 -323
- package/dist/cloudflare/core/tokens/formatters/css-vars.js +0 -338
- package/dist/cloudflare/core/tokens/formatters/dtcg.js +0 -376
- package/dist/cloudflare/core/tokens/formatters/index.js +0 -45
- package/dist/cloudflare/core/tokens/formatters/json.js +0 -205
- package/dist/cloudflare/core/tokens/formatters/less.js +0 -4
- package/dist/cloudflare/core/tokens/formatters/scss.js +0 -258
- package/dist/cloudflare/core/tokens/formatters/stubs.js +0 -13
- package/dist/cloudflare/core/tokens/formatters/style-dictionary-v3.js +0 -213
- package/dist/cloudflare/core/tokens/formatters/tailwind-v3.js +0 -237
- package/dist/cloudflare/core/tokens/formatters/tailwind-v4.js +0 -335
- package/dist/cloudflare/core/tokens/formatters/tokens-studio.js +0 -256
- package/dist/cloudflare/core/tokens/formatters/ts-module.js +0 -198
- package/dist/cloudflare/core/tokens/index.js +0 -16
- package/dist/cloudflare/core/tokens/parsers/css-vars.js +0 -4
- package/dist/cloudflare/core/tokens/parsers/dtcg.js +0 -280
- package/dist/cloudflare/core/tokens/parsers/index.js +0 -138
- package/dist/cloudflare/core/tokens/parsers/json.js +0 -7
- package/dist/cloudflare/core/tokens/parsers/scss.js +0 -4
- package/dist/cloudflare/core/tokens/parsers/stubs.js +0 -20
- package/dist/cloudflare/core/tokens/parsers/style-dictionary-v3.js +0 -4
- package/dist/cloudflare/core/tokens/parsers/tailwind-v3.js +0 -4
- package/dist/cloudflare/core/tokens/parsers/tailwind-v4.js +0 -4
- package/dist/cloudflare/core/tokens/parsers/tokens-studio.js +0 -4
- package/dist/cloudflare/core/tokens/schemas.js +0 -152
- package/dist/cloudflare/core/tokens/transforms/color.js +0 -12
- package/dist/cloudflare/core/tokens/transforms/index.js +0 -29
- package/dist/cloudflare/core/tokens/transforms/size.js +0 -7
- package/dist/cloudflare/core/tokens/types.js +0 -18
- package/dist/cloudflare/core/tokens-tools.js +0 -1788
- package/dist/cloudflare/core/types/design-code.js +0 -4
- package/dist/cloudflare/core/types/enriched.js +0 -5
- package/dist/cloudflare/core/types/index.js +0 -4
- package/dist/cloudflare/core/variable-resolver.js +0 -85
- package/dist/cloudflare/core/version-tools.js +0 -1199
- package/dist/cloudflare/core/websocket-connector.js +0 -436
- package/dist/cloudflare/core/websocket-server.js +0 -1009
- package/dist/cloudflare/core/write-tools.js +0 -2506
- package/dist/cloudflare/index.js +0 -3010
package/README.md
CHANGED
|
@@ -14,10 +14,11 @@
|
|
|
14
14
|
- **Mode-limit safety** — `figma_setup_design_tokens` and `figma_create_variable_collection` roll the collection back on a mode-limit failure instead of orphaning it, and the setup tool returns your file's real ceiling as `planModeLimit`; the schema's stale 4-mode cap is now a 40 sanity bound (current Figma plans allow 10/20/unlimited — the runtime limit governs)
|
|
15
15
|
- **No orphaned nodes on failure** — `figma_create_connector` validates endpoints before creating (a stale nodeId can no longer strand an endpoint-less connector), and create-child / add-text-to-slide / create-table remove their partially-created node on error; batch stickies report the id of any sticky a failed row left behind. `figma_create_child` also gains the POLYGON/STAR/VECTOR types the plugin always supported
|
|
16
16
|
- **Per-command dispatch budgets** — long-running bridge commands (variable refresh and component scans at 300s, lint/audit at 120s, large component sets) no longer get silently cut off at 30s: the server's real timeout rides in each WS frame and the dispatcher honors it, on both local and cloud transports ([upstream #94](https://github.com/southleft/figma-console-mcp/issues/94) lineage)
|
|
17
|
-
- **Streamable HTTP transport** in local mode — set `MCP_HTTP_PORT` to serve MCP at `http://localhost:<port>/mcp` and connect multiple local clients to one running instance ([upstream #48](https://github.com/southleft/figma-console-mcp/issues/48)). Loopback only: it binds `127.0.0.1`, and every request must
|
|
18
|
-
- **Per-call file targeting** —
|
|
19
|
-
- **Security ahead of the v1.36.0 base** — MCP SDK 1.32 (fixes, among others, a single oversized HTTP request exhausting server memory); `figma_scan_code_accessibility` never executes `<script>` tags or inline handlers from the HTML it scans (they previously ran inside the server's Node process)
|
|
20
|
-
- **`VariableID:` alias support** in `figma_batch_create_variables` and `figma_setup_design_tokens` ([upstream #52](https://github.com/southleft/figma-console-mcp/issues/52))
|
|
17
|
+
- **Streamable HTTP transport** in local mode — set `MCP_HTTP_PORT` to serve MCP at `http://localhost:<port>/mcp` and connect multiple local clients to one running instance ([upstream #48](https://github.com/southleft/figma-console-mcp/issues/48)). Loopback only: it binds `127.0.0.1`, and every request must match an exact loopback `Host` (`localhost:<port>`, `127.0.0.1:<port>`, or `[::1]:<port>`) and carry either no `Origin` (non-browser clients) or an `http:`/`https:` loopback one, so web pages can't reach it through DNS rebinding — anything else gets a 403. Per-request HTTP servers wrap tools for `_mcp` identity tagging and close cleanly on response close. The HTTP port is published as `mcpHttpPort` in the instance's port-discovery file, and stays there if the file is deleted and the heartbeat re-creates it. (Upstream added its own, separate HTTP endpoint in v1.44.0 under `FIGMA_MCP_HTTP_PORT`, advertised as `mcpHttpUrl`; this fork's `MCP_HTTP_PORT` / `mcpHttpPort` are unchanged.)
|
|
18
|
+
- **Per-call file targeting** — all 31 write tools (`figma_execute`, variable/collection/mode tools, node manipulation, component creation/instantiation, and design lint/audit tools) take an optional `fileKey`. With it, the call runs only in that file, whatever the active file or target lock, so several clients can work in different files at once without the active file shifting underneath them. If that file isn't connected the call is refused, naming the file and listing the connected ones, rather than landing in the active file. Without it, nothing changes. `figma_execute` results carry `fileContext` — `{ fileName, fileKey }` of the file the code actually ran in — and `resultAnalysis`, so a caller can verify the targeting from the response. Both arrive on success once the Desktop Bridge plugin has been re-imported from v0.5.4 or later (and `fileContext` arrives on syntax/runtime failures too after re-importing from the updated plugin); an earlier plugin drops them, so a missing `fileContext` means the targeting is unverified. Local mode only; the cloud relay refuses a `fileKey` ([details](docs/tools.md#targeting-a-file-filekey))
|
|
19
|
+
- **Security ahead of the v1.36.0 base** — MCP SDK 1.32 (fixes, among others, a single oversized HTTP request exhausting server memory); `figma_scan_code_accessibility` never executes `<script>` tags or inline handlers from the HTML it scans (they previously ran inside the server's Node process); `ui.html` activity-log HTML escapes quotes
|
|
20
|
+
- **`VariableID:` alias support & hex validation** in `figma_batch_create_variables`, `figma_batch_update_variables`, and `figma_setup_design_tokens` ([upstream #52](https://github.com/southleft/figma-console-mcp/issues/52)); invalid color strings throw instead of writing `NaN` channels, and `#RGB`/`#RGBA`/`#RRGGBB`/`#RRGGBBAA` are all supported
|
|
21
|
+
- **Daemon & bridge reliability** — ESM-safe startup orphan cleanup with 3-way PID verification (never kills or removes files for unrelated/inconclusive PIDs) and multi-candidate eviction; guarded WebSocket heartbeat pings; post-write variable cache invalidation; synchronous-throw handling and socket-identity tracking (with 10s connect timeout) in the Desktop Bridge UI; failure-path `data` forwarding so `CREATE_STICKIES` partial-failure orphan IDs reach callers
|
|
21
22
|
- **`page`/`pageSize` honored in `figma_get_variables` `format: "full"`** ([upstream #98](https://github.com/southleft/figma-console-mcp/issues/98))
|
|
22
23
|
- **Plugin + server build versions surfaced** in the Desktop Bridge UI and diagnostics
|
|
23
24
|
- **CI + plugin-asset guards** — Node 22/24 test matrix, a per-file typecheck ratchet, and regression tests that parse the plugin files and run Figma's own import-expression scanner against `code.js` so a comment can never again brick the plugin loader
|