Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
学ぶ アイテムの垂直方向の整列 | Flexboxによるモダンレイアウト
CSSの基礎

bookアイテムの垂直方向の整列

メニューを表示するにはスワイプしてください

align-items プロパティは、フレックスアイテムの垂直方向の配置を制御します。デフォルト値は stretch です。

align-items: stretch | center | flex-start | flex-end | baseline;

次の例を実行して、どのような場面で必要になるかを確認します。

stretch

クロス軸全体にアイテムを拡張することを意味します。

index.html

index.html

index.css

index.css

copy

center

アイテムが交差軸の中央に配置される。

index.html

index.html

index.css

index.css

copy

flex-start

すべてのアイテムが交差軸の先頭に配置される。

index.html

index.html

index.css

index.css

copy

flex-end

すべてのアイテムが交差軸の末尾(親フレックスコンテナの末尾)に配置される。

index.html

index.html

index.css

index.css

copy

baseline

すべてのフレックスアイテムは、そのテキストコンテンツのベースラインに基づいて整列。

index.html

index.html

index.css

index.css

copy

1. align-itemsプロパティは何をしますか?

2. align-itemsプロパティで使用できる値は次のうちどれですか?

question mark

align-itemsプロパティは何をしますか?

正しい答えを選んでください

question mark

align-itemsプロパティで使用できる値は次のうちどれですか?

すべての正しい答えを選択

すべて明確でしたか?

どのように改善できますか?

フィードバックありがとうございます!

セクション 4.  4

AIに質問する

expand

AIに質問する

ChatGPT

何でも質問するか、提案された質問の1つを試してチャットを始めてください

セクション 4.  4
some-alt