From 8e46da5e8094014eb8ecdcae036215f1845cf674 Mon Sep 17 00:00:00 2001 From: Lim Chee Aun Date: Mon, 24 Apr 2023 21:56:13 +0800 Subject: [PATCH] Fix set focus on status, make status itself scroll unwillingly --- src/components/status.jsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/components/status.jsx b/src/components/status.jsx index 8e41de98..10a78796 100644 --- a/src/components/status.jsx +++ b/src/components/status.jsx @@ -719,7 +719,8 @@ function Status({ direction="right" onClose={() => { setIsContextMenuOpen(false); - statusRef.current?.focus?.(); + // statusRef.current?.focus?.(); + statusRef.current?.closest('[tabindex]')?.focus?.(); }} portal={{ target: document.body,