Token导航 LogoToken导航TokenDH.com
研究检索操作浏览器github未标认证来源可访问许可证需确认审计提醒

building-blocks积木

Agent Skill

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

总安装

12,235

周安装

380

GitHub Stars

40

下载量

3,000
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/adobe/helix-website --skill 'Building Blocks'

简介

用于创建或修改 AEM Edge Delivery 的可复用组件(blocks),遵循内容驱动开发原则。

  • 涵盖内容模型理解、JavaScript 装饰逻辑实现、样式应用及代码质量标准维护。
  • 应在 content-driven-development 技能之后调用,并与 block-collection-and-party、testing-blocks 协同工作。
  • 安装命令:npx skills add https://github.com/adobe/helix-website --skill 'Building Blocks'。
  • 注意:需确保项目已配置 AEM 环境,且相关依赖技能已正确加载。

SKILL.md

Building Blocks

This skill guides you through creating new AEM Edge Delivery blocks or modifying existing ones, following Content Driven Development (CDD) principles. Blocks are the reusable building blocks of AEM sites - each transforms authored content into rich, interactive experiences through JavaScript decoration and CSS styling. This skill covers the complete development process: understanding content models, implementing decoration logic, applying styles, and maintaining code quality standards.

Related Skills

  • content-driven-development: MUST be invoked before using this skill to ensure content and content models are ready
  • block-collection-and-party: Use to find similar blocks for patterns
  • testing-blocks: Automatically invoked after implementation for comprehensive testing

When to Use This Skill

This skill should ONLY be invoked from the content-driven-development skill during Phase 2 (Implementation).

If you are not already following the CDD process:

  • STOP - Do not proceed with this skill
  • Invoke the content-driven-development skill first
  • The CDD skill will ensure test content and content models are ready before implementation

This skill handles:

  • Creating new block files and structure
  • Implementing JavaScript decoration
  • Adding CSS styling
  • Code quality and testing

Prerequisites

REQUIRED before using this skill:

  • ✅ Test content must exist (in CMS or local drafts)
  • ✅ Content model must be defined
  • ✅ Test content URL must be available

Information needed:

  1. Block name: What should the block be called?
  2. Content model: The defined structure authors will use
  3. Test content URL: Path to test content for development

Process Overview

  1. Verify Prerequisites (CDD completed)
  2. Find Similar Blocks (for patterns and reuse)
  3. Create or Modify Block Structure (files and directories)
  4. Implement JavaScript Decoration (DOM transformation)
  5. Add CSS Styling (scoped, responsive styles)
  6. Test the Implementation (local testing, linting)
  7. Document Block (developer and author-facing docs)

Detailed Process

1. Verify Prerequisites

Before proceeding, confirm with the user:

"Do you have:

  • ✅ Test content created (URL or path)?
  • ✅ Content model defined?

If not, we need to use the content-driven-development skill first."

If prerequisites are not met, STOP and invoke the content-driven-development skill.

If prerequisites are met, get the test content URL from the user and proceed to step 2.

2. Find Similar Blocks

For new blocks or major modifications:

  1. Search the codebase for similar blocks that might provide useful patterns or code we can re-use
  2. Use the block-collection-and-party skill to find relevant reference blocks

Review the implementation patterns in similar blocks to inform your approach.

For minor modifications to existing blocks: Skip to step 3.

3. Create or Modify Block Structure

For new blocks:

  1. Create directory: blocks/{block-name}/
  2. Create files: {block-name}.js and {block-name}.css
  3. Use the boilerplate structure (or reference templates in resources/ if helpful):

- JS file exports a default decorate(block) function (can be async if needed) - CSS file targets the .{block-name} class

For existing blocks:

  1. Locate the existing block directory in blocks/{block-name}/
  2. Review the current implementation before making changes
  3. Understand the existing decoration logic and styles

4. Implement JavaScript Decoration

Follow patterns and conventions in resources/js-guidelines.md:

  • Use DOM APIs to transform the initial block HTML structure
  • Keep decoration logic focused and single-purpose
  • Handle variants appropriately (check block.classList for variant classes)
  • Follow established patterns from similar blocks

Read resources/js-guidelines.md for detailed examples, code standards, and best practices.

5. Add CSS Styling

Follow patterns and conventions in resources/css-guidelines.md:

  • All CSS selectors must be scoped to the block (start with .{block-name})
  • Use BEM-like naming within the block scope
  • Leverage CSS custom properties for theming
  • Write mobile-first responsive styles
  • Keep specificity low
  • Follow established patterns from similar blocks

Read resources/css-guidelines.md for detailed examples, code standards, and best practices.

6. Test the Implementation

After implementation is complete, invoke the testing-blocks skill:

The testing-blocks skill will guide you through:

  • Writing unit tests for any logic-heavy utilities
  • Browser testing to validate block behavior
  • Taking screenshots for validation and PR documentation
  • Running linting and fixing issues
  • Verifying GitHub checks pass

Provide the testing-blocks skill with:

  • Block name being tested
  • Test content URL (from CDD process)
  • Any variants that need testing

Return to this skill after testing is complete to proceed to step 7.

7. Document Block

Blocks require two types of documentation:

Developer Documentation

  • Most blocks are simple and self-contained and only need code comments for documentation
  • If a block is especially complex (has many variants, or especially complex code) consider adding a brief README.md in the block folder
  • Keep any README documentation very brief so it can be consumed at a glance

Author-Facing Documentation

Author-facing documentation helps content authors understand how to use the block in the CMS. This documentation typically exists as draft/library content in the CMS itself, not in the codebase.

When author documentation is needed:

Almost all blocks should have author-facing documentation. The only exceptions are:

  • Deprecated blocks that should no longer be used but can't be removed yet
  • Special-purpose blocks used very infrequently on a need-to-know basis
  • Auto-blocked blocks that shouldn't be used directly by authors

Maintaining author documentation:

Author documentation must be kept in sync with the block implementation:

  • Update when variants are added, removed, or modified
  • Update when the content structure changes
  • Update when block behavior or functionality changes

Where author documentation lives:

Different projects use different approaches for author documentation:

  1. Sidekick Library (Google Drive/SharePoint authoring):

- Uses https://github.com/adobe/franklin-sidekick-library - Check for /tools/sidekick/library.html in the codebase - If present, guide user to add/update block documentation in the library

  1. Document Authoring (DA) Library:

- Uses https://docs.da.live/administrators/guides/setup-library - Different implementation than Sidekick Library - If in use, guide user to update block documentation in DA library

  1. Universal Editor (UE) projects:

- Often skip dedicated author documentation libraries - May use inline help or other mechanisms

  1. Simple documentation pages:

- Some projects maintain documentation under /drafts or /docs - Pages contain authoring guides and block examples

What to include in author documentation:

The specific content of author documentation varies by project. As an agent:

  1. Identify that author documentation needs to be created or updated
  2. Determine which documentation approach the project uses (check for /tools/sidekick/library.html as a signal)
  3. Guide the user on what aspects of the block should be documented based on the changes made
  4. Provide specific guidance based on the project's documentation approach

Reference Materials

  • resources/js-guidelines.md
  • resources/css-guidelines.md

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

35.45%
按下载量换算1,064

Claude

32.48%
按下载量换算974

Cursor

17.99%
按下载量换算540

Gemini CLI

10.22%
按下载量换算307

安全审计

Gen Agent Trust Hub

可疑

Socket

通过

Snyk

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills