Svelte UI Design System is a design Claude Skill built by Diego Rodrigues de Sa e Souza. Best for: Frontend developers building Svelte interfaces need a reference for mobile-first, dark-mode-ready, accessible component styling without custom CSS..
Apply consistent Tailwind-based design patterns for Svelte components: spacing, typography, colors, buttons, inputs, and state handling.
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 classes/plugin install svelte-ui-design-system@diegosouzapwRequires Claude Code CLI.
Frontend developers building Svelte interfaces need a reference for mobile-first, dark-mode-ready, accessible component styling without custom CSS.
No reviews yet. Be the first to review this skill.