ui
ui copied to clipboard
Command component bug with keyboard navigation ⌨️ 🐞
On https://ui.shadcn.com/themes, after opening the command bar and repeatedly hitting the down arrow ⬇️, navigation through command items glitches.
@harveyhq perfect working not get issue Screencast from 15-12-23 01:35:56 PM IST.webm
@Dhruvn-patel But as I see you just opened Command menu, after opening it please try pressing only the down arrow key a few times to navigate through the items, on my vid you can see that the navigation doesn't work as expected. I tried on Windows 11, latest versions of Chrome and Firefox, the result is the same.
Yes, it advances one item and then starts over. If you have 10 items you have to tab through 10 times almost like it discovers a new item each time and adds it to a tab list and then starts over from the first tab.
The input and select components work the same way.
Any idea how to fix keyboard interaction with arrow or tab buttons?
This issue has been automatically closed because it received no activity for a while. If you think it was closed by accident, please leave a comment. Thank you.
I'm seeing this issue with my whole form. It almost seems like something is forcing the whole form to re-render, but all I'm doing is tabbing through the form fields. @Jamison1 did you find a workaround for this?
@shadcn this is still happening on the themes page and when using the command component, especially when rendering async search results
@shadcn I'm seeing the same issue.
@makrandgupta @dlicheva re-opening. I'll take a look.
The issue for me is only happening when the CommandItem
contains an Avatar
with an AvatarFallback
. It's resolved if I remove the AvatarFallback
and set the Avatar
's tabIndex to -1
https://www.instagram.com/1900_officelle?igsh=MW5ueDI0b21qbW44Zg==
Diana @.***> schrieb am Mo., 5. Aug. 2024, 12:55:
The issue for me is only happening when the CommandItem contains an Avatar with an AvatarFallback. It's resolved if I remove the AvatarFallback.
— Reply to this email directly, view it on GitHub https://github.com/shadcn-ui/ui/issues/2116#issuecomment-2268786014, or unsubscribe https://github.com/notifications/unsubscribe-auth/BIO77CM6WUBLWCWGYGV77QTZP5K25AVCNFSM6AAAAABAVRC7XCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDENRYG44DMMBRGQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>