yomichan/tmpl/fields.html

85 lines
2.6 KiB
HTML
Raw Normal View History

2017-01-27 05:51:24 +00:00
{{#*inline "glossary-single"}}
{{~#if html~}}
{{~#if tags~}}
<div>({{#each tags}}{{name}}{{#unless @last}}, {{/unless}}{{/each}})</div>
{{~/if~}}
{{~#if glossary.[1]~}}
<ul>{{#each glossary}}<li>>{{#multiLine}}{{.}}{{/multiLine}}></li>{{/each}}</ul>
{{~else~}}
<div>{{#multiLine}}{{glossary.[0]}}{{/multiLine}}</div>
{{~/if~}}
{{~else~}}
{{~#if tags~}}
({{#each tags}}{{name}}{{#unless @last}}, {{/unless}}{{/each}})
{{~/if~}}
{{~#if glossary.[1]~}}
{{#each glossary}}{{.}}{{#unless @last}}, {{/unless}}{{/each}}
{{~else~}}
{{glossary.[0]}}
{{~/if~}}
{{~/if~}}
2017-01-24 05:12:46 +00:00
{{/inline}}
2017-01-22 03:30:01 +00:00
{{#*inline "audio"}}{{/inline}}
{{#*inline "character"}}
2017-01-24 05:12:46 +00:00
{{definition.character}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "dictionary"}}
2017-01-24 05:12:46 +00:00
{{definition.dictionary}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "expression"}}
2017-01-24 05:12:46 +00:00
{{#if modeTermKana}}{{#if definition.reading}}{{definition.reading}}{{else}}{{definition.expression}}{{/if}}{{else}}{{definition.expression}}{{/if}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "furigana"}}
2017-01-27 05:51:24 +00:00
{{~#if html~}}
{{~#if definition.reading}}<ruby>{{definition.expression}}<rt>{{definition.reading}}</rt></ruby>{{else}}{{definition.expression}}{{/if~}}
{{~else~}}
{{~#if definition.reading}}{{definition.expression}} [{{definition.reading}}]{{else}}{{definition.expression}}{{/if~}}
{{~/if~}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "glossary"}}
2017-01-27 05:51:24 +00:00
{{~#if html}}<div style="text-align: left;">{{/if~}}
{{~#if group~}}
{{~#if definition.definitions.[1]~}}
{{~#if html}}<ol>{{#each definition.definitions}}<li>{{> glossary-single}}</li>{{/each}}</ol>
{{~else}}{{#each definition.definitions}}* {{> glossary-single}}{{/each}}{{/if~}}
{{~else~}}
{{> glossary-single definition.definitions.[0]}}
{{~/if~}}
{{~else~}}
{{> glossary-single definition}}
{{~/if~}}
{{~#if html}}</div>{{/if~}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "kunyomi"}}
2017-01-27 05:51:24 +00:00
{{#each definition.kunyomi}}{{.}}{{#unless @last}}, {{/unless}}{{/each}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "onyomi"}}
2017-01-27 05:51:24 +00:00
{{#each definition.onyomi}}{{.}}{{#unless @last}}, {{/unless}}{{/each}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "reading"}}
2017-01-27 05:51:24 +00:00
{{#unless modeTermKana}}{{definition.reading}}{{/unless}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "sentence"}}
2017-01-24 05:12:46 +00:00
{{definition.sentence}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "tags"}}
2017-01-24 05:12:46 +00:00
{{#each definition.tags}}{{name}}{{#unless @last}}, {{/unless}}{{/each}}
2017-01-22 03:30:01 +00:00
{{/inline}}
{{#*inline "url"}}
2017-01-24 05:12:46 +00:00
{{#if html}}<a href="{{definition.url}}">{{definition.url}}</a>{{else}}{{definition.url}}{{/if}}
2017-01-22 03:30:01 +00:00
{{/inline}}
2017-01-27 05:51:24 +00:00
{{~> (lookup . "marker") ~}}