Actions

Template

Difference between revisions of "ArticleNote"

From Sonic Retro

m
 
(87 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{#if:{{{mini|}}} |
+
<includeonly>{{#ifeq:{{{mini}}}|yes|{{#vardefine:imgsize|50x30px}}|{{#vardefine:imgsize|50px}}}}{{#if:{{{imagesize|}}}|{{#vardefine:imgsize|{{{imagesize}}}px}}|}}{|class="prettytable" style="width:auto; margin-left:30px; border-bottom:none; {{#if:{{{inline|}}}|display:inline-block;}} {{#if:{{{style|}}}|{{{style}}}}}"
<div style="text-align:center">
+
|-style="height:30px;"
<div class="toc" style="text-align:left;display:inline-block; -moz-box-shadow:0 0 10px rgba(0,0,0,.5);
+
{{#if: {{{image|}}} | {{!}}style="padding:{{#if:{{{mini|}}}|3|8}}px; vertical-align:middle; text-align:center;"{{!}} [[File:{{{image}}}|{{#var:imgsize}}]] }}
-webkit-box-shadow:0 0 10px rgba(0,0,0,.5); box-shadow:0 0 10px rgba(0,0,0,.5);overflow:hidden">
+
|style="padding-top:2px; padding-bottom:2px; {{#if:{{{textstyle|}}}|{{{textstyle}}}}}"| {{#if: {{{text|}}} | {{{text}}} | Text goes here. }}
{{ #if: {{{image|}}} | <div style="position:relative;left:{{ #if: {{{leftposition|}}} | {{{leftposition}}} | -10px }};top:{{ #if: {{{topposition|}}} | {{{topposition}}} | -17px }};height:15px;
+
|}</includeonly><noinclude>
float:left">[[Image:{{{image}}}{{!}}{{ #if: {{{imagewidth|}}} | {{{imagewidth}}} | 50px }}{{!}}link=]]</div> | }}
+
This template is for transclusion in [[:Category:Cleanup templates|cleanup templates]] and other similar site-wide templates.
<div style="float:left">{{{text}}}</div>
 
</div></div>
 
| <!-- else normal version -->
 
{{{!}}class="toc" width="50%" style="margin:0 auto;-moz-box-shadow:0 0 10px rgba(0,0,0,.5); -webkit-box-shadow:0 0 10px rgba(0,0,0,.5); box-shadow:0 0 10px rgba(0,0,0,.5);"
 
{{!}}-
 
{{ #if: {{{image|}}} | {{!}}[[Image:{{{image}}}{{!}}{{ #if: {{{imagewidth|}}} | {{{imagewidth}}} | 50px {{!}}}}link=]] | }}
 
{{!}}{{{text}}}
 
{{!}}}
 
}}<noinclude>
 
This template is for transclusion in [[:Category:Cleanup Templates|cleanup templates]] and other similar site-wide templates.
 
  
 
==Usage==
 
==Usage==
 
<pre>
 
<pre>
 
{{ArticleNote
 
{{ArticleNote
|image=
+
| image=
|text=
+
| text=
|imagewidth=
+
| mini=
|mini=
+
| inline=
|topposition=
+
| style=
|leftposition=
+
| textstyle=
 
}}
 
}}
 
</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.
+
===Examples===
[[Category:Sonic Retro Templates|Download]]
+
{| class="prettytable"
 +
! Code || Result
 +
|-
 +
|
 +
<pre>{{ArticleNote
 +
| image=Sonicretro-round.svg
 +
| text=This is a stub.
 +
| mini=yes
 +
| style=min-width:400px;
 +
| textstyle=font-family:times new roman;
 +
}}</pre>
 +
|
 +
{{ArticleNote
 +
| image=Sonicretro-round.svg
 +
| text=This is a stub.
 +
| mini=yes
 +
| style=min-width:400px;
 +
| textstyle=font-family:times new roman;
 +
}}
 +
|-
 +
|
 +
<pre>{{ArticleNote
 +
| image=Lock.svg
 +
| text='''This page is protected from editing to prevent vandalism.'''
 +
}}</pre>
 +
|
 +
{{ArticleNote
 +
| image=Lock.svg
 +
| text='''This page is protected from editing to prevent vandalism.'''
 +
}}
 +
|-
 +
| <pre>{{Reqbook}}</pre>
 +
| {{Reqbook}}
 +
|-
 +
| <pre>{{Segaretro}}</pre>
 +
| {{Segaretro}}
 +
|-
 +
|
 +
<pre>{{ArticleNote
 +
| image=
 +
| text=Template with no image.
 +
}}</pre>
 +
|
 +
{{ArticleNote
 +
| image=
 +
| text=Template with no image.
 +
| inline=yes
 +
}}
 +
|}
 +
 
 +
{{cleanup|ds dasf
 +
* fgsdfg
 +
*( dfasf
 +
*gfafdfsadf
 +
sadfsadfas}}
 +
 
 +
[[Category:Templates]]
 
</noinclude>
 
</noinclude>

Latest revision as of 19:17, 1 January 2022

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

Usage

{{ArticleNote
| image=
| text=
| mini=
| inline=
| style=
| textstyle=
}}

Examples

Code Result
{{ArticleNote
| image=Sonicretro-round.svg
| text=This is a stub.
| mini=yes
| style=min-width:400px;
| textstyle=font-family:times new roman;
}}
Sonicretro-round.svg This is a stub.
{{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=
| text=Template with no image.
}}
Template with no image.


Sonicretro-round.svg This article needs cleanup.
This article needs to be edited to conform to a higher standard of article quality. Specifically, issues with this article are:

ds dasf

  • fgsdfg
  • ( dfasf
  • gfafdfsadf
sadfsadfas

After the article has been cleaned up, you may remove this message. See How to Edit a Page for help.