figura-cli 0.10.2 → 0.11.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/dist/index.js +154 -130
- package/dist/mcp.js +27 -27
- package/package.json +1 -1
- package/skills/fig/SKILL.md +14 -5
- package/skills/figura-brand/SKILL.md +10 -4
package/package.json
CHANGED
package/skills/fig/SKILL.md
CHANGED
|
@@ -48,11 +48,20 @@ greenfield.
|
|
|
48
48
|
|
|
49
49
|
## How to fig
|
|
50
50
|
|
|
51
|
-
1. **
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
51
|
+
1. **Verify the destination team** — call **`figura_whoami`** (or
|
|
52
|
+
`figura whoami --json`) and check BOTH halves before generating anything:
|
|
53
|
+
- **Connected?** Not connected → tell the user to run `figura link` (or
|
|
54
|
+
`figura login`), or add the MCP: `claude mcp add figura -- figura mcp`.
|
|
55
|
+
(Creating / publishing figs needs the `figs:write` scope on the team — a
|
|
56
|
+
read-only token passes whoami but fails the land step.)
|
|
57
|
+
- **Bound to THIS project?** Read `binding.source` in the response. `project`
|
|
58
|
+
(or an explicit `env` token) → proceed, and say where the fig will land
|
|
59
|
+
("figging to team *slug*"). **`global` → STOP before generating**: nothing
|
|
60
|
+
pins this repo to that team — the fig would land on whatever team this
|
|
61
|
+
machine last logged into (this is exactly how mocks have ended up on the
|
|
62
|
+
wrong tenant). Tell the user to run `figura link` in this repo, then
|
|
63
|
+
re-verify. If the response has no `binding` field (older CLI/MCP), confirm
|
|
64
|
+
the team slug matches this project with the user before proceeding.
|
|
56
65
|
|
|
57
66
|
2. **Default — build it yourself, with YOUR Claude.** Fetch the team's design
|
|
58
67
|
system — `bunx figura-cli brand --json` — and hand-build the fig's HTML against
|
|
@@ -17,15 +17,21 @@ directory). Default to the current repo.
|
|
|
17
17
|
|
|
18
18
|
## Prerequisites
|
|
19
19
|
|
|
20
|
-
The user needs
|
|
20
|
+
The user needs this repo linked to its Figura team (`figura link`; a global
|
|
21
|
+
`figura login` also works but is only a machine-wide fallback) — the brand is
|
|
21
22
|
written to the team that token belongs to. If a `figura` **MCP server** is
|
|
22
23
|
connected, prefer its `figura_set_brand` tool over the CLI. If neither the CLI nor
|
|
23
24
|
`bunx figura-cli` is available, tell the user to install it
|
|
24
25
|
(`curl -fsSL https://figura.so/install.sh | bash`) and stop.
|
|
25
26
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
the
|
|
27
|
+
Verify the destination team first: `figura whoami --json` (or the `figura_whoami`
|
|
28
|
+
tool) and check `binding.source`. `project` (or an explicit `env` token) → name
|
|
29
|
+
the team out loud and continue. **`global` → STOP**: nothing pins this repo to
|
|
30
|
+
that team — you could read *another product's* brand as the baseline and
|
|
31
|
+
overwrite *their* profile with this repo's. Tell the user to run `figura link`
|
|
32
|
+
here first. The brand is **team-wide and overwrites** the current one — never
|
|
33
|
+
push without showing the user what you're about to set and getting an explicit
|
|
34
|
+
OK.
|
|
29
35
|
|
|
30
36
|
## Workflow
|
|
31
37
|
|