analyze_contrast
Check WCAG contrast between two hex colors and determine pass or fail for normal and large text sizes. Use foreground, background, font size, and weight inputs.
Instructions
Calculate WCAG contrast for two opaque hex colors and normal/large text thresholds.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"foreground": "<foreground>",
"background": "<background>"
},
"name": "analyze_contrast"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fontPx | No | ||
| weight | No | ||
| background | Yes | ||
| foreground | Yes |