LobeHub Interactive Prototype
lobehub/lobehub
Builds single-file interactive HTML prototypes rendered with the real LobeHub UI components and written as production-style React, so they can later be split into files.
当需要用 @ant-design/x-card 让 AI Agent 动态渲染富交互 UI 时使用——涵盖 XCard.Box、XCard.Card、A2UI v0.9 命令、数据绑定、Catalog、Actions 和流式渲染模式。
$ npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install kqcoxn/MaaPipelineEditor x-card --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/kqcoxn/MaaPipelineEditor.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/ant-design-x/skills/x-card .claude/skills/x-card && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "x-card" agent skill from https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-card into .claude/skills/x-card/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "x-card", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-cardType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install kqcoxn/MaaPipelineEditor x-card --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kqcoxn/MaaPipelineEditor.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.agents/skills/ant-design-x/skills/x-card .agents/skills/x-card && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "x-card" agent skill from https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-card into .agents/skills/x-card/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "x-card", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install kqcoxn/MaaPipelineEditor x-card --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kqcoxn/MaaPipelineEditor.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.agents/skills/ant-design-x/skills/x-card .cursor/skills/x-card && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "x-card" agent skill from https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-card into .cursor/skills/x-card/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "x-card", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/kqcoxn/MaaPipelineEditor.git --path .agents/skills/ant-design-x/skills/x-card--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install kqcoxn/MaaPipelineEditor x-card --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kqcoxn/MaaPipelineEditor.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.agents/skills/ant-design-x/skills/x-card .gemini/skills/x-card && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "x-card" agent skill from https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-card into .gemini/skills/x-card/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "x-card", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install kqcoxn/MaaPipelineEditor x-cardInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/kqcoxn/MaaPipelineEditor.git skills-src && mkdir -p .github/skills && cp -r skills-src/.agents/skills/ant-design-x/skills/x-card .github/skills/x-card && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "x-card" agent skill from https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-card into .github/skills/x-card/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "x-card", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install kqcoxn/MaaPipelineEditor x-card --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/kqcoxn/MaaPipelineEditor.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.agents/skills/ant-design-x/skills/x-card .opencode/skills/x-card && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "x-card" agent skill from https://github.com/kqcoxn/MaaPipelineEditor/tree/main/.agents/skills/ant-design-x/skills/x-card into .opencode/skills/x-card/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "x-card", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
x-card当需要用 @ant-design/x-card 让 AI Agent 动态渲染富交互 UI 时使用——涵盖 XCard.Box、XCard.Card、A2UI v0.9 命令、数据绑定、Catalog、Actions 和流式渲染模式。
X Card is an agent skill from kqcoxn/MaaPipelineEditor. 当需要用 @ant-design/x-card 让 AI Agent 动态渲染富交互 UI 时使用——涵盖 XCard.Box、XCard.Card、A2UI v0.9 命令、数据绑定、Catalog、Actions 和流式渲染模式。
Its SKILL.md is about 2.1k tokens, which your agent loads only when the skill is triggered. The skill folder holds 8 other files (for example `reference/ACTIONS.md`, `reference/API.md` and `reference/CATALOG.md`).
It works with Ant Design. The repository describes itself as: ✨ 可视化构建 MaaFramework Pipeline 的下一代工作流 审阅&编辑&调试 工具,你的工程师牛牛! ✨. The licence is MIT.
5 steps, taken from the first numbered list in SKILL.md.
Read from SKILL.md and the folder at commit bbfe0d0. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
Shell commands in SKILL.md call:
npmFrom the folder's file list and the shell code blocks in SKILL.md.
Links to these hosts (documentation or services it may open):
a2ui.orggithub.comFrom URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
X Card loads about 2.1k tokens when it runs. Until then it costs about 31 tokens; SKILL.md has 316 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from kqcoxn/MaaPipelineEditor at commit bbfe0d0, republished under its MIT licence (© kqcoxn). 316 words, ~2,111 tokens.
.claude/skills/x-card/SKILL.md (or your agent's skills folder). This skill also uses 7 other files; get the full folder from GitHub.本技能覆盖 @ant-design/x-card —— A2UI 协议的 React 实现,使 AI Agent 能够通过结构化 JSON 命令流动态渲染富交互 UI。
覆盖范围:
XCard.Box + XCard.Card 组件用法createSurface、updateComponents、updateDataModel、deleteSurface范围说明:v0.9 是推荐协议,v0.8 仅为向后兼容保留——所有新功能请使用 v0.9。
| 包名 | 职责 |
|---|---|
@ant-design/x-card | A2UI 协议的 React 渲染器 —— XCard.Box、XCard.Card、Catalog API |
@ant-design/x | 聊天 UI 组件(Bubble、Sender 等)—— 本技能不涉及 |
@ant-design/x-sdk | 数据 Provider、流式处理 —— 本技能不涉及 |
npm install @ant-design/x-card导出内容:
import {
XCard,
registerCatalog,
loadCatalog,
validateComponent,
clearCatalogCache,
} from '@ant-design/x-card';
import type {
XAgentCommand_v0_9,
XAgentCommand_v0_8,
ActionPayload,
Catalog,
CatalogComponent,
} from '@ant-design/x-card';
// 子组件
XCard.Box; // 容器:接收命令,持有 Catalog 映射
XCard.Card; // 渲染器:按 id 渲染单个 SurfaceXCard.Box
├── 持有:catalogMap、surfaceCatalogMap
├── 分发:commands → 所有 XCard.Card 子组件
├── 汇聚:所有 Card 的 onAction 事件
└── XCard.Card (id="surface-a")
│ ├── 持有:组件树、数据模型、commandVersion
│ └── 处理:数据绑定解析、Action 触发
└── XCard.Card (id="surface-b")
└── ...interface BoxProps {
commands?: (XAgentCommand_v0_9 | XAgentCommand_v0_8)[];
/** 组件名称必须以大写字母开头 */
components?: Record<string, React.ComponentType<any>>;
onAction?: (payload: ActionPayload) => void;
children?: React.ReactNode; // 应包含 XCard.Card 元素
}interface CardProps {
id: string; // 要渲染的 surfaceId
}interface ActionPayload {
name: string; // 来自 action.event.name
surfaceId: string; // 触发动作的 Surface
/**
* 组件传递的上下文,已自动解析 path 引用
*
* 对于 action.event.context 中使用 { path: "xxx" } 格式的字段:
* - X-Card 会自动将其解析为 { value: "实际值" } 格式
* - 其他属性(如 label)会被保留
*
* 示例输入配置:
* { username: { path: "/form/username", label: "用户名" } }
*
* 示例解析后 context:
* { username: { value: "张三", label: "用户名" } }
*/
context: Record<string, any>;
}| 当你需要... | 优先阅读 |
|---|---|
| 配置 XCard.Box + XCard.Card | USAGE.md → 基础配置 |
| 从 Agent 发送命令到卡片 | COMMANDS.md |
| 注册自定义组件 Catalog | CATALOG.md → 本地 Catalog |
| 把组件属性绑定到实时数据 | DATA_BINDING.md |
| 处理用户交互/表单提交 | ACTIONS.md |
| 构建流式渐进 UI | USAGE.md → 流式渲染 |
| 从 v0.8 迁移到 v0.9 | COMMANDS.md → v0.8 vs v0.9 |
| 查询完整类型定义 | API.md |
XCard.Box 的 components prop 传入。XCard.Box 包裹,每个 Surface 对应一个 XCard.Card。XAgentCommand_v0_9[] 传入 commands prop(通常来自 Agent 流式响应)。onAction 中接收 ActionPayload,追加新命令作为响应。import React, { useState } from 'react';
import { XCard, registerCatalog } from '@ant-design/x-card';
import type { XAgentCommand_v0_9, ActionPayload, Catalog } from '@ant-design/x-card';
// 1. 定义并注册本地 Catalog
const myCatalog: Catalog = {
catalogId: 'local://my_catalog.json',
components: {
Text: {
type: 'object',
properties: { text: { type: 'string' }, variant: { type: 'string' } },
required: ['text'],
},
Button: {
type: 'object',
properties: { text: { type: 'string' }, action: {} },
required: ['text'],
},
},
};
registerCatalog(myCatalog);
// 2. 自定义组件实现
const Text: React.FC<{ text: string; variant?: string }> = ({ text, variant }) => (
<p className={`text-${variant ?? 'body'}`}>{text}</p>
);
const Button: React.FC<{ text: string; onAction?: (ctx: any) => void; action?: any }> = ({
text,
onAction,
action,
}) => <button onClick={() => onAction?.(action?.event?.context ?? {})}>{text}</button>;
// 3. 构建命令(来自 Agent 流)
const commands: XAgentCommand_v0_9[] = [
{
version: 'v0.9',
createSurface: {
surfaceId: 'welcome',
catalogId: 'local://my_catalog.json',
},
},
{
version: 'v0.9',
updateComponents: {
surfaceId: 'welcome',
components: [
{ id: 'root', component: 'Column', children: ['title', 'btn'] },
{ id: 'title', component: 'Text', text: { path: '/user/name' }, variant: 'h1' },
{
id: 'btn',
component: 'Button',
text: '开始',
action: { event: { name: 'start', context: {} } },
},
],
},
},
{
version: 'v0.9',
updateDataModel: {
surfaceId: 'welcome',
path: '/user/name',
value: 'Alice',
},
},
];
// 4. 渲染
export default function App() {
const [cmdQueue, setCmdQueue] = useState<XAgentCommand_v0_9[]>(commands);
const handleAction = (payload: ActionPayload) => {
console.log('Action:', payload.name, payload.context);
// 根据 Agent 响应追加新命令
setCmdQueue((prev) => [...prev /* 新命令 */]);
};
return (
<XCard.Box commands={cmdQueue} components={{ Text, Button }} onAction={handleAction}>
<XCard.Card id="welcome" />
</XCard.Box>
);
}"version": "v0.9" —— 缺少会导致协议拒绝。id: "root" 组件 —— 这是组件树的根节点。id 字符串引用。updateComponents 负责布局,updateDataModel 负责内容/状态。registerCatalog()。components map 传给 XCard.Box,而不是 XCard.Card —— Box 负责向所有 Card 分发。components 对象 —— 用 useMemo 或模块级常量保持稳定,避免不必要的重渲染。value: { path: "..." } 双向绑定 —— 字面量值不会更新数据模型。action.event.context 中的路径是写入目标 —— 它们指向用户输入数据在数据模型中的存储位置,不要作为读取来源解析。{ path: "xxx" } 转换为 { value: "实际值" } 格式。这适用于 v0.9(action.event.context = { key: { path } })和 v0.8(action.context = [{ key, value: { path } }])两种格式。action.context 是数组格式 —— [{ key, value: { path } }],与 v0.9 的对象格式 { key: { path } } 不同,混用会导致 action 数据丢失。| 场景 | 技能组合 |
|---|---|
| AI 对话 + 结构化卡片响应 | use-x-chat + x-components + x-card |
| 独立的 Agent 表单 UI | 仅 x-card |
| 流式 Markdown + 卡片侧边栏 | x-markdown + x-card |
| HTTP 流式 Agent 数据注入卡片 | x-request → 将响应作为命令传入 |
© kqcoxn, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 7 other files in .agents/skills/ant-design-x/skills/x-card of kqcoxn/MaaPipelineEditor.
Open the folder on GitHubat commit bbfe0d0
X Card next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| X Card this skillkqcoxn/MaaPipelineEditor | 408 | — | ~2.1k | Automated safety check: Pass | MIT | |
| LobeHub Interactive Prototypelobehub/lobehub | 83k | — | ~1.6k | Automated safety check: Pass | Custom licence | |
| Version ReleaseNG-ZORRO/ng-zorro-antd | 9.2k | — | ~3.1k | Automated safety check: Pass | MIT | |
| Ant Design Mobile Releaseant-design/ant-design-mobile | 12k | — | ~497 | Automated safety check: Pass | MIT | |
| Lobe Designlobehub/lobe-ui | 2.2k | — | ~2.2k | Automated safety check: Pass | MIT | |
| Feature SyncNG-ZORRO/ng-zorro-antd | 9.2k | — | ~840 | Automated safety check: Pass | MIT |
lobehub/lobehub
Builds single-file interactive HTML prototypes rendered with the real LobeHub UI components and written as production-style React, so they can later be split into files.
NG-ZORRO/ng-zorro-antd
NG-ZORRO/ng-zorro-antd repository release workflow. An agent skill from NG-ZORRO/ng-zorro-antd.
ant-design/ant-design-mobile
Prepares an npm release of ant-design-mobile up to the version commit, then tags and publishes the GitHub Release after you run the publish command yourself.
lobehub/lobe-ui
Build UI with the LobeHub design system — @lobehub/ui/base-ui, the controlled form at @lobehub/ui/base-ui/form, and the chat, mobile, dashboard, awesome, brand, mdx, and i18n namespaces, plus…
NG-ZORRO/ng-zorro-antd
Sync an Ant Design React component or feature into NG-ZORRO.
lazzyfu/goInsight
Build, refactor, or review production-grade admin interfaces with Vue 3 + JavaScript + Ant Design Vue 4.x.
kqcoxn/MaaPipelineEditor
Decision guide for antd 6.x, Ant Design Pro 5/ProComponents, Ant Design X v2, and the offline @ant-design/cli.
kqcoxn/MaaPipelineEditor
MaaFramework 开发与集成指南。当任务涉及 MaaFramework 项目结构、Pipeline 协议、ProjectInterface V2 协议、自定义识别/动作(Custom/Agent)、Python/NodeJS/CSharp 等语言 Binding 集成、控制器配置、回调协议或运行时行为时使用。
kqcoxn/MaaPipelineEditor
为 MPE 桌面端策划、生成或修改版本主题背景图,复用机械动力牛牛与章鱼猫的定稿形象;也用于维护这两个角色的设定与三视图。不用于普通界面样式修改或无关插画。
kqcoxn/MaaPipelineEditor
专注讲解如何使用 useXChat Hook,包括自定义 Provider 的集成、消息管理、错误处理、多会话管理等. An agent skill from kqcoxn/MaaPipelineEditor.
kqcoxn/MaaPipelineEditor
专注于自定义 Chat Provider 的实现,帮助将任意流式接口适配为 Ant Design X 标准格式. An agent skill from kqcoxn/MaaPipelineEditor.
kqcoxn/MaaPipelineEditor
使用 @ant-design/x 组件库构建 AI 对话 UI 时使用 —— 涵盖 Bubble、Sender、Conversations、Prompts、ThoughtChain、Actions、Welcome、Attachments、Sources、Suggestion、Think、FileCard、CodeHighlighter、Mermaid、Folder、XProvider 和…
Works with
当需要用 @ant-design/x-card 让 AI Agent 动态渲染富交互 UI 时使用——涵盖 XCard.Box、XCard.Card、A2UI v0.9 命令、数据绑定、Catalog、Actions 和流式渲染模式。. X Card is an agent skill from kqcoxn/MaaPipelineEditor.
Run `npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a claude-code`. Or copy the skill folder (.agents/skills/ant-design-x/skills/x-card in kqcoxn/MaaPipelineEditor) into .claude/skills/x-card in your project. Claude Code loads it when a task matches its description.
Run `npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a codex`. Or copy the skill folder (.agents/skills/ant-design-x/skills/x-card in kqcoxn/MaaPipelineEditor) into .agents/skills/x-card in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add kqcoxn/MaaPipelineEditor --skill x-card -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/x-card, .gemini/skills/x-card, .github/skills/x-card and .opencode/skills/x-card in your project.
Going by SKILL.md and its folder, X Card needs the command-line tools its instructions call (npm). Our summary lists: Node.js.
SKILL.md names 2 domains. As links in the text: a2ui.org and github.com. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
X Card is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 2.1k tokens (SKILL.md is roughly 8.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.
Skills that share tags, products or a category with X Card: LobeHub Interactive Prototype (lobehub/lobehub, 83k stars), Version Release (NG-ZORRO/ng-zorro-antd, 9.2k stars), Ant Design Mobile Release (ant-design/ant-design-mobile, 12k stars) and Lobe Design (lobehub/lobe-ui, 2.2k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
kqcoxn (a GitHub user) maintains it in kqcoxn/MaaPipelineEditor, which has 408 GitHub stars. The repository holds 12 skills in this directory. The repository was last updated on October 9, 2026.
Source: kqcoxn/MaaPipelineEditor on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.