Template:Languages/doc: Difference between revisions

From OpenStreetMap Wiki
Jump to navigation Jump to search
(Added instructions for modifying language list)
Line 4: Line 4:


If a translation is missing in any language that has its own language namespace, this template automatically adds the current page to [[:Category:Pages with missing translation|the corresponding tracking category]]. The current page's sort key in the category consists of the current page's language code and title.
If a translation is missing in any language that has its own language namespace, this template automatically adds the current page to [[:Category:Pages with missing translation|the corresponding tracking category]]. The current page's sort key in the category consists of the current page's language code and title.

To modify the full list of languages displayed in the language bar, follow the instructions at [[Module:Languages/config#languageCodes|Module:Languages/config]].


=== Usage ===
=== Usage ===

Revision as of 16:14, 20 June 2019

Inserts a language bar with links to the page's current and future translations. Redlinks are hidden by default; clicking the "Other languages" link unhides them so that the user can quickly begin translating. This template appears at the top of almost every page of this wiki, thanks in part to templates like {{KeyDescription}} and {{ValueDescription}}.

If a translation is missing in any language that has its own language namespace, this template automatically adds the current page to the corresponding tracking category. The current page's sort key in the category consists of the current page's language code and title.

To modify the full list of languages displayed in the language bar, follow the instructions at Module:Languages/config.

Usage

{{Languages}}
{{Languages|Source page name}}

Parameters:

  1. (Optional) The name of the source page (typically in English), including any namespace. If unspecified, a source page name is inferred from the current page's name.

Examples

Inferred source page

{{Languages/sandbox}}


Main namespace

{{Languages/sandbox|Map Features}}


Main namespace with pseudonamespace

{{Languages/sandbox|Key:access}}


Technical details

This template is powered by Module:Languages and the configuration at Module:Languages/config. MediaWiki:Common.css and MediaWiki:Mobile.css style the language list as an inline list and hide redlinks by default. MediaWiki:Common.js and MediaWiki:Mobile.js turn the "Other languages" link into a toggle for redlink visibility.

See also