# makepad-2.0-theme

A skill covering the Makepad 2.0 theme system: theme.* variables, dark and light modes, colors, fonts and spacing in Splash.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · ★ 751
- Author: ZhangHanDong
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/ZhangHanDong/makepad-skills/tree/HEAD/skills/makepad-2.0-theme/SKILL.md
- Updated: 2026-04-07
- HTML: https://affpapa.org/en/nevibecode/skills/makepad-20-theme

## What it does

The skill documents how Makepad 2.0 themes work and which `theme.*` variables Splash scripts can use. It lists the three built-in themes — `mod.themes.dark` (the default), `mod.themes.light` and the hardcoded `mod.themes.skeleton` — and maps variables for backgrounds, text, widget states, status colors and the bevel layers.

A separate section walks through theme loading in `App::run`. Call `theme_mod` first, pick the active theme with `script_eval!`, then load `widgets_mod`. Skip the first two calls and you get the dark theme, since `theme_mod` sets it. Widgets reach the theme through `mod.prelude.widgets_internal`, so the choice has to happen before they load; otherwise every color and spacing value comes from the dark set.

The skill's rule for production UI: no literal colors, font sizes or spacing. Pull them from `theme.*` instead, and theme switching keeps working without touching each widget.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add ZhangHanDong/makepad-skills --skill makepad-2.0-theme -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/makepad-2.0-theme/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/makepad-2.0-theme/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add ZhangHanDong/makepad-skills --skill makepad-2.0-theme -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/makepad-2.0-theme/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add ZhangHanDong/makepad-skills --skill makepad-2.0-theme -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/makepad-2.0-theme/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install ZhangHanDong/makepad-skills makepad-2.0-theme
```

2. **Manually: put the files in place**
- File: `.github/skills/makepad-2.0-theme/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add ZhangHanDong/makepad-skills --skill makepad-2.0-theme -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/ZhangHanDong/makepad-skills --path skills/makepad-2.0-theme
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/makepad-2.0-theme/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add ZhangHanDong/makepad-skills --skill makepad-2.0-theme -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/ZhangHanDong/makepad-skills/tree/HEAD/skills/makepad-2.0-theme/SKILL.md

## When to use it
- pick the active theme before widgets load
- swap hardcoded colors for `theme.*` variables
- ship one interface in both light and dark
- choose text colors for hover, focus and disabled states
- tune global theme parameters such as corner radius and the spacing multiplier

## Example prompts
- Show how to select `mod.themes.light` instead of the dark theme in `App::run`
- Which `theme.*` variables cover container background and alternating rows?
- Rewrite the button colors to use theme variables so mode switching works

## Similar
- [ant-design](https://affpapa.org/en/nevibecode/skills/ant-design.md) — skill · 4100 installs
- [chakra-ui-builder](https://affpapa.org/en/nevibecode/skills/chakra-ui-builder.md) — skill · 3500 installs
- [color-mode-and-theme](https://affpapa.org/en/nevibecode/skills/color-mode-and-theme.md) — skill · 926 installs
- [styles](https://affpapa.org/en/nevibecode/skills/styles.md) — skill · 2200 installs
- [godot-ui-control](https://affpapa.org/en/nevibecode/skills/godot-ui-control.md) — skill · 7000 installs
- [godot-ui-theming](https://affpapa.org/en/nevibecode/skills/godot-ui-theming.md) — skill · 617 installs

From the same set: [zhanghandong/makepad-skills](https://affpapa.org/en/nevibecode/by/zhanghandong/makepad-skills.md) — 6 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
