mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui: autocomplete: fix styles & ensure key type (#191)
This commit is contained in:
1 parent
79ec4d300c
commit
fe36a3f17e
3 files changed
+7
-21
No files matched your search
@@ -20,6 +20,8 @@ export default class AutoComplete extends DOMAttachedObject {
|
||||
this.onChange = this.onChange.bind(this);
|
||||
this.container = document.createElement('div');
|
||||
this.$dom.addClass('autocomplete-dummy').after(this.container);
|
||||
// Note: use `setTimeout(fn, 0)` to ensure that code is executed after browser autofill
|
||||
// also see https://stackoverflow.com/a/779785/13553984
|
||||
setTimeout(() => this.attach(), 0);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user