rc-color-picker
color-picker ui component for react
Last updated 2 years ago by noyobo .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install rc-color-picker 
SYNC missed versions from official npm registry.

rc-color-picker


React Color Picker

npm version npm download npm dependency Build Status

Browser Support

Chrome Edge Firefox IE Opera Safari
Chrome 31.0+ ✔ Edge 12.0+ ✔ Firefox 31.0+ ✔ IE 10+ ✔ Opera 30.0+ ✔ Safari 7.0+ ✔

Screenshots

Development

npm install
npm start

Example

online example: http://react-component.github.io/color-picker/

Feature

  • support color mode RGB HSB HSL

install

rc-color-picker

Usage

var ColorPicker = require('rc-color-picker');
var React = require('react');
var ReactDOM = require('react-dom');
ReactDOM.render(<ColorPicker />, container);

API

ColorPicker.props

name type default description
align Object: alignConfig of dom-align popup 's align config
alpha Number 100 opacity of the color
animation String index.css support 'slide-up'
children Node <span className='react-colorpicker-trigger'></span> additional trigger appended to picker
className String '' Aditional class to be added to component
color String #ff0000 color board current background color
defaultAlpha Number 100 opacity of the color
defaultColor String #ff0000 color board current background color
enableAlpha Boolean true enable alpha controls
getCalendarContainer Function():Element function(){return document.body;} dom node where picker to be rendered into
mode String RGB color mode, support mode 'RGB', 'HSB' or 'HSL'
onChange Function noop when select color
onClose Function noop when color picker popup close
onOpen Function noop when color picker popup open
placement String topLeft one of ['topLeft', 'topRight', 'bottomLeft', 'bottomRight']
transitionName String css class for animation

ColorPicker.Panel.props

name type default description
alpha Number 100 opacity of the color
className String '' Aditional class to be added to component
color String #ff0000 color board current background color
defaultAlpha Number 100 opacity of the color
defaultColor String #ff0000 color board current background color
enableAlpha Boolean true enable alpha controls
mode String RGB color mode, support mode 'RGB', 'HSB' or 'HSL'
onBlur Function when picker loose focus
onChange Function when select color trigger
onFocus Function when picker focus trigger
style Object {} root node CSS style

License

rc-color-picker is released under the MIT license.

Current Tags

  • 1.2.6                                ...           latest (2 years ago)

17 Versions

  • 1.2.6                                ...           2 years ago
  • 1.2.5                                ...           2 years ago
  • 1.2.4                                ...           2 years ago
  • 1.2.3                                ...           3 years ago
  • 1.2.2                                ...           3 years ago
  • 1.2.1                                ...           3 years ago
  • 1.2.0                                ...           3 years ago
  • 1.1.7                                ...           3 years ago
  • 1.1.6                                ...           3 years ago
  • 1.1.5                                ...           3 years ago
  • 1.1.4                                ...           3 years ago
  • 1.1.3                                ...           3 years ago
  • 1.1.2                                ...           4 years ago
  • 1.1.1                                ...           4 years ago
  • 1.1.0                                ...           4 years ago
  • 1.0.1                                ...           4 years ago
  • 1.0.0                                ...           4 years ago
Downloads
Today 134
This Week 619
This Month 397
Last Day 126
Last Week 744
Last Month 3,290
Dependencies (5)
Dev Dependencies (6)

Copyright 2014 - 2016 © taobao.org |