CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

design-qe

Design QA for a web page against its design system. Measures, in a real browser, whether rendered colours, type and spacing match the design tokens (DESIGN.md, W3C/Tokens Studio JSON, Figma variables, CSS variables); finds overflow, clipped text and sideways scrolling at each screen width; compares screenshots with approved baselines; runs axe-core accessibility and contrast checks; then adds a clearly labelled opinion pass against DESIGN.md. Use when asked to check a UI against its design, run visual or design QA, check breakpoints, compare screenshots, or audit a page against DESIGN.md or Figma tokens.

Quality

95%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Medium

Suggest reviewing before use

SKILL.md
Quality
Evals
Security

design-qe

Five checks. Four are measured in the browser; one is opinion. The report keeps them apart, and any check that could not run says NOT measured and why. Never fill a gap with a guess, and never report a NOT measured check as a pass.

#CheckKind
1Token conformance: rendered colour, font size, family, weight, spacing, radius vs the tokensMeasured
2Breakpoints: sideways scroll, text cut off or spilling, chart labels past the edgeMeasured
3Screenshot baselines: pixel diff against approved screenshotsMeasured
4Accessibility: axe-core rules plus measured text contrastMeasured
5Judgement pass: screenshots compared with what DESIGN.md asks forOpinion

All commands below run from the project being tested. $DQE means node <this skill folder>/scripts/dqe.mjs. Needs Node 20 or newer; no install step.

Browser

Use the browser the host gives you. The skill needs four abilities: run JavaScript in the page and get the result back, save a screenshot of the visible window to a file, resize the window, and move the pointer. How each host provides them is in references/browser-adapters.md. If the host lacks one, the checks that depend on it are NOT measured; say so in the report.

Run

  1. Do not ask the user for files. init finds the design sources itself: DESIGN.md (root, docs/, design/; YAML-frontmatter and table styles), token JSON (tokens.json, design-tokens.json, tokens/*.json; W3C or Tokens Studio format) and light-theme CSS variables in the usual global stylesheets (app/globals.css, src/index.css, ...). It also reads the dev server's port from package.json. Only if a Figma MCP server is connected and the user mentions Figma: call its variable tool (e.g. get_variable_defs) on the relevant frame, save the output as tokens/figma.json, and it will be picked up. Before starting a dev server, check the project's CLAUDE.md or PROJECT_STATE.md for rules about which database it may reach.

  2. Start the run from the project root:

    $DQE init [--path /pricing] [--widths 375,768,1280] [--mask ".clock,.avatar"] [--browser "<host browser name>"]

    Defaults: the home page, widths 375, 768 and 1280. If no dev server is answering, init says how to start it. --url, --design and --tokens override discovery when the user names something specific. Read the printed summary back to the user: which sources were used, and any kind with 0 values (e.g. no spacing tokens), which will be NOT measured. Conflicts between sources are listed too. Leave out --include-text unless the user asks: it copies page text into the findings, and pages can hold personal or patient data.

  3. Start the local server in the background: $DQE serve (port 8787; change with --port, on both init and serve). It serves the in-page script, saves results, and hosts the comparison page.

  4. Prepare the browser.

    • Resize the window to 1440x900 (or at least the largest width + 40px). Use the same size every run; baselines only compare against captures taken at the same window size.
    • Open the page in a new tab.
    • Load the checks. On a localhost page run:
      await new Promise((resolve, reject) => { const s = document.createElement('script'); s.src = 'http://localhost:8787/inject.js'; s.onload = resolve; s.onerror = () => reject(new Error('blocked')); document.head.appendChild(s); }); window.__dqe.info()
      If that is blocked, or the page is not on localhost, read <run folder>/inject.js and pass its whole content as the JavaScript to run. The result shows the run id and token counts.
    • Public (non-localhost) pages only: run window.__dqe.connect(), take a screenshot, and click the "Connect design-qe" button it shows, once per run. That opens a local receiver tab, so results save straight to the run folder instead of passing through the conversation. Browsers only allow that tab after a real click. Then switch back to the page's tab.
  5. For each width, in this order:

    1. await window.__dqe.openFrame(<width>). It returns ok, captureArgs and where to park the pointer. If ok is false, see "When a step fails" below.
    2. await window.__dqe.audit() then await window.__dqe.accessibility(). When saving works (localhost page, or a connected receiver) only a summary comes back. Otherwise the full JSON comes back with a saveNote; write it to the run folder as the file named there.
    3. Take a screenshot as its own call (this refreshes the pointer coordinates), then move the pointer to the bottom-right corner of the window as its own call.
    4. Take the capture: a screenshot saved to disk at full scale (in Claude in Chrome: save_to_disk: true, scale: 1). Smaller scales shrink the saved file and break comparisons.
    5. Register it: $DQE capture <captureArgs> --file <saved path>.
  6. Compare screenshots. Open http://localhost:8787/compare in a tab. When window.__dqeVisual.done is true, read window.__dqeVisual.summary. Results and diff images are saved in the run folder. Screens without an approved baseline say "No baseline"; that is expected on a first run.

  7. Judgement pass. Follow references/judgement-template.md and write <run folder>/judgement.md. Look at the captures; quote DESIGN.md. Do not repeat measured findings, and do not state an opinion as a measurement.

  8. Report. $DQE report writes <run folder>/report.md. Give the user: the counts per check, the most important measured problems, every NOT measured item with its reason, and then the opinion points, labelled as opinion. Offer the comparison page link for the screenshots.

  9. Baselines need the user's yes. Never approve on your own. Show the captures (or the comparison page), ask, and only then run $DQE approve --key <page>-<width> or $DQE approve --all.

  10. Clean up. window.__dqe.close(), close the tabs you opened, stop the server.

When a step fails

  • openFrame says the site blocks frames: call window.__dqe.useWindow() instead, after resizing the window so the page is the width you want (wait a second after resizing). Windows cannot go below about 500px, so record narrower widths as $DQE capture --width <w> --failed "site blocks frames; window cannot be made <w>px wide".
  • openFrame says the window is too narrow: resize it and retry.
  • Accessibility returns NOT_MEASURED: the page's security policy blocked axe-core. Keep the result; the report shows the reason.
  • Screenshot could not be saved: $DQE capture --width <w> --failed "<what happened>".
  • A value in a result reads [BLOCKED: ...]: the browser tool hid it. Leave it; do not reconstruct it.
  • Anything else fails twice: stop and tell the user what failed.

What it does not check

Hover, focus and open states unless set up before capturing; content below the first screen unless extra scroll positions are captured; line height, letter spacing, shadows, borders widths and motion; touch input and device pixel ratio (frame mode changes width only). The report lists these too.

Repository

bencium/bencium-marketplace

Path

design-qe/skills/design-qe/SKILL.md

Last updated
First committed

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.