Template:example/documentation: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{{documentation subpage}} {{uses lua|Module:example}} {{shortcut|Template:ex}} Renders an example sentence for a language entry. ==Usage== Here's a sample usage as you might find with a definition. # to {{tempn|eng|write}} {{tempn|eng|in}} #: {{tempn|example|kil||Drazam wihurad haleṯad '''lešēndah'''.|I '''wrote''' my name in the book.}} This would render the below: # to {{eng|write}} {{eng|in}} #: {{example|kil||Drazam wihurad haleṯad '''lešēndah'''.|I '''...") |
TheNightAvl (talk | contribs) mNo edit summary |
||
(8 intermediate revisions by 2 users not shown) | |||
Line 5: | Line 5: | ||
==Usage== | ==Usage== | ||
Here's a sample usage as you might find with a definition. | Here's a sample usage as you might find with a definition. You can use <code>*asterisks*</code> to bold the sentence and gloss. | ||
# to {{tempn|eng|write}} {{tempn|eng|in}} | # to {{tempn|eng|write}} {{tempn|eng|in}} | ||
#: {{tempn| | #: {{tempn|ex|kil|Drazam wihurad haleṯad *lešēndah*.|I *wrote* my name in the book.}} | ||
This would render the below: | This would render the below: | ||
# to {{eng|write}} {{eng|in}} | # to {{eng|write}} {{eng|in}} | ||
#: {{ | #: {{ex|kil|Drazam wihurad haleṯad *lešēndah*.|I *wrote* my name in the book.|nocat=1}} | ||
and would add the category [[:Kilitic terms with usage examples]]. | and would add the category [[:Category:Kilitic terms with usage examples|Kilitic terms with usage examples]]. | ||
===Parameters=== | |||
; {{para|1|req=1}} | |||
: The language code of the language that the example is in. | |||
; {{para|2|req=1}} | |||
: The example sentence itself. | |||
; {{para|3|opt=1}} | |||
: An optional translation. | |||
; {{para|inline}} | |||
: Whether the example is short enough that it can be shown inline. | |||
; {{para|nocat}} | |||
: An optional marker which, if set to true, will suppress any categories from being automatically added to the entry. |
Latest revision as of 15:41, 23 February 2024
Uses Lua: |
Shortcut
{{ex}} |
Renders an example sentence for a language entry.
Usage
Here's a sample usage as you might find with a definition. You can use *asterisks*
to bold the sentence and gloss.
# to {{eng|write}} {{eng|in}} #: {{ex|kil|Drazam wihurad haleṯad *lešēndah*.|I *wrote* my name in the book.}}
This would render the below:
and would add the category Kilitic terms with usage examples.
Parameters
|1=
(required)- The language code of the language that the example is in.
|2=
(required)- The example sentence itself.
|3=
(optional)- An optional translation.
|inline=
- Whether the example is short enough that it can be shown inline.
|nocat=
- An optional marker which, if set to true, will suppress any categories from being automatically added to the entry.