aboutsummaryrefslogtreecommitdiff
path: root/tmpl/fields.html
blob: d5c9f1db648d648b3a212f5e597007c255faffb4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
{{#*inline "definition"}}
    {{#if html}}
        {{#if definition.tags}}
            (<div>{{#each definition.tags}}{{name}}{{#unless @last}}, {{/unless}}{{/each}}</div>)
        {{/if}}
        {{#if definition.glossary.[1]}}
            <ul>{{#each definition.glossary}}<li>>{{#multiLine}}{{.}}{{/multiLine}}></li>{{/each}}</ul>
        {{else}}
            <div>{{#multiLine}}{{definition.glossary.[0]}}{{/multiLine}}</div>
        {{/if}}
    {{else}}
        {{#if definition.tags}}({{#each definition.tags}}{{name}}{{#unless @last}}, {{/unless}}{{/each}}) {{/if}}{{#if definition.glossary.[1]}}{{#each definition.glossary}}{{.}}{{#unless @last}}, {{/unless}}{{/each}}{{else}}{{definition.glossary.[0]}}{{/if}}
    {{/if}}
{{/inline}}

{{#*inline "audio"}}{{/inline}}

{{#*inline "character"}}
    {{definition.character}}
{{/inline}}

{{#*inline "dictionary"}}
    {{definition.dictionary}}
{{/inline}}

{{#*inline "expression"}}
    {{#if modeTermKana}}{{#if definition.reading}}{{definition.reading}}{{else}}{{definition.expression}}{{/if}}{{else}}{{definition.expression}}{{/if}}
{{/inline}}

{{#*inline "furigana"}}
    {{#if definition.reading}}<ruby>{{definition.expression}}<rt>{{definition.reading}}</rt></ruby>{{else}}{{definition.expression}}{{/if}}
{{/inline}}

{{#*inline "glossary"}}
<div style="text-align: left;">
{{#if group}}
    {{#if definitions.[1]}}
    <ol>
        {{#each definitions}}
            <li>{{> definition}}</li>
        {{/each}}
    </ol>
    {{else}}
        {{> definition definitions.[0]}}
    {{/if}}
{{else}}
    {{> definition}}
{{/if}}
</div>
{{/inline}}

{{#*inline "kunyomi"}}
    {{definition.kunyomi}}
{{/inline}}

{{#*inline "onyomi"}}
    {{definition.onyomi}}
{{/inline}}

{{#*inline "reading"}}
    {{definition.reading}}
{{/inline}}

{{#*inline "sentence"}}
    {{definition.sentence}}
{{/inline}}

{{#*inline "tags"}}
    {{#each definition.tags}}{{name}}{{#unless @last}}, {{/unless}}{{/each}}
{{/inline}}

{{#*inline "url"}}
    {{#if html}}<a href="{{definition.url}}">{{definition.url}}</a>{{else}}{{definition.url}}{{/if}}
{{/inline}}

{{> (lookup . "marker") }}