Wikipedia:Lua/Modul/TemplateData/Values

Vorlagenprogrammierung Diskussionen Lua Test Unterseiten
Modul Deutsch English Modul: Dokumentation

Testfall für {{TemplateData}}.

Während das MediaWiki-Format von März 2021 nur Zeichenketten als Elemente des Arrays in suggestedvalues zulässt, akzeptiert die Erweiterung auch Objekte wie folgt:

suggestedvalues = Array aus:

While the official MediaWiki code is limited to an Array of strings as suggestedvalues, this extension does permit more exhaustive objects as Array elements:

suggestedvalues = Array of:

  • string
  • object
    code
    Mandatory string
    Value, as in basic format
    label
    multilingual string
    Brief explanation; the code might be less comprehensive
    support
    wiki-page-name as multilingual string
    Page name to assign an internal link to the value
    icon
    wiki-file-name
    Media identifier of a small image to precede the explanation
    class
    string or Array
    class names to be applied to the entire element
    style
    string or object
    CSS inline definition to be applied to the entire element
    less
    boolean
    true – suppress presentation of the value itself, e.g. on file names