This commit is contained in:
Mirco Wittrien 2020-02-12 16:07:43 +01:00
parent 9b41ce6f5a
commit a58eae903d
2 changed files with 3 additions and 4 deletions

View File

@ -2894,14 +2894,13 @@
}
function updateGradient () {
gradientpane.style.removeProperty("background-color");
var gradient = {};
let gradient = {};
for (let cursor of gradientpane.querySelectorAll(".gradient-cursor")) gradient[parseFloat(cursor.style.getPropertyValue("left"))/100] = cursor.firstElementChild.style.getPropertyValue("background-color");
gradientpane.style.setProperty("background-image", BDFDB.ColorUtils.createGradient(gradient));
if (isreact) container.setState({
container.setState({
selectedColor: gradient,
customColor: gradient
});
else setSwatch(container.querySelector(BDFDB.dotCN.colorpickerswatch + BDFDB.dotCN.colorpickerswatch), gradient, true);
}
};

File diff suppressed because one or more lines are too long