Actions

Template

Difference between revisions of "ArticleNote"

From Sonic Retro

(more consistent)
Line 1: Line 1:
<includeonly>{{#if:{{{mini|}}} |
+
<includeonly>{{#ifeq:{{{mini}}}|yes|{{#vardefine:imgsize|50x30px}}|{{#vardefine:imgsize|50px}}}}{|class="prettytable" style=""
<div style="{{ #if: {{{inline|}}} |display:block;float:left| }};">
+
|style="width:50px; padding:0px; vertical-align:middle; text-align:center;"| {{#if: {{{image|}}} | [[File:{{{image}}}|{{#var:imgsize}}]] | [[File:Sonicretro-round.svg|{{#var:imgsize}}]] }}
<div class="toc shadow posrel" style="{{ #if: {{{inline|}}} ||display:table;}}{{ #ifeq: {{{align|}}}|left||margin:0 auto;}} text-align:left; margin-bottom:1em;
+
|style="padding-top:2px; padding-bottom:2px;"| {{#if: {{{text|}}} | {{{text}}} | Text goes here. }}
overflow:hidden;{{ #if: {{{bgcolor|}}} | background:{{{bgcolor}}} | }}">
+
|}</includeonly><noinclude>
{{ #if: {{{image|}}} | <div style="position:relative;left:{{ #if: {{{leftposition|}}} | {{{leftposition}}} | -10px }};top:{{ #if: {{{topposition|}}} | {{{topposition}}} | -17px }};height:10px;
 
float:left">[[Image:{{{image}}}{{!}}{{ #if: {{{imagewidth|}}} | {{{imagewidth}}} | 50px }}{{!}}link=]]</div> | }}
 
<div style="{{ #if: {{{textcolor|}}} | color:{{{textcolor}}} | }}; vertical-align:middle; {{#if:{{{image|}}}|margin-left:50px;|}} margin-top:3px; margin-bottom:-4px;">{{{text}}}</div>
 
</div></div>
 
| <!-- else normal version -->
 
{{{!}}class="toc shadow" width="{{ #if: {{{width|}}} | {{{width}}} | 50% }}" style="margin:0 auto;{{ #if: {{{bgcolor|}}} | background:{{{bgcolor}}} | }}"
 
{{!}}-
 
{{ #if: {{{image|}}} | {{!}}width="{{ #if: {{{imagewidth|}}} | {{{imagewidth}}} | 50px }}"{{!}}[[Image:{{{image}}}{{!}}{{ #if: {{{imagewidth|}}} | {{{imagewidth}}} | 50px }}{{!}}link=]] | }}
 
{{!}}style="padding:0 0 0 5px;{{ #if: {{{textcolor|}}} | color:{{{textcolor}}} | }}"{{!}}<p style="margin:.2em 0 .4em 0; font-size:1em">{{{text}}}</p>
 
{{!}}}
 
}}</includeonly><noinclude>
 
 
This template is for transclusion in [[:Category:Cleanup templates|cleanup templates]] and other similar site-wide templates.
 
This template is for transclusion in [[:Category:Cleanup templates|cleanup templates]] and other similar site-wide templates.
  
Line 19: Line 8:
 
<pre>
 
<pre>
 
{{ArticleNote
 
{{ArticleNote
|image=
+
| image=
|text=
+
| text=
|imagewidth=
+
| mini=
|align=
 
|width=
 
|mini=
 
|topposition=
 
|leftposition=
 
|inline=
 
 
}}
 
}}
 
</pre>
 
</pre>
Set <tt>mini</tt> to yes/no for a minified version.  <tt>topposition</tt> (default: <tt>-17px</tt>) and <tt>leftposition</tt> (default: <tt>-10px</tt>) are optional values used to position the icon in the minified version.  Only possible value for <tt>align</tt> is <tt>left</tt>.
 
  
==Example==
+
===Examples===
===Normal use===
+
{| class="prettytable"
 +
! Code || Result
 +
|-
 +
|
 
<pre>{{ArticleNote
 
<pre>{{ArticleNote
| image=clock-green.png
+
| image=Sonicretro-round.svg
| text='''This article is outdated.'''<br />
+
| text=This is a stub.
Due to changing events, this article is either no longer correct or needs information added to it to make it complete. You can help Sonic Retro by [{{SERVER}}{{localurl:{{NAMESPACE}}:{{PAGENAME}}|action=edit}} updating it] so it is consistent with current knowledge.  After fixing this article, please remove this notice.
 
 
}}</pre>
 
}}</pre>
 
+
|
 
{{ArticleNote
 
{{ArticleNote
| image=clock-green.png
+
| image=Sonicretro-round.svg
| text='''This article is outdated.'''<br />
+
| text=This is a stub.
Due to changing events, this article is either no longer correct or needs information added to it to make it complete. You can help Sonic Retro by [{{SERVER}}{{localurl:{{NAMESPACE}}:{{PAGENAME}}|action=edit}} updating it] so it is consistent with current knowledge.  After fixing this article, please remove this notice.
 
 
}}
 
}}
 
+
|-
 
+
|
 
 
===mini=yes===
 
 
<pre>{{ArticleNote
 
<pre>{{ArticleNote
 
| image=Lock.svg
 
| image=Lock.svg
| mini=yes
 
 
| text='''This page is protected from editing to prevent vandalism.'''<br />
 
| text='''This page is protected from editing to prevent vandalism.'''<br />
 
Please discuss any proposed changes on this article's talk page.
 
Please discuss any proposed changes on this article's talk page.
| bgcolor=#000033
 
| textcolor=#fff
 
 
}}</pre>
 
}}</pre>
 
+
|
 
{{ArticleNote
 
{{ArticleNote
 
| image=Lock.svg
 
| image=Lock.svg
| mini=yes
 
 
| text='''This page is protected from editing to prevent vandalism.'''<br />
 
| text='''This page is protected from editing to prevent vandalism.'''<br />
 
Please discuss any proposed changes on this article's talk page.
 
Please discuss any proposed changes on this article's talk page.
| bgcolor=#000033
 
| textcolor=#fff
 
 
}}
 
}}
 
+
|-
 +
|
 +
<pre>{{ArticleNote
 +
| image=Lock.svg
 +
| text='''This page is protected from editing to prevent vandalism.'''
 +
}}</pre>
 +
|
 
{{ArticleNote
 
{{ArticleNote
 
| image=Lock.svg
 
| image=Lock.svg
 +
| text='''This page is protected from editing to prevent vandalism.'''
 +
}}
 +
|-
 +
| <pre>{{Reqbook}}</pre>
 +
| {{Reqbook}}
 +
|-
 +
| <pre>{{Segaretro}}</pre>
 +
| {{Segaretro}}
 +
|-
 +
|
 +
<pre>{{ArticleNote
 +
| image=
 
| mini=yes
 
| mini=yes
| text='''This page is protected from editing to prevent vandalism.'''
+
| text=Template with no image.
| bgcolor=#000033
+
}}</pre>
| textcolor=#fff
+
|
 +
{{ArticleNote
 +
| image=
 +
| mini=yes
 +
| text=Template with no image.
 
}}
 
}}
 +
|}
  
 
+
[[Category:Sonic Retro templates]]
[[Category:Sonic Retro templates|{{PAGENAME}}]]
 
 
</noinclude>
 
</noinclude>

Revision as of 20:24, 30 July 2018

This template is for transclusion in cleanup templates and other similar site-wide templates.

Usage

{{ArticleNote
| image=
| text=
| mini=
}}

Examples

Code Result
{{ArticleNote
| image=Sonicretro-round.svg
| text=This is a stub.
}}
Sonicretro-round.svg This is a stub.
{{ArticleNote
| image=Lock.svg
| text='''This page is protected from editing to prevent vandalism.'''<br />
Please discuss any proposed changes on this article's talk page.
}}
Lock.svg This page is protected from editing to prevent vandalism.

Please discuss any proposed changes on this article's talk page.

{{ArticleNote
| image=Lock.svg
| text='''This page is protected from editing to prevent vandalism.'''
}}
Lock.svg This page is protected from editing to prevent vandalism.
{{Reqbook}}
Image upload.svg This book or strategy guide requires additional or replacement scans.
{{Segaretro}}
Segaretro-round.svg It has been suggested that this page be moved over to Sega Retro as to be in accordance with both sites' policies.
Please see the talk page for relevant discussion and export procedure.
{{ArticleNote
| image=
| mini=yes
| text=Template with no image.
}}
Template with no image.