-
Notifications
You must be signed in to change notification settings - Fork 4.1k
focus start from selected option #3813
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
Conversation
💥 No ChangesetLatest commit: a67c548 Merging this PR will not cause any packages to be released. If these changes should not cause updates to packages in this repo, this is fine 🙂 If these changes should be published to npm, you need to add a changeset. Click here to learn what changesets are, and how to add one. Click here if you're a maintainer who wants to add a changeset to this PR |
Hey @JedWatson + other maintainers - 👋🏼 I'm on the front end platform team for Trello, and we're currently using |
Hey @ankush29 thanks for the PR and @jamieshark thanks for the offer to help get it over the line. This one (and #3815 and #3814) are pretty hard to review without any context on
In this case, it looks like this change could introduce issues because not all options are expected to be focusable, which is why the Can you help answer the points above? Thanks! |
@JedWatson - thanks for responding! Here's some more context from our end:
You bring up a good point of not all menu options being focusable. I also tried to create a workaround for this by using the |
An example on CodeSandbox on how the focus is not working properly: https://codesandbox.io/s/autumn-wind-l3ed8?fontsize=14 Note that whatever the selected option is, when opening the menu it will always focus the first option. |
Hello! I'm closely following this because it'd be useful for the app I'm working on as well. Luckily I found a workaround, it flickers a little at the beggining, but it's good enough until this is merged: <Select
ref={ref}
options={options}
value={value}
onMenuOpen={() => {
setTimeout(() => {
ref.current.select.scrollToFocusedOptionOnUpdate = true;
ref.current.select.setState({
focusedOption: options.find(option => option.value === value)
});
}, 0);
}}
/> |
Hey guys, is this getting merged any time soon? @JedWatson |
Since it looks like there is no progress on this PR, I've opened a new one in #3868. |
@JedWatson is there any update on when you could look at this PR. This is a blocking bug. |
@Avery246813579 it looks like this PR won't be merged because it contains some errors (as pointed out by @JedWatson) and since then there has not been any progress on this PR. There's a new pull request #3868 that contains a fix while respecting @JedWatson's comments. So far the maintainers didn't have any time to have a look at it, so we just patiently have to wait until they do have time to provide feedback or merge the changes. |
I ended up rolling back to v3.0.3 in order to fix this issue. Some of you guys may have to do the same until this issue is resolved properly. |
Is there any update for this issue? |
@Huanghuiying0624 nope, seems like the only way to get this working is rolling back to 3.0.3. |
PR #3868 addresses this issue. Fix released in version |
No description provided.