Token导航 LogoToken导航TokenDH.com
AI 工具external-servicegithub未标认证来源可访问clear审计通过

resource-design资源设计

Agent Skill

用于辅助界面设计、视觉规范、排版、配色、布局和交互体验优化。它适合让 Agent 根据产品场景整理页面结构、生成 UI 方案、检查视觉一致性或改进组件层级。使用时需要结合现有品牌、设计系统和用户任务,不应只堆装饰元素;涉及真实页面改动时,应通过截图或浏览器预览检查文本溢出、对齐和响应式表现。

总安装

667

周安装

27

GitHub Stars

公开资料未说明

下载量

210
CodexClaudeCursorGemini CLI

安装说明

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

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/xmcp-dev/skills --skill resource-design

简介

辅助界面设计、视觉规范和布局优化。适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

  • 适合生成 UI 方案、检查视觉一致性。
  • 通过 npx skills add 命令从指定仓库安装并使用。
  • 需结合现有品牌和设计系统使用,注意响应式表现。
  • resource-design 属于AI 工具类 Skill,可作为该场景下的辅助能力补充。

SKILL.md

Create xmcp Resource

You are helping the user create a new xmcp resource. Follow this interactive workflow.

Step 1: Gather Information

Before generating any code, ask the user these questions using AskUserQuestion:

  1. Resource name (if not provided): What should the resource be named? (Use kebab-case)
  2. Resource type: Ask which type of resource they need:

- Static - Fixed content that doesn't change (configuration, documentation) - Dynamic - Content that depends on parameters (user profiles, reports) - File-based - Content read from files (logs, data files)

  1. URI pattern: How should the resource be accessed?

- Simple: config://app or docs://readme - With parameters: users://[userId]/profile - Nested: reports://[year]/[month]/summary

  1. Content details:

- What is the content about?

  1. Widget support (optional): Ask if they need OpenAI widget rendering.

Step 2: Generate the Resource

Create the resource file in src/resources/ following the routing conventions:

File Location & Routing

Resources use file-based routing similar to Next.js:

src/resources/
├── (config)/              # Route group (not in URI)
│   └── app.ts            # → config://app
├── (users)/
│   └── [userId]/         # Dynamic segment
│       └── profile.ts    # → users://[userId]/profile
└── docs/
    └── readme.ts         # → docs://readme

Routing conventions:

  • (folder) - Route group, excluded from URI path
  • [param] - Dynamic parameter segment
  • Filename becomes the final URI segment

Resource Structure Reference

Every xmcp resource has two main exports:

// 1. Metadata (optional) - Resource configuration
export const metadata: ResourceMetadata = { /* ... */ };

// 2. Handler (required) - Default export function
export default function handler(params?) { /* ... */ }

// 3. Schema (optional) - For dynamic resources with parameters
export const schema = { /* ... */ };

Quick Reference

Essential Imports

import { type ResourceMetadata } from "xmcp";

// For dynamic resources
import { z } from "zod";
import { type InferSchema, type ResourceMetadata } from "xmcp";

Metadata Fields

FieldTypeRequiredDescription
namestringNo*Unique resource identifier
titlestringNoHuman-readable title
descriptionstringNoWhat this resource provides
mimeTypestringNoContent type (default: text/plain)
sizenumberNoContent size in bytes
_metaobjectNoVendor extensions (OpenAI, etc.)

*When metadata is omitted, xmcp uses the filename as the resource name.

Handler Return Types

Return TypeUse Case
stringSimple text content
{text: string}Explicit text content
{blob: Uint8Array, mimeType: string}Binary content
JSON.stringify(data)JSON content

Detailed Templates

For complete code templates including:

  • Static resource patterns
  • Dynamic resource with parameters
  • File-based resources
  • Nested routing examples
  • OpenAI metadata examples

Read: references/patterns.md


Checklist After Generation

  1. File created in correct src/resources/ location
  2. If using metadata, ensure it has descriptive name and description
  3. Schema uses .describe() for all parameters (if dynamic)
  4. Handler returns appropriate content type
  5. File path matches intended URI pattern

Suggest running pnpm build to verify the resource compiles correctly.

适合场景

01

用户想查找某类 Agent Skill 时

02

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

03

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

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

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

能力 4

补充不同宿主或平台的使用分布数据

能力 5

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

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

平台分布

Antigravity

29.48%
按下载量换算62

Cursor

21.55%
按下载量换算45

Gemini CLI

16.03%
按下载量换算34

OpenCode

11.37%
按下载量换算24

Claude Code

8.45%
按下载量换算18

windsurf

3.6%
按下载量换算8

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

external-service

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

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills