Automattic / Iris

A(n awesome) Color Picker
GNU General Public License v2.0
259 stars 67 forks source link

Set color to empty #53

Open Ninos opened 8 years ago

Ninos commented 8 years ago

Hey there, it's not possible to reset color of the iris color picker to an empty value: jQuery( element ).wpColorPicker( 'color', '' ); is not working here. I solved it in following way: jQuery( this ).find( '.wp-color-result' ).css( 'background-color', '' );

On initialization it works fine.

PS: I know it's the wp-color-picker, in iris it would be something like that: jQuery( element ).iris( 'color', '' ); jQuery( this ).find( '.iris-result' ).css( 'background-color', '' );