surface-theme-scaffold-gen
Generate Clef Surface design system theme scaffolds including palette configuration , typography scale , motion definitions , elevation scale , and light dark theme manifests Follows WCAG accessibility guidelines for contrast ratios
Best use case
surface-theme-scaffold-gen is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Generate Clef Surface design system theme scaffolds including palette configuration , typography scale , motion definitions , elevation scale , and light dark theme manifests Follows WCAG accessibility guidelines for contrast ratios
Teams using surface-theme-scaffold-gen should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/surface-theme-scaffold-gen/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How surface-theme-scaffold-gen Compares
| Feature / Agent | surface-theme-scaffold-gen | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Generate Clef Surface design system theme scaffolds including palette configuration , typography scale , motion definitions , elevation scale , and light dark theme manifests Follows WCAG accessibility guidelines for contrast ratios
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
<!-- Auto-generated by Clef Clef Bind — claude-skills target -->
<!-- Concept: SurfaceThemeScaffoldGen -->
<!-- Do not edit manually; regenerate with: clef interface generate -->
# SurfaceThemeScaffoldGen
Scaffold a Clef Surface design system theme **$ARGUMENTS** with palette tokens, typography scale, motion transitions, and elevation shadows.
> **When to use:** Use when creating a new Clef Surface design system theme. Generates palette configuration, typography scale, motion definitions, elevation scale, and light/dark theme manifests with WCAG accessibility compliance.
## Design Principles
- **Token-Based Design:** Every visual value is a named design token — no hardcoded colors, sizes, or shadows anywhere in component code.
- **WCAG Compliance:** Every color pair must meet WCAG 2.1 AA contrast (4.5:1 normal text, 3:1 large text). The generator validates at generation time.
- **Reduced Motion Respect:** All motion durations collapse to 0ms when prefers-reduced-motion is active. This is built into the motion token system, not opt-in.
- **Theme Layering:** Themes are layered: base + variants. Multiple variants can be active simultaneously, resolved by priority then activation order.
## Step-by-Step Process
### Step 1: Register Generator
Self-register with PluginRegistry so KindSystem can track ThemeConfig → CoifTheme transformations. Registration is also handled automatically by register-generator-kinds.sync.
**Examples:**
*Register the theme scaffold generator*
```typescript
const result = await surfaceThemeScaffoldGenHandler.register({}, storage);
```
### Step 2: Preview Changes
Dry-run the generation using Emitter content-addressing to classify each output file as new, changed, or unchanged. No files are written.
**Arguments:** `$0` **name** (string), `$1` **primaryColor** (string), `$2` **fontFamily** (string), `$3` **baseSize** (int), `$4` **mode** (string)
### Step 3: Generate Clef Surface Theme
Generate a complete Clef Surface theme scaffold with palette tokens ,
typography scale , motion transitions , elevation shadows ,
and light dark theme JSON files
**Arguments:** `$0` **name** (string), `$1` **primaryColor** (string), `$2` **fontFamily** (string), `$3` **baseSize** (int), `$4` **mode** (string)
**Checklist:**
- [ ] Theme name is kebab-case?
- [ ] Primary color generates full 50-950 scale?
- [ ] Palette has semantic roles (primary, secondary, error, etc.)?
- [ ] WCAG contrast ratios meet AA standard (4.5:1 normal, 3:1 large)?
- [ ] Typography uses modular ratio scale?
- [ ] Motion respects prefers-reduced-motion?
- [ ] Elevation scale covers 0-5 levels?
- [ ] Light and dark themes are generated (if mode=both)?
- [ ] All files written through Emitter (not directly to disk)?
- [ ] Source provenance attached to each file?
- [ ] Generation step recorded in GenerationPlan?
**Examples:**
*Generate a theme with defaults*
```bash
clef scaffold theme --name ocean
```
*Generate a custom theme*
```bash
clef scaffold theme --name brand --primary '#3b82f6' --font 'Inter, sans-serif' --base-size 18
```
*Generate light-only theme*
```bash
clef scaffold theme --name print --mode light
```
## References
- [Clef Surface design system and theme architecture](references/surface-theme-guide.md)
## Supporting Materials
- [Clef Surface theme scaffolding walkthrough](examples/scaffold-surface-theme.md)
## Quick Reference
| Input | Type | Purpose |
|-------|------|---------|
| name | String | Theme name (kebab-case) |
| primaryColor | String | Primary color hue or hex value |
| secondaryColor | String | Secondary color hue or hex |
| fontFamily | String | Primary font stack |
| baseSize | Int | Base font size in pixels (default: 16) |
| scale | Float | Modular ratio (default: 1.25 major third) |
| borderRadius | String | Default border radius |
| mode | String | light, dark, or both (default: both) |
**Output Files:**
| File | Purpose |
|------|---------|
| `suite.yaml` | Theme suite manifest |
| `themes/{name}-light.json` | Light theme tokens |
| `themes/{name}-dark.json` | Dark theme tokens |
| `tokens/palette.json` | Color scale configuration |
| `tokens/typography.json` | Type scale and font stacks |
| `tokens/motion.json` | Animation timing and easing |
| `tokens/elevation.json` | Shadow scale |
## Anti-Patterns
### Hardcoded colors in components
Component uses raw hex values instead of design tokens.
**Bad:**
```
.button { background: #3b82f6; color: #ffffff; }
```
**Good:**
```
.button {
background: var(--color-primary);
color: var(--color-on-primary);
}
```
### Ignoring reduced motion
Animations play regardless of prefers-reduced-motion setting.
**Bad:**
```
.dialog { transition: transform 300ms ease; }
```
**Good:**
```
.dialog {
transition: transform var(--motion-duration-slow) var(--motion-ease-default);
}
@media (prefers-reduced-motion: reduce) {
.dialog { transition-duration: 0ms; }
}
```
## Validation
*Generate a Clef Surface theme scaffold:*
```bash
npx tsx cli/src/index.ts scaffold theme --name ocean --primary 220 --font 'Inter, sans-serif'
```
*Run scaffold generator tests:*
```bash
npx vitest run tests/scaffold-generators.test.ts
```
## Related Skills
| Skill | When to Use |
| --- | --- |
| `/surface-component-scaffold` | Generate components to use the theme tokens |
| `/suite-scaffold` | Generate suite manifests for theme packages |Related Skills
stl-cube-scaffold
Analyze an STL mesh (AABB + approximate OBB) and generate a single connected STL that includes an L×L×L cube scaffold (default 100mm) plus connectors, so the final solid's OBB is locked to the target cube size for packing/measurement checks.
skills-scaffolding
Guide for creating effective Claude Code skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.
scaffold-project
Bootstrap or review project-level context primitives for Claude Code. First run creates .claude/primitives/ and .claude/skills/project-context/. Re-runs review existing primitives against the codebase, auto-update what changed, and flag what's stale. Invoke with '/scaffold-project' or say 'scaffold project', 'set up project context', 'review project context'.
project-scaffold
Generate project boilerplate from scaffold templates. Use when creating a new project after stack selection. Triggers on: scaffold project, generate boilerplate, create from template.
plugin-scaffolder
Scaffolds complete Claude Code plugin structures with all necessary directories, manifest, and documentation. Activates when user wants to create a new plugin, package features together, or prepare for marketplace distribution. Creates plugin.json, directory structure, and starter documentation. Use when user mentions "create plugin", "new plugin", "scaffold plugin", "plugin structure", or "share via marketplace".
m365-agent-scaffolder
Quickly scaffolds new Microsoft 365 Copilot declarative agent (M365 agent, copilot agent, agent, declarative copilot, copilot) projects using ATK CLI. Collects project information and creates the initial project structure. Use only when creating a new empty M365 Copilot agent project from scratch.
electron-scaffold
Scaffold a native-looking, effective Electron app with best practices baked in. Creates a production-ready Electron application with security hardening, modern tooling, proper IPC patterns, auto-updates, native UI elements, and optimal build configuration. Use this skill when users want to start a new Electron project or modernize an existing one.
create-plugin-scaffold
Create a new Cursor plugin scaffold with a valid manifest, component directories, and marketplace wiring. Use when starting a new plugin or adding a plugin to a multi-plugin repository.
awesome-copilot-root-meta-agentic-project-scaffold
Meta agentic project creation assistant to help users create and manage project workflows effectively. Use when: the task directly matches meta agentic project scaffold responsibilities within plugin awesome-copilot-root. Do not use when: a more specific framework or task-focused skill is clearly a better match.
awesome-copilot-meta-agentic-project-scaffold
Meta agentic project creation assistant to help users create and manage project workflows effectively. Use when: the task directly matches meta agentic project scaffold responsibilities within plugin awesome-copilot. Do not use when: a more specific framework or task-focused skill is clearly a better match.
api-scaffolding
Quickly scaffold production-ready FastAPI endpoints for client workflows. Use when building new APIs for QuickBooks, ShipStation, or webhook integrations.
anthropic-theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with colors/fonts that you can apply to any artifact that has been creating, or can generate a new theme on-the-fly.