Figma Generate Libraryのロゴ

Figma Generate Library

組織
memi-design
figma-generate-library

Generate Figma component library from React/shadcn codebase with Code Connect parity

概要

公開者memi-design
リポジトリdesign-skills
スキル名figma-generate-library
スター
7
フォーク
0
同梱ファイル
1
ライセンスMIT
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 1個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    memi-designがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキル「Figma Generate Library」をTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/memi-design/design-skills/tree/main/skills/figma-generate-library
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/memi-design/design-skills.git /tmp/design-skills
mkdir -p .claude/skills
cp -r /tmp/design-skills/skills/figma-generate-library .claude/skills/figma-generate-library
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでFigma Generate Libraryを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあるとすぐに、モデルが自動的にFigma Generate Libraryを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Figma Generate Libraryは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、スキルを使わない間は指示の読み込みにトークンを消費しません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

/figma-generate-library — Create Component Library from Codebase

Generate Figma components from your React/shadcn codebase, establishing Code Connect for perfect design-code parity. Requires /figma-use.

Freedom Level: High

Full creative freedom for visual representation, but component structure must mirror the codebase exactly.

Prerequisites

  • /figma-use foundational skill loaded
  • Codebase has shadcn/ui or similar component library
  • memi connect active
  • figma_search_components called this session

Workflow

Step 1: Check Existing Mappings

get_code_connect_map → what's already mapped?

Skip components that already have Code Connect mappings. Only create what's missing.

Step 2: Scan Codebase Components

Read generated/ and src/components/ directories
Identify all React components with:
  - Props interface (variants, sizes, states)
  - shadcn/ui base components used
  - Tailwind classes → map to Figma properties
  - Atomic level (atom/molecule/organism)

Step 3: Create Variables First (Batch)

Before components, ensure design tokens exist:

figma_batch_create_variables (up to 100 per call):
  colors/ → all color tokens (primary, secondary, destructive, etc.)
  spacing/ → 0, 1, 2, 3, 4, 5, 6, 8, 10, 12, 16, 20, 24, 32, 40, 48, 64
  radius/ → none, sm, default, md, lg, xl, 2xl, full
  typography/ → font sizes, weights, line heights

Always use batch tools — 10-50x faster than individual calls.

Step 4: Build Components Bottom-Up

1. Create or find "Design System" page
2. Create Section per atomic level:
   ├── Section "Atoms"
   ├── Section "Molecules"
   ├── Section "Organisms"
   └── Section "Templates"
3. For each component:
   a. Use use_figma (preferred) or typed Mémoire Figma actions for creation
   b. Add variant properties matching React props
   c. Bind all visual properties to variables
   d. Apply correct sizing (hug/fill)
   e. Document with description
4. Arrange with figma_arrange_component_set
Atoms (shadcn/ui primitives)

Each atom becomes a Component Set with variant properties:

ComponentSet "Button"
├── variant=default, size=default
├── variant=destructive, size=default
├── variant=outline, size=sm
└── variant=ghost, size=lg

Properties:
  variant: default | destructive | outline | secondary | ghost | link
  size: default | sm | lg | icon
  state: default | hover | active | disabled | focused
  hasIcon: boolean
  label: text property
Molecules (composed atoms)
Component "FormField"
├── Label (instance of Atom/Label)
├── Input (instance of Atom/Input)
└── HelpText (instance of Atom/HelpText, optional)

Properties:
  state: default | error | success | disabled
  hasHelpText: boolean
  label: text
  placeholder: text
Organisms (composed molecules + atoms)
Component "LoginForm"
├── FormField (email)
├── FormField (password)
├── Checkbox (remember me)
├── Button (submit, fill width)
└── Links row

Properties:
  hasSocialLogin: boolean
  hasRememberMe: boolean

Step 5: Self-Healing Loop (per component)

Run the self-healing loop from /figma-use for each component. Additionally verify: matches codebase visually, all variants render, properties documented, PascalCase naming.

Step 6: Establish Code Connect (PRIMARY OUTPUT)

This is the most important step. Map every Figma component to code:

add_code_connect_map:
  Button → src/components/ui/button.tsx
  Input → src/components/ui/input.tsx
  Card → src/components/ui/card.tsx
  FormField → src/components/molecules/FormField.tsx
  LoginForm → generated/components/LoginForm/LoginForm.tsx

Step 7: Generate Mémoire Specs

For each component created:

memi spec component Button
memi spec component FormField
memi spec component LoginForm

shadcn/ui → Figma Mapping

shadcn ComponentFigma TypeAtomic LevelKey Properties
ButtonComponent SetAtomvariant, size, state, hasIcon
InputComponent SetAtomstate, type, hasIcon
LabelComponentAtomrequired (boolean)
BadgeComponent SetAtomvariant
CardComponentAtom—
SeparatorComponentAtomorientation
SelectComponent SetMoleculestate, hasPlaceholder
DialogComponent SetOrganismhasOverlay, size
SheetComponent SetOrganismside, size
TableComponent SetOrganismhasHeader, hasPagination
SidebarComponentOrganismcollapsed (boolean)
TabsComponent SetMoleculevariant, orientation
TooltipComponentAtomposition
AvatarComponent SetAtomsize, hasImage

Anti-Patterns

  • Creating components without variables (hardcoded colors/spacing)
  • Skipping Auto Layout (absolute positioning breaks responsiveness)
  • Not documenting component properties
  • Missing hover/active/disabled states
  • Forgetting to create the component set (just loose frames)
  • Not establishing Code Connect after creation — this is the whole point
  • Using individual variable creation instead of batch operations
  • Using raw Figma execution for design-system-aware creation when use_figma works

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Figma Generate Library」では何ができますか?

Generate Figma component library from React/shadcn codebase with Code Connect parity

TypingMindでFigma Generate Libraryを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Figma Generate Libraryはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにFigma Generate Libraryをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/memi-design/design-skills/tree/main/skills/figma-generate-libraryを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Figma Generate Libraryを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストの内容がこのスキルの用途に合ったときに、このスキルを読み込めます。

Figma Generate Libraryで使えるAIモデルの数に制限はありますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもFigma Generate Libraryを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Figma Generate Library」は無料ですか?

はい。memi-designがMITライセンスのもとでGitHubに公開しています。ご利用のAIプロバイダーに支払うのは、使用したトークンの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇