@ruyfranca/myskills 1.0.18 → 1.0.20
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/.agent/skills/creative-design-figma/SKILL.md +81 -0
- package/.agent/skills/figma-dev-mode/SKILL.md +76 -0
- package/.agent/workflows/creative-design-figma.md +11 -0
- package/.agent/workflows/figma.md +10 -0
- package/.mcp.json +7 -0
- package/README.md +14 -0
- package/index.js +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: creative-design-figma
|
|
3
|
+
description: Use the Official Figma MCP server to fetch design context, screenshots, variables, and assets from Figma via OAuth token, and to translate Figma nodes into production code.
|
|
4
|
+
allowed-tools: Read, Write, Edit, Glob, run_command
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# 🎨 Creative Design Figma
|
|
8
|
+
|
|
9
|
+
> Integrate the Official Figma MCP Server to extract pixel-perfect details, colors, and design context directly via the cloud.
|
|
10
|
+
> Note: This relies on the Remote Figma MCP (`https://mcp.figma.com/mcp`), NOT the local Dev Mode server.
|
|
11
|
+
|
|
12
|
+
## 🎯 Selective Reading Rule
|
|
13
|
+
|
|
14
|
+
**Read ONLY files relevant to the request!** If you just need prompt patterns, you don't need to read the setup.
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## 📑 Content Map
|
|
19
|
+
|
|
20
|
+
| Context | Action |
|
|
21
|
+
|---------|--------|
|
|
22
|
+
| Project has no `.mcp.json` | Create `.mcp.json` with the Figma Cloud MCP |
|
|
23
|
+
| Generating Code | Follow the Required Flow for extracting `get_design_context` |
|
|
24
|
+
| Extracting Tokens | Execute `get_variable_defs` for colors and spacing |
|
|
25
|
+
|
|
26
|
+
---
|
|
27
|
+
|
|
28
|
+
## 🔌 Setup Config
|
|
29
|
+
|
|
30
|
+
To enable the Official Figma MCP, the following `.mcp.json` block must be present in the user's project root (or inside their global Claude config).
|
|
31
|
+
|
|
32
|
+
**⚠️ REQUIREMENT:** The user MUST provide `FIGMA_OAUTH_TOKEN`.
|
|
33
|
+
|
|
34
|
+
```json
|
|
35
|
+
{
|
|
36
|
+
"mcpServers": {
|
|
37
|
+
"Figma Official MCP": {
|
|
38
|
+
"command": "npx",
|
|
39
|
+
"args": ["-y", "@figma/mcp-server"],
|
|
40
|
+
"env": {
|
|
41
|
+
"FIGMA_OAUTH_TOKEN": "<USER_MUST_PROVIDE_THIS>"
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
```
|
|
47
|
+
|
|
48
|
+
> **Reminder:** Tell the user to add their Personal Access Token if connection fails. This is a Cloud API.
|
|
49
|
+
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
## 🔗 Related Skills
|
|
53
|
+
|
|
54
|
+
| Need | Skill |
|
|
55
|
+
|------|-------|
|
|
56
|
+
| Frontend implementation | `@[skills/senior-frontend]` |
|
|
57
|
+
| Visual Design tokens | `@[skills/theme-factory]` |
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
## ✅ Integration Workflow (Required)
|
|
62
|
+
|
|
63
|
+
When transforming a Figma design into code via this skill, perform these steps in order:
|
|
64
|
+
|
|
65
|
+
1. **`get_design_context`**: Run this first using the Figma Frame/Layer link to get structured design data.
|
|
66
|
+
2. **`get_metadata` (Optional)**: If the node is too large and the context truncates, fetch the metadata outline first, then target specific child nodes.
|
|
67
|
+
3. **`get_screenshot`**: Request a screenshot of the node to have a visual reference of the variant.
|
|
68
|
+
4. **Implement**: Start the design-to-code translation. Ensure you map Figma tokens to the project's Tailwind config or CSS custom properties.
|
|
69
|
+
|
|
70
|
+
---
|
|
71
|
+
|
|
72
|
+
## ❌ Anti-Patterns
|
|
73
|
+
|
|
74
|
+
**DON'T:**
|
|
75
|
+
- Use placeholders for images when the MCP returns an asset download link. Use the provided asset source.
|
|
76
|
+
- Pull new external icon libraries (like Lucide or FontAwesome) if the designer specifically provided custom SVGs in the Figma payload.
|
|
77
|
+
|
|
78
|
+
**DO:**
|
|
79
|
+
- Prompt the user for the Figma URL (copy link to frame).
|
|
80
|
+
- Request the `FIGMA_OAUTH_TOKEN` if you see authentication errors.
|
|
81
|
+
- Extract styling strictly reproducing the visual screenshot.
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: figma-dev-mode
|
|
3
|
+
description: Setup and utilization of the Figma Dev Mode MCP to inspect components, layouts, and styles directly from Figma design files.
|
|
4
|
+
allowed-tools: Read, Write, Edit, Glob, run_command
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Figma Dev Mode MCP
|
|
8
|
+
|
|
9
|
+
> Integrate UI design precisely measuring and extracting information directly from Figma directly through the Dev Mode MCP.
|
|
10
|
+
|
|
11
|
+
## 🎯 Selective Reading Rule
|
|
12
|
+
|
|
13
|
+
**Read ONLY files relevant to the request!** If you just need to query nodes, you don't need to read setup.
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## 📑 Content Map
|
|
18
|
+
|
|
19
|
+
| Context | Action |
|
|
20
|
+
|---------|--------|
|
|
21
|
+
| Project has no `.mcp.json` | Create `.mcp.json` with Figma MCP config |
|
|
22
|
+
| Analyzing UI/UX | Use MCP to inspect Figma Node IDs |
|
|
23
|
+
| Translating to Code | Extract CSS/Tailwind properties from Figma |
|
|
24
|
+
|
|
25
|
+
---
|
|
26
|
+
|
|
27
|
+
## 🔌 Setup Config
|
|
28
|
+
|
|
29
|
+
To enable the Figma MCP into the project, the following `.mcp.json` block must be present in the user's project root:
|
|
30
|
+
|
|
31
|
+
```json
|
|
32
|
+
{
|
|
33
|
+
"mcpServers": {
|
|
34
|
+
"Figma Dev Mode MCP": {
|
|
35
|
+
"url": "http://127.0.0.1:3845/mcp"
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
> **Requirements:** The user MUST have the Figma Desktop App running locally with Dev Mode enabled for the MCP to work.
|
|
42
|
+
|
|
43
|
+
---
|
|
44
|
+
|
|
45
|
+
## 🔗 Related Skills
|
|
46
|
+
|
|
47
|
+
| Need | Skill |
|
|
48
|
+
|------|-------|
|
|
49
|
+
| Frontend implementation | `@[skills/senior-frontend]` |
|
|
50
|
+
| Design Systems | `@[skills/ui-design-system]` |
|
|
51
|
+
| UI/UX Best practices | `@[skills/ui-ux-pro-max]` |
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
## ✅ Integration Checklist
|
|
56
|
+
|
|
57
|
+
Before implementing a design from Figma:
|
|
58
|
+
|
|
59
|
+
- [ ] **Figma Desktop is running?** (Remind the user if MCP connection fails)
|
|
60
|
+
- [ ] **Figma Node URL/ID provided?** (Ask the user for the specific Figma frame link)
|
|
61
|
+
- [ ] **Selected the correct framework?** (Tailwind, Vanilla CSS, React Native)
|
|
62
|
+
- [ ] **Extracted exact tokens?** (Colors, border-radii, spacing)
|
|
63
|
+
|
|
64
|
+
---
|
|
65
|
+
|
|
66
|
+
## ❌ Anti-Patterns
|
|
67
|
+
|
|
68
|
+
**DON'T:**
|
|
69
|
+
- Guess dimensions and colors when the Figma link is provided.
|
|
70
|
+
- Fail silently if the MCP connection drops (tell the user to open Figma).
|
|
71
|
+
- Extract hardcoded colors without checking if they belong to a Design System's token.
|
|
72
|
+
|
|
73
|
+
**DO:**
|
|
74
|
+
- Use the MCP to precisely query the layout properties.
|
|
75
|
+
- Map Figma styles to tailwind config variables when possible.
|
|
76
|
+
- Remind the user to open the specific project in Figma Desktop.
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Start Official Figma MCP integration via Creative Design Figma skill
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
# Official Figma MCP Workflow
|
|
6
|
+
|
|
7
|
+
1. Ensure the `.mcp.json` includes the Official Figma MCP configuration.
|
|
8
|
+
2. Ensure the user has provided the `FIGMA_OAUTH_TOKEN` environment variable.
|
|
9
|
+
3. Ask the user for the specific Figma URL (Frame/Layer link) they want to implement.
|
|
10
|
+
4. Call `@[skills/creative-design-figma]` to begin extraction mapping (`get_design_context` and `get_screenshot`).
|
|
11
|
+
5. Proceed to implement code directly mapping Figma tokens to the current codebase framework.
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Start Figma Dev Mode MCP integration and UI design translation
|
|
3
|
+
---
|
|
4
|
+
|
|
5
|
+
# Figma Workflow
|
|
6
|
+
|
|
7
|
+
1. Configure the `.mcp.json` in the user's project to point to the Figma MCP at `http://127.0.0.1:3845/mcp`.
|
|
8
|
+
2. Instruct the user to open the Figma Desktop app and ensure the design file is active.
|
|
9
|
+
3. Ask the user for the specific Figma URL or Node ID they want to implement.
|
|
10
|
+
4. Call `@[skills/figma-dev-mode]` and `@[skills/senior-frontend]` to begin extraction and implementation.
|
package/.mcp.json
ADDED
package/README.md
CHANGED
|
@@ -99,6 +99,18 @@ Especialista em otimização para mecanismos de busca:
|
|
|
99
99
|
Inteligência avançada de design e experiência do usuário:
|
|
100
100
|
- **Design System**: Gerador de sistemas de design com base em indústria e estilo.
|
|
101
101
|
|
|
102
|
+
### [Figma Dev Mode](file:///Users/ruy/Code/mySkills/.agent/skills/figma-dev-mode/SKILL.md)
|
|
103
|
+
Integração direta com o Figma através do Model Context Protocol (MCP):
|
|
104
|
+
- **Extração**: Inspeção de nós visuais, tokens de cor, tipografia e espaçamento.
|
|
105
|
+
- **Integração**: Configuração de `.mcp.json` para conectar o Claude/Cursor ao Figma Desktop.
|
|
106
|
+
- **Workflow**: Tradução perfeita do design para código.
|
|
107
|
+
|
|
108
|
+
### [Creative Design Figma](file:///Users/ruy/Code/mySkills/.agent/skills/creative-design-figma/SKILL.md)
|
|
109
|
+
Integração com o Figma Oficial na Nuvem:
|
|
110
|
+
- **Cloud MCP**: Extração de dados da API Oficial do Figma via `FIGMA_OAUTH_TOKEN`.
|
|
111
|
+
- **Flow**: Fluxos estruturados de Contexto Visual (`get_design_context`) e Print de Tela (`get_screenshot`).
|
|
112
|
+
- **Precisão**: Extração limpa de variáveis, componentes e assets (SVGs e imagens).
|
|
113
|
+
|
|
102
114
|
---
|
|
103
115
|
## 📚 Mais de 70 Skills Especializadas!
|
|
104
116
|
A biblioteca foi expandida massivamente com recursos do Antigravity Kit. Algumas novas categorias incluem:
|
|
@@ -366,6 +378,8 @@ Você pode acessar as skills diretamente via comandos de barra no chat:
|
|
|
366
378
|
- `/marketing-campaigns`: Ativa o gestor de campanhas para planejamento e execução estratégica.
|
|
367
379
|
- `/web-perf`: Ativa o engenheiro de performance para otimização de Core Web Vitals.
|
|
368
380
|
- `/invoice-organizer`: Ativa o assistente de organização financeira e contábil.
|
|
381
|
+
- `/figma`: Ativa a integração MCP com o Figma Dev Mode para extração visual.
|
|
382
|
+
- `/creative-design-figma`: Ativa a integração MCP Oficial usando tokens de Nuvem do Figma.
|
|
369
383
|
|
|
370
384
|
## 📁 Estrutura do Projeto
|
|
371
385
|
|
package/index.js
CHANGED