Skip to main content
Glama

a11y-toolkit: prefers-reduced-motion honored?

a11y_reduced_motion
Read-onlyIdempotent

Tests whether a site honors prefers-reduced-motion by counting looping CSS animations before and after emulation, flagging pages that ignore the user preference.

Instructions

Does the site HONOR prefers-reduced-motion? Loads the page normally, counts looping CSS animations (>0.15s infinite), then reloads emulating prefers-reduced-motion: reduce and counts again. If the number does not drop, the site ignores the user's preference (2.2.2; 2.3.3 AAA). Nobody else automates this — axe leaves it as manual review. Covers CSS animations and video[autoplay]; JS/WebGL/scroll-parallax remain manual. Returns JSON: {mode, normal, reduced, respects, score, findings, limits}.

Input Schema

NameRequiredDescriptionDefault
urlYesPage URL to test
langNooutput language
browserNoBrowser engine (auto = detect the first available)
timeoutNopage load timeout seconds (45 default)
auth_stateNoPath to a Playwright storage_state JSON (exported session) to test behind login — stays local

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv5.9.0

TDQS

A4.4/5.0
Behavior5/5

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

With readOnlyHint/idempotentHint already declaring the safe-read profile, the description adds real behavioral detail: the two-pass reload methodology, the specific animation threshold (>0.15s infinite), the video[autoplay] coverage, and the honest limits. That is exactly the context annotations cannot carry.

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

Conciseness4/5

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

Front-loads the core question, then method, then scope limits, then return shape — a good information hierarchy. Mild deduction: 'Nobody else automates this' is marketing filler that does not help an agent invoke the tool.

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

Completeness5/5

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

No output schema exists, yet the description enumerates the return keys ({mode, normal, reduced, respects, score, findings, limits}), covers the manual-review boundaries, and already reflects the safety annotations. An agent has everything needed to call and interpret it.

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 url, lang, browser, timeout, and auth_state are already documented in the schema, including that auth_state stays local. The description adds no syntax or format detail beyond that, so baseline 3 applies.

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?

States a specific, testable verb+resource: it checks whether a site HONORS prefers-reduced-motion, and spells out the exact method (load, count looping animations, reload with reduce, recount). This is unmistakably distinct from siblings like a11y_forced_colors or a11y_reflow.

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?

Gives clear context — WCAG 2.2.2 / 2.3.3 AAA — and explicitly notes the alternative gap ('axe leaves it as manual review'), plus what remains manual (JS/WebGL/scroll-parallax). It stops short of explicit when-not-to-use framing, but a caller can infer scope well.

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