canicode 0.7.1 → 0.8.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/README.md +2 -0
- package/dist/cli/index.js +16 -2
- package/dist/cli/index.js.map +1 -1
- package/dist/index.d.ts +15 -2
- package/dist/index.js +255 -2
- package/dist/index.js.map +1 -1
- package/dist/mcp/server.js +264 -3
- package/dist/mcp/server.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -78,6 +78,8 @@ For Cursor / Claude Desktop config, see [`docs/CUSTOMIZATION.md`](docs/CUSTOMIZA
|
|
|
78
78
|
|
|
79
79
|
Then ask: *"Analyze this Figma design: https://www.figma.com/design/..."*
|
|
80
80
|
|
|
81
|
+
> **Note:** MCP/Skill path extracts style data from Figma MCP's generated code (React + Tailwind), not raw Figma node properties. For the most accurate analysis, use the CLI with a Figma API token.
|
|
82
|
+
|
|
81
83
|
### 3. Web (no install)
|
|
82
84
|
|
|
83
85
|
Go to **[let-sunny.github.io/canicode](https://let-sunny.github.io/canicode/)**, paste a Figma URL, and get results instantly in your browser.
|
package/dist/cli/index.js
CHANGED
|
@@ -2618,8 +2618,9 @@ CANICODE SETUP GUIDE
|
|
|
2618
2618
|
|
|
2619
2619
|
Flow:
|
|
2620
2620
|
Claude Code
|
|
2621
|
-
-> Figma MCP get_metadata(fileKey, nodeId) -> XML node tree
|
|
2622
|
-
->
|
|
2621
|
+
-> Figma MCP get_metadata(fileKey, nodeId) -> XML node tree (structure)
|
|
2622
|
+
-> Figma MCP get_design_context(fileKey, nodeId) -> code (styles)
|
|
2623
|
+
-> Merge into fixture JSON (structure + styles)
|
|
2623
2624
|
-> canicode analyze fixture.json -> report
|
|
2624
2625
|
|
|
2625
2626
|
\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501
|
|
@@ -2640,6 +2641,19 @@ CANICODE SETUP GUIDE
|
|
|
2640
2641
|
In Figma -> Figma Plugin
|
|
2641
2642
|
Browser -> Web App (GitHub Pages)
|
|
2642
2643
|
Quick trial, offline -> CLI + JSON fixtures
|
|
2644
|
+
|
|
2645
|
+
\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501
|
|
2646
|
+
DATA SOURCE DIFFERENCES
|
|
2647
|
+
\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501
|
|
2648
|
+
|
|
2649
|
+
CLI (REST API) Reads raw Figma node data directly.
|
|
2650
|
+
Most accurate \u2014 all style properties available.
|
|
2651
|
+
|
|
2652
|
+
MCP / Skill Uses Figma MCP's get_metadata (structure) and
|
|
2653
|
+
get_design_context (styles). Style data is extracted
|
|
2654
|
+
from Figma MCP's own generated code (React + Tailwind),
|
|
2655
|
+
not raw Figma node properties. Results may differ
|
|
2656
|
+
slightly from CLI due to this interpretation layer.
|
|
2643
2657
|
`.trimStart());
|
|
2644
2658
|
}
|
|
2645
2659
|
function printDocsRules() {
|