Difference between revisions of "Template:Note"

From Northumberland Climbing
Jump to navigation Jump to search
Template>Krinkle
 
Tag: 2017 source edit
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
<languages/>
+
<onlyinclude>{{#switch:
<onlyinclude>{{#switch:<translate></translate>
 
 
| =
 
| =
 
{{#if: {{#if:{{{1|}}}|{{{1}}}|{{#if:<noinclude>demo</noinclude>|demo|{{{demo|}}}}} }} | <templatestyles src="Note/styles.css" /><div role="note" class="note note-{{#switch:{{{2|}}}
 
{{#if: {{#if:{{{1|}}}|{{{1}}}|{{#if:<noinclude>demo</noinclude>|demo|{{{demo|}}}}} }} | <templatestyles src="Note/styles.css" /><div role="note" class="note note-{{#switch:{{{2|}}}
Line 7: Line 6:
 
     |#default={{{2|}}}
 
     |#default={{{2|}}}
 
     }} {{#if:{{{inline|}}}|note-inline}}">{{{1}}}</div>
 
     }} {{#if:{{{inline|}}}|note-inline}}">{{{1}}}</div>
   | [[File:OOjs UI icon lightbulb-20 fc3.svg|18px|<translate><!--T:1--> Note</translate>|link=]]&nbsp;'''<translate><!--T:2--> Note:</translate>''' }}
+
   | [[File:OOjs UI icon lightbulb-20 fc3.svg|18px|<!--T:1--> Note|link=]]&nbsp;'''<!--T:2--> Note:''' }}
 
| #default=
 
| #default=
   {{#invoke:Template translation|renderTranslatedTemplate|template=Template:Note|noshift=1}}
+
   {{#invoke:template=Template:Note|noshift=1}}
 
}}</onlyinclude>
 
}}</onlyinclude>
{{documentation|content=
+
 
<translate>
 
 
== Usage == <!--T:3-->
 
== Usage == <!--T:3-->
</translate>
+
 
 
<pre>
 
<pre>
 
{{Note|Foo}}
 
{{Note|Foo}}
Line 21: Line 19:
 
{{Note|Foo|warn}}
 
{{Note|Foo|warn}}
 
{{Note|Foo|error}}
 
{{Note|Foo|error}}
{{Note}} <translate><!--T:6--> Loose test</translate>
+
{{Note}} <!--T:6--> Loose test
  
 
* Text {{Note|Foo|inline=1}}
 
* Text {{Note|Foo|inline=1}}
Line 30: Line 28:
 
{{Note|Foo|warn}}
 
{{Note|Foo|warn}}
 
{{Note|Foo|error}}
 
{{Note|Foo|error}}
{{Note}} <translate><!--T:4--> Loose test</translate>
+
{{Note}} <!--T:4--> Loose test
  
 
* Text {{Note|Foo|inline=1}}
 
* Text {{Note|Foo|inline=1}}
 
== Parameters ==
 
<templatedata>
 
{
 
"params": {
 
"1": {
 
"type": "content",
 
"label": "Text",
 
"required": true
 
},
 
"2": {
 
"label": "Type",
 
"description": "One of 'info', 'reminder', 'warn', or 'error'. This setting affects the color and icon.",
 
"type": "line",
 
"default": "info"
 
},
 
"inline": {
 
"label": "Inline formatting",
 
"description": "Show the template without line breaks before and after it",
 
"type": "line"
 
}
 
},
 
"format": "inline",
 
"description": "Show a note in a box (e.g. a top-of-the-page warning)."
 
}
 
</templatedata>
 
}}
 
[[Category:Templates{{#translation:}}|{{PAGENAME}}]]
 

Latest revision as of 06:43, 11 August 2020

{{{1}}}

Usage[edit]

{{Note|Foo}}
{{Note|Foo|info}}
{{Note|Foo|reminder}}
{{Note|Foo|warn}}
{{Note|Foo|error}}
{{Note}} <!--T:6--> Loose test

* Text {{Note|Foo|inline=1}}
Foo
Foo
Foo
Foo
Foo

Note  Note: Loose test

  • Text
    Foo