Fix the toggling of image modifiers

The toggling of image modifiers doesn't get properly applied if weights are changed after restoring the image modifiers.
This commit is contained in:
patriceac 2023-02-19 15:59:20 -08:00 committed by GitHub
parent e7a2dfa57f
commit 41a3309cbe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -40,7 +40,7 @@
// refresh activeTags
let modifierName = i.parentElement.getElementsByClassName('modifier-card-label')[0].getElementsByTagName("p")[0].dataset.fullName
activeTags = activeTags.map(obj => {
if (obj.name === modifierName) {
if (trimModifiers(obj.name) === trimModifiers(modifierName)) {
return {...obj, inactive: (obj.element.classList.contains('modifier-toggle-inactive'))};
}