0.2.0 • Published 3 years ago
rsuite-color-picker v0.2.0
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
:
- color (value / defaultValue)
- disableAlpha (disableAlpha)
- onChange (onChange)
- onChangeComplete (onChangeComplete)
Less variable
- @color-picker-wrapper-padding: 5px;
- @color-picker-border-radius: 6px;
License
MIT licensed
0.2.0
3 years ago
0.1.3
4 years ago
0.1.2
4 years ago
0.1.1
4 years ago
0.1.0-beta.4
5 years ago
0.1.0-beta.3
5 years ago
0.1.0-beta.2
5 years ago
0.1.0-beta.1
5 years ago
0.1.0-alpha
5 years ago