From 464cddcbed436fcf1b5404b35254393c2452bad5 Mon Sep 17 00:00:00 2001
From: SuperMaxusa <41739128+SuperMaxusa@users.noreply.github.com>
Date: Sun, 14 Sep 2025 01:25:29 +0300
Subject: [PATCH] fix filters, add "Reset filters" button (#1405)
---
index.html | 4 +++-
src/browser/main.js | 11 ++++++++++-
2 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/index.html b/index.html
index 589bf8c0..37bfe324 100644
--- a/index.html
+++ b/index.html
@@ -57,7 +57,9 @@
-->
-
+
diff --git a/src/browser/main.js b/src/browser/main.js
index b41c464b..4a4bf27e 100644
--- a/src/browser/main.js
+++ b/src/browser/main.js
@@ -1667,7 +1667,7 @@ function onload()
};
}
- const os_info = Array.from(document.querySelectorAll("#oses tbody tr")).map(element =>
+ const os_info = Array.from(document.querySelectorAll("#oses a.tr")).map(element =>
{
const [_, size_raw, unit] = element.children[1].textContent.match(/([\d\.]+)\+? (\w+)/);
let size = +size_raw;
@@ -1764,6 +1764,15 @@ function onload()
}
}
+ $("reset_filters").onclick = function()
+ {
+ for(const element of document.querySelectorAll("#filter input[type=checkbox]"))
+ {
+ element.checked = false;
+ }
+ update_filters();
+ };
+
function set_proxy_value(id, value)
{
const elem = $(id);