Skip to main content
Glama

check_css_vars

Validates CSS custom property usage in web components. Catches unknown properties with typo suggestions and !important on design tokens.

Instructions

Validates consumer CSS for custom property usage against a component CEM — catches unknown CSS custom properties with typo suggestions, and !important on design tokens (anti-pattern). Run this on any CSS that sets component-scoped custom properties.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
libraryIdNoOptional library ID to target a specific loaded library instead of the default.
cssTextYesThe CSS code to validate for custom property usage.
tagNameYesThe custom element tag name to validate against (e.g. "sl-button").
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries full burden. It discloses the tool catches unknown custom properties with typo suggestions and flags !important on design tokens as an anti-pattern. It implies a non-destructive validation but doesn't detail side effects or permissions. Still, it adequately describes the tool's behavioral traits.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is two sentences, each earning its place: the first conveys purpose and key features, the second provides usage context. No superfluous words or repetition. Highly efficient and front-loaded.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

The tool has no output schema, but the description is sufficient for an agent to understand its purpose, inputs, and when to apply it. It covers the core functionality and usage context. While it doesn't specify return format, the validation nature implies a report of issues. Given the tool complexity and sibling count, the description is adequately complete.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so baseline is 3. The description does not add additional meaning beyond the schema; it mentions 'consumer CSS' and 'component CEM' but doesn't elaborate on parameter details. The schema already adequately documents the three parameters, so the description meets the minimum viable standard.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool validates CSS for custom property usage against a component CEM, catching unknown properties with typo suggestions and detecting !important on design tokens. It specifies the input (consumer CSS setting component-scoped custom properties) and distinguishes itself from sibling tools like check_css_scope or check_css_shorthand by focusing on custom properties.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly advises when to run this tool: 'Run this on any CSS that sets component-scoped custom properties.' It provides clear context but does not explicitly state when not to use it or mention alternative tools. However, the guidance is sufficient for correct usage.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/bookedsolidtech/helixir'

If you have feedback or need assistance with the MCP directory API, please join our Discord server