Difference between revisions of "Template:Flatlist/testcases"

From blackwiki
Jump to navigation Jump to search
imported>Droll
(tests)
 
imported>Droll
(tweaked testcases)
Line 1: Line 1:
 
{{template test cases notice}}
 
{{template test cases notice}}
<div class="hlist" style="margin:{{{margin|inherit}}}; margin-left:{{{indent|0}}}em;{{{style|}}}">{{#if:{{{1|}}}|<nowiki />
+
== Without options ==
{{{1}}}
+
=== Active ===
</div>}}<noinclude>{{endflatlist/sandbox}}
 
  
=== Usage ===
+
;old syntax
Starts a horizontal list, such as:
+
{{flatlist}}
 
 
{{flatlist/sandbox}}
 
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 14: Line 11:
 
*[[sheep]]
 
*[[sheep]]
 
*[[pig]]
 
*[[pig]]
{{endflatlist/sandbox}}
+
{{endflatlist}}
{{flatlist/sandbox|
+
 
 +
;new syntax
 +
{{flatlist|
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 24: Line 23:
 
}}
 
}}
  
Syntax:
+
=== Sandbox ===
  
<pre><nowiki>
+
;old syntax
{{flatlist}}
+
{{flatlist/sandbox}}
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 35: Line 34:
 
*[[pig]]
 
*[[pig]]
 
{{endflatlist}}
 
{{endflatlist}}
{{flatlist|
+
 
 +
;new syntax
 +
{{flatlist/sandbox|
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 43: Line 44:
 
*[[pig]]
 
*[[pig]]
 
}}
 
}}
</nowiki></pre>
 
  
===Optional parameters===
+
== Test indent ==
* ''style'', additional CSS style options. Example: ''style = border:solid 1px silver; background:lightyellow'' (complex styles should not be used in articles but may be acceptable on user, project and talk pages)
+
;indent=2
* ''indent'', add left indent by a number of em-spaces, particularly handy for inclusion in an indented discussion thread. Example: ''indent = 2''
 
{{template sandbox notice}}
 
  
=== Examples ===
+
=== Active ===
Normal spacing, indent 2:
+
{{flatlist|indent=2|
{{flatlist/sandbox|indent=2}}
 
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 59: Line 56:
 
*[[sheep]]
 
*[[sheep]]
 
*[[pig]]
 
*[[pig]]
{{endflatlist/sandbox}}
+
}}
 +
 
 +
=== Sandbox ===
 
{{flatlist/sandbox|indent=2|
 
{{flatlist/sandbox|indent=2|
 
*[[cat]]
 
*[[cat]]
Line 69: Line 68:
 
}}
 
}}
  
 +
==  Other style properties ==
 +
style=width:30em; text-align:right;
  
Compact:
+
=== Active ===
{{flatlist/sandbox |style=margin:0em;}}
+
{{flatlist|style=width:30em; text-align:right;|
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 78: Line 79:
 
*[[sheep]]
 
*[[sheep]]
 
*[[pig]]
 
*[[pig]]
{{endflatlist/sandbox}}
+
}}
{{flatlist/sandbox|style=margin:0em;|
+
 
 +
=== Sandbox ===
 +
{{flatlist/sandbox|style=width:30em; text-align:right;|
 
*[[cat]]
 
*[[cat]]
 
*[[dog]]
 
*[[dog]]
Line 87: Line 90:
 
*[[pig]]
 
*[[pig]]
 
}}
 
}}
</noinclude>
 

Revision as of 20:39, 8 August 2011

Without options

Active

old syntax
new syntax

Sandbox

old syntax
new syntax

Test indent

indent=2

Active

Sandbox

Other style properties

style=width:30em; text-align:right;

Active

Sandbox