feat(skill): register split, color strategy, and pre-design intake

Splits the skill into two register references (editorial, product),
replaces category-based theme selection with a forced physical-scene
inference, and introduces a four-step color strategy axis (Restrained /
Committed / Full palette / Drenched) with editorial permission for the
bold three.

Adds a seed mode to /impeccable document for pre-implementation
projects, updates /impeccable teach Step 5 to offer the seed path, and
grows /impeccable shape with Design Direction + Scope intake
(fidelity, breadth, interactivity, time). Extends live-mode variant
distinctness to forbid three variants sharing theme and dominant hue.

Also drops the anti-pattern validator coupling, consolidates a11y into
audit.md, and updates CLAUDE.md with the register architecture.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Paul Bakaus
2026-04-21 14:13:29 -07:00
co-authored by Claude Opus 4.7
parent 81f880d030
commit 4daabe5232
172 changed files with 7316 additions and 6973 deletions
+11 -7
View File
@@ -214,16 +214,20 @@ export function writeFile(filePath, content) {
}
/**
* Extract patterns from frontend-design SKILL.md
* Parses DO/DON'T lines grouped by section headings.
* Recognizes both formats:
* Extract DO/DON'T patterns from a skill markdown file, grouped by section
* (h3 `### ` headings). Recognizes both formats:
* - Markdown bullet form: `**DO**: …` / `**DON'T**: …`
* - XML-block prose form: `DO …` / `DO NOT …` (used inside
* <typography_rules>, <color_rules>, <spatial_rules>, <absolute_bans>)
* - Prose form: `DO …` / `DO NOT …`
*
* Defaults to the main impeccable SKILL.md but accepts any relative path so
* rules in `src/detect-antipatterns.mjs` can anchor to register-specific
* reference files (e.g. `reference/editorial.md`) via an optional `skillFile`
* field. Callers that don't pass `relativePath` get the legacy behavior.
*
* Returns { patterns: [...], antipatterns: [...] }
*/
export function readPatterns(rootDir) {
const skillPath = path.join(rootDir, 'source/skills/impeccable/SKILL.md');
export function readPatterns(rootDir, relativePath = 'source/skills/impeccable/SKILL.md') {
const skillPath = path.join(rootDir, relativePath);
if (!fs.existsSync(skillPath)) {
return { patterns: [], antipatterns: [] };