js代码
var colorPicker = new ewPlugins('colorpicker', {
el: "#colorpicker",
alpha: true,//是否开启透明度
size: 'small',//颜色box类型
predefineColor: ['#223456', 'rgba(122,35,77,.5)','rgba(255,255,255,1)'],//预定义颜色
disabled: false,//是否禁止打开颜色选择器
openPickerAni: 'opacity',//打开颜色选择器动画
sure: function (color) {
document.body.style.background = color;
},//点击确认按钮事件回调
clear: function () {
document.body.style.background = this.defaultColor;
}//点击清空按钮事件回调
})