From 148291d3a7cea096317c1c8d22f06f6e18cfdcfb Mon Sep 17 00:00:00 2001 From: Alex Yatskov Date: Sun, 8 Jan 2017 15:33:45 -0800 Subject: WIP --- ext/bg/js/translator.js | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'ext/bg/js/translator.js') diff --git a/ext/bg/js/translator.js b/ext/bg/js/translator.js index bdd606b7..8710f568 100644 --- a/ext/bg/js/translator.js +++ b/ext/bg/js/translator.js @@ -82,6 +82,12 @@ class Translator { }); } + findTermGrouped(text, dictionaries, enableSoftKatakanaSearch) { + return this.findTerm(text, dictionaries, enableSoftKatakanaSearch).then(({length, definitions}) => { + return {length, definitions: groupTermDefs(definitions)}; + }); + } + findKanji(text, dictionaries) { const processed = {}, promises = []; for (const c of text) { -- cgit v1.2.3