Communitygithub.com

components.build 仕様

モダンで構成可能、かつアクセシブルなReact UIコンポーネントをcomponents.build仕様に従って構築します。コンポーネントライブラリ、デザインシステム、再利用可能なUIコンポーネントの作成、レビュー、リファクタリング時に使用します。コンポーネントAPI、構成パターン、アクセシビリティ、スタイリングシステム、TypeScript propsに関連するタスクで発動します。

components.build 仕様 とは?

このスキルは、Hayden Bleasel氏とshadcn氏が共同執筆したcomponents.build仕様に基づき、モダンで構成可能かつアクセシブルなReact UIコンポーネントを構築するための包括的なガイドラインを提供します。16のルールカテゴリ(概要、原則、定義、構成、アクセシビリティ、状態、型、ポリモーフィズム、As-Child、データ属性、スタイリング、デザイントークン、ドキュメント、レジストリ、npm、マーケットプレイス)から構成され、優先度順に整理されています。このスキルは、コンポーネントAPIやプロップインターフェースの設計、アクセシビリティ機能の実装、Tailwind CSSとCVAを用いたスタイリング、レジストリやnpmへの公開など、あらゆるUIコンポーネント開発のワークフローをサポートします。各ルールカテゴリには詳細な説明と、誤ったコード例と正しいコード例が含まれており、ベストプラクティスを学ぶことができます。

対応✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/ulasalyesil/personal-website-v2/tree/HEAD/.agents/skills/components-build

お気に入りのAIに質問する

このエージェントスキルを事前に読み込んだ状態で新しいチャットを開きます。

ドキュメント

components.build 仕様 は何をしますか?

モダンで構成可能、かつアクセシブルなUIコンポーネントを構築するための包括的なガイドラインです。コア原則から配布までをカバーする16のルールカテゴリが含まれており、Hayden Bleasel氏とshadcn氏の共著です。

適用タイミング

以下の場合にこれらのガイドラインを参照します:

  • 新しいReactコンポーネントやコンポーネントライブラリを作成する場合
  • コンポーネントAPIとプロップインターフェースを設計する場合
  • アクセシビリティ機能(キーボード、ARIA、フォーカス管理)を実装する場合
  • 構成可能なコンポーネントアーキテクチャを構築する場合
  • Tailwind CSSとCVAでコンポーネントをスタイリングする場合
  • レジストリやnpmにコンポーネントを公開する場合

ルールカテゴリ(優先度順)

優先度カテゴリフォーカスプレフィックス
1概要仕様の範囲と目標overview
2原則コアデザイン哲学principles
3定義共通用語definitions
4構成複雑なコンポーネントの分解composition
5アクセシビリティキーボード、スクリーンリーダー、ARIAaccessibility
6状態制御/非制御パターンstate
7型TypeScriptのpropsとインターフェースtypes
8ポリモーフィズムasプロップによる要素切り替えpolymorphism
9As-ChildRadix Slot構成パターンas-child
10データ属性data-stateとdata-slotdata-attributes
11スタイリングTailwind CSS、cnユーティリティ、CVAstyling
12デザイントークンCSS変数とテーマ設定design-tokens
13ドキュメントコンポーネントドキュメントdocumentation
14レジストリコンポーネントレジストリregistry
15npmnpmへの公開npm
16マーケットプレイスコンポーネントマーケットプレイスmarketplaces

クイックリファレンス

1. 概要

  • overview - 仕様の範囲、目標、哲学

2. 原則

  • principles - 構成可能性、アクセシビリティ、カスタマイズ性、透明性

3. 定義

  • definitions - 共通用語(プリミティブ、複合、ヘッドレスなど)

4. 構成

  • composition-root - 共有状態を持つContextを持つルートコンポーネント
  • composition-item - アイテムラッパーコンポーネント
  • composition-trigger - インタラクティブなトリガーコンポーネント
  • composition-content - コンテンツ表示コンポーネント
  • composition-export - 名前空間エクスポートパターン

5. アクセシビリティ

  • accessibility-semantic-html - 適切なHTML要素を使用
  • accessibility-keyboard - 完全なキーボードナビゲーションサポート
  • accessibility-aria - 適切なARIAロール、状態、プロパティ
  • accessibility-focus - フォーカス管理と復元
  • accessibility-live-regions - スクリーンリーダーへの通知
  • accessibility-contrast - カラーコントラスト要件

6. 状態

  • state-uncontrolled - 内部状態管理
  • state-controlled - 外部状態委譲
  • state-controllable - useControllableStateによる両パターンのサポート

7. 型

  • types-extend-html - ネイティブHTML属性の拡張
  • types-export - コンシューマ向けにプロップ型をエクスポート
  • types-single-element - 1つのコンポーネントが1つの要素をラップ

8. ポリモーフィズム

  • polymorphism-as-prop - レンダリングされる要素タイプの変更
  • polymorphism-typescript - 型安全なポリモーフィックコンポーネント
  • polymorphism-defaults - 意味論的な要素のデフォルト

9. As-Child

  • as-child-slot - プロップマージのためのRadix Slot
  • as-child-composition - 子コンポーネントとの構成

10. データ属性

  • data-attributes-state - 状態のスタイリングにdata-stateを使用
  • data-attributes-slot - サブコンポーネントのターゲットにdata-slotを使用

11. スタイリング

  • styling-cn-utility - clsxとtailwind-mergeの組み合わせ
  • styling-order - ベース → バリアント → 条件 → ユーザーオーバーライド
  • styling-cva - バリアントのためのClass Variance Authority
  • styling-css-variables - CSS変数を用いた動的な値

12. デザイントークン

  • design-tokens-css-variables - CSS変数としてトークンを定義
  • design-tokens-theming - ライト/ダークモードとテーマのサポート

13. ドキュメント

  • documentation-props - JSDocですべてのプロップを文書化
  • documentation-examples - 使用例の提供

14. レジストリ

  • registry-structure - レジストリのファイル構造
  • registry-schema - コンポーネントのメタデータスキーマ

15. npm

  • npm-package-json - パッケージ設定
  • npm-exports - モジュールエクスポート

16. マーケットプレイス

  • marketplaces-distribution - コンポーネント配布戦略

使用方法

詳細な説明とコード例については、個別のルールファイルをお読みください:

rules/composition/SKILL.md
rules/accessibility/SKILL.md
rules/styling/SKILL.md

各ルールファイルには以下が含まれます:

  • それが重要である理由の簡単な説明
  • 説明付きの誤ったコード例
  • 説明付きの正しいコード例
  • ベストプラクティスと一般的な落とし穴

完全な統合ドキュメント

すべてのルールを展開した完全なガイドはこちら: AGENTS.md

主要な原則

  1. 構成よりも構成 - コンポーネントを構成可能なサブコンポーネントに分割する
  2. デフォルトでアクセシブル - 後付けではなく、必須条件とする
  3. 単一要素ラッピング - 各コンポーネントは1つのHTML要素をラップする
  4. HTML属性の拡張 - 常にネイティブ要素のプロップを拡張する
  5. 型のエクスポート - プロップ型をコンシューマが利用できるようにする
  6. 両方の状態パターンをサポート - 制御と非制御
  7. インテリジェントなクラス結合 - tailwind-mergeを備えたcn()ユーティリティを使用

著者

共著:

AIスキルとして翻案:

components.build仕様に基づく。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

ulasalyesil/personal-website-v2

Create beautiful visual art in .png and .pdf documents using design philosophy. You should use this skill when the user asks to create a poster, piece of art, design, or other static piece. Create original visual designs, never copying existing artists' work to avoid copyright violations.

ulasalyesil/personal-website-v2

Conduct design interviews, generate five distinct UI variations in a temporary design lab, collect feedback, and produce implementation plans. Use when the user wants to explore UI design options, redesign existing components, or create new UI with multiple approaches to compare.

ulasalyesil/personal-website-v2

Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, artifacts, posters, or applications (examples include websites, landing pages, dashboards, React components, HTML/CSS layouts, or when styling/beautifying any web UI). Generates creative, polished code and UI design that avoids generic AI aesthetics.

ulasalyesil/personal-website-v2

Design and implement microinteractions, motion design, transitions, and user feedback patterns. Use when adding polish to UI interactions, implementing loading states, or creating delightful user experiences.

ulasalyesil/personal-website-v2

This skill is for interface design — dashboards, admin panels, apps, tools, and interactive products. NOT for marketing design (landing pages, marketing sites, campaigns).

ulasalyesil/personal-website-v2

Best practices and example-driven guidance for building SwiftUI views and components. Use when creating or refactoring SwiftUI UI, designing tab architecture with TabView, composing screens, or needing component-specific patterns and examples.

ulasalyesil/personal-website-v2

UI/UX design intelligence. 50 styles, 21 palettes, 50 font pairings, 20 charts, 9 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind, shadcn/ui). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, mobile app, .html, .tsx, .vue, .svelte. Elements: button, modal, navbar, sidebar, card, table, form, chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, flat design. Topics: color palette, accessibility, animation, layout, typography, font pairing, spacing, hover, shadow, gradient. Integrations: shadcn/ui MCP for component search and examples.

ulasalyesil/personal-website-v2

Conduct WCAG 2.2 accessibility audits with automated testing, manual verification, and remediation guidance. Use when auditing websites for accessibility, fixing WCAG violations, or implementing accessible design patterns.

ulasalyesil/personal-website-v2

Review UI code for Web Interface Guidelines compliance. Use when asked to "review my UI", "check accessibility", "audit design", "review UX", or "check my site against best practices".

ulasalyesil/personal-website-v2

Enforces an opinionated UI baseline to prevent AI-generated interface slop.

ulasalyesil/personal-website-v2

Ship correct, complete metadata.

ulasalyesil/personal-website-v2

Survey any codebase as a senior advisor and produce prioritized, self-contained implementation plans for OTHER models/agents to execute. Strictly read-only on source code — never implements, fixes, or refactors anything itself. Use when asked to audit a codebase, find improvement opportunities (bugs, security, performance, test coverage, tech debt, migrations, DX), suggest features or where to take the project next (roadmap, product direction), or generate handoff plans for another agent to implement.

ulasalyesil/personal-website-v2

Defines the product's objects, relationships, states, and vocabulary independently of any interface — the most load-bearing layer

ulasalyesil/personal-website-v2

Maps domain concepts, terminology conflicts, and bounded contexts — produces a noun harvest for the conceptual model layer

ulasalyesil/personal-website-v2

Maps interaction structure and flow — produces breadboard notation with edge cases, failure paths, and open decisions

ulasalyesil/personal-website-v2

Framework orientation for Layers of Product Design — load this first; provides the context all other skills depend on

ulasalyesil/personal-website-v2

User research planning and synthesis at the observed behaviour layer — produces candidate job stories with confidence ratings

ulasalyesil/personal-website-v2

Diagnostic audit across all seven layers — identifies the bottleneck layer and recommends where to focus

ulasalyesil/personal-website-v2

Connects user opportunities to business outcomes and solution bets — produces a strategy tree and prioritised experiments

ulasalyesil/personal-website-v2

Audits existing surface against lower-layer decisions and produces a surface decision inventory — vocabulary, object consistency, completeness, feedback, hierarchy, accessibility

関連スキル