fix(ui): hide "Previous page" inputs

Replaces logic for hiding certain buttons with logic to hide inputs that start with "Previous page," avoiding redundant hiding of buttons. This refines UI behavior and improves code maintainability by correctly targeting elements to be hidden.
This commit is contained in:
Kumi 2024-11-14 16:54:16 +01:00
parent 36a095145a
commit 923676455e
Signed by: kumi
GPG key ID: ECBCC9082395383F

View file

@ -74,11 +74,15 @@ document.addEventListener("DOMContentLoaded", function () {
$("button").each(function () {
if ($(this).text().startsWith("Check")) {
$(this).hide();
} else if ($(this).text().startsWith("Previous page")) {
$(this).hide();
}
});
$("input").each(function () {
if ($(this).val().startsWith("Previous page")) {
$(this).hide();
}
}
$("form").each(function () {
const form = $(this);