mirror of
https://codeberg.org/aryak/mozhi
synced 2025-06-04 00:41:07 +05:30
fix deepl (partial fix for #55)
This commit is contained in:
23
views/deepl_extras.html
Normal file
23
views/deepl_extras.html
Normal file
@@ -0,0 +1,23 @@
|
||||
<div id="definitions_and_translations">
|
||||
<div class="translations">
|
||||
{{ if or .Translation.TargetSynonyms .Translation.SourceSynonyms }}
|
||||
<span class="def_type">Synonyms & Equivalent Words</span>
|
||||
<ul>
|
||||
{{ if .Translation.TargetSynonyms }}
|
||||
<li>
|
||||
<span class="syn_type">Synonyms for {{.Translation.OutputText}}</span>
|
||||
<span class="syn">{{ range $index, $key := .Translation.TargetSynonyms }}{{ if eq $key "" }}{{ else }}{{ if eq $index 0 }}{{ else }}, {{ end }}{{.}}{{ end }}{{ end }}</span>
|
||||
</li>
|
||||
<br>
|
||||
{{ end }}
|
||||
{{ if .Translation.SourceSynonyms }}
|
||||
<li>
|
||||
<span class="syn_type">Synonyms for {{.OriginalText}}</span>
|
||||
<span class="syn">{{ range $index, $key := .Translation.SourceSynonyms }}{{ if eq $key "" }}{{ else }}{{ if eq $index 0 }}{{ else }}, {{ end }}{{.}}{{ end }}{{ end }}</span>
|
||||
</li>
|
||||
<br>
|
||||
{{ end }}
|
||||
</ul>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
@@ -163,6 +163,9 @@
|
||||
{{ if eq .Engine "google" }}
|
||||
{{ template "google_extras" . }}
|
||||
{{ end }}
|
||||
{{ if eq .Engine "deepl" }}
|
||||
{{ template "deepl_extras" . }}
|
||||
{{ end }}
|
||||
</form>
|
||||
<script>
|
||||
// @license magnet:?xt=urn:btih:0b31508aeb0634b347b8270c7bee4d411b5d4109&dn=agpl-3.0.txt AGPL-3.0
|
||||
|
Reference in New Issue
Block a user