From 8e0518d777cc824987c27ff007550e2e0e2decbf Mon Sep 17 00:00:00 2001 From: nimishmedatwal Date: Mon, 29 Jan 2024 16:47:34 +0530 Subject: [PATCH] user_profile: Navigate tabs by arrow keys. Left/right keys arrows in User Profile now navigates between tabs when it's first opened. Fixes #28615 --- web/src/user_profile.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/web/src/user_profile.js b/web/src/user_profile.js index 58ff671146..abf9854395 100644 --- a/web/src/user_profile.js +++ b/web/src/user_profile.js @@ -481,6 +481,9 @@ export function show_user_profile(user, default_tab_key = "profile-tab") { const $elem = toggler.get(); $elem.addClass("large allow-overflow"); $("#tab-toggle").append($elem); + setTimeout(() => { + $(".ind-tab.selected").trigger("focus"); + }, 0); if (show_user_subscribe_widget) { reset_subscribe_widget(); }