apemancolor

1.3.0 • Public • Published

apemancolor

Build Status Code Climate Code Coverage npm Version JS Standard

Color utility.

Installation

$ npm install apemancolor --save

Usage

'use strict'
 
const apemancolor = require('apemancolor')
 
// Rotate colors
{
  let base = '#A33'
  apemancolor.rotate(base, 30) // Rotate hue 30 degree
}
 
// Decide text color for background color
{
  let textColor = (backgroundColor) => apemancolor.isDark(backgroundColor) ? '#FF' : '#111'
  textColor('#AA0') // Get text color for background color
}
 

License

This software is released under the MIT License.

Links

Readme

Keywords

Package Sidebar

Install

npm i apemancolor

Weekly Downloads

1

Version

1.3.0

License

MIT

Last publish

Collaborators

  • okunishinishi