audit_layout
Diagnose visual rhythm issues in rendered pages by capturing element geometry with a DevTools snippet and receiving alignment, gap-rhythm, and optical-balance scores.
Instructions
Evaluate visual rhythm from a rendered page's geometry. Call with no arguments to get a DevTools snippet to paste into your page — it prints {elements, viewport} JSON. Call again with that JSON to get alignment, gap-rhythm, and optical-balance scores. This is the complement to audit_page for things only visible once rendered.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "audit_layout"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| elements | No | Array of element rects captured from the rendered page via the DevTools snippet | |
| viewport | No | Viewport dimensions {w,h} at capture time |