Computed styles and box of an element
qa_stylesReads an element's computed CSS styles, pixel box, and in-scope design tokens via snapshot ref or selector so you can compare a built page against its design without screenshots.
Instructions
The COMPUTED styles of one element — colour, type, spacing, border, shadow, layout — plus its box in CSS pixels, and the CSS custom properties (design tokens) in scope for it. This is how you check a built page against a design: it answers "this button renders #3B82F6 at 15px with 22px padding" without a screenshot and without measuring anything by eye. Target it by a qa_snapshot ref (preferred) or a CSS selector. Read-only and executes NOTHING: the property list is fixed in the extension, so you name an element, never a program. Pair it with a design source (a Figma file, a token JSON) to report the diff, and with qa_spotlight to show the human which element you mean.
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": "qa_styles"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | No | A ref from qa_snapshot (e.g. "e12") — preferred over selector | |
| tabId | No | Target tab (from qa_tabs); omit for the active tab | |
| tokens | No | Include the CSS custom properties in scope (default true) | |
| frameId | No | Which frame to ask, from qa_frames. Omit for the page itself. A payment form, an SSO step or an embedded widget usually lives in a frame of its own, and a cross-origin one can only be read from inside it. | |
| selector | No | CSS selector of the element |