/name-that-color

A VS Code Plugin to convert hex colors into friendly names.

Primary LanguageTypeScriptMIT LicenseMIT

Name That Color

A VS Code Plugin to convert hex color representation into friendly names built upon Chirag Mehta's ntc.js.

Features

  • Get a friendly name from hex color representation
  • Generate Sass variable name from hex color representation
  • Deals with close hex color representations (return the same name)
  • Works with single or multiple selections

Usage

Get color name

  • Select a Hex color representation
  • From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
  • Select Name that color : get color name

feature get color name

Replace selectin with color name

  • Select a Hex color representation
  • From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
  • Select Name that color : replace selection

feature replace hex code with friendly name

Generate Sass variable

  • Select a Hex color representation
  • From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
  • Select Name that color : generate Sass variable

feature generate sass variable

Tip: It works for multiple selection as well.

feature multiple selection

Installation

If you have any requirements or dependencies, add a section describing those and how to install and configure them.

  • Install Visual Studio Code 1.5.0 or higher
  • Launch Code
  • From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX)
  • Select Install Extension
  • Choose the extension (Name That Color)
  • Reload Visual Studio Code

Release Notes

0.1.1

Update Readme.

0.1.0

Improve selection (works with or without #).

0.0.1

Initial release.

Source

GitHub

Contribute

If you have any problem, idea or suggestion, feel free to create issues and pull requests on GitHub.

Credit

Chirag Mehta http://chir.ag

Guillaume Doutriaux (@gdoutriaux)

License

MIT - https://opensource.org/licenses/MIT