Skip to content
Back to skills

Source Command Audit

ASecurity

Check existing code against your design system for spacing, depth, color, and pattern violations.

  • 2 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added November 26, 2026
design

Security analysis

A100/100

Scanned November 26, 2026

npx -y skills add tangchunwu/skill-hub --skill source-command-audit --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Source Command Audit?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Source Command Audit
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/tangchunwu-source-command-audit/badge)](https://www.skillsdirectory.com/skills/tangchunwu-source-command-audit)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: "source-command-audit"
description: "Check existing code against your design system for spacing, depth, color, and pattern violations."
---

# source-command-audit

Use this skill when the user asks to run the migrated source command `audit`.

## Command Template

# interface-design audit

Check existing code against your design system.

## Usage

```
/audit <path>     # Audit specific file/directory
/audit            # Audit common UI paths
```

## What to Check

**If `.interface-design/system.md` exists:**

1. **Spacing violations**
   - Find spacing values not on defined grid
   - Example: 17px when base is 4px

2. **Depth violations**
   - Borders-only system → flag shadows
   - Subtle system → flag layered shadows
   - Allow ring shadows (0 0 0 1px)

3. **Color violations**
   - If palette defined → flag colors not in palette
   - Allow semantic grays

4. **Pattern drift**
   - Find buttons not matching Button pattern
   - Find cards not matching Card pattern

**Report format:**
```
Audit Results: src/components/

Violations:
  Button.tsx:12 - Height 38px (pattern: 36px)
  Card.tsx:8 - Shadow used (system: borders-only)
  Input.tsx:20 - Spacing 14px (grid: 4px, nearest: 12px or 16px)

Suggestions:
  - Update Button height to match pattern
  - Replace shadow with border
  - Adjust spacing to grid
```

**If no system.md:**

```
No design system to audit against.

Create a system first:
1. Build UI → establish system automatically
2. Run /extract → create system from existing code
```

## Implementation

1. Check for system.md
2. Parse system rules
3. Read target files (tsx, jsx, css, scss)
4. Compare against rules
5. Report violations with suggestions

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in design →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.