Want to contribute? Fork me on Codeberg.org!
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
This repo is archived. You can view files and clone it, but cannot push or open issues/pull-requests.

27 lines
707 B

{{ define "entry" }}
<div class="box">
<h3 lang="ja">
<a href="/word/{{ .Kanji }}">
{{- range .Furigana -}}
{{- if .Furigana -}}
<ruby>{{- .Kanji -}}<rp>(</rp><rt>{{- .Furigana -}}</rt><rp>)</rp></ruby>
{{- else -}}
{{- .Kanji -}}
{{- end -}}
{{- end -}}
</a>
</h3>
{{- $count := len .Definitions -}}
{{ if eq $count 1 -}}
<p>{{- template "definition" (index .Definitions 0) -}}</p>
{{- else if ne $count 0 -}}
<ol>
{{- range .Definitions }}
<li>
{{ template "definition" . }}
</li>
{{- end }}
</ol>
{{- end }}
</div>
{{ end }}