From 33058f2b292b3a581333bdfb21b8f671898c5060 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Tue, 8 Dec 2020 14:40:17 -0500 Subject: initial commit --- files/ja/web/css/display-listitem/index.html | 65 ++++++++++++++++++++++++++++ 1 file changed, 65 insertions(+) create mode 100644 files/ja/web/css/display-listitem/index.html (limited to 'files/ja/web/css/display-listitem') diff --git a/files/ja/web/css/display-listitem/index.html b/files/ja/web/css/display-listitem/index.html new file mode 100644 index 0000000000..11d0b6586a --- /dev/null +++ b/files/ja/web/css/display-listitem/index.html @@ -0,0 +1,65 @@ +--- +title: +slug: Web/CSS/display-listitem +tags: + - CSS + - CSS データ型 + - CSS 表示 + - Reference + - list-item +translation_of: Web/CSS/display-listitem +--- +
{{CSSRef}}
+ +

list-item キーワードは、要素に {{CSSxRef("list-style")}} プロパティで指定された内容 (例えば見出し記号) を含む ::marker 疑似要素と共に、自身の内容物のために指定された種類の基本的なボックスを生成します。

+ +

構文

+ +

list-item 単独の値を指定すると、要素はリストの項目のように動作します。これは {{CSSxRef("list-style-type")}} や {{CSSxRef("list-style-position")}} と共に使用することができます。

+ +

list-item は {{CSSxRef("<display-outside>")}} キーワードのいずれかと、 {{CSSxRef("<display-inside>")}} の flow または flow-root キーワードと組み合わせることもできます。

+ +
+

メモ: 二つの値の構文に対応しているブラウザーでは、内部表示種別がないと既定で flow になります。外部表示種別が指定されないと、基本ボックスは外部表示種別が block になります。

+
+ +

+ +

HTML

+ +
<div class="fake-list">I will display as a list item</div>
+
+ +

CSS

+ +
.fake-list {
+  display: list-item;
+  list-style-position: inside;
+}
+
+ +

結果

+ +

{{EmbedLiveSample("Example", "100%", 150)}}

+ +

ブラウザーの互換性

+ + + +

list-item の対応

+ +

{{Compat("css.properties.display.list-item", 10)}}

+ +

関連情報

+ + -- cgit v1.2.3-54-g00ecf