-
Notifications
You must be signed in to change notification settings - Fork 185
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(TabbarItem): avoid double focus (#8241)
Двойной фокус при переходе через `TabbarItem`'s табом происходит в основном из-за того, что внутри `TabbarItem`, который является кнопкой/ссылкой, лежит интерактивный `Tappable`. `Tappable` внутри нужен для того, чтобы на android был ripple эффект. ------ Видел решение #5914. Тоже изначально думал как бы оставить один Tappable, но решил сделать быстрый фикс конкретно этого поведения. Но в целом, в будущем стоит отрефакторить TabbarItem, чтобы избавиться от ненужных нод и упростить компонент. Изменения - убраем возможность фокуса на `Tappable` через tabindex="-1". - добавляем focus-visible у `Tappable` при фокусировании на `TabbarItem`. Так как иначе при фокусе с клавиатуры вообще фокуса видно не будет, из-за tabindex="-1".
- Loading branch information
1 parent
fcf48ad
commit 2b144f4
Showing
2 changed files
with
70 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters