Skip to content

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 

Repository files navigation

🎨 Chroma

A fast, beautiful color palette generator for designers and developers — right in your browser. No build step, no dependencies, no tracking. Just one self-contained HTML file.

▶ Live demo

Features

  • Instant palettes — press Space to generate a fresh 5-color scheme.
  • Harmony modes — Auto, Analogous, Monochromatic, Complementary, Triadic, and Tetradic.
  • Lock what you love — 🔒 pin any color, then regenerate the rest around it.
  • One-click copy — click any hex to copy it to your clipboard.
  • Shareable URLs — every palette lives in the URL, so a copied link reproduces it exactly.
  • Export anywhere — CSS variables, Tailwind config, JSON, or SVG.
  • Smart contrast — hex labels automatically switch to a readable color per swatch.
  • Light & dark UI — with your preference remembered.
  • Zero dependencies — a single index.html, ~15 KB. Works offline.

Usage

Open index.html in any modern browser. That's it.

Action How
Generate a palette Press Space or click Generate
Copy a color Click its hex code
Lock a color Hover a swatch → click the 🔒
Nudge lightness Hover a swatch → click the ☀
Export Click Export and pick a format
Share Click Copy share link

Running locally

No tooling required — it's a static file:

git clone https://github.com/dustfillerr-code/chroma.git
cd chroma
# then just open index.html, or serve it:
python -m http.server 8000   # http://localhost:8000

How it works

Colors are generated in HSL space so each harmony mode can reason about hue relationships (offsets of 120° for triadic, 180° for complementary, etc.), then converted to hex for display. Contrast is chosen with the WCAG relative luminance formula so text stays legible on every swatch. Everything is plain vanilla JavaScript — no frameworks.

License

MIT © 2026

About

?? A fast, zero-dependency color palette generator for designers and developers. Generate harmonious palettes, lock favorites, copy hex, and export to CSS/Tailwind/JSON.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages