Shorthand property that sets the list-style-type, list-style-position and list-style-image properties in one declaration.
Overview tabledisc outside none
listStyle
list-style: inherit
list-style: list-style-type list-style-position list-style-image
list-style
property can contain up to three components:
list-style-type
: This takes any of the range of style values available to the list-style-type, which includes circle
, disc
, decimal
, upper-roman
, etc. To see a the full list of possible values, see the list-style-type.list-style-position
: Specifies if the list-item markers should appear inside or outside the content flow.list-style-image
: This property sets the image that will be used as the list item marker.The following example contains multiple examples of using this property, omitting some of the values.
.first-list {
list-style: disc inside url(/docs/w/skins/webplatform/images/logo.svg);
}
.second-list {
list-style: disc url(/docs/w/skins/webplatform/images/logo.svg);
}
.third-list {
list-style: circle url(/docs/w/skins/webplatform/images/logo.svg);
}
.fourth-list {
list-style: outside;
}
An example to show how setting padding-left to 0 when position is set to outside will produce the market not being shown at all. A ul contained in a div with overflow hidden might run into this issue.
ul {
padding-left: 0;
}
.list-position-outside {
list-style-position: outside;
}
.list-position-inside {
list-style-position: inside;
}
Usage
The list-style property is a composite property. You can omit one or more of the values. If both list-style-type and list-style-image are provided, and the value for this last one is different than none and links to an available image, the image takes precedence and it will be shown as the marker.
When the list-style-position
value is set to outside and the padding or padding-left is set to 0, the list marker won’t be displayed.
list-style
Microsoft Developer Network: [Windows Internet Explorer API reference Article]
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4