256 Color Matcher

256 Color Matcher

Project Links

Project overview

This is a simple web app written in pure HTML, CSS and JS for finding the closest matching standard 256 (8bit) color from a given input color. This is useful if you’re styling e.g. xterm and need to find the closest color in the palette.

Features

  • Pure HTML, CSS and JS — no frameworks
  • Hex and RGB modes (updates color texts and inputs)
  • 18kb bundle size
  • 3 npm dependencies
  • Bundled with webpack
  • Tests for all non-vendor library modules (jest)
  • Last color saved to localStorage and retrieved on next visit

Project story

I went through a huge terminal phase. I still love the terminal and do pretty much everything I can do on the command line. I find it often much faster than reaching for a GUI. I had a very elaborate ViM setup at one point, and took styling pretty seriously. I wanted to be able to get standard 256 colors close to certain palettes, but wanted a quick way to find these. Thus 256-color-matcher was born