From c89678f5dbcb892225ce3781c350fc630d776373 Mon Sep 17 00:00:00 2001 From: Yoitsumi Date: Sun, 20 Aug 2017 16:07:55 +0200 Subject: Improve {furigana} marker for anki export --- tmpl/fields.html | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) (limited to 'tmpl') diff --git a/tmpl/fields.html b/tmpl/fields.html index 944a43e6..8bd94dc0 100644 --- a/tmpl/fields.html +++ b/tmpl/fields.html @@ -44,9 +44,19 @@ {{#*inline "furigana"}} {{~#if html~}} - {{~#if definition.reading}}{{definition.expression}}{{definition.reading}}{{else}}{{definition.expression}}{{/if~}} + {{~#definition.furigana~}} + {{~#if furigana~}} + {{text}}{{furigana}} + {{~else~}} + {{text}} + {{/if~}} + {{~/definition.furigana~}} {{~else~}} - {{~#if definition.reading}}{{definition.expression}} [{{definition.reading}}]{{else}}{{definition.expression}}{{/if~}} + {{#definition.furigana}} + {{~#furigana}} {{/furigana~}} + {{text}} + {{~#furigana}}[{{.}}]{{/furigana~}} + {{/definition.furigana}} {{~/if~}} {{/inline}} -- cgit v1.2.3