From f8700247a34d2edab66427d07f558d85d9b934d2 Mon Sep 17 00:00:00 2001 From: rain Date: Thu, 25 May 2023 13:56:33 -0500 Subject: [PATCH] Re-added the toggle active row function --- app/static/js/table.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/static/js/table.js b/app/static/js/table.js index 4654def..d6344ac 100644 --- a/app/static/js/table.js +++ b/app/static/js/table.js @@ -6,6 +6,14 @@ function count_rows() { return get_displayed_rows().length; } +// Add toggle listener for row clicks +document.querySelectorAll("tbody tr").forEach((row) => { + row.addEventListener("click", function() { + row.classList.toggle('active'); + }); +}); + +// Add listener for copy addresses from query document.querySelector(".result-count").addEventListener("click", function() { var addresses = []; get_displayed_rows().forEach((element) => {