search
HomeWeb Front-endHTML TutorialCSS list property_html/css_WEB-ITnose

CSS list:

属性

描述

list-style

简写属性。用于把所有用于列表的属性设置于一个声明中。

list-style-image

将图象设置为列表项标志。

list-style-position

设置列表中列表项标志的位置。

list-style-type

设置列表项标志的类型。

marker-offset

 

Properties

Description

list-style

描述

none

无标记。

disc

默认。标记是实心圆。

circle

标记是空心圆。

square

标记是实心方块。

decimal

标记是数字。

decimal-leading-zero

0开头的数字标记。(01, 02, 03等)

lower-roman

小写罗马数字(i, ii, iii, iv, v等)

upper-roman

大写罗马数字(I, II, III, IV, V等)

lower-alpha

小写英文字母The marker is lower-alpha (a, b, c等)

upper-alpha

大写英文字母The marker is upper-alpha (A, B, C等)

lower-greek

小写希腊字母(alpha, beta, gamma等)

lower-latin

小写拉丁字母(a, b, c,等)

upper-latin

大写拉丁字母(A, B, C,等)

hebrew

传统的希伯来编号方式

armenian

传统的亚美尼亚编号方式

georgian

传统的乔治亚编号方式(an, ban, gan等)

cjk-ideographic

简单的表意数字

hiragana

标记是:a, i, u, e, o, ka, ki等。(日文片假名)

katakana

标记是:A, I, U, E, O, KA, KI等。(日文片假名)

hiragana-iroha

标记是:i, ro, ha, ni, ho, he, to等。(日文片假名)

katakana-iroha

标记是:I, RO, HA, NI, HO, HE, TO等。(日文片假名)

Abbreviation attribute. Used to set all properties for a list in one declaration.

list-style-image

Sets the image as the list item flag.
list-style-position

Set the position of the list item mark in the list.

list-style-type

Set the type of list item flag.

marker-offset

描述

URL

图像的路径。

none

默认。无图形被显示。

inherit

规定应该从父元素继承 list-style-image 属性的值。

1. List type: list-style-type attribute (1) Function: Modify the flag type used for list items; (2) Possible values:
Value Description
none No tag.
disc Default. Markers are filled circles.
circle The mark is a hollow circle.
square Markers are solid squares.
decimal Markers are numbers.
decimal-leading-zero Number tag starting with 0. (01, 02, 03, etc.)
lower-roman Lowercase Roman numerals (i, ii, iii, iv, v, etc.)
upper-roman Uppercase Roman numerals (I , II, III, IV, V, etc.)
lower-alpha Lowercase English letter The marker is lower-alpha (a, b, c, etc.)
upper-alpha uppercase English letters The marker is upper-alpha (A, B, C, etc.)
lower-greek Lowercase Greek letters (alpha, beta, gamma, etc.)
lower-latin lowercase Latin letters (a, b, c, etc.)
upper-latin Uppercase Latin letters (A, B, C, etc.)
hebrew Traditional Hebrew numbering
armenian Traditional Armenian numbering
georgian Traditional Georgian numbering (an, ban, gan, etc.)
cjk-ideographic Simple ideographic numbers
hiragana The tags are: a, i, u, e, o, ka, ki, etc. (Japanese katakana)
katakana The tags are: A, I, U, E, O, KA, KI, etc. (Japanese Katakana)
hiragana-iroha The tags are: i, ro, ha, ni, ho, he, to, etc. (Japanese katakana)
katakana-iroha The tags are: I, RO, HA, NI, HO, HE, TO, etc. (Japanese katakana)
(3) Browser support: All browsers support the list-style-type attribute. Ps:Any version of Internet Explorer (including IE8) does not support the attribute values ​​​​"decimal-leading-zero", "lower-greek", "lower-latin" ", "upper-latin", "armenian", "georgian" or "inherit". 2. List item image: list-style-image attribute (1) Function: Use an image to replace a list item mark. (2) Possible values:
value Description
URL Path to the image.
none Default. No graphics are displayed.
inherit Specifies that the value of the list-style-image attribute should be inherited from the parent element.

(3) Browser support: All browsers support the list-style-image attribute.

Ps: Always specify a "list-style-type" attribute in case the image is not available.

3. List mark position: list-style-position attribute

(1) Function: Set where to place the list Item tag;

(2) Possible values:

描述

inside

列表项目标记放置在文本以内,且环绕文本根据标记对齐。

outside

默认值。保持标记位于文本的左侧。列表项目标记放置在文本以外,且环绕文本不根据标记对齐。

inherit

规定应该从父元素继承 list-style-position 属性的值。

Value

Description

inside

The list item tag is placed inside the text, And the wrapping text is aligned according to the marker.

outside Default value. Keep the mark to the left of the text. The list item tag is placed outside the text, and the surrounding text is not aligned according to the tag.
inherit

Specifies that the value of the list-style-position attribute should be inherited from the parent element.

(3) Browser support: All browsers support the list-style-position attribute.

4. Abbreviated list style: list-style attribute

(1) Function: Set all list attributes in one statement;

( 2) Order: type, position, image;

Ps: The values ​​of list-style

can be listed in any order, and these values ​​can be ignored. As long as one value is provided, the others will be filled in with their default values.
Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Difficulty in updating caching of official account web pages: How to avoid the old cache affecting the user experience after version update?Difficulty in updating caching of official account web pages: How to avoid the old cache affecting the user experience after version update?Mar 04, 2025 pm 12:32 PM

The official account web page update cache, this thing is simple and simple, and it is complicated enough to drink a pot of it. You worked hard to update the official account article, but the user still opened the old version. Who can bear the taste? In this article, let’s take a look at the twists and turns behind this and how to solve this problem gracefully. After reading it, you can easily deal with various caching problems, allowing your users to always experience the freshest content. Let’s talk about the basics first. To put it bluntly, in order to improve access speed, the browser or server stores some static resources (such as pictures, CSS, JS) or page content. Next time you access it, you can directly retrieve it from the cache without having to download it again, and it is naturally fast. But this thing is also a double-edged sword. The new version is online,

How do I use HTML5 form validation attributes to validate user input?How do I use HTML5 form validation attributes to validate user input?Mar 17, 2025 pm 12:27 PM

The article discusses using HTML5 form validation attributes like required, pattern, min, max, and length limits to validate user input directly in the browser.

What are the best practices for cross-browser compatibility in HTML5?What are the best practices for cross-browser compatibility in HTML5?Mar 17, 2025 pm 12:20 PM

Article discusses best practices for ensuring HTML5 cross-browser compatibility, focusing on feature detection, progressive enhancement, and testing methods.

How to efficiently add stroke effects to PNG images on web pages?How to efficiently add stroke effects to PNG images on web pages?Mar 04, 2025 pm 02:39 PM

This article demonstrates efficient PNG border addition to webpages using CSS. It argues that CSS offers superior performance compared to JavaScript or libraries, detailing how to adjust border width, style, and color for subtle or prominent effect

What is the purpose of the <datalist> element?What is the purpose of the <datalist> element?Mar 21, 2025 pm 12:33 PM

The article discusses the HTML <datalist> element, which enhances forms by providing autocomplete suggestions, improving user experience and reducing errors.Character count: 159

What is the purpose of the <progress> element?What is the purpose of the <progress> element?Mar 21, 2025 pm 12:34 PM

The article discusses the HTML <progress> element, its purpose, styling, and differences from the <meter> element. The main focus is on using <progress> for task completion and <meter> for stati

How do I use the HTML5 <time> element to represent dates and times semantically?How do I use the HTML5 <time> element to represent dates and times semantically?Mar 12, 2025 pm 04:05 PM

This article explains the HTML5 <time> element for semantic date/time representation. It emphasizes the importance of the datetime attribute for machine readability (ISO 8601 format) alongside human-readable text, boosting accessibilit

What is the purpose of the <meter> element?What is the purpose of the <meter> element?Mar 21, 2025 pm 12:35 PM

The article discusses the HTML <meter> element, used for displaying scalar or fractional values within a range, and its common applications in web development. It differentiates <meter> from <progress> and ex

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
2 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Repo: How To Revive Teammates
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌
Hello Kitty Island Adventure: How To Get Giant Seeds
4 weeks agoBy尊渡假赌尊渡假赌尊渡假赌

Hot Tools

MantisBT

MantisBT

Mantis is an easy-to-deploy web-based defect tracking tool designed to aid in product defect tracking. It requires PHP, MySQL and a web server. Check out our demo and hosting services.

PhpStorm Mac version

PhpStorm Mac version

The latest (2018.2.1) professional PHP integrated development tool

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

Atom editor mac version download

Atom editor mac version download

The most popular open source editor