document.querySelectorAll("tr.child-of-item-88404").forEach((e) => e.remove()); template = document.createElement("template"); template.innerHTML = ""; document.querySelector("#item-88404").after(...template.content.children) template.remove() document.querySelector("#item-expand-link-88404").style.display = 'none'; document.querySelector("#item-collapse-link-88404").style.display = 'inline-block';