Skip to content

Commit 8c5bc3d

Browse files
committedAug 21, 2021
v.2.2.0
* onSelect callback called on color select
1 parent 4c137ec commit 8c5bc3d

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed
 

‎colorpicker.js

+2-1
Original file line numberDiff line numberDiff line change
@@ -853,8 +853,9 @@ function ColorPicker(el, options)
853853
livehandlers.push({el:ui, event:'click', handler:live('colorpicker_save', 'click', function() {
854854
prev_color = model.rgb.slice().concat(model.opacity);
855855
update_ui(model, fields, true);
856-
if (hide) hide(true);
857856
update_element(colorselector, input, get_color(model, format), colorChange);
857+
options.onSelect(self);
858+
if (hide) hide(true);
858859
}, ui)});
859860
livehandlers.push({el:ui, event:'click', handler:live('colorpicker_restore', 'click', function() {
860861
model.rgb = prev_color.slice(0, 3);

0 commit comments

Comments
 (0)