github / github/auto-complete-element

Dropdown does not close on all blur events

Abierto
#136 0 comentarios 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
JavaScript
Estrellas
407
Forks
57
Merge medio
1 d 7 h
PR fusionados (30 d)
5

Descripción

We recently moved our application to this library from twitter-typeahead and have run into an issue where the results dropdown will only close when a selection is made. If a user clicks away from the input or tabs to the next form item the dropdown remains open.

This is inconvenient when a value for the field is already set and does not need to be changed. The user accidentally clicks the input or is tabbing through the page and the dropdown opens from the focus event, visually blocking the next form fields until the user makes the selection again.

Is this dropdown behavior intended? If so, could a prop be added so that implementers can turn it on or off?

If it isn't intended behavior, I think changing [this line](https://github.com/github/auto-complete-element/blob/main/src/autocomplete.ts#L250) to `this.interactingWithList = false` or possibly just removing that line altogether would fix things.

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Start at src/autocomplete.ts line 250 and trace how blur, focus, and list interaction state control the dropdown. Confirm the intended behavior for clicking away and tabbing, then verify that the dropdown closes in both cases without breaking selection behavior.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
javascript
Área
frontend
Tipo de issue
Error
Dificultad
2/5
Tiempo estimado
1-3 horas
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
55/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.