1.0.3 • Published 2 years ago

color-from-image v1.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

color-from-image

Pick color from an image

NPM JavaScript Style Guide

Demo

ScreenShot

Install

npm install --save color-from-image

Usage

import React from 'react'

import ColorFromImage from 'color-from-image'

const App = () => {
  return <ColorFromImage src='...' />
}

export default App

Documentation

You can use all img attributes.

ParameterTypeDescription
hideColorbooleanTo hide color view in hex.
onChangeColor(hexColor: string) => voidTo get color on mouse moved.
onChooseColor(hexColor: string) => voidTo get color on click.

License

MIT © abdulrahmanAlh