Template:Documentation: Difference between revisions
Appearance
Content deleted Content added
Bsadowski1 (talk | changes) |
Davidgothberg (talk | changes) Calling /core2 for more parameter preprocessing, it in turn calls /core. Since adding smarter namespace handling, and stuff for debug-reporting to a category. See talk, "Subject space vs talk space". |
||
Line 15: | Line 15: | ||
}}<!-- |
}}<!-- |
||
Start of green doc box. |
Start of green doc box. |
||
--> |
-->{{documentation/core2 |
||
| heading = {{{heading|¬}}} <!--Empty but defined means no header--> |
|||
| heading-style = {{{heading-style|}}} |
|||
| content = {{{content|}}} |
|||
| link box = {{{link box|}}} <!--So "link box=off" works--> |
|||
<!--Some namespaces must have the /doc, /sandbox and /testcases |
|||
These are the literal class definitions in MediaWiki:Common.css: |
|||
in talk space--> |
|||
| docspace = |
|||
{{#switch: {{SUBJECTSPACE}} |
|||
| {{ns:0}} |
|||
| {{ns:File}} |
|||
| {{ns:MediaWiki}} |
|||
| {{ns:Category}} = {{TALKSPACE}} |
|||
| #default = {{SUBJECTSPACE}} |
|||
}} |
|||
<!--For debug purposes--> |
|||
/* For template documentation */ |
|||
| not-docspace = |
|||
.template-documentation { |
|||
{{#switch: {{SUBJECTSPACE}} |
|||
clear: both; |
|||
| {{ns:0}} |
|||
| {{ns:File}} |
|||
border: 1px solid #aaa; |
|||
| {{ns:MediaWiki}} |
|||
background-color: #ecfcf4; |
|||
| {{ns:Category}} = {{SUBJECTSPACE}} |
|||
padding: 1em; |
|||
| #default = {{TALKSPACE}} |
|||
} |
|||
}} |
|||
| 1 = {{{1|}}} <!--Other docname, if fed--> |
|||
|<!--**NOTHING**--> |
|||
|<div style="padding-bottom:3px; border-bottom: 1px solid #aaa; margin-bottom:1ex">{{#ifeq:{{{content|μ}}}|μ |
|||
|<span class="editsection plainlinks" id="doc_editlinks">{{#ifexist: {{{1|{{Documentation/docname}}}}} |
|||
|<!--** /doc EXISTS** -->[[{{fullurl:{{{1|{{Documentation/docname}}}}}|action=edit}} edit]] [{{purge|purge}}] |
|||
|<!--**/doc DOESN'T EXIST**-->[[{{fullurl:{{{1|{{Documentation/docname }}}}}|action=edit&preload=Template:Documentation/preload}} create]] |
|||
}}</span> |
|||
}} <span style="{{#if:{{{heading-style|}}}|{{{heading-style}}}|{{#ifeq:{{NAMESPACE}}|{{ns:template}}|font-weight: bold; font-size: 125%|font-size: 150%}}}}">{{#if:{{{heading|}}}|{{{heading}}}|{{#ifeq:{{NAMESPACE}}|{{ns:template}}|[[Image:Template-info.svg|50px]] Template documentation|Documentation}}}}</span></div> |
|||
}}<!-- |
|||
<!--The namespace is added in /core2--> |
|||
--><div id="template_doc_page_transcluded" class="dablink plainlinks"><!-- |
|||
| template page = |
|||
-->{{#ifexist: {{{1|{{Documentation/docname}}}}} |
|||
{{#switch: {{SUBPAGENAME}} |
|||
|<!--**/doc EXISTS**-->This [[Wikipedia:Template documentation|documentation]] is [[Wikipedia:Transclusion|transcluded]] from [[{{{1|{{Documentation/docname}}}}}]]. <small style="font-style: normal">([{{fullurl:{{{1|{{Documentation/docname}}}}}|action=edit}} edit] | [{{fullurl:{{{1|{{Documentation/docname}}}}}|action=history}} history])</small><br /> |
|||
| sandbox |
|||
}}{{Documentation/links}}<!-- Add links to /sandbox and /testcases when appropriate --> |
|||
| testcases = {{BASEPAGENAME}} |
|||
</div> |
|||
| #default = {{PAGENAME}} |
|||
{{#if:{{{content|}}}|{{{content}}}|{{#ifexist:{{{1|{{Documentation/docname}}}}} | {{ {{{1|{{Documentation/docname}}}}} }} }}}} |
|||
}} |
|||
<div style="clear: both;"></div> |
|||
}}<!--End of green doc box--><noinclude> |
|||
<!-- Add categories and interwikis to the /doc subpage, not here! --> |
<!-- Add categories and interwikis to the /doc subpage, not here! --> |