color-utils
English | 简体中文
Color conversion tool library.
Features
RGB
/RGBA
/HEX
/HSL
/HSLA
/color-name
color interconversion. ([color-name]- Validators for the above types of colors.
- Provide computational multi-color fusion function.
- Provides the function of calculating the complementary color.
- Provide the function of judging the color light and dark (mostly used to deal with the relationship between the background color and the displayed text).
Install
npm install @nmsn/color-utils
Usage
import { isLight } from '@nmsn/color-utils';
const isLightColor = isLight('#999'); // true
Online Address: https://color-utils-site.vercel.app/
Project Address: https://github.com/nmsn/color-utils-site
Finished
- <input checked="" disabled="" type="checkbox">
RGB
/RGBA
/HEX
/HSL
/HSLA
/color-name
interconversion. - <input checked="" disabled="" type="checkbox"> Checksum functions for each color format.
- <input checked="" disabled="" type="checkbox"> Unit testing of existing features.
- <input checked="" disabled="" type="checkbox"> Color fusion calculations.
- <input checked="" disabled="" type="checkbox"> Complementary color calculation.
- <input checked="" disabled="" type="checkbox"> Color brightness judgment.
- <input checked="" disabled="" type="checkbox">
Rollup
Basic Function Package.
Todo
- <input disabled="" type="checkbox">
Rollup
packed volume optimization. - <input disabled="" type="checkbox"> Code optimization.