PluginBench
Skill
Pass
Audit score 90

visual-edit-precision

wshobson/agents

Make targeted UI edits guided by visual context and element selections.

What is visual-edit-precision?

Use this skill when making frontend changes based on visual indicators like screenshots, element selections, or annotations. It ensures you make precise, minimal edits to exactly what was indicated while preserving surrounding code and behavior.

  • Identify exact elements from visual context (screenshots, selections, annotations)
  • Make minimal, targeted CSS or markup changes to selected elements only
  • Preserve existing styles, classes, event handlers, and accessibility attributes
  • Handle multiple independent visual edits without refactoring surrounding code
  • Verify changes render correctly without unintended side effects

How to install visual-edit-precision

npx skills add https://github.com/wshobson/agents --skill visual-edit-precision
Claude Code
Cursor
Windsurf
Cline

How to use visual-edit-precision

  1. 1.Receive visual context (screenshot, element selection, or annotation) alongside the change request
  2. 2.Identify the exact component file and element(s) being indicated
  3. 3.Determine the minimal CSS or markup change needed to achieve the visual result
  4. 4.Make only the targeted edit—do not refactor surrounding code or logic
  5. 5.Verify the change renders correctly and preserves existing behavior and accessibility

Use cases

Good for
  • User selects a button in a screenshot and requests a color change—edit only that button's style
  • Designer annotates a card layout and asks for spacing adjustment—modify only the indicated card's CSS
  • Multiple UI elements need tweaks—process each visual edit independently without cross-component changes
  • Component appearance needs adjustment while preserving all logic and event handlers
  • Responsive design must be maintained when making visual edits to specific breakpoints
Who it's for
  • Frontend developers making UI refinements
  • Designers collaborating with agents on visual changes
  • Teams using visual feedback (screenshots, annotations) to guide edits
  • Developers who need precision edits without component refactoring

visual-edit-precision FAQ

Should I refactor the component if I see other issues while making a visual edit?

No. Visual edits are precision-focused. Change only what was indicated. If broader refactoring is needed, that's a separate request.

What if the visual context points to multiple elements?

Process each element independently. If two edits conflict (same element, different requests), prioritize the most recent request.

Can I change component logic or props during a visual edit?

Only if the visual change requires it. Preserve all existing behavior, event handlers, and accessibility attributes unless explicitly asked to change them.

How do I handle responsive design when making visual edits?

Maintain existing responsive behavior. If editing a specific breakpoint, ensure the change doesn't break other screen sizes unless that was the explicit request.

What should I do if I can't identify the exact element from the visual context?

Ask for clarification—request a more specific selection, annotation, or description of which element or component needs to change.

Full instructions (SKILL.md)

Source of truth, from wshobson/agents.


name: visual-edit-precision description: >- Use when making UI/frontend changes guided by visual context, when the user selects elements visually, draws annotations, or provides screenshots alongside change requests. Also use when editing components where spatial context (element identity, DOM references, layout data) supplements text instructions.

Visual Edit Precision

Overview

When visual context accompanies a change request (element selections, annotations, screenshots), make targeted, minimal edits. Precision over ambition: change exactly what was indicated, preserve everything else.

Process

When visual context is provided:

  1. IDENTIFY - What exact element(s) were indicated? Which component file owns them?
  2. SCOPE - Change ONLY what was pointed at. Don't refactor surrounding code.
  3. PRESERVE - Keep existing styles, classes, and behavior. Only modify what was asked.
  4. TARGETED - Make the minimal CSS/markup change that achieves the visual result.
  5. VERIFY - Confirm the change renders correctly without side effects.

Key Principles

Precision Over Ambition

Visual context gives a SPECIFIC element. Don't:

  • Refactor the entire component when only one style was requested
  • Change the component's API when only its appearance was pointed at
  • Touch logic when only visuals were selected

Do:

  • Find the exact file and line for the selected element
  • Make the minimal edit that achieves the described visual change
  • Preserve all existing behavior, event handlers, accessibility

Multiple Edits

When multiple visual edits arrive:

  • Each targets its own element independently
  • Don't wait for one to finish before processing another
  • If two edits conflict (same element, different requests), handle the most recent

Common Mistakes

  • Rewriting an entire component when the user pointed at one button
  • Changing global config when only one element's color needs adjusting
  • Breaking responsive behavior by adding fixed widths to match a selection
  • Ignoring specificity (user indicated ONE card, agent changed ALL cards)
  • Removing accessibility attributes (aria-*, role, tabindex) during visual edits