Name That Color
A VS Code Plugin to convert hex or rgb color representation into friendly names built upon Chirag Mehta's ntc.js.
Features
- Get a friendly name from color representation
- Generate Sass or CSS variables name from color representation
- Deals with close color representations (return the same name)
- Works with single, multiple and block selections
- Works with Hex and RGB
Usage
Get color name
- Select a color
- From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
- Select Name that color : get color name
Replace selectin with color name
- Select a color
- From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
- Select Name that color : replace selection
Generate Sass variable
- Select a color
- From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
- Select Name that color : generate Sass variable
Generate CSS variable
- Select a color
- From the command palette Ctrl-Shift-P (Windows, Linux) or Cmd-Shift-P (OSX),
- Select Name that color : generate CSS variable
Tip: It works for single, multiple and block selection as well.
Tip: You can choose the delimiter used in variables.
Tip: You can add a prefix and/or a suffix to variables.
Tip: You can use both Hex and RGB colors.
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
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)
Przemysław Adamczewski (CSS Variables)
License
MIT - https://opensource.org/licenses/MIT
| |