aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/bg/js/search.js5
-rw-r--r--ext/fg/js/frontend.js2
2 files changed, 7 insertions, 0 deletions
diff --git a/ext/bg/js/search.js b/ext/bg/js/search.js
index 47d495e6..d69daea6 100644
--- a/ext/bg/js/search.js
+++ b/ext/bg/js/search.js
@@ -301,6 +301,11 @@ class DisplaySearch extends Display {
this.queryParser.setText(interpretedQuery);
}
+ async setContent(type, details) {
+ this.query.blur();
+ await super.setContent(type, details);
+ }
+
setIntroVisible(visible, animate) {
if (this.introVisible === visible) {
return;
diff --git a/ext/fg/js/frontend.js b/ext/fg/js/frontend.js
index b2cb0cd8..7ba0de2e 100644
--- a/ext/fg/js/frontend.js
+++ b/ext/fg/js/frontend.js
@@ -257,6 +257,8 @@ class Frontend {
const definitions = await apiKanjiFind(searchText, optionsContext);
if (definitions.length === 0) { return null; }
+ textSource.setEndOffset(1);
+
return {definitions, type: 'kanji'};
}