plugins/harness-powers/skills/harness-frontend/SKILL.md
Use this skill for tasks that produce user-facing interfaces: landing pages, marketing sites, dashboards, admin tools, web apps, prototypes, components, forms, or any HTML/CSS/JSX/Vue output users will see. Trigger even if the user doesn’t say “design” (e.g. “build a page”, “make a dashboard”, “create a form”, “scaffold UI”, “polish this”, “convert Figma”, or UI screenshots). Applies to both new builds and redesigns. In repository work, this is a frontend specialization layered under `harness-brainstorm`, `harness-feat`, or `harness-fix`, not a replacement for lifecycle ownership. The workflow is opinionated and taste-driven: identify surface type, run quick structured option selection with the user, define visual/content/interaction direction, apply the correct rule set (landing/app/dashboard/game), generate production-ready code, and validate both design quality and repo delivery readiness. Goal: avoid generic AI UI patterns and produce deliberate, high-quality, ship-ready interfaces.
npx skillsauth add Refinex-Space/Refinex-Skills harness-frontendInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
A taste-driven, brainstorm-first workflow for shipping production-grade frontend work that does not look like every other AI-generated page.
This is a domain skill, not a primary lifecycle owner. In repository work, harness-using routes first, harness-brainstorm, harness-feat, or harness-fix keeps control of design/preflight/plan/scope, harness-frontend owns the frontend-specific discovery/thesis/build decisions, and harness-verify closes the success claim with fresh evidence.
Announce at start: I'm using harness-frontend to shape the frontend direction and implementation details for this task.
Use this skill in one of two modes:
harness-brainstorm, harness-feat, or harness-fix must already own the workflow. This skill may not bypass design approval, preflight, planning, or fresh verification evidence.If the task is repository work and no process skill owns it yet, stop and route through harness-using first. Domain quality is not a substitute for workflow discipline.
Underspecified frontend prompts make models fall back to the most frequent patterns in their training data: card grids, Inter font, white-with-purple-gradient hero, pill clusters, dashboard mosaics, Lorem ipsum, three feature columns, sign-up CTA at the bottom. The output is plausible but generic, and the user can feel it. This skill exists to interrupt that fallback with a short, opinionated workflow that forces five things to happen before the first line of code is written:
The "elicitation with options" step is the part most other frontend skills skip, and it is the single biggest lever for quality. People rarely volunteer their preferences upfront, but they reliably recognise them when shown three good options.
Every invocation of this skill walks through these five phases in order. Do not skip phases. Do not collapse phases into one big prose response. The phases are explicit because each one fights a specific failure mode.
Phase 1 — Discover : classify the surface type and capture hard constraints
Phase 2 — Elicit : present 2–4 option menus with opinionated defaults
Phase 3 — Thesis : write the Working Model (visual / content / interaction)
Phase 4 — Build : implement using the rule pack for this surface type
Phase 5 — Verify : run design litmus checks, then hand off to the delivery gate
A short response is fine. A landing page for "a coffee shop in Brooklyn" still goes through all five phases — they just take two sentences each. Skipping phases is what produces slop.
Before anything else, classify the surface type and capture the hard constraints. Output one short paragraph with these fields filled in. If a field is missing from the user's prompt, infer it and mark the inference with (assumed) so the user can correct.
If the user's request is primarily a document, email, slide, poster, or another non-frontend artifact, do not force it into this taxonomy. Route to the appropriate writing or document skill instead.
Skipping discovery is the most common failure mode. Without the surface type, the model defaults to "marketing landing page" rules even for an internal dashboard, and produces a hero section on a settings screen. The surface type is the single most important fact about a frontend task.
This is the part that distinguishes this skill from instruction-only frontend skills. Present the user with 2 to 4 short option menus, each with 3–5 mutually exclusive choices, and always pre-select the default you actually recommend. Never ask open-ended questions like "what mood do you want?" — people freeze. Always give them tappable choices with a clear default.
Use the environment's structured choice-input tool when it is available. When it is not, present the menus inline as numbered lists so the user can reply with the numbers.
Pick from the menu library below based on the surface type and on what is genuinely undecided. Do not ask about things the user already specified. Cap the round at 4 questions — fewer is better. The point is to make taste decisions visible, not to interview the user.
Always include menu A (Tone) and menu B (Density). The other menus are situational.
Forbidden defaults, never offer these as menu choices: Inter, Roboto, Arial, system-ui, Space Grotesk (overrepresented in AI output), purple→pink gradients on white, white-with-blue-CTA SaaS template.
Lead with one short sentence stating what the user is about to decide, then the menus. After the user picks, restate the decisions as a single line of "locked-in choices" so they can be referenced in Phase 3.
If the user replies with "you choose" or "just pick", proceed using the recommended defaults. Do not interview them again.
Before writing any code, write three short artifacts. These are not for the user — they are for the model itself, to anchor every subsequent decision. Output them in the response so the user can sanity-check, but keep them tight.
1. Visual thesis — one sentence describing mood, material, and energy.
Example: "Cold editorial restraint — a Brooklyn coffee shop that does not need to explain itself; warm grayscale photography, a single oxblood accent, magazine cadence."
2. Content plan — the section sequence with one job per section. For landing pages, default to: Hero → Support → Detail → Final CTA. For apps and dashboards, replace this with the working surface itself (no marketing hero).
Example: Hero (brand + opening hours + a single hero photograph) → Support (the menu, one column, no cards) → Detail (about the roaster, single long photograph) → Final CTA (address + map + reserve a table).
3. Interaction thesis — 2–3 specific motions that change how the page feels. Each one has to be describable in a single phrase. If a motion cannot be described that simply, it is decoration and should not ship.
Example: "Hero photograph crossfades through three frames over 8 seconds; section headings reveal in a staggered upward translate on scroll; the menu items underline-fill on hover."
Models that skip the Working Model invariably ship sections that fight each other, motions that have no relationship to the rest of the page, and content sequences that are just a column of cards. Writing the thesis forces every later choice to be checkable against it: does this section serve the visual thesis? does this motion match the interaction thesis? If the answer is no, it gets cut.
Now implement. Read the rule pack for the surface type before writing code. Each rule pack lives in references/ and is loaded only when relevant:
references/landing.mdreferences/dashboard.mdreferences/app.mdreferences/landing.md for the composition rules and ignore the marketing-copy sectionreferences/app.md and additionally apply the artifact constraints in references/anti-slop.mdThe rule packs differ meaningfully. Applying landing-page rules to a dashboard produces a dashboard with a hero section, which is wrong. Applying dashboard rules to a landing page produces a Notion page, which is also wrong. Read the right one.
Choose based on the user's constraints. If the user did not specify, lean toward the first option that fits:
For motion, prefer in this order: pure CSS → Framer Motion (in React) → GSAP (only when CSS and Framer cannot do it).
For icons, prefer Lucide (works in React via lucide-react and as inline SVG elsewhere). Avoid emoji as iconography in product UI.
When the surface needs real imagery and the environment supports it:
picsum.photos with a fixed seed for reproducibility, or placehold.co with the brand colors) and clearly mark them as placeholders the user should replace.Never commit <img src="https://placeholder.example/foo.jpg"> without a comment explaining how to replace it.
This skill targets production-grade output, not snippets:
<header>, <main>, <nav>, <button> not <div onclick>), focus states that are visible, color contrast at WCAG AA minimum, alt text on every image, labels on every form field.// TODO left in the file.Before declaring the work done, walk this design checklist. Any "no" answer means go back and fix, then re-check.
Report the litmus result back to the user as a short pass/fail list. This is the moment of accountability.
The litmus checklist proves design quality. It does not prove that the repository work is done.
If this task changed a real codebase:
harness-brainstorm, harness-feat, or harness-fix).harness-verify to run those commands in the current turn before any "done", "fixed", "passing", or "ready" claim.In short:
Design litmus PASS != repository completion
Repository completion = litmus PASS + fresh technical evidence via harness-verify
If the task is artifact mode rather than repository mode, report the litmus result plus any local preview command or usage note that helps the user inspect the artifact.
These apply on every build, regardless of surface type. The rule packs in references/ add more.
<div> where a semantic element exists.references/anti-slop.md for the maintained list.When the work is complete, give the user these things in the closing message:
harness-verify for repository-mode completion.references/landing.md — landing page / marketing rule pack (hero rules, viewport budget, narrative sequence, copy rules)references/app.md — product UI / web app rule pack (Linear-style restraint, surface hierarchy, interaction patterns)references/dashboard.md — dashboard / admin rule pack (utility copy, KPI orientation, density management, chrome minimization)references/anti-slop.md — the maintained list of forbidden patterns with examples and what to do insteadreferences/elicitation-menus.md — extended option menus for Phase 2 with rationale, for cases where the menus in this file are not enoughRead only the files relevant to the current build. Do not pre-load all of them.
development
Deep initialization of project AGENTS.md hierarchy and control plane for AI coding agents. Use this skill whenever the user wants to set up, initialize, bootstrap, or create AGENTS.md / CLAUDE.md files for their project, or when they mention "init-deep", "harness setup", "control plane", "agent context", "project initialization for agents", or want to make their codebase agent-ready. Also trigger when a user says things like "set up my repo for Claude Code", "make this project work better with agents", "create agent instructions", "bootstrap harness", or "initialize agent docs". This skill handles both existing large codebases (where hierarchical, module-scoped AGENTS.md files are needed) and new/small projects (where brainstorming with the user comes first). Do NOT use this skill for routine code changes, bug fixes, or general documentation — it is specifically for creating the structured agent control plane.
development
Detect and fix drift in project AGENTS.md files and agent control plane. Use this skill whenever the user wants to audit, recalibrate, refresh, update, or fix their existing AGENTS.md files, or when they mention "drift", "stale AGENTS.md", "outdated agent instructions", "recalibrate", "sync agents", "audit control plane", "AGENTS.md is wrong/old/broken", or when they suspect their agent harness has fallen out of sync with the codebase. Also trigger when a user says things like "my agents keep making wrong assumptions", "Claude doesn't understand the new structure", "we refactored but the AGENTS.md is old", "check if my AGENTS.md is still accurate", or "update my agent docs". This skill is the companion to init-deep — init-deep creates the control plane from scratch, drift-doctor maintains it over time. Do NOT use for initial creation of AGENTS.md (use init-deep instead). Do NOT use for general code review or documentation updates unrelated to agent context.
development
Use when adding, fixing, reviewing, or generating code comments, docstrings, Javadoc, JSDoc/TSDoc, rustdoc, SQL comments, or documentation comments for source, markup, configuration, or database files.
development
Enforce production-grade Java development standards when writing, reviewing, or architecting Java code. Covers commenting, core Java idioms (Stream, collections, concurrency, generics), 23 GoF design patterns, SonarQube/Alibaba p3c/Lombok rules, Spring Boot MVC structure, Spring Cloud DDD microservices, MyBatis/JPA/transaction management, exception handling, logging, REST API design, testing, and security. Trigger whenever the user writes Java code, reviews Java code, designs a Spring Boot or Spring Cloud project, implements a design pattern, fixes code smells, discusses architecture, or asks about Java best practices. Also trigger when Java code is pasted for feedback or the user asks about package structure, DTO/VO/PO conventions, or coding standards.