Skip to content

Tabulation in dropdown makes tagify failΒ #1397

@Massi-X

Description

@Massi-X

Prerequisites

  • I am running the latest version
  • I checked the documentation and found no answer
  • I checked to make sure that this issue has not already been filed

πŸ’₯ Demo Page

https://jsbin.com/kedanixiso/edit?html,js,console,output
https://jsbin.com/noxuzusave/1/edit?html,js,console,output

Explanation

Go on the demo page and tab on the tagify input so that the dropdown opens. Continue tabbing, the first value is inserted. This should not happen because the first value ("1") is already present in the input. This happens because when tabbing (and only when tabbing, this does not happen when using the mouse to select) the name is passed as value instead of the real value in transformTag. This also has the side effect or creating a corrupted output list.

I suggest not to fix this, but simply to disable select with the tab key cause this is an issue for impaired users (how are they supposed to escape the dropdown after it opened?) I know they can use the esc key it but it is not really intuitive, it would be better to close the dropdown with another tab click, and if the user really wants to select something, he obviously will do with arrows/enter keys.

  • What is the expected behavior?
    Inserting a value with tab key should work normally

  • What is happening instead?
    The name is passed instead of the value in transformTag

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions