Fit.UI icon indicating copy to clipboard operation
Fit.UI copied to clipboard

DropDown: Better support for iOS

Open FlowIT-JIT opened this issue 6 years ago • 1 comments

The experience with the DropDown control on iOS is not great. In fact it almost doesn't work with iOS 9 and below. See #87 and #88. But even on more recent versions, the keyboard that slides up when clicking the DropDown is just annoying.

Possible solution:

If the user clicks the input section, and it has InputEnabled(true), then just focus it and do not open the dropdown. The user can now enter a seach value. Else, open the DropDown without focusing an input field - the user is expected to just point and click to select elements. However, make sure it is considered focused (control.Focused() must return true. We probably need something but the input fields to focus in this case (must have tabIndex set).

TODO: Search DropDown.js for references to focusInputOnMobile to figure out what needs to be changed. Do make sure to read related comments. Making things work on older versions of iOS is a pain so there might be reasons for the current implementation. Also consider whether something was done to reduce/prevent events firing, ensure a certain order of execution of events, reduce reflows, or something else.

Safari on iOS 6 was pretty much broken, but we should be able to get this to work with iOS 7.

We can consider #87 and #88 fixed when this issue has been resolved.

FlowIT-JIT avatar Dec 12 '19 12:12 FlowIT-JIT

Testing today on iOS 9 and iOS 13 - seems to be working acceptable. While the keyboard might still be annoying, it only pops up when clicking the input field. Clicking (touching) the arrow just opens the DropDown, and selecting items were working just fine. Both when Boundary Detection was enabled and disabled. Changing from Bug to Minor Bug.

Jemt avatar Jan 11 '20 14:01 Jemt