JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 23
  • Score
    100M100P100Q42044F
  • License Public Domain

Render color range by channel or space for the color passed. Useful for creating any king of color picker.

Package Exports

  • color-ranger
  • color-ranger/worker

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (color-ranger) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

Color-ranger

Render rectangular/polar color range into an ImageData. Useful in a color-picker both as a separate web-worker and single flow.

Tests.

Use

var renderRange = require('color-ranger');
var Color = require('color');


var color = new Color('rgba(10,250,30,.3)');


var imageData = renderRange.rect(color.rgbaArray(), 'hsl', [0,1], data);

API

rect()

Render rectangular range.

polar()

Render polar range.

grid()

Render transparency grid.