From ba5e2dba3c95a7b8b41b267df20b96e26b722446 Mon Sep 17 00:00:00 2001 From: mrilyew <99399973+mrilyew@users.noreply.github.com> Date: Fri, 13 Dec 2024 22:03:58 +0300 Subject: [PATCH] fix(search tips): remove them on click --- Web/static/css/main.css | 2 +- Web/static/js/al_navigation.js | 2 +- Web/static/js/router.js | 2 ++ 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/Web/static/css/main.css b/Web/static/css/main.css index e740e49d..928ef300 100644 --- a/Web/static/css/main.css +++ b/Web/static/css/main.css @@ -2856,7 +2856,7 @@ a.poll-retract-vote { .page_header.search_expanded .header_navigation #search_box #searchBoxFastTips.shown { display: flex; flex-direction: column; - z-index: 2; + z-index: 11; } .page_header.search_expanded_at_all .header_navigation #search_box #searchBoxFastTips.shown { diff --git a/Web/static/js/al_navigation.js b/Web/static/js/al_navigation.js index 394fdbae..49ec4385 100644 --- a/Web/static/js/al_navigation.js +++ b/Web/static/js/al_navigation.js @@ -138,7 +138,7 @@ u(`#search_box input[type='search']`).on('input', async (e) => { u('#searchBoxFastTips').html('') json_result.items.forEach(item => { u('#searchBoxFastTips').append(` - +
${ovk_proc_strtr(item['name'].escapeHtml(), 50)} diff --git a/Web/static/js/router.js b/Web/static/js/router.js index b0f103ee..51ba1a48 100644 --- a/Web/static/js/router.js +++ b/Web/static/js/router.js @@ -102,6 +102,8 @@ window.router = new class { } else { if(u('.page_header').hasClass('search_expanded_at_all')) { u('.page_header').removeClass('search_expanded_at_all').removeClass('search_expanded') + } else { + u('.page_header').removeClass('search_expanded') } }