From 186026fa6dd2f0a09ac026b8e213ef26d859e1ca Mon Sep 17 00:00:00 2001 From: partisan Date: Tue, 22 Oct 2024 08:38:50 +0200 Subject: [PATCH] fixed search suggestions on other pages than main page --- static/css/style.css | 4 ++-- static/js/autocomplete.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/static/css/style.css b/static/css/style.css index 34dacec..d8d1223 100644 --- a/static/css/style.css +++ b/static/css/style.css @@ -937,13 +937,13 @@ form.torrent-sort { padding: 8px 12px; } -.show .autocomplete ul li { +.wrapper-searching .autocomplete ul li { opacity: 1; display: block; text-align: left; } -.show .autocomplete { +.wrapper-searching .autocomplete { padding-top: 10px; padding-bottom: 10px; color: var(--font-fg); diff --git a/static/js/autocomplete.js b/static/js/autocomplete.js index b704d56..939116b 100644 --- a/static/js/autocomplete.js +++ b/static/js/autocomplete.js @@ -1,7 +1,7 @@ // Wait for the DOM to load document.addEventListener('DOMContentLoaded', () => { const searchInput = document.getElementById('search-input'); - const searchWrapper = document.querySelector('.wrapper'); + const searchWrapper = document.querySelector('.wrapper, .wrapper-results'); const resultsWrapper = document.querySelector('.autocomplete'); let suggestions = [];