From ec1441434f35ad7ac2d1feb4eae1cee12bf00609 Mon Sep 17 00:00:00 2001 From: siikamiika Date: Sat, 3 Aug 2019 15:50:49 +0300 Subject: [PATCH] allow multi level context --- ext/mixed/js/display.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ext/mixed/js/display.js b/ext/mixed/js/display.js index 0067d457..9a178a1f 100644 --- a/ext/mixed/js/display.js +++ b/ext/mixed/js/display.js @@ -62,6 +62,7 @@ class Display { if (this.context) { context.sentence = this.context.sentence; context.url = this.context.url; + context.source.source = this.context.source; } const kanjiDefs = await apiKanjiFind(link.text()); @@ -100,6 +101,7 @@ class Display { if (this.context) { context.sentence = sentence; context.url = this.context.url; + context.source.source = this.context.source; } this.termsShow(definitions, this.options, context); @@ -405,7 +407,8 @@ class Display { const context = { url: this.context.source.url, sentence: this.context.source.sentence, - index: this.context.source.index + index: this.context.source.index, + source: this.context.source.source }; this.termsShow(this.context.source.definitions, this.options, context);