From cd0a3f6de09095eecf46ed2b41db6470343370ce Mon Sep 17 00:00:00 2001 From: "Jokob @NetAlertX" <96159884+jokob-sk@users.noreply.github.com> Date: Fri, 27 Mar 2026 10:12:12 +0000 Subject: [PATCH] feat(plugins): Refactor auto-hide functionality to leverage Bootstrap's tab management for improved visibility handling --- front/pluginsCore.php | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/front/pluginsCore.php b/front/pluginsCore.php index 36685e51..2f7f9689 100755 --- a/front/pluginsCore.php +++ b/front/pluginsCore.php @@ -484,13 +484,10 @@ function autoHideEmptyTabs(counts, prefixes) { if ($activeLi.length === 0) { const $firstVisibleLi = $(`#tabs-location li:visible`).first(); if ($firstVisibleLi.length) { - $firstVisibleLi.addClass('active'); - const targetPrefix = $firstVisibleLi.find('a').attr('href')?.replace('#', ''); - if (targetPrefix) { - $(`#tabs-content-location > #${targetPrefix}`).addClass('active'); - // Trigger shown.bs.tab so deferred DataTables initialize - $firstVisibleLi.find('a').tab('show'); - } + // Let Bootstrap's .tab('show') manage the active class on both + // the