Token导航 LogoToken导航

Agent Skill · 研究检索

create-component(创建组件)

create-component 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

create-component 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为调用外部服务;许可证信息还不明确,第三方扫描有提醒项,按安装量在研究检索类的 73,675 个 Skill 里排第 25,571。

总安装 3,740周安装 159GitHub Stars 55下载 1,310核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:create-component(创建组件)
来源仓库:https://github.com/adobe/skills
仓库路径:skills/create-component
安装命令:
npx skills add https://github.com/adobe/skills --skill create-component
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/adobe/skills --skill create-component

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

create-component 用于创建遵循 Adobe 最佳实践的 AEM 组件,支持完整组件结构和规范生成。它要求首先检查 .aem-skills-config.yaml 配置文件是否存在且已启用,否则将终止执行。适用于需要快速搭建符合企业标准的 AEM 前端组件的开发场景,减少重复配置工作。

使用前请确认项目路径、包名配置正确,避免因配置错误导致生成文件结构异常。适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

来源仓库内路径:skills/create-component

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/adobe/skills --skill create-component;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要调用外部服务,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

create-component 怎么安装?

在终端执行 npx skills add https://github.com/adobe/skills --skill create-component。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

create-component 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

create-component 需要什么权限?

权限级别是调用外部服务。该 Skill 可能调用第三方服务、云服务或外部模型 API,使用前需要确认账号、额度、数据发送范围和服务条款。

create-component 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

create-component 用的人多吗?

公开数据是累计安装 3,740 次,近一周安装 159 次,下载 1,310 次,GitHub 55 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

create-component 安全吗?

第三方扫描有提醒项,说明存在需要人工确认的行为。安装前请打开源码看清它读了什么、联网到哪里。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。

先想清楚的地方

  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
create-component

创建组件 · 本页

3,74055调用外部服务未明确有提醒

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

AEM Component Creation Skill

Creates complete AEM components following Adobe best practices.

Configuration Gate Check — Do This First

This configuration check needs to happen first because without it, the skill will use incorrect project paths and package names, causing every generated file to be wrong.

First tool call: Read .aem-skills-config.yaml in the project root (same level as pom.xml).

Check: Does the file exist and does it have configured: true?

StatusAction
File missing or configured: falseStop and display the error message below. Do not explore the codebase or proceed — the config values are needed for correct file paths and naming. Wait for the user to configure.
configured: trueRead project, package, and group values from the YAML file. Proceed with component creation.

If NOT configured, Display This Message and Stop:

Project configuration required!

Before creating components, configure your project settings in:
`.aem-skills-config.yaml` (in your project root, same level as pom.xml)

Open the file and update:
- project: Your AEM project name (e.g., 'mysite', 'wknd')
- package: Your Java package (e.g., 'com.mysite.core')
- group: Your component group (e.g., 'MySite Components')
- configured: true

After updating, ask me to create the component again.

Why you should not explore the codebase when unconfigured:

Doing any of the following before configuration is set will lead to incorrect assumptions and wasted effort:

  • Reading any other repository files
  • Listing directories to "understand the project"
  • Checking existing components for patterns
  • Looking at pom.xml, Java files, or folder structures
  • Inferring values from any source

The config file is the single source of truth for project values — skipping it leads to wrong paths and package names in every generated file.

No Hallucination Rule

Only create the exact fields the user specified — adding extra fields creates authoring confusion and maintenance burden, and renaming fields breaks content contracts.

Load reference for full rules: references/no-hallucination-rules.md

Workflow Overview

StepAction
0Configuration validation (do this first — see above)
1Extract & validate component name
1.5Component extension decision (if extending)
2Gather requirements & confirm dialog specification
2.3Figma design fetch (if Figma URL provided)
3Create all component files
3.11Dependency verification (required for servlets)
4Completion summary

Step 0: Configuration Validation

0.1 Read Configuration

  1. Read .aem-skills-config.yaml from the project root
  2. Check that configured: true
  3. Read project, package, and group values

0.2 Validate — Use Only the Config File

Do not infer project values from the file system, existing components, Java files, pom.xml, or prior knowledge. These sources may be outdated or inconsistent — .aem-skills-config.yaml is the single source of truth because the user explicitly sets it.

0.3 Load Conventions

  1. Read references/aem-conventions.md for file structure templates, naming conventions, and patterns

0.4 Project State Analysis (after configuration validated)

  1. Check Component Name Uniqueness - Look in /apps/[project]/components/
  2. Check Model Class Conflicts - Look in core/src/main/java/[package-path]/models/
  3. Analyze Existing Patterns - Review 1-2 recent components for style reference

Step 1: Extract & Validate Component Name

  • Parse component name from user's message (ask if not provided)
  • Normalize to lowercase kebab-case (e.g., My Component -> my-component)
  • Validate: starts with letter, only letters/numbers/hyphens, no consecutive hyphens

Step 1.5: Component Extension Decision

When user says "extend {component}":

Tier 1: Check Project Components First

  • Search /apps/{project}/components/{component}
  • If found -> Use as sling:resourceSuperType

Tier 2: Check Core Components

User SaysMaps To
imagecore/wcm/components/image/v3/image
teaser, cardcore/wcm/components/teaser/v2/teaser
text, richtextcore/wcm/components/text/v2/text
title, headingcore/wcm/components/title/v3/title
listcore/wcm/components/list/v4/list
button, ctacore/wcm/components/button/v2/button
navigation, navcore/wcm/components/navigation/v2/navigation
container, sectioncore/wcm/components/container/v1/container
accordioncore/wcm/components/accordion/v1/accordion
tabscore/wcm/components/tabs/v1/tabs
carouselcore/wcm/components/carousel/v1/carousel
embed, videocore/wcm/components/embed/v2/embed

Tier 3: Not Found - Ask user for clarification.

For extension patterns, load: references/extending-core-components.md

Step 1.6: Core Component Extension Requirements

Required when extending with "hide", "remove", "add custom field", or "override" (these operations need Sling Resource Merger patterns to work correctly):

Load reference: references/extending-core-components.md

User RequestAction
"Add custom fields"Create new tab OR add to existing
"Hide {tab}"Use sling:hideResource="{Boolean}true"
"Hide {field}"Use sling:hideResource="{Boolean}true"
"Override {field}"Use sling:hideProperties + new values

When extending Core Components:

  • Use @Self @Via(type = ResourceSuperType.class) for model delegation
  • Implement ComponentExporter interface
  • Add resourceType to @Model annotation
  • Use sling:hideResource in dialog for inherited tabs/fields
Note: If the parent component is a project component (not a Core Component), use direct Java class extension (extends ParentModel) instead of the delegation pattern. The @Self @Via(type = ResourceSuperType.class) pattern is only for Core Components. Load references/extending-core-components.md for the decision table.

Step 2: Gather Requirements

2.1 Parse Dialog Specification

Echo back EXACTLY what you understood before creating:

Dialog Specification Confirmed:
I will create exactly {N} fields:
| # | Field Label | Field Type | Property Name |
|---|-------------|------------|---------------|
| 1 | {label1}    | {type1}    | {name1}       |
No additional fields will be added.
Is this correct?

2.2 Mockup Image Handling

  • Both mockup AND spec provided: Dialog spec takes precedence. Mockup for HTML/CSS only.
  • Only mockup provided: Propose fields and ASK for confirmation.

2.3 Figma Design Input

Load: references/figma-design-rules.md

When user provides a Figma URL (figma.com/design/..., figma.com/make/..., or figma.com/board/...):

  1. Parse the URL to extract fileKey and nodeId (see references/figma-design-rules.md Rule 1)
  • Convert - to : in the node-id query parameter
  • Use branchKey as fileKey for branch URLs
  1. Call get_design_context via the plugin-figma-figma MCP server (see Rule 2):{"server": "plugin-figma-figma", "toolName": "get_design_context", "arguments": {"nodeId": "<extracted-node-id>", "fileKey": "<extracted-file-key>", "clientLanguages": "html,css,javascript", "clientFrameworks": "htl"}}
  2. Extract design tokens from the response — colors, fonts, sizes, spacing, layout (see Rules 3-4)
  3. Use the Figma output for HTL structure, CSS styling, and JS behavior — NOT for dialog fields

Precedence when BOTH dialog spec AND Figma URL are provided:

  • Dialog specification → determines dialog fields (absolute precedence, no hallucination)
  • Figma design → determines HTML structure, CSS styling, JS behavior only

When ONLY Figma URL is provided (no dialog spec):

  • Analyze the design and PROPOSE dialog fields to the user
  • ASK for confirmation before proceeding

Figma response handling:

  • The response is React+Tailwind — treat as a REFERENCE, not production code
  • Convert JSX to semantic HTL with BEM classes (see Rule 5)
  • Extract all CSS values to the component clientlib (see Rule 6)
  • Create JS only if interactivity is implied (see Rule 7)
  • Do not hardcode Figma temporary image URLs — they expire and will break in production (see Rule 8)

2.4 Dynamic Content Requirements

User IndicatesServlet Required?
External API integrationYes (GET)
Dynamic data loadingYes (GET)
Form submissionYes (POST)
Search/filterYes (GET)
Static dialog contentNo

Step 3: Create Component Files

Create ALL files in this order:

3.1 Component Definition

Path: ui.apps/src/main/content/jcr_root/apps/[project]/components/{component-name}/.content.xml

Load: references/aem-conventions.md

3.2 Component Dialog

Path: ui.apps/.../components/{component-name}/_cq_dialog/.content.xml

Load: references/dialog-patterns.md

For extended components: Load references/extending-core-components.md — Sling Resource Merger is required here because dialog inheritance only works through the merger; without it, parent dialog nodes won't be resolved.

3.2.1 Image Field Handling

When a user specifies an image or photo field:

  • Default approach: Embed the Core Image component via data-sly-resource — do NOT create a fileupload dialog field with manual <img> rendering.
  • Fileupload is only for non-image files (PDFs, documents, etc.). Only use cq/gui/components/authoring/dialog/fileupload when the user explicitly asks for a non-image file upload.
  • Load references/htl-patterns.md (Image Handling section) for the correct embedding pattern.

3.3 HTL Template

Path: ui.apps/.../components/{component-name}/{component-name}.html

Load: references/htl-patterns.mdIf Figma URL provided, ALSO load: references/figma-design-rules.md (Rules 5, 8) — Convert JSX structure to semantic HTL with BEM classes. Replace static text with Sling Model expressions. Use the Figma screenshot as visual truth for element hierarchy.

i18n check: If the component has static display text (labels, button text, placeholder strings), use HTL i18n expressions: ${'Label Text' @ i18n}. Do not handle static text translation in the Sling Model — keep it in HTL where translation is automatic.

3.4 Sling Model

Path: core/src/main/java/[package-path]/models/{ComponentName}Model.java

Load: references/model-patterns.md, references/java-standards.md

For extensions: Load references/extending-core-components.md

Delegation Pattern (for Core Component extensions):

@Model(adaptables = SlingHttpServletRequest.class,
       adapters = {CustomModel.class, ComponentExporter.class},
       resourceType = CustomModel.RESOURCE_TYPE)
@Exporter(name = ExporterConstants.SLING_MODEL_EXPORTER_NAME,
          extensions = ExporterConstants.SLING_MODEL_EXTENSION)
public class CustomModel implements ComponentExporter {
    @Self @Via(type = ResourceSuperType.class)
    private com.adobe.cq.wcm.core.components.models.List coreList;
    // Use FQN for core interfaces to avoid import collision
}

3.5 Child Item Model - If Multifield

Path: core/src/main/java/[package-path]/models/{ItemName}.java

3.6 Unit Test

Path: core/src/test/java/[package-path]/models/{ComponentName}ModelTest.java

Load: references/test-patterns.md

3.7 Component Clientlib — Create for Every Component

Path: ui.apps/.../clientlibs/clientlib-{component-name}/

Load: references/clientlib-patterns.mdIf Figma URL provided, ALSO load: references/figma-design-rules.md (Rules 6, 7) — Extract exact colors, fonts, sizes, spacing, border-radius from the Figma response. Place all CSS into css/{component-name}.css using BEM naming. Create JS in js/{component-name}.js only if the design implies interactivity. Verify pixel-perfect fidelity against the Figma screenshot.

3.8 Dialog Clientlib - If Conditional Logic

Path: ui.apps/.../clientlibs/clientlib-{component-name}-dialog/

Load: references/clientlib-patterns.md (Dialog JavaScript Pattern section)

3.9 Sling Servlet - If Dynamic Content

Path: core/src/main/java/[package-path]/servlets/{ComponentName}Servlet.java

Load: references/sling-servlet-standards.md

3.10 Servlet Unit Test

Path: core/src/test/java/[package-path]/servlets/{ComponentName}ServletTest.java

3.11 Dependency Verification — Required for Servlets

Before completing, verify dependencies in core/pom.xml:

  • Do not hardcode versions — check parent pom.xml for version properties instead, since hardcoded versions drift out of sync and cause build conflicts
  • Most common APIs included in aem-sdk-api (GSON, Jackson, Commons)
  • Use provided scope for AEM runtime libraries

Step 4: Completion Summary

Component '{component-name}' created successfully!

## Files Created
- ui.apps/.../components/{component-name}/.content.xml
- ui.apps/.../components/{component-name}/_cq_dialog/.content.xml
- ui.apps/.../components/{component-name}/{component-name}.html
- core/.../models/{ComponentName}Model.java
- core/.../models/{ComponentName}ModelTest.java
- ui.apps/.../clientlibs/clientlib-{component-name}/
[+ servlet files if applicable]

## Dialog Fields (Exact Match)
{table matching specification}

Would you like me to add any additional fields or build the project?

Quick Reference: Field Type Mapping

User SaysGranite Resource Type
Textfieldgranite/ui/components/coral/foundation/form/textfield
Textareagranite/ui/components/coral/foundation/form/textarea
Richtext, RTEcq/gui/components/authoring/dialog/richtext
Pathfield, Pathgranite/ui/components/coral/foundation/form/pathfield
Image, PhotoEmbed Core Image component (see references/htl-patterns.md Image Handling section). Do not use fileupload for image rendering.
Fileupload, File Uploadcq/gui/components/authoring/dialog/fileupload (for non-image files: PDFs, documents)
Multifieldgranite/ui/components/coral/foundation/form/multifield
Checkboxgranite/ui/components/coral/foundation/form/checkbox
Select, Dropdowngranite/ui/components/coral/foundation/form/select
Numberfieldgranite/ui/components/coral/foundation/form/numberfield
Datepickergranite/ui/components/coral/foundation/form/datepicker

For complete mappings: assets/field-type-mappings.md

Reference Files

Load on-demand based on what you're creating:

CreatingLoad Reference
Any component.aem-skills-config.yaml (project root, load first — see Configuration Gate Check), then references/aem-conventions.md
Dialog XMLreferences/dialog-patterns.md
HTL Templatereferences/htl-patterns.md
Sling Modelreferences/model-patterns.md, references/java-standards.md
Unit Testsreferences/test-patterns.md
Clientlibsreferences/clientlib-patterns.md
Extending Core Componentreferences/extending-core-components.md
Extending Core Component — worked example & checklistsreferences/extending-core-components-example.md (load when you need a complete worked example of extending a Core Component, unit testing patterns, or the implementation checklist)
Sling Servletreferences/sling-servlet-standards.md
Core Component patternsreferences/core-components.md
No Hallucination rulesreferences/no-hallucination-rules.md
Figma design integrationreferences/figma-design-rules.md
Troubleshootingreferences/troubleshooting.md
Examplesreferences/examples.md

If encountering issues during or after component creation, consult references/troubleshooting.md for common problems and solutions.

平台分布

Codex

35.35%
按下载量换算463

Claude

28.18%
按下载量换算369

Cursor

19.03%
按下载量换算249

Gemini CLI

9.32%
按下载量换算122

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

调用外部服务

该 Skill 可能调用第三方服务、云服务或外部模型 API,使用前需要确认账号、额度、数据发送范围和服务条款。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills