Module:Wikt-lang/doc: Difference between revisions
→Tracking categories: not used |
|||
Line 33: | Line 33: | ||
== Tracking categories == |
== Tracking categories == |
||
* {{Category link with count|Wikt-lang module errors}} |
* {{Category link with count|Wikt-lang module errors}} |
||
* [[Template:Tracking/wikt-lang/reconstructed with no asterisk]] |
|||
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | |
<includeonly>{{#ifeq:{{SUBPAGENAME}}|sandbox | | |
Revision as of 09:59, 23 October 2024
Language templates |
---|
Language names (ISO 639) |
|
Interwiki links |
Foreign-language text |
|
Other |
|
![]() | This module depends on the following other modules: |
This module is used by {{Wikt-lang}}
. It is inspired by the templates {{m}} and {{l}} and their associated modules on Wiktionary. It has a Wiktionary link function that links to the correct section of the Wiktionary entry, and applies correct language formatting and italics. The language-tagging function does most of what {{Lang}} does, except that italics can't be customized and categories aren't added.
The module uses Module:Wikt-lang/data to retrieve the language name for a language code, and to perform the necessary entry-name replacements (for instance, removing macrons from Latin entry names). These are unfortunately not automatically retrieved from Wiktionary's Wikt-lang data modules. For language codes that do not have a name
value in this module, the language name is fetched with mw.language.fetchLanguage
. When mw.language.fetchLanguage
does not fetch the correct language name (or any language name at all), please add it to Module:Wikt-lang/data, and similarly when the correct entry name is not generated, please add the entry name replacements to the module.
Examples
{{#invoke:Wikt-lang|wikt|en|language}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|en|language|languages}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|fr|bourguignon}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|la|homō}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|grc|δημοκρατίᾱ}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|ru|язы́к}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|ar|العَرَبِيَّة}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|fa|فارسی}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|ine-x-proto|*h₂enǵʰ-}}
-> Script error: The function "wikt" does not exist.
Invalid codes
{{#invoke:Wikt-lang|wikt|EN|language}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|En|language|languages}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|La|homō}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|Grc|δημοκρατίᾱ}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|Ru|язы́к}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|Ar|العَرَبِيَّة}}
-> Script error: The function "wikt" does not exist.{{#invoke:Wikt-lang|wikt|Fa|فارسی}}
-> Script error: The function "wikt" does not exist.
Errors
{{#invoke:Wikt-lang|wikt|en-Latin|language}}
-> Script error: The function "wikt" does not exist.