mozilla

Revision 20299 of list-style

  • Revision slug: CSS/list-style
  • Revision title: list-style
  • Revision id: 20299
  • Created:
  • Creator: teoli
  • Is current revision? No
  • Comment lang, outline; 20 words added, 10 words removed

Revision Content

{{ CSSRef() }}

Summary

The list-style CSS property is a shorthand property for setting {{ cssxref("list-style-type") }}, {{ cssxref("list-style-image") }} and {{ cssxref("list-style-position") }}.

  • {{ Xref_cssinitial() }}: see individual properties for details
  • Applies to: elements with display: list-item
  • {{ Xref_cssinherited() }}: no
  • Media: {{ Xref_cssvisual() }}
  • {{ Xref_csscomputed() }}: see individual properties

Syntax

list-style:  list-style-type || list-style-position || list-style-image 

Values

Accepts one, two or three keywords in any order.

list-style-type
See {{ cssxref("list-style-type") }}
list-style-image
See {{ cssxref("list-style-image") }}
list-style-position
See {{ cssxref("list-style-position") }}

Examples

{{ CSSLiveSample("list-style") }}

ul { list-style: circle; }
#foo { list-style: square inside; }

Specifications

Browser compatibility

{{ CompatibilityTable() }}

Feature Chrome Firefox (Gecko) Internet Explorer Opera Safari
Basic support 1.0 {{ CompatGeckoDesktop("1") }} 4.0 7.0 1.0
Feature Android Firefox Mobile (Gecko) IE Phone Opera Mobile Safari Mobile
Basic support 1.0 {{ CompatGeckoMobile("1") }} 6.0 6.0 1.0

See Also

{{ Cssxref("list-style-type") }}, {{ Cssxref("list-style-image") }}, {{ Cssxref("list-style-position") }}

{{ languages({ "es": "es/CSS/list-style", "de": "de/CSS/list-style", "fr": "fr/CSS/list-style", "ja": "ja/CSS/list-style", "pl": "pl/CSS/list-style", "pt": "pt/CSS/list-style"}) }}

Revision Source

<p>{{ CSSRef() }}</p> <h2 id="Summary" name="Summary">Summary</h2>
<p>The<code> list-style </code>CSS property is a shorthand property for setting {{ cssxref("list-style-type") }}, {{ cssxref("list-style-image") }} and {{ cssxref("list-style-position") }}.</p> <ul class="cssprop"> <li><dfn>{{ Xref_cssinitial() }}:</dfn> see individual properties for details</li> <li><dfn>Applies to:</dfn> elements with<code> display: list-item</code></li> <li><dfn>{{ Xref_cssinherited() }}:</dfn> no</li> <li><dfn>Media:</dfn> {{ Xref_cssvisual() }}</li> <li><dfn>{{ Xref_csscomputed() }}:</dfn> see individual properties</li>
</ul> <h2 id="Syntax" name="Syntax">Syntax</h2>
<pre>list-style:  list-style-type || list-style-position || list-style-image </pre> <h3 id="Values" name="Values">Values</h3>
<p>Accepts one, two or three keywords in any order.</p>
<dl> <dt>list-style-type</dt> <dd>See {{ cssxref("list-style-type") }}</dd> <dt>list-style-image</dt> <dd>See {{ cssxref("list-style-image") }}</dd> <dt>list-style-position</dt> <dd>See {{ cssxref("list-style-position") }}</dd>
</dl> <h2 id="Examples" name="Examples">Examples</h2>
<p>{{ CSSLiveSample("list-style") }}</p>
<pre>ul { list-style: circle; }
</pre>
<pre>#foo { list-style: square inside; }</pre> <h2 id="Specifications" name="Specifications">Specifications</h2>
<ul> <li><a class="external" href="http://www.w3.org/TR/CSS21/generate.html#propdef-list-style">CSS 2.1 #list-style</a></li> <li><a class="external" href="http://www.w3.org/TR/css3-lists/#list-style">CSS 3 Lists #list-style</a> Working draft</li>
</ul> <h2 id="Browser_compatibility">Browser compatibility</h2>
<p>{{ CompatibilityTable() }}</p>
<div id="compat-desktop"> <table class="compat-table"> <tbody> <tr> <th>Feature</th> <th>Chrome</th> <th>Firefox (Gecko)</th> <th>Internet Explorer</th> <th>Opera</th> <th>Safari</th> </tr> <tr> <td>Basic support</td> <td>1.0</td> <td>{{ CompatGeckoDesktop("1") }}</td> <td>4.0</td> <td>7.0</td> <td>1.0</td> </tr> </tbody> </table>
</div>
<div id="compat-mobile"> <table class="compat-table"> <tbody> <tr> <th>Feature</th> <th>Android</th> <th>Firefox Mobile (Gecko)</th> <th>IE Phone</th> <th>Opera Mobile</th> <th>Safari Mobile</th> </tr> <tr> <td>Basic support</td> <td>1.0</td> <td>{{ CompatGeckoMobile("1") }}</td> <td>6.0</td> <td>6.0</td> <td>1.0</td> </tr> </tbody> </table>
</div>
<h2 id="See_Also" name="See_Also">See Also</h2>
<p>{{ Cssxref("list-style-type") }}, {{ Cssxref("list-style-image") }}, {{ Cssxref("list-style-position") }}</p>
<div class="noinclude">{{ languages({
"es": "es/CSS/list-style",
"de": "de/CSS/list-style",
"fr": "fr/CSS/list-style",
"ja": "ja/CSS/list-style",
"pl": "pl/CSS/list-style",
"pt": "pt/CSS/list-style"}) }}</div>
Revert to this revision