From 11e44dabc31ae66cacfdf0f02c9b8b08aaa4d22d Mon Sep 17 00:00:00 2001 From: lilydjwg Date: Wed, 6 Oct 2021 21:51:16 +0800 Subject: [PATCH] use keydown instead of keyup to watch Enter; trigger search on group change keyup receives keys from after IME --- src/App.svelte | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/App.svelte b/src/App.svelte index e9795bf..5b03a71 100644 --- a/src/App.svelte +++ b/src/App.svelte @@ -101,6 +101,13 @@ } } + async function on_group_change() { + error = '' + if(query) { + await do_search() + } + } + async function do_search_more() { const more = result.messages[result.messages.length-1].t const old_msgs = result.messages @@ -114,7 +121,7 @@