miljodir / md-components

Design-komponenter for Miljødirektoratet (CSS og React)
https://miljodir.github.io/md-components
MIT License
2 stars 2 forks source link

fix: When escaping inside an autocomplete, the displayvalue was shown while input was focused #179

Closed aurorascharff closed 2 weeks ago

aurorascharff commented 2 weeks ago

Describe your changes

When closing an autocomplete with enter or escape, the displayvalue was shown while input being focused. The value would not be editable and behavior was weird. Remove the autofocus for the autocomplete on close. In the future, hopefully the bug can be fixed in a better way.

Checklist before requesting a review

github-actions[bot] commented 2 weeks ago

Please set a versioning label of either major, minor, or patch to the pull request.