Template:Plainlist

From The Sims Wiki, a collaborative database for The Sims series
(Redirected from User:K6ka/Plainlist)
Jump to navigation Jump to search
Template documentation (View · Edit · History · Purge)
This template provides a WCAG/ISO-standards-compliant accessible alternative to <br /> separated lists.

Usage[edit source]

{{plainlist}} starts a plain (i.e. unbulleted) list, such as:

It uses proper HTML list markup, which is more standards-compliant and more accessible than separating list items with <br />.

This template can be used with or without {{endplainlist}}.

Examples[edit source]

{{plainlist|
* [[cat]]
* [[dog]]
* [[horse]]
* [[llama]]
}}
{{plainlist}}
* [[cat]]
* [[dog]]
* [[horse]]
* [[llama]]
{{endplainlist}}

Technical details[edit source]

{{Plainlist}} works by constructing a div with the CSS class "plainlist" which has the following style (see MediaWiki:Common.css):

.plainlist ul {
    line-height: inherit;
    list-style: none none;
    margin: 0;
}
.plainlist ul li {
    margin-bottom: 0;
}
Wikitext Expanded template HTML
{{Plainlist|
* Example 1
* Example 2
* Example 3
}}
<div class="plainlist">
* Example 1
* Example 2
* Example 3
</div>
<div class="plainlist">
<ul>
<li>Example 1</li>
<li>Example 2</li>
<li>Example 3</li>
</ul>
</div>

Credits[edit source]

This template's code and documentation were taken from the English Wikipedia.

TemplateData[edit source]

This is the TemplateData documentation for this template used by the VisualEditor and other tools.

TemplateData for Plainlist

This template provides a WCAG/ISO-standards-compliant accessible alternative to &lt;br /&gt; separated lists. It uses proper HTML list markup, which is more standards-compliant and more accessible than separating list items with &lt;br /&gt;.

Template parameters

ParameterDescriptionTypeStatus
List content1

If supplied, the list, as a normal bulleted list. (Every line should start with an asterisk. No blank lines between lines.)

Contentsuggested
CSS classesclass

Adds a CSS class to the containing div.

Default
The class "plainlist" is always applied.
Stringoptional
Custom CSSstyle

Adds CSS style options.

Example
border:solid 1px silver; background:lightyellow
Unknownoptional
Indent levelindent

Indents the list by a number of standard indents (one indent being 1.6em), particularly handy for inclusion in an indented discussion thread.

Example
2
Numberoptional

Visit Template:Plainlist/doc to edit this text! (How does this work?) (Refresh this text - why?)