[codex] Add shadcn theme variables skill - #14
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces a new skill, shadcn-theme-variables, which assists in creating, repairing, or normalizing Figma Variables to align with the shadcn/ui semantic theming model. The changes include adding the skill definition file, updating the main README catalog, and integrating the skill into the Figma skill router with specific tie-breaker rules. The review feedback correctly points out that the border-radius scale calculation in the skill definition should be updated to use shadcn's standard subtraction-based formula (e.g., radius - 2px and radius - 4px) instead of a multiplication-based scale.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
| - `radius-sm` | ||
| - `radius-md` | ||
| - `radius-lg` | ||
| - `radius-xl` | ||
| - `radius-2xl` | ||
| - `radius-3xl` | ||
| - `radius-4xl` | ||
|
|
||
| Use the user's CSS values when available. If only the base radius is available, use shadcn's scale relationship as the naming guide and compute practical Figma values from the base radius: | ||
|
|
||
| - `radius-sm`: `radius * 0.6` | ||
| - `radius-md`: `radius * 0.8` | ||
| - `radius-lg`: `radius` | ||
| - `radius-xl`: `radius * 1.4` | ||
| - `radius-2xl`: `radius * 1.8` | ||
| - `radius-3xl`: `radius * 2.2` | ||
| - `radius-4xl`: `radius * 2.6` |
There was a problem hiding this comment.
Shadcn/ui uses a subtraction-based formula for its border-radius scale rather than a multiplication-based scale. Specifically, it defines radius-lg as the base --radius, radius-md as calc(var(--radius) - 2px), and radius-sm as calc(var(--radius) - 4px). It also does not include larger sizes like radius-xl through radius-4xl by default.
Consider updating this section to align with the standard shadcn/ui radius scale:
- `radius-sm`
- `radius-md`
- `radius-lg`
Use the user's CSS values when available. If only the base radius is available, use shadcn's scale relationship as the naming guide and compute practical Figma values from the base radius:
- `radius-sm`: `radius - 4px`
- `radius-md`: `radius - 2px`
- `radius-lg`: `radius`There was a problem hiding this comment.
Pull request overview
Adds a new installable Figma skill that guides agents through creating/repairing semantic-only shadcn/ui theme variables (light/dark modes, semantic token set, bindings), and wires it into the catalogue and router documentation so it is discoverable and correctly routed.
Changes:
- Added
shadcn-theme-variablesskill document with semantic token architecture, mode/value rules, binding guidance, and cleanup/conflict handling. - Registered the new skill in the
figma-skill-routercatalogue index and tie-breaker guidance. - Updated the README catalogue entry and incremented the displayed skill count to 57 (matches current
skills/figma-agent/*/SKILL.mdcount).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| skills/figma-agent/shadcn-theme-variables/SKILL.md | New skill definition and workflow for semantic shadcn theme variable creation/repair in Figma. |
| skills/figma-agent/figma-skill-router/SKILL.md | Adds the new skill to routing index + clarifies when to use it vs token-tailwind-theme-sync. |
| README.md | Adds the skill to the public catalogue and updates the visible skill count. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Summary
skills/figma-agent/shadcn-theme-variables/SKILL.mdfor semantic-only shadcn theme variable creation and repair in Figma.Notes
The skill intentionally stays semantic-only and does not create a primitive token layer unless the user explicitly asks for one. It treats project CSS as the source of truth when available.
I did not update
skills-lock.json; the visible repository validation checks canonicalSKILL.mdlayout and frontmatter, but not the lockfile. If the lockfile is generated by release tooling, it should be regenerated by that workflow.Validation
scripts/validate_skills.py.tests/figma_skill_router.test.ts.ghis not installed.