MLavazza

Joined 3 December 2020
no edit summary
No edit summary
No edit summary
Line 57: Line 57:


//add arrows linking to expanded child proposition
//add arrows linking to expanded child proposition
remarkNumber = document.getElementById('1').innerHTML;
var numbersOfRemarksWithChildren = document.querySelectorAll('.tlp-pr-with-children .tlp-aside-par');
console.log(remarkNumber);
for (i = 0; i < numbersOfRemarksWithChildren.length; i++) {
remarkNumber = remarkNumber + ' <a href="#separator-1">→</a>';
    var oldNumberString = numbersOfRemarksWithChildren[i].innerHTML;
console.log(remarkNumber);
    console.log("oldNumberString: " + oldNumberString);
document.getElementById('1').innerHTML = remarkNumber;
    var numberStringId = numbersOfRemarksWithChildren[i].id;
    console.log("id: " + numberStringId);
    var newNumberString = oldNumberString + ' <a href="#separator-' + numberStringId + '">→</a>';
    console.log("newNumberString: " + newNumberString);
    numbersOfRemarksWithChildren[i].innerHTML = newNumberString;
}
</script>
</script>
</html>
</html>