pn-audit-layout

pn-audit-layout is a command for Claude Code, Cursor from perniemann/pnCore. It costs 35 tokens per session (519 once invoked), scanned A, original, MIT.

A review of a website’s layout, including spacing, grids, repeated component sizes, vertical rhythm, and behavior at different screen widths.

In plain words
What is it for?
Use it to inspect pages and layout components without changing their fonts or colors.
Why use it?
It finds inconsistent spacing and responsive layout problems that make pages feel disjointed or difficult to use.

Command for Claude CodeCursor

Written for Cursor and Claude Code: shipped in a Cursor plugin, but also a Claude Code command (commands/*.md).

Part of the pn-core plugin — 133 skills, 19 commands, 9 agents, 1 MCP server shipped together

Good fit Use it to inspect pages and layout components without changing their fonts or colors.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/perniemann/pncore/pn-audit-layout
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/perniemann/pnCore

Made for: Claude Code, Cursor.

Or install pn-core, the plugin that ships this one along with the rest of its 133 skills, 19 commands, 9 agents, 1 MCP server.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for pn-audit-layout

README.md
[![agentmods](https://agentmods.dev/badge/commands/perniemann/pncore/pn-audit-layout.svg)](https://agentmods.dev/commands/perniemann/pncore/pn-audit-layout)
Your own site
<a href="https://agentmods.dev/commands/perniemann/pncore/pn-audit-layout"><img src="https://agentmods.dev/badge/commands/perniemann/pncore/pn-audit-layout.svg" alt="Measured on agentmods" height="20"></a>
Per session 35 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 519 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00035 $0.00519
Opus 5 $0.00017 $0.00260
Sonnet 5 $0.00007 $0.00104
Haiku 4.5 $0.00003 $0.00052

Measured 7d ago against content hash bc92f8c7eeaa, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

pn-audit-layout scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 7d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

packages/pn-core-mcp/content/commands/pn-audit-layout.md · 63 lines

What it actually says

pn-audit-layout

Start every response with: [pn-command] 🔺

Advanced (palette-hidden). Not in the / slash palette. Invoked by the /pn-frontend-audit umbrella, or directly via get_command("pn-audit-layout").

Focused layout pass: audit spacing tokens, grid usage, component rhythm, and responsive breakpoints. No typography changes (use pn-audit-typography), no color changes (use pn-colorize) — layout only.

Flow

1. Context

Check .pncore-stack.md and target scope. Ask if unclear: "Which pages or layout components should I audit?"

2. Audit

Load get_skill("pn-frontend-design-philosophy") for the layout scoring rubric (Phase 3).

Spacing tokens:

  • Is there a consistent spacing scale (e.g. 4px or 8px grid)?
  • Are arbitrary pixel values used instead of tokens?
  • Do padding/margin values match the scale?

Grid system:

  • Is a grid defined (CSS Grid / Flexbox layout container)?
  • Are columns consistent across similar content types?
  • Do full-bleed sections align to the defined max-width?

Component rhythm:

  • Do card / list item sizes match?
  • Is vertical rhythm consistent (equal spacing between sections)?
  • No "identical card grids with zero variation" anti-pattern?

Responsive behavior:

  • Breakpoints defined in tokens / CSS variables?
  • Mobile-first or correct media query order?
  • Content reflow tested at 360px, 768px, 1440px?

Output: numbered issues table (location | issue | severity | suggested fix). Save to docs/audits/.

Gate: Present issues for triage. Apply fixes after confirmation.

3. Fix

Apply in severity order:

  • Arbitrary values → replace with nearest token
  • Missing grid container → add layout wrapper with defined columns
  • Broken mobile layout → add responsive breakpoints

4. Summary

Table: issues found → issues fixed. Ref pn-arrange for visual arrangement refinement.

Skills to use

  • pn-frontend-design-philosophy — Phase 3 scoring rubric (Layout + CSS System Audit)
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 7d ago First seen · 63 lines · 35 tokens per session scan A bc92f8c7eeaa

Subscribe to this mod's changes

pn-audit-layout is a command published in the GitHub repository perniemann/pnCore (0 stars, last pushed yesterday), licensed MIT. It adds 35 tokens to every session and 519 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.