Difference between revisions of "Template:Literal translation/doc"

From blackwiki
Jump to navigation Jump to search
imported>Menchi
(explantion)
imported>Menchi
(replace a rarely used example (italics, apparently this template was based off {{circa}}) with a more useful one (unlinking) // To fill out missing fields in documentation // List synonyms)
Line 7: Line 7:
 
* <code><nowiki>{{literal translation}}</nowiki></code> &rarr; {{literal translation}}
 
* <code><nowiki>{{literal translation}}</nowiki></code> &rarr; {{literal translation}}
 
* <code><nowiki>{{literal translation|lk=yes}}</nowiki></code> &rarr; {{literal translation|lk=yes}}
 
* <code><nowiki>{{literal translation|lk=yes}}</nowiki></code> &rarr; {{literal translation|lk=yes}}
* <code><nowiki>{{literal translation|i=yes}}</nowiki></code> &rarr; {{literal translation|i=yes}}
+
* <code><nowiki>{{literal translation|lk=no}}</nowiki></code> &rarr; {{literal translation|lk=no}}
 
* <code><nowiki>{{literal translation|a}}</nowiki></code> &rarr; {{literal translation|a}}
 
* <code><nowiki>{{literal translation|a}}</nowiki></code> &rarr; {{literal translation|a}}
* <code><nowiki>{{literal translation|''a''}}</nowiki></code> &rarr; {{literal translation|''a''}}
+
* <code><nowiki>{{literal translation|''a'' A}}</nowiki></code> &rarr; {{literal translation|''a'' A}}
 
* <code><nowiki>{{literal translation|a|b}}</nowiki></code> &rarr; {{literal translation|a|b}}
 
* <code><nowiki>{{literal translation|a|b}}</nowiki></code> &rarr; {{literal translation|a|b}}
 
* <code><nowiki>{{literal translation|a|b|c|d}}</nowiki></code> &rarr; {{literal translation|a|b|c|d}}
 
* <code><nowiki>{{literal translation|a|b|c|d}}</nowiki></code> &rarr; {{literal translation|a|b|c|d}}
  
 
For now, the template takes up to four separate translations (<code>|a|b|c|d</code>). If each meaning is a single word, using serial commas is another stylistic choice: <code>a, b, c, d</code>.
 
For now, the template takes up to four separate translations (<code>|a|b|c|d</code>). If each meaning is a single word, using serial commas is another stylistic choice: <code>a, b, c, d</code>.
 +
 +
Unlinking (<code>lk=no</code>) avoids cluttering the same paragraph or list with repetitive overlinking of "{{lit.}}".
  
 
== Spacing demonstration ==
 
== Spacing demonstration ==
Line 33: Line 35:
 
"1": {
 
"1": {
 
"label": "literal meaning",
 
"label": "literal meaning",
"example": "\"not is\"",
+
"description": "Gloss for a term",
 
"type": "string",
 
"type": "string",
 
"required": true
 
"required": true
 
},
 
},
 
"2": {
 
"2": {
"label": "second literal meaning",
+
"label": "2nd literal meaning",
 +
"description": "Another meaning, if any",
 +
"type": "string"
 +
},
 +
"3": {
 +
"label": "3rd literal meaning",
 +
"description": "Another meaning, if any",
 +
"type": "string"
 +
},
 +
"4": {
 +
"label": "4th literal meaning",
 +
"description": "Another meaning (last possible), if any",
 
"type": "string"
 
"type": "string"
 
},
 
},
 
"sortable": {
 
"sortable": {
"type": "string"
+
"type": "string",
 +
"description": "In sortable tables, ignore 'lit.'"
 
},
 
},
 
"i": {
 
"i": {
 
"label": "italic",
 
"label": "italic",
 +
"description": "If 'yes', the prefix 'lit.' is italicized. The meaning is still not italicized. Italics of either is almost never necessary stylistically.",
 
"type": "string"
 
"type": "string"
 
},
 
},
 
"lk": {
 
"lk": {
 
"label": "link",
 
"label": "link",
"type": "string"
+
"type": "string",
 +
"description": "If 'yes' or 'on', linked to the article on literal translation. If 'no' or 'off', no links or dashed underlines."
 
}
 
}
 
}
 
}
 
}
 
}
 
</templatedata>
 
</templatedata>
 +
 +
==Redirects==
 +
Any of the following can be used instead of {{tl|literal translation}}, with the same parameters and results:
 +
*{{tl|Lit}} / {{tl|lit}}
 +
*{{tl|Lit.}} / {{tl|lit.}}
 +
*{{tl|Literally}} / {{tl|literally}}

Revision as of 09:09, 7 August 2020

Currently this template uses single quotation marks ('…'), because the present Wikipedia's Manual of Style (MOS:SINGLE) suggests that simple glosses be enclosed this way.

Usage

For now, the template takes up to four separate translations (|a|b|c|d). If each meaning is a single word, using serial commas is another stylistic choice: a, b, c, d.

Unlinking (lk=no) avoids cluttering the same paragraph or list with repetitive overlinking of "lit.".

Spacing demonstration

  • a{{literal translation}}bcd → alit.bcd
  • a{{literal translation|i=yes}}bcd → alit.bcd
  • a{{literal translation|b}}cd → alit.Template:Sp 'b'cd
  • a{{literal translation|b|i=yes}}cd → alit.Template:Sp 'b'cd
  • a{{literal translation|b|c}}d → alit.Template:Sp 'b'Template:Sp or 'c'd
  • a{{literal translation|b|c|i=yes}}d → alit.Template:Sp 'b'Template:Sp or 'c'd


No description.

Template parameters

ParameterDescriptionTypeStatus
literal meaning1

Gloss for a term

Stringrequired
2nd literal meaning2

Another meaning, if any

Stringoptional
3rd literal meaning3

Another meaning, if any

Stringoptional
4th literal meaning4

Another meaning (last possible), if any

Stringoptional
Sortablesortable

In sortable tables, ignore 'lit.'

Stringoptional
italici

If 'yes', the prefix 'lit.' is italicized. The meaning is still not italicized. Italics of either is almost never necessary stylistically.

Stringoptional
linklk

If 'yes' or 'on', linked to the article on literal translation. If 'no' or 'off', no links or dashed underlines.

Stringoptional

Redirects

Any of the following can be used instead of {{literal translation}}, with the same parameters and results: