Skip to content

cXiaof/rsuite-color-picker

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 
lib
 
 
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

rsuite-color-picker

Package a color picker extension that can select color for rsuite.

Examples

DEMO

Installation

npm install rsuite-color-picker --save

or

yarn add rsuite-color-picker

Usage

import ColorPicker from 'rsuite-color-picker'
import 'rsuite-color-picker/lib/styles.less'
// import 'rsuite-color-picker/lib/styles.css'

const App = () => <ColorPicker />

ReactDOM.render(<App />, mountNode)

Props

Property Type(Default) Description
disabled boolean(false) disabled
value String/Object value (Controlled)
defaultValue String/Object(#00bcd4) Default value
disableAlpha boolean(false) Remove alpha slider and options from picker
onChange Function call every time the color is changed
onChangeComplete Function call once a color change is complete

see detail of 4 props in React Color:

  1. color (value / defaultValue)
  2. disableAlpha (disableAlpha)
  3. onChange (onChange)
  4. onChangeComplete (onChangeComplete)

Less variable

  • @color-picker-wrapper-padding: 5px;
  • @color-picker-border-radius: 6px;

License

MIT licensed

About

Package a color picker extension that can select color for rsuite.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages