Fix kanji furigana HTML display

rust
Elnu 2 years ago
parent 7bbf0f1fd8
commit aa4408a593

@ -80,7 +80,7 @@
{{- range.text -}} {{- range.text -}}
{{- if reflect.IsMap . -}} {{- if reflect.IsMap . -}}
{{- range $kanji, $furigana := . -}} {{- range $kanji, $furigana := . -}}
<a href="https://jisho.org/search/{{- $kanji -}} %23kanji" target="_blank"><ruby>{{- $kanji -}}<rp>(</rp><rt>{{- $furigana -}}</rt><rp>)</rp></ruby></a> <a href="https://jisho.org/search/{{- $kanji -}} %23kanji" target="_blank"><ruby>{{- $kanji | safeHTML -}}<rp>(</rp><rt>{{- $furigana | safeHTML -}}</rt><rp>)</rp></ruby></a>
{{- end -}} {{- end -}}
{{- else -}} {{- else -}}
{{- . -}} {{- . -}}

Loading…
Cancel
Save