Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SelectField] Can not focus programmably #4709

Closed
scarletsky opened this issue Jul 14, 2016 · 2 comments
Closed

[SelectField] Can not focus programmably #4709

scarletsky opened this issue Jul 14, 2016 · 2 comments
Labels
bug 🐛 Something doesn't work component: select This is the name of the generic UI component, not the React module!

Comments

@scarletsky
Copy link
Contributor

Problem description

In my case, I need to implement focus the form control programmably. So I need to access the components via ref. Things has done except the SelectField component.
SelectField is composed by TextField and DropDownMenu, and I notice that I can not access the DropDownMenu because there is no ref attribute.

I wonder why you guys do not add a ref attribute in the DropDownMenu component in SelectField ?

I can send a pull request if you need.

@mpontikes mpontikes mentioned this issue Aug 5, 2016
13 tasks
@antoinerousseau
Copy link
Contributor

any luck with this? can send a PR too if it gets accepted

@antoinerousseau
Copy link
Contributor

workaround: put the tag inside a <div ref="myField"> and then call this.refs.myField.scrollIntoView() when you want to focus

@oliviertassinari oliviertassinari added component: select This is the name of the generic UI component, not the React module! bug 🐛 Something doesn't work labels Feb 12, 2017
@oliviertassinari oliviertassinari changed the title Can not focus the SelectField programmably [SelectField] Can not focus programmably Mar 26, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 Something doesn't work component: select This is the name of the generic UI component, not the React module!
Projects
None yet
Development

No branches or pull requests

3 participants