Color Picker: Allow to override mode and width values for Iris via wpColorPicker options.

props jtsternberg.
fixes #30182.

git-svn-id: https://develop.svn.wordpress.org/trunk@30330 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dominik Schilling (ocean90) 2014-11-13 12:33:27 +00:00
parent 8d476eee4f
commit 2aac7ef27c

View File

@ -15,7 +15,9 @@
change: false,
clear: false,
hide: true,
palettes: true
palettes: true,
width: 255,
mode: 'hsv'
},
_create: function() {
// bail early for unsupported Iris.
@ -51,8 +53,8 @@
el.iris( {
target: self.pickerContainer,
hide: self.options.hide,
width: 255,
mode: 'hsv',
width: self.options.width,
mode: self.options.mode,
palettes: self.options.palettes,
change: function( event, ui ) {
self.toggler.css( { backgroundColor: ui.color.toString() } );