Fixed clear function

This commit is contained in:
2023-04-26 11:22:25 +02:00
parent f5737b359e
commit c008382af6

View File

@@ -13,8 +13,8 @@ const color_red = "#ff8f8f";
* @returns {void} * @returns {void}
*/ */
function clearDefaultContent(element, text) { function clearDefaultContent(element, text) {
if (element.value == text) { if (element.innerText == text) {
element.value = ""; element.innerText = "";
element.style.color = "#000000"; element.style.color = "#000000";
element.style.backgroundColor = "#ffffff"; element.style.backgroundColor = "#ffffff";
} }
@@ -57,9 +57,11 @@ function clearDataField() {
document.getElementById("xmlArea").style.color = null; document.getElementById("xmlArea").style.color = null;
document.getElementById("xmlArea").style.backgroundColor = null; document.getElementById("xmlArea").style.backgroundColor = null;
document.getElementById("transformArea").value = ""; document.getElementById("transformArea").innerHTML = "";
document.getElementById("transformArea").style.color = null; document.getElementById("transformArea").style.color = null;
document.getElementById("transformArea").style.backgroundColor = null; document.getElementById("transformArea").style.backgroundColor = null;
document.getElementById("resultArea").innerHTML = "";
} }