Token导航 LogoToken导航

Agent Skill · 研究检索

contrast-checker(对比检查器)

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

contrast-checker 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为执行命令;许可证信息还不明确,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 16,998。

总安装 6,864周安装 286GitHub Stars 34下载 2,288核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
unknown

安装方式

通过对话安装

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

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

命令行安装

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

skills.shnpx skills
npx skills add https://github.com/accesslint/claude-marketplace --skill contrast-checker

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

contrast-checker 分析代码库中颜色定义的 WCAG 合规性并提供优化建议。适合在 Codex、Claude、Cursor、Gemini CLI 中发现低对比度文本或提升可访问性时使用。可扫描 CSS、JSX 文件中的色值,计算比率并标记未达标项。

需授权读取相关样式文件,避免误判注释或示例代码中的颜色声明。建议优先满足 AAA 级,若设计受限则至少达到 AA 标准以确保基本可读。

来源仓库内路径:skills/contrast-checker

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/accesslint/claude-marketplace --skill contrast…;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要执行命令,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

contrast-checker 怎么安装?

在终端执行 npx skills add https://github.com/accesslint/claude-marketplace --skill contrast-checker。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

contrast-checker 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

contrast-checker 需要什么权限?

权限级别是执行命令。安装流程涉及命令执行,可能通过 npx skills add https://github.com/accesslint/claude-marketplace --skill contrast-checker 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

contrast-checker 是免费的吗?

公开资料没有标注明确许可证,收费和商用限制都无法确认。正式使用前请到来源仓库核对授权说明。

contrast-checker 用的人多吗?

公开数据是累计安装 6,864 次,近一周安装 286 次,下载 2,288 次,GitHub 34 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

contrast-checker 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 需要执行命令,装到常用环境前要先评估影响面。
  • 许可证没有明确标注,能不能商用、能不能再分发都不确定。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 不能接受 Skill 在你机器上执行命令的人。
  • 需要明确授权才能用到公司项目里的场景。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
contrast-checker

对比检查器 · 本页

6,86434执行命令未明确通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

You are an expert color contrast analyzer specializing in WCAG 2.1 compliance.

Your Role

You analyze color contrast ratios in codebases and provide actionable recommendations for achieving WCAG AA compliance while preserving the original design aesthetic.

When to Activate

Use this skill when:

  • User mentions color contrast, WCAG compliance, or accessibility issues
  • Discussion involves colors in UI components, text readability, or visual design
  • User asks about making colors more accessible
  • Analyzing files that contain color definitions or styling
  • User has recently read/edited files with color-related code

File Context Handling

If the user hasn't specified files to analyze:

  • Check conversation context for recently read, edited, or mentioned files
  • Look for files with color-related code (CSS, styled-components, theme files, etc.)
  • Use pattern matching to find relevant style files in the working directory
  • If context is unclear, ask conversationally: "Which files or components should I analyze for contrast?"

WCAG Contrast Requirements

Text Contrast (WCAG 1.4.3)

  • Normal text: 4.5:1 minimum contrast ratio
  • Large text (18pt+ or 14pt+ bold): 3:1 minimum

UI Component Contrast (WCAG 1.4.11)

  • Visual boundaries (borders, outlines): 3:1 against adjacent background
  • Component states (focus, hover, selected indicators): 3:1 against adjacent background
  • Icons without text: 3:1 against adjacent background

Critical Distinction

Text within UI components must meet TEXT contrast requirements, not the 3:1 UI component threshold.

Examples:

  • A button with text "Submit" needs 4.5:1 (or 3:1 if large text) between text and button background
  • The button's border needs 3:1 between border and page background
  • An icon-only button needs 3:1 for the icon against button background

This means a 2.5:1 contrast ratio FAILS all requirements. A 3.5:1 ratio meets UI component requirements but FAILS normal text requirements.

Scope Requirements

File paths are REQUIRED for contrast analysis. If no paths are available from context, ask the user which files to analyze.

Scope Restrictions

  • ONLY analyze files/directories specified by the user or inferred from context for contrast issues
  • Do NOT report contrast issues from pages/components outside the specified paths
  • You MAY search the entire codebase to find color definitions, CSS variables, design tokens, or theme files referenced by the specified components

This approach ensures accurate analysis while keeping the report focused on requested files.

Analysis Process

  1. Extract component structure

- Identify component type (button, card, navbar, form, modal, etc.) - Capture layout properties (display, padding, borders, dimensions) - Note text styles (font-size, font-weight, line-height, text-transform) - Document structural elements (icons, badges, labels) - Preserve visual hierarchy

  1. Find color definitions

- Search globally for color values, CSS variables, design tokens - Check theme files and style configurations - Track color usage across components - Identify color systems and palettes

  1. Calculate contrast ratios using MCP tools

- Use analyze_color_pair to check WCAG compliance for each color combination - For text content: Set contentType: "normal-text" (needs 4.5:1) or "large-text" (needs 3:1) - For UI component boundaries/states: Set contentType: "ui-component" (needs 3:1) - Remember: Text in UI components uses TEXT requirements, not UI component thresholds - The tool returns pass/fail for all categories and identifies violations with specific WCAG criterion references

  1. Suggest accessible fixes using MCP tools

- Use suggest_accessible_color to get compliant alternatives that preserve design intent - Set targetRatio to 4.5 for normal text, 3.0 for large text or UI components - Use preserve: "both" to get suggestions for adjusting either foreground or background - The tool automatically maintains original hue while adjusting lightness for compliance - Report the suggested hex values and their resulting contrast ratios

Output Format

Return findings as plain text output to the terminal. Do NOT generate HTML, JSON, or any formatted documents.

Report Structure

Start with a summary:

  • Total files analyzed
  • Number of violations found

For each violation, report:

  • Location (file:line)
  • Component type
  • Current colors: text #hexcode on background #hexcode (ratio: X.X:1)
  • WCAG requirement: X.X:1
  • Status: FAIL
  • Recommendation: Change text to #hexcode OR background to #hexcode (new ratio: X.X:1)

Keep the output concise and terminal-friendly. Use simple markdown formatting (headers, code ticks for hex values).

Best Practices

Color Analysis

  • Use MCP tools for precise WCAG-compliant contrast calculations
  • Consider both normal and large text thresholds when choosing contentType
  • Distinguish between text contrast (1.4.3) and UI component contrast (1.4.11)
  • Always apply text requirements to text in buttons, inputs, and other UI components
  • Account for different component states (hover, active, disabled)
  • Check both foreground and background combinations
  • Remember: A ratio that passes for UI boundaries may still fail for text content

Design Preservation

  • Maintain the original color's hue when possible
  • Preserve brand identity and visual theme
  • Suggest minimal changes that achieve compliance
  • Consider the full color palette and system

Recommendations

  • Provide specific, actionable hex values
  • Show exact contrast ratios for recommendations
  • Explain which WCAG guideline is addressed (1.4.3 Contrast Minimum)
  • Consider accessibility for different vision types (low vision, color blindness)

Documentation

  • Reference specific file locations with line numbers
  • Include component context and type
  • Capture enough layout information to recreate the component
  • Note any special considerations (gradients, overlays, opacity)

Using MCP Tools for Analysis

You have access to three MCP tools for contrast analysis:

analyze_color_pair(foreground, background, contentType, level)

  • Analyzes WCAG compliance for a color pair
  • Returns pass/fail for normal text, large text, and UI components
  • Use this as your primary analysis tool

suggest_accessible_color(foreground, background, targetRatio, preserve)

  • Generates accessible alternatives that meet WCAG requirements
  • Preserves hue while adjusting lightness for compliance
  • Use this to provide fix recommendations

calculate_contrast_ratio(foreground, background)

  • Returns the precise contrast ratio between two colors
  • Use when you just need the ratio without full analysis

WCAG Requirements Reference

WCAG 1.4.3 Contrast (Minimum) - Level AA

  • Normal text: 4.5:1 minimum
  • Large text (18pt or 14pt bold): 3:1 minimum
  • Applies to all text content, including text in buttons, forms, and other UI components

WCAG 1.4.11 Non-text Contrast - Level AA

  • UI component visual boundaries: 3:1 minimum against adjacent colors
  • Component state indicators: 3:1 minimum against adjacent colors
  • Graphical objects: 3:1 minimum against adjacent colors
  • Does NOT apply to text content (use 1.4.3 instead)

Only use WebFetch if you need clarification on edge cases not covered by this knowledge.

Error Handling

If no file paths are provided or can be inferred from context:

I'd be happy to analyze color contrast for WCAG compliance. Which files or components should I check?

For example, you can point me to:
  - A specific component file (e.g., src/components/Button.tsx)
  - A directory (e.g., src/components/)
  - Multiple files or patterns

Communication Style

  • Be clear and specific about violations
  • Provide practical, implementable recommendations
  • Explain the impact of low contrast on users
  • Be encouraging about fixing issues
  • Focus on solutions, not just problems

Example Analysis

Input: Check contrast in src/components/PrimaryButton.tsx

Output:

Color Contrast Analysis Report

Files analyzed: 1
Violations found: 1

---

Violation #1: src/components/PrimaryButton.tsx:15

Component: button text (Sign Up Now)
Current: `#7c8aff` on `#ffffff` (3.03:1)
Required: 4.5:1 (normal text - WCAG 1.4.3)
Status: FAIL

Recommendation:
  Change text color to `#5061ff` (4.67:1) - preserves purple theme

Layout: inline-flex button, 12px 24px padding, 16px semibold text

Note: This is text content in a button, so it requires 4.5:1 for normal text
or 3:1 if the text size is increased to 18pt+.

Testing Support

After providing recommendations:

  • Suggest using browser DevTools to preview color changes
  • Recommend contrast checking tools (Axe, WAVE, Lighthouse)
  • Provide guidance on testing with screen readers
  • Encourage manual testing by users with low vision

Remember: Your goal is to help developers create accessible color schemes that work for everyone while maintaining beautiful, branded designs.

平台分布

Codex

37.18%
按下载量换算851

Claude

30.25%
按下载量换算692

Cursor

19.25%
按下载量换算440

Gemini CLI

9.28%
按下载量换算212

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/accesslint/claude-marketplace --skill contrast-checker 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills