Agent SkillsAutomattic/studio › editing-themes

editing-themes

GitHub

用于修改现有WordPress区块主题的指南,强调最小化变更、遵循设计规范及参考文件,禁止随意重写核心文件或更改主题定位。

packages/data-liberation-agent/skills/editing-themes/SKILL.md Automattic/studio

Trigger Scenarios

用户要求修改现有的WordPress主题文件 需要调整主题的颜色、排版或模板结构

Install

npx skills add Automattic/studio --skill editing-themes -g -y
More Options

Non-standard path

npx skills add https://github.com/Automattic/studio/tree/trunk/packages/data-liberation-agent/skills/editing-themes -g -y

Use without installing

npx skills use Automattic/studio@editing-themes

指定 Agent (Claude Code)

npx skills add Automattic/studio --skill editing-themes -a claude-code -g -y

安装 repo 全部 skill

npx skills add Automattic/studio --all -g -y

预览 repo 内 skill

npx skills add Automattic/studio --list

SKILL.md

Frontmatter
{
    "name": "editing-themes",
    "description": "Guidelines for modifying existing WordPress block themes — load this before editing theme files",
    "disable-model-invocation": true
}

When to use me

Use this skill when modifying an existing theme (files already exist in the workspace). Do not use this skill when creating a new theme from scratch.

Absolute Rules

  • NEVER recreate or overwrite files the user did not ask you to change. If the user asks to "add a newsletter template", you add the new template/pattern files and update the index template to include it — nothing else.
  • NEVER rewrite theme.json, functions.php, or style.css unless the user's request specifically requires changes to them (e.g., adding a new color, changing fonts, registering a new asset).
  • NEVER change the theme's topic, branding, or content direction. If the theme is for a dance studio, new additions must be contextually appropriate for a dance studio — not generic placeholder content.
  • NEVER delete existing patterns, templates, or template parts unless the user explicitly asks to remove them.

Editing Guidelines

  • Read theme.json, style.css, and functions.php before making changes — understand the current configuration, design tokens, and registered assets
  • Make minimal, targeted changes — only modify what the user requested
  • Only touch files that need to change — do not rewrite unrelated templates or patterns
  • Use the edit tool for targeted changes; only use write when replacing more than 50% of a file
  • When modifying colors, typography, or spacing, update theme.json — not CSS — unless the change cannot be expressed in theme.json
  • When adding or modifying template parts, ensure they are registered in theme.json if needed
  • Preserve the theme's existing design direction and aesthetic unless the user explicitly asks to change it
  • New content (patterns, templates) must match the theme's existing topic, tone, and visual style
  • After changes, verify templates still reference valid template parts and patterns

Reference Files

Before editing theme files, read the relevant references from the creating-themes/references/ directory.

  • creating-themes/references/block-html.md — REQUIRED: read this FIRST. Block HTML validity rules, block comment ↔ HTML matching, image/cover/button block structure. Violating these causes "unexpected or invalid content" errors.
  • creating-themes/references/design-direction.md — REQUIRED: read this before generating any theme files. Contains guidelines and good design directions.
  • creating-themes/references/navigation.md — read this before generating any header template part, covers wp:navigation block markup, overlay (hamburger menu)
  • creating-themes/references/query-loop.md — read this if the theme must display dynamic content (blog posts, archives, search results) in templates or patterns

Version History

  • 0d55cb5 Current 2026-08-20 12:16

Same Skill Collection

apps/cli/ai/skills/annotate/SKILL.md
apps/cli/ai/skills/block-content/SKILL.md
apps/cli/ai/skills/hosting-plans-helper/SKILL.md
apps/cli/ai/skills/liberate/SKILL.md
apps/cli/ai/skills/need-for-speed/SKILL.md
apps/cli/ai/skills/plugin-recommendations/SKILL.md
apps/cli/ai/skills/rank-me-up/SKILL.md
apps/cli/ai/skills/site-spec/SKILL.md
apps/cli/ai/skills/taxonomist/SKILL.md
apps/cli/ai/skills/visual-design/SKILL.md
apps/cli/ai/skills/visual-polish/SKILL.md
apps/cli/ai/skills/wpcom-remote-management/SKILL.md
packages/data-liberation-agent/skills/adapt/SKILL.md
packages/data-liberation-agent/skills/creating-blocks/SKILL.md
packages/data-liberation-agent/skills/creating-themes/SKILL.md
packages/data-liberation-agent/skills/design-foundations/SKILL.md
packages/data-liberation-agent/skills/diagnose/SKILL.md
packages/data-liberation-agent/skills/editing-blocks/SKILL.md
packages/data-liberation-agent/skills/generating-patterns/SKILL.md
packages/data-liberation-agent/skills/migrate/SKILL.md
packages/data-liberation-agent/skills/model-local-data/SKILL.md
packages/data-liberation-agent/skills/qa/SKILL.md
packages/data-liberation-agent/skills/rebuild-section/SKILL.md
packages/data-liberation-agent/skills/testing-js/SKILL.md
packages/data-liberation-agent/skills/testing-php/SKILL.md
packages/data-liberation-agent/skills/testing-wp-runtime/SKILL.md
skills/studio-cli/SKILL.md
packages/data-liberation-agent/skills/compose-page-blocks/SKILL.md
packages/data-liberation-agent/skills/design-qa/SKILL.md
packages/data-liberation-agent/skills/match-page/SKILL.md
packages/data-liberation-agent/skills/match-section/SKILL.md
packages/data-liberation-agent/skills/replicate-theme/SKILL.md
packages/data-liberation-agent/skills/replicate-with-blocks/SKILL.md

Metadata

Files
0
Version
0d55cb5
Hash
80ff94fc
Indexed
2026-08-20 12:16

- 위키
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-08-26 01:43
浙ICP备14020137号-1 $방문자$