fix colorpicker updates

This commit is contained in:
JFH
2020-12-24 16:01:53 +01:00
parent ad959ce7a6
commit 00d98958f2
3 changed files with 39 additions and 38 deletions

View File

@@ -2946,12 +2946,13 @@ editor.init = () => {
$('#group_opacity').val(configObj.curConfig.initOpacity * 100);
const handleColorPicker = (type, evt) => {
// const {paint} = evt.detail;
const {paint} = evt.detail;
svgCanvas.setPaint(type, paint);
updateToolButtonState();
};
$id('stroke_color').addEventListener('change', (evt) => handleColorPicker('stroke', evt));
$id('fill_color').addEventListener('change', (evt) => handleColorPicker('stroke', evt));
$id('fill_color').addEventListener('change', (evt) => handleColorPicker('fill', evt));
$('#group_opacityLabel').click(() => {
$('#opacity_dropdown button').mousedown();