Difference between revisions of "Template:PortalButton/Documentation"

From blackwiki
Jump to navigation Jump to search
test>Cesdeva
(Rem. signature)
test>Cesdeva
(Parameters)
Line 23: Line 23:
 
'''|Width=''' (Div width, default is 25%)
 
'''|Width=''' (Div width, default is 25%)
 
</br>
 
</br>
'''|Float=''' (left or right, default none)
+
'''|float=''' (left or right, default none)
'''|Background-c=''' (color, default #efefef)
+
'''|background-c=''' (color, default #efefef)
'''|Border-w=''' (Border width, default 2px)
+
'''|border-w=''' (Border width, default 2px)
'''|Border-t=''' (Border type, default solid)
+
'''|border-t=''' (Border type, default solid)
'''|Border-c=''' (Border color, default #efefef)
+
'''|border-c=''' (Border color, default #efefef)
'''|Border-r=''' (Border radius, default 20px)
+
'''|border-r=''' (Border radius, default 20px)
'''|Margin=''' (Margin around div, default 5px)
+
'''|margin=''' (Margin around div, default 5px)
'''|Image=''' (File name, default PButton2.jpg)
+
'''|overflow=''' (Overflow, default hidden)
'''|Image-t=''' (Type, default frameless)
+
'''|image=''' (File name, default PButton2.jpg)
 +
'''|image-t=''' (Type, default frameless)
 
</br>
 
</br>
'''|Link=''' (Target, default Portal:Contents/)
+
'''|link=''' (Target, default Portal:Contents/)
'''|Image-s=''' (Image size; pair with |Width)
+
'''|image-s=''' (Image size; pair with |Width)
'''|Text-c=''' (Font color, default #FFFF)
+
'''|text-c=''' (Font color, default #FFFF)
 
</br>
 
</br>
'''|Font-wt=''' (Font weight, default none, options are <code>bold</code> and <code>italics</code>.)
+
'''|font-wt=''' (Font weight, default none, options are <code>bold</code> and <code>italics</code>.)
 
</br>
 
</br>
'''|Text=''' (Add text below image, centered)
+
'''|text=''' (Add text below image, centered)
 
</div>
 
</div>
  
Line 49: Line 50:
 
<pre>
 
<pre>
 
{{PortalButton
 
{{PortalButton
|Width=
+
|width=
|Float=
+
|float=
|Background-c
+
|background-c
|Border-w=
+
|border-w=
|Border-t
+
|border-t
|Border-c=
+
|border-c=
|Border-r=
+
|border-r=
|Margin=
+
|margin=
|Image=
+
|overflow=
|Link=
+
|image=
|Image-s=
+
|link=
|Text-c=
+
|image-s=
|Font-wt=
+
|text-c=
|Text=
+
|font-wt=
 +
|text=
 
}}
 
}}
 
</pre>
 
</pre>

Revision as of 00:21, 25 May 2018

This is a documentation page, and not a template.

 Documentation

This template is in Alpha-testing
The Portal Button template is designed to provide a rounded-edge wrapper for intra-wiki linked images; giving the appearance of a 'button' to users. Utilisation of purpose-made graphics can add further semantic meaning. The wrapper incorporates the CSS overflow:hidden attribute, which in combination with the width attribute will crudely 'crop' images. Normal image sizing syntax is optional but will be overidden horizontally by the value in the |width parameter.

 Parameters

|Width= (Div width, default is 25%)
|float= (left or right, default none) |background-c= (color, default #efefef) |border-w= (Border width, default 2px) |border-t= (Border type, default solid) |border-c= (Border color, default #efefef) |border-r= (Border radius, default 20px) |margin= (Margin around div, default 5px) |overflow= (Overflow, default hidden) |image= (File name, default PButton2.jpg) |image-t= (Type, default frameless)
|link= (Target, default Portal:Contents/) |image-s= (Image size; pair with |Width) |text-c= (Font color, default #FFFF)
|font-wt= (Font weight, default none, options are bold and italics.)
|text= (Add text below image, centered)

To transclude the template, copy and paste the following text:

{{PortalButton
|width=
|float=
|background-c
|border-w=
|border-t
|border-c=
|border-r=
|margin=
|overflow=
|image=
|link=
|image-s=
|text-c=
|font-wt=
|text=
}}

Be sure to remove any parameters you don't fill, otherwise rendering will be affected.

 Rendered examples

Geogdivhills2.jpg

Churchdiv2.jpg

Overlookingcheshire2.jpg Geography

Brayheadcross.jpg Religion