JedWatson / JedWatson/react-select

Input loses focus when removing value unless menu is open, on safari for iOS

Open
#3,607 3 comments 8 reactions 0 assignees View on GitHub

@karlingen is already working on this.

Since Jun 11, 2019.

  • #3617 by @karlingen — open
issue/bug-confirmed issue/has-pr issue/reviewed
Dominant language
TypeScript
Stars
28k
Forks
4.1k
PR merge metrics
No merged PRs in 30d

Description

On mobile devices, whenever the menu is closed, removing an option from a MultiValue Select causes the input to lose focus. This makes you having to tap on the input field again after removing some values before you can start typing again.

Steps to replicate

  1. Navigate to the repro link using Safari on an iPhone.
  2. Add a few options
  3. Tap on the input and make sure it is focused
  4. Remove one option by tapping the "x" button next to it and notice how the input is still focused
  5. Remove another option and notice how the input no longer is focused.

React Select v3.0.4
React v16.8.6

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the focus loss in Safari on an iPhone using the linked CodeSandbox and the MultiValue Select steps. Review open pull request #3617 for the work already underway, then verify that removing successive options while the menu is closed keeps the input focused.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.