Skip to content
Back to skills

Ui Icons

ASecurity

Makes interface icons look clean and professional — thin, consistent outline icons (Lucide-style) that share their label's color and weight, instead of chunky filled, two-tone or hand-drawn glyphs. Use this skill whenever you build or edit any UI that contains icons, such as sidebars, nav menus, tab bars, toolbars, buttons, dashboards, settings pages, tables, list rows, empty states or feature grids, in React, HTML, Vue, Svelte, Tailwind, shadcn or any other stack, even if the person never me...

  • 6 stars
  • 0 votes
  • 2 copies
  • 30 views
  • Added November 29, 2026
developmentreactvueangularnodegitapi

Works with

  • api

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned November 29, 2026

npx -y skills add GabrielBigardi/ui-icons-skill --skill ui-icons --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Ui Icons?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Ui Icons
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/gabrielbigardi-ui-icons/badge)](https://www.skillsdirectory.com/skills/gabrielbigardi-ui-icons)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: ui-icons
description: Makes interface icons look clean and professional — thin, consistent outline icons (Lucide-style) that share their label's color and weight, instead of chunky filled, two-tone or hand-drawn glyphs. Use this skill whenever you build or edit any UI that contains icons, such as sidebars, nav menus, tab bars, toolbars, buttons, dashboards, settings pages, tables, list rows, empty states or feature grids, in React, HTML, Vue, Svelte, Tailwind, shadcn or any other stack, even if the person never mentions icons. Also use it whenever someone asks to add, choose, replace, fix or restyle icons, or says icons look clunky, cartoonish, blobby, heavy, inconsistent, cheap or "AI-generated".
---

# UI Icons

Icons in an interface are supporting cast. The label carries the meaning; the icon makes the item faster to scan and find. Icons that do this well look like the ones in the sidebars of Linear, Stripe, Vercel or GitHub: thin open outlines, all from one family, in the same color as the text beside them. Icons that fail are filled, chunky, two-tone glyphs that are louder than their labels and blur into similar-looking blobs at small sizes.

This skill sets that first look as the default and gives the rules that keep it consistent.

## The target look

Outline (stroke) icons with no fills, all from one icon family. Rendered at 16–20px with a stroke that looks about as thick as the stems of the label's letters. Colored with `currentColor` so they match their label in every state. Plenty of open space inside each glyph so the shape still reads at small sizes. When an item is selected, the row's color and background change; the icon's style does not.

## Why filled, multi-tone glyphs look worse

Knowing the reasons lets you judge cases the rules below don't cover.

**Mass beats line at small sizes.** A filled 18px glyph is a solid shape with far more ink than the word next to it, so a column of them becomes the loudest thing on the screen, louder than the labels they serve. An outline icon has roughly the same ink density as text, so icon and label read as one unit.

**Fills erase detail.** At 16–20px, the details that tell "store", "product" and "payments" apart (an awning, a tape line, lines of text) survive in a filled glyph only as tiny cut-outs, and they get lost. Many filled glyphs collapse into near-identical rounded rectangles. Strokes keep those details as lines with open space around them.

**Two-tone fills add a second palette.** Gray icon bodies with lighter gray accents, next to near-black text, introduce colors that exist nowhere else in the UI. That reads as decoration rather than as part of the system.

**Switching style on the active item breaks the set.** If the selected item's icon turns into a colored filled block while the others stay gray glyphs, the set no longer looks like one family, and the selection looks like a different component.

## Step 1: Use an icon library, never hand-drawn paths

Don't write SVG path data from memory. Freehand paths are where wobbly curves, off-grid points, mismatched corner radii and uneven weights come from, and they are the main reason AI-made icons look AI-made. Library icons are drawn by designers on a shared grid with matched stroke, corner and cap rules, which is what makes a set feel calm.

Use **Lucide** by default (`lucide-react`, `@lucide/vue`, `@lucide/svelte`, `@lucide/angular`, `lucide-react-native`, or the `lucide` package for plain HTML). Alternatives with the same look: Tabler Icons (outline set), Heroicons (24px outline), Phosphor (Regular or Light weight), Feather.

- **One library per product.** Each library has its own grid, corner radius and stroke ends; mixing them is visible even when people can't say why.
- **Respect what's already there.** If the project already uses an icon library, keep it and use its outline/stroke variant rather than adding a second one.
- **Use current, canonical names.** Libraries rename icons. Lucide 1.x renamed `home` → `house`, `bar-chart-3` → `chart-column`, `help-circle` → `circle-question-mark`, `trash-2` → `trash` and `more-horizontal` → `ellipsis`. Old names often survive as aliases but can be removed later. When unsure whether a name exists, check the installed package (for example `ls node_modules/lucide-static/icons`) or lucide.dev/icons rather than guessing.
- **Pin exact versions** in CDN script URLs (for example `lucide@1.70.0`), never `@latest`.

```jsx
import { House, Wallet, CreditCard } from "lucide-react";

<House size={18} strokeWidth={1.75} aria-hidden="true" />
```

Setup for each framework and a complete sidebar implementation are in `references/examples.md`.

## Step 2: Pick the expected metaphor

People recognize icons by convention, not by cleverness. Pick the icon most products use for the concept, so it can be guessed from the label.

| Concept | Lucide icon |
|---|---|
| Home / Dashboard | `house` / `layout-dashboard` |
| Balance / Wallet | `wallet` |
| Payments | `credit-card` |
| Subscriptions / Recurring | `refresh-cw` or `repeat` |
| Customers / One user | `user` |
| Team / Many users | `users` |
| Products / Inventory | `package` |
| Access / API keys | `key-round` |
| Revenue / Reports | `chart-column` |
| Analytics / Trends | `chart-line` |
| Store / Shop | `store` |
| Settings | `settings` |

For anything beyond these, read `references/icon-mapping.md`, which covers SaaS, commerce, finance, developer tools, content, communication and actions.

- **Every item in a set gets a distinct icon.** If two items want the same one, use a sibling (`user` / `users`, `chart-column` / `chart-line`) or rethink the labels.
- **Simple single objects over scenes.** One object with few strokes reads at 18px; a composition of several objects doesn't.
- **Don't force icons.** A button with a clear label often needs none. Navigation lists, toolbars and icon-only controls are where icons earn their place. Within one list, either every item has an icon or none does.

## Step 3: Size, stroke and alignment

The rendered stroke should look about as thick as the stems of the label's letters. Lucide's viewBox is 24 units, so a `strokeWidth` of 1.75 at 18px renders as roughly 1.3px, which matches regular-weight 14–15px text.

| Context | Label size | Icon size | strokeWidth (24-unit viewBox) |
|---|---|---|---|
| Dense tables, inline with small text, badges | 12–13px | 14–16px | 2 |
| Sidebar and nav items, buttons, menus, tabs | 14–15px | 18–20px | 1.75 |
| Page or section headers | 16–20px | 20–24px | 1.5 |
| Empty states, feature callouts | — | 32–48px | 1.25–1.5 |

- **Same size for every icon in a list.** Library icons are already optically balanced against each other; don't hand-scale individual ones.
- **Lay icon and label out in a flex row** with `align-items: center` and a gap of 10–12px in nav items or 6–8px in buttons.
- **Give the icon a fixed box** (`width`/`height` set, `flex-shrink: 0`) so all labels start on the same vertical line.
- **Accessibility:** `aria-hidden="true"` on icons that sit next to a visible label; an `aria-label` on icon-only buttons.

## Step 4: Color and states

- **Use `stroke="currentColor"`** (library default) and set color on the parent row, never hardcoded on the SVG. The icon then follows the label through hover, active, disabled and dark mode automatically.
- **Icon color = label color.** The one allowed variation is an icon one step lighter in the same neutral family (label `gray-900`, icon `gray-600`). Never a different hue, and never so light it looks disabled.
- **Hover:** a subtle neutral background on the row (`gray-100` / `zinc-100`); text and icon may darken slightly.
- **Active / selected:** a light accent background on the row (for example `violet-50` or `violet-100`), with label and icon both in a dark accent (`violet-700`), label weight 500–600. Keep the same outline icon at the same stroke.
- **Disabled:** lower the opacity of the whole row so icon and label fade together.
- **No decoration:** no colored tile behind each nav icon, no gradients, no drop shadows, no two-tone fills, no emoji used as icons.

**Exception:** platforms whose convention is filled-when-selected (iOS tab bars with SF Symbols, Android bottom navigation with Material Symbols) may switch to the *same family's* filled variant for the selected item, but only where the library ships matched outline/fill pairs (SF Symbols, Material Symbols' FILL axis, Phosphor Regular/Fill). Web sidebars and menus keep the outline icon.

## Step 5: When no library icon fits

First search harder. Libraries tag icons with synonyms (Lucide ships `tags.json`; lucide.dev/icons searches tags), so search for what the thing *is* or *does* rather than its label. Most "missing" icons are there under another name.

If you truly need a custom glyph, match the family exactly:

```svg
<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24"
     fill="none" stroke="currentColor" stroke-width="2"
     stroke-linecap="round" stroke-linejoin="round" aria-hidden="true">
  <!-- 2 to 5 simple elements -->
</svg>
```

- Keep all drawing inside the 2–22 area of the 24 grid, with coordinates on whole or half units.
- Build from primitives (`rect` with `rx="2"`, `circle`, `line`, `polyline`, simple arcs) and start from a similar library icon's geometry where possible.
- Strokes only, no fills (a tiny filled dot of `r="1"` is the one exception).
- Render it at the size it will be used, next to library icons, and fix anything that looks heavier, lighter, larger or busier than its neighbors.

## Anti-patterns

These are the specific things that make icons look cheap. If you see them in existing code you're editing, point them out and offer to fix them.

- Filled or solid glyphs in nav lists, menus and toolbars.
- Two-tone gray fills, or icons in a gray darker or lighter than anything else in the UI.
- An active state that swaps the icon for a filled or boxed version.
- Hand-written SVG paths when a library icon exists.
- Several icon libraries in one product, or mixed outline and filled icons in one list.
- Colored rounded-square tiles behind every list icon (the "app launcher" look).
- Emoji standing in for icons.
- Different icon sizes in the same list, or strokes much heavier than the text.
- Detailed, illustrative icons at small sizes.
- The same icon reused for two different items.

## Checklist before finishing

- All icons come from one library, in its outline variant, using names that exist in the installed version.
- Icons within each list share one size, and the stroke matches the text weight.
- Icons use `currentColor` and match their label in every state.
- The active state changes color and background only, never the icon's style.
- Each item has a distinct, conventional icon.
- No fills, two-tone, emoji, tiles, gradients or shadows on icons.
- Icons next to labels are `aria-hidden`; icon-only buttons have an `aria-label`.
- If you can render the UI, look at a screenshot at 1x: every icon should be recognizable at a glance and sit quieter than its label.

## Reference files

- `references/icon-mapping.md` — concept → icon tables for Lucide with Heroicons and Tabler equivalents for the most common ones. Read when choosing icons for more than the handful listed above.
- `references/examples.md` — install and usage for React, Vue, Svelte, plain HTML via CDN and native platforms, plus a complete sidebar in React + Tailwind and in plain HTML/CSS. Read when writing the code.

Files in this skill

  • SKILL.md11.3 KB
  • references/examples.md7.6 KB
  • references/icon-mapping.md5.9 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in development →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.