leave more time to update_value() before hide

This commit is contained in:
lilydjwg 2021-10-28 13:34:59 +08:00
parent c754fe3a90
commit ead237f941

View File

@ -127,7 +127,7 @@
<input bind:this={input} type="text" <input bind:this={input} type="text"
on:input={() => {should_hide=false;may_complete()}} on:input={() => {should_hide=false;may_complete()}}
on:focus={() => should_hide=false} on:focus={() => should_hide=false}
on:blur={() => {setTimeout(() => should_hide=true, 100);update_value()}} on:blur={() => {setTimeout(() => should_hide=true, 500);update_value()}}
on:keydown={select_by_key} on:keydown={select_by_key}
/> />
<img class="selected-avatar" alt="" src="{url}/avatar/{selected?selected:'nobody'}.jpg"/> <img class="selected-avatar" alt="" src="{url}/avatar/{selected?selected:'nobody'}.jpg"/>