Template:TemplateData header/doc

From BAMOS Wiki
< Template:TemplateData header
Revision as of 18:18, 26 January 2022 by RoS (talk | contribs) (Created page with "{{Documentation subpage}} <!-- Add categories where indicated at the bottom of this page and interwikis at Wikidata --> {{TemplateData header|editlinks=1|docpage=TemplateData...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

{{#switch:<translate></translate> | = {{#if:{{#ifexpr: ( {{#ifeq:doc|doc|1|0}} or ( {{#ifeq:{{#titleparts:template:templatedata header/doc|-1|-2}}|doc|1|0}} and {{#if:{{#invoke:Template translation|getLanguageSubpage}}|1|0}} ) )|1|}}

    | 

{{#ifeq:show |show

         | Template:Mbox
        }}{{#if: |
         |   {{#ifexist:Template:TemplateData header
                  | [[Category:{{#switch:Template
                          | Template | Project = Template
                          | Module   = Module
                          | User     = User
                          | #default = MediaWiki
                      }} documentation pages{{#translation:}}]]
                  | [[Category:Documentation subpages without corresponding pages{{#translation:}}]]
                 }}
        }}
    | 
   }}

| #default=

 {{#invoke:Template translation|renderTranslatedTemplate|template=Template:Documentation subpage|noshift=1|uselang=⧼lang⧽}}

}} {{#switch:<translate></translate> |=

{{#if:{{safesubst:#switch: 1
|no
|n
|false
|0        = 
|         = 
|¬        = 
|yes
|y
|true
|1        = yes
|#default = yes

}}|{{#ifexpr:{{#if:TemplateData header/doc|{{#ifeq:Template:TemplateData header/doc|{{#switch:

|#default = TemplateData header/doc 
| = 
   {{#ifeq:  | 
     | Template:TemplateData header/doc            
     | TemplateData header/doc      
   }}

}}|0|1}}|not{{#ifexpr: ( {{#ifeq:doc|doc|1|0}} or ( {{#ifeq:{{#titleparts:template:templatedata header/doc|-1|-2}}|doc|1|0}} and {{#if:{{#invoke:Template translation|getLanguageSubpage}}|1|0}} ) )|1|0}}}}|<templatestyles src="Module:Navbar/styles.css"/>{{#if:1||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:1|[}}[[{{#switch:

|#default = TemplateData header/doc 
| = 
   {{#ifeq:  | 
     | Template:TemplateData header/doc            
     | TemplateData header/doc      
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default = TemplateData header/doc 
| = 
   {{#ifeq:  | 
     | Template:TemplateData header/doc            
     | TemplateData header/doc      
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:1|]}}}}}} {{#if:||<translate> This is the [[<tvar name=1>Special:MyLanguage/Help:TemplateData</tvar>|TemplateData]] documentation for this template used by [[<tvar name=2>Special:MyLanguage/VisualEditor</tvar>|VisualEditor]] and other tools.</translate>}}

TemplateData header

{{#ifeq:doc|sandbox||{{#if:{{#ifexpr: (

{{#ifeq:doc|doc|1|0}} or ( {{#ifeq:{{#titleparts:template:templatedata header/doc|-1|-2}}|doc|1|0}} and {{#if:{{#invoke:Template translation|getLanguageSubpage}}|1|0}} ) )|1|}}|[[Category:TemplateData documentation{{#translation:}}]]|[[Category:Templates using TemplateData{{#translation:}}]]}}}} | #default=

 {{#invoke:Template translation|renderTranslatedTemplate|template=Template:TemplateData header|noshift=1|uselang={{#if:Template:Pagelang|Template:Pagelang|⧼lang⧽}}}}

}} <templatedata> { "description": "Inserts a brief header for the template data section.", "format": "inline", "params": { "1": { "label": "Template name", "description": "Used to display a name for the template other than the default, which is TemplateData header.", "type": "string", "required": false }, "noheader": { "label": "No header", "description": "Assigning any value to this parameter will cause the template to omit the first sentence of the header text.", "type": "string", "required": false }, "editlinks": { "label": "Edit Links?", "description": "Whether to show <templatestyles src="Module:Navbar/styles.css"/>{{#if:||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} editlinks on pages that transclude the TemplateData", "default": "0", "autovalue": "1", "type": "boolean" }, "docpage": { "label": "Doc Page", "description": "The name of the current page, used for <templatestyles src="Module:Navbar/styles.css"/>{{#if:||{{#if:|{{{text}}}|<translate> This box:</translate>}} }}{{#if:|[}}[[{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}|<span style="" title="<translate nowrap> View this template</translate>">{{#if:|<translate> v</translate>|<translate> view</translate>}}]] · [[[:Template:Fullurl:]] <span style="" title="<translate nowrap> Discuss this template</translate>">{{#if:|<translate> d</translate>|<translate> talk</translate>}}]{{#if:|| · [{{fullurl:{{#switch:

|#default =  
| = 
   {{#ifeq:  | 
     | Template:{{{1}}}            
     |       
   }}

}}|action=edit}} <span style="" title="<translate nowrap> Edit this template</translate>">{{#if:|<translate> e</translate>|<translate> edit</translate>}}]}}{{#if:|]}} edit links", "default": "TemplateData header/doc", "autovalue": "TemplateData header/doc", "suggested": true, "type": "wiki-template-name" } }, "paramOrder": [ "1", "noheader", "editlinks", "docpage" ] } </templatedata>