Skip to content

Commit

Permalink
Replace wrap-inner logic with an approach where the browser handles e…
Browse files Browse the repository at this point in the history
…scaping
  • Loading branch information
richardebeling committed Sep 18, 2023
1 parent e71e544 commit 1a593d9
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion evap/evaluation/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,10 @@
// activate clickable hover tables
document.querySelectorAll(".table-seamless-links [data-url]").forEach(row => {
for(const table_data of row.children) {
table_data.innerHTML = "<a href='" + row.dataset["url"] + "'>" + table_data.innerHTML + "</a>"
const wrapping_anchor = document.createElement("a");
wrapping_anchor.href = row.dataset["url"];
wrapping_anchor.append(...table_data.children);
table_data.replaceChildren(wrapping_anchor);
}
});

Expand Down

0 comments on commit 1a593d9

Please sign in to comment.