From 39d9d74210b276c34a91ef71b8b1a37617d1e4a7 Mon Sep 17 00:00:00 2001 From: Satyam Date: Wed, 25 Feb 2026 12:01:00 +0100 Subject: [PATCH 1/2] =?UTF-8?q?the=20span=20with=20the=20text=20=E2=80=9C(?= =?UTF-8?q?Selected)=E2=80=9D=20becomes=20part=20of=20the=20link=20and=20i?= =?UTF-8?q?s=20read=20out=20to=20screen=20reader=20users.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Tabs/classes/class.ilTabsGUI.php | 17 +++++++++++------ .../Tabs/templates/default/tpl.sub_tabs.html | 4 +++- .../Tabs/templates/default/tpl.tabs.html | 4 +++- 3 files changed, 17 insertions(+), 8 deletions(-) diff --git a/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php b/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php index 19d5939846ce..bfd88f16101a 100755 --- a/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php +++ b/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php @@ -437,9 +437,7 @@ private function __getHTML( } if ($tabtype === "tabactive" || $tabtype === "subtabactive") { - $tpl->setCurrentBlock("sel_text"); - $tpl->setVariable("TXT_SELECTED", $lng->txt("stat_selected")); - $tpl->parseCurrentBlock(); + //remove TXT_SELECTED area block if (!$this->getSetupMode()) { if ($a_get_sub_tabs) { @@ -460,17 +458,24 @@ private function __getHTML( : ""; // bs-patch: end - $tpl->setVariable($pre2 . "TAB_TYPE", $tabtype); - $hash = ""; + $tpl->setVariable($pre2 . "TAB_TYPE", $tabtype); + if ($target["dir_text"]) { $text = $target["text"]; } else { $text = $lng->txt($target["text"]); } + + if ($tabtype === "active") { + $text .= ' (' . $lng->txt("selected") . ')'; + } + $link = $f->link()->standard($text, $target["link"]); + if ($target["frame"] != "") { - $link->withOpenInNewViewport(true); + $link = $link->withOpenInNewViewport(true); } + $ttext = $ilHelp->getTabTooltipText($target["id"]); if ($ttext !== "") { $link = $link->withHelpTopics( diff --git a/components/ILIAS/UIComponent/Tabs/templates/default/tpl.sub_tabs.html b/components/ILIAS/UIComponent/Tabs/templates/default/tpl.sub_tabs.html index 1bdea3731f62..74419f1e221e 100755 --- a/components/ILIAS/UIComponent/Tabs/templates/default/tpl.sub_tabs.html +++ b/components/ILIAS/UIComponent/Tabs/templates/default/tpl.sub_tabs.html @@ -1,6 +1,8 @@

{TXT_SUBTABS}

diff --git a/components/ILIAS/UIComponent/Tabs/templates/default/tpl.tabs.html b/components/ILIAS/UIComponent/Tabs/templates/default/tpl.tabs.html index d02975b08c74..13fd9409707c 100755 --- a/components/ILIAS/UIComponent/Tabs/templates/default/tpl.tabs.html +++ b/components/ILIAS/UIComponent/Tabs/templates/default/tpl.tabs.html @@ -7,7 +7,9 @@

{TXT_TABS}

  • {BACK_ICON} {BACK_TAB_TEXT}
  • -
  • {LINK} ({TXT_SELECTED})
  • +
  • + {LINK} +
  • From dd3a9f6fe49cf441956e3d4bfee77d9465591c4e Mon Sep 17 00:00:00 2001 From: Satyam Valjibhai Mangroliya <93871216+satyammangroliya@users.noreply.github.com> Date: Wed, 25 Feb 2026 16:29:07 +0100 Subject: [PATCH 2/2] Fix formatting issue in setVariable call --- components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php b/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php index bfd88f16101a..712c110b0cb8 100755 --- a/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php +++ b/components/ILIAS/UIComponent/Tabs/classes/class.ilTabsGUI.php @@ -458,7 +458,7 @@ private function __getHTML( : ""; // bs-patch: end - $tpl->setVariable($pre2 . "TAB_TYPE", $tabtype); + $tpl->setVariable($pre2 . "TAB_TYPE", $tabtype); if ($target["dir_text"]) { $text = $target["text"];