fix issue on rotation undo

This commit is contained in:
JFH
2020-12-19 18:47:15 +01:00
parent ccf891f985
commit dca89321d4
2 changed files with 10 additions and 2 deletions

View File

@@ -188,7 +188,11 @@ export const changeSelectedAttributeNoUndoMethod = function (attr, newValue, ele
// }
} else if (attr === '#href') {
setHref(elem, newValue);
} else { elem.setAttribute(attr, newValue); }
} else if (newValue) {
elem.setAttribute(attr, newValue);
} else {
elem.removeAttribute(attr);
}
// Go into "select" mode for text changes
// NOTE: Important that this happens AFTER elem.setAttribute() or else attributes like