.agents/skills/design/SKILL.md
Design consistency and visual styling for the Svelte client UI. Use when creating or modifying visual elements, colors, typography, buttons, inputs, or cards.
npx skillsauth add vigneshksaithal/binarygrid designInstall 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.
All code must follow the Coding Principles in AGENTS.md (functional, minimal, readable, modular).
<style> blocks, no inline style= attributes.Use Tailwind's default spacing scale. Avoid arbitrary values (p-[13px]).
| Use case | Class |
|----------|-------|
| Component padding | p-4 (16px) |
| Section gap | gap-4 or space-y-4 |
| Tight inline gap | gap-2 |
| Card/panel padding | p-4 or p-6 |
| Page horizontal padding | px-4 |
| Page vertical padding | py-3 |
<h1 class="text-xl font-bold tracking-tight">Title</h1>
<h2 class="text-base font-semibold">Section</h2>
<p class="text-sm text-gray-700 dark:text-gray-300">Body</p>
<span class="text-xs text-gray-500">Caption / meta</span>
text-sm (14px). Never below text-xs for readable content.max-w-sm or max-w-xs for prose.| Role | Light | Dark |
|------|-------|------|
| Background | bg-white | dark:bg-gray-900 |
| Surface / card | bg-gray-50 | dark:bg-gray-800 |
| Border | border-gray-200 | dark:border-gray-700 |
| Primary text | text-gray-900 | dark:text-gray-100 |
| Secondary text | text-gray-500 | dark:text-gray-400 |
| Accent / brand | text-orange-500 | same |
| Destructive | text-red-500 | same |
| Success | text-green-500 | same |
Always pair a light and dark variant. Reddit renders in both modes.
<!-- Primary -->
<button class="w-full rounded-lg bg-orange-500 px-4 py-2.5 text-sm font-semibold text-white
hover:bg-orange-600 active:scale-95 transition-all disabled:opacity-50
disabled:cursor-not-allowed focus-visible:outline-none focus-visible:ring-2
focus-visible:ring-orange-400">
Submit
</button>
<!-- Secondary -->
<button class="w-full rounded-lg border border-gray-300 dark:border-gray-600 px-4 py-2.5
text-sm font-semibold text-gray-700 dark:text-gray-200
hover:bg-gray-100 dark:hover:bg-gray-700 active:scale-95 transition-all">
Cancel
</button>
min-h-[44px] or py-2.5 on text-sm.disabled:opacity-50 disabled:cursor-not-allowed.active:scale-95 transition-all for tactile feedback.<input
class="w-full rounded-lg border border-gray-300 dark:border-gray-600 bg-white
dark:bg-gray-800 px-3 py-2 text-sm text-gray-900 dark:text-gray-100
placeholder:text-gray-400 focus:outline-none focus:ring-2 focus:ring-orange-400"
/>
Every data-driven component must handle all four states:
| State | Pattern |
|-------|---------|
| Loading | animate-pulse skeleton or spinner with label |
| Error | Red tinted surface, human-readable message |
| Empty | Neutral muted text, optionally a CTA |
| Success | Normal render; optionally brief text-green-500 confirmation |
<div class="rounded-xl border border-gray-200 dark:border-gray-700
bg-white dark:bg-gray-800 p-4 shadow-sm">
<!-- content -->
</div>
rounded-xl for cards, rounded-lg for inputs/buttons, rounded-md for badges.shadow-sm only — avoid heavy shadows.transition-all, transition-colors, transition-opacity.150ms). No custom durations.animate-pulse for loading, animate-spin for spinners.<style> blocks — Tailwind classes onlyp-[13px]) — use scale stepsdisabled, active:scale-95, and focus-visible:ring classesdevelopment
Test-Driven Development workflow using Vitest + @devvit/test. Use when writing any new feature, fixing bugs, or refactoring existing code.
tools
Create a Svelte 5 component with optional data fetching. Use when adding UI components, views, interactive elements, or wiring client-side fetch to server endpoints.
data-ai
Design and implement Redis data storage for a new feature. Use when adding new data models, leaderboards, counters, or any persistent state.
development
Interact with the Reddit API from server-side code. Use when reading user info, submitting posts/comments, setting flair, or accessing subreddit data.