firefox-devtools / firefox-devtools/profiler
Convert IdleSearchField to a function compontent / use hooks
Open
code maintenance
- Dominant language
- TypeScript
- Stars
- 1.5k
- Forks
- 491
- Avg merge
- 3d 46m
- Merged PRs (30d)
- 27
Description
IdleSearchField currently does not provide a way for parent components to focus the `input`. The current patch in #6025 uses a `ref` on a wrapper element and then gets at the `input` using `wrapper.querySelector("input[type=search]")` .
A cleaner solution would be to convert `IdleSearchField` to a function component and then use `forwardRef`, so that `` gives the parent a ref to the input.
┆Issue is synchronized with this [Jira Task](https://mozilla-hub.atlassian.net/browse/FP-1310)
Contributor guide
Assessment
This issue has not been assessed yet.