# Theme Review Skill

Review a WordPress block theme against the team's quality checklist and draft a PR comment with findings.

## Quick Start

```
/theme-review themeslug
```

## What It Does

1. **Locates the theme** - Finds the theme directory by slug
2. **Runs automated checks** - Validates against the team checklist:
   - Required templates (archive, index, 404, page, search, single)
   - Template content (query blocks, pagination, main tags, etc.)
   - theme.json configuration (fluid fonts, spacing, custom templates)
   - Assets (fonts registered, images used, proper paths)
   - Patterns (i18n, Inserter settings, Categories)
   - File metadata (screenshot, readme.txt, style.css)
   - Global checks (no hardcoded values, no dev URLs)
3. **Flags items for manual review** - Color variations, custom templates, etc.
4. **Generates a draft PR comment** - Formatted with findings
5. **Lets you review before posting** - Edit or post the comment

## Example Session

```
> /theme-review themeslug

Locating theme... found at ./themeslug/

Running automated checks...

## Theme Review: themeslug

### Summary
- **Passed:** 42 checks
- **Issues:** 2 issues found
- **Manual Review Needed:** 1 item

---

### Issues Found

1. **patterns/footer.php:5** - Template pattern missing `Inserter: no`
2. **parts/header.html:9** - Navigation block has `"ref":77` (site-specific ID)

---

### Manual Review Needed

- [ ] Custom template: `home.html`

---

Would you like to:
- Post this comment to a PR
- Copy to clipboard
- Edit and retry
- Cancel
```

## Checklist Coverage

The skill checks against these categories:

| Category | Checks |
|----------|--------|
| Templates | Required templates exist, proper blocks, main tags |
| theme.json | Fluid fonts, spacing, padding, template registration |
| functions.php | Block stylesheet enqueuing |
| Assets | Font registration, image usage, proper paths |
| Patterns | i18n, Inserter settings, Categories |
| Metadata | screenshot dimensions, readme.txt, style.css |
| Global | fontSize presets, no dev URLs, no nav refs |

## Notes

- This skill is **read-only** - it doesn't modify any files
- Always verify findings before posting to a PR
- Some items require manual testing (color contrast, visual review)
- See `checklist.md` for the complete checklist with explanations
