-
Notifications
You must be signed in to change notification settings - Fork 23
Auto Focus? #9
Comments
Yes it is possible, what is your issue! |
I currently have a modal with an OK button. When that modal opens, I want the OK button to be focused. Is there a code example that does this? |
Just add the |
@diegoddox Sounds good, actually what was needed was
This also does not quite work |
Actually, this only seems to work on select inputs. Not on buttons. Is there an example with a working autoFocus on a button I can work off of? |
Your question has nothing to do with the
|
Sure it does. Since my app is using the Redux pattern, components can't have ref or state. So, this doesn't work. The autofocus value on the button should just work when placed on a modal from this repo. |
no, and you can still use |
It should be possible to automatically focus a selected modal element when it opens.
It should be possible to focus a specific other element when the modal closes.
The text was updated successfully, but these errors were encountered: