From b5dcea43eb1d9e42283f42a6edcd52ae3208cf23 Mon Sep 17 00:00:00 2001 From: Masahiro FUJIMOTO Date: Mon, 8 Nov 2021 00:46:41 +0900 Subject: CSS Box Model のプロパティの変換準備 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- files/ja/web/css/margin-bottom/index.html | 146 ------------------------------ files/ja/web/css/margin-bottom/index.md | 146 ++++++++++++++++++++++++++++++ 2 files changed, 146 insertions(+), 146 deletions(-) delete mode 100644 files/ja/web/css/margin-bottom/index.html create mode 100644 files/ja/web/css/margin-bottom/index.md (limited to 'files/ja/web/css/margin-bottom') diff --git a/files/ja/web/css/margin-bottom/index.html b/files/ja/web/css/margin-bottom/index.html deleted file mode 100644 index f035539d6b..0000000000 --- a/files/ja/web/css/margin-bottom/index.html +++ /dev/null @@ -1,146 +0,0 @@ ---- -title: margin-bottom -slug: Web/CSS/margin-bottom -tags: - - CSS - - CSS Property - - Reference - - 'recipe:css-property' -translation_of: Web/CSS/margin-bottom ---- -
{{CSSRef}}
- -

margin-bottomCSS のプロパティで、要素の下側のマージン領域を設定します。正の数を指定すると、隣との間が遠くなるように配置され、負の数を指定すると、近くなるように配置します。

- -
{{EmbedInteractiveExample("pages/css/margin-bottom.html")}}
- - - -

要素ボックスにおける CSS の margin-bottom プロパティの効果

- -

このプロパティは、 {{HTMLElement("span")}} または {{HTMLElement("code")}} のような置換のインライン要素には効果がありません。

- -

構文

- -
/* <length> 値 */
-margin-bottom: 10px;  /* 絶対的な寸法 */
-margin-bottom: 1em;   /* 文字の寸法からの相対 */
-margin-bottom: 5%;    /* 直近のブロックコンテナーの幅からの相対 */
-
-/* キーワード値 */
-margin-bottom: auto;
-
-/* グローバル値 */
-margin-bottom: inherit;
-margin-bottom: initial;
-margin-bottom: unset;
-
- -

margin-bottom プロパティは auto キーワード、または <length><percentage> で指定されます。正の数、ゼロ、負の数が指定できます。

- -

- -
-
{{cssxref("<length>")}}
-
固定値によるマージンの寸法です。
-
{{cssxref("<percentage>")}}
-
包含ブロックの width に対するパーセントによるマージンの寸法です。
-
auto
-
ブラウザ―が適切な値を選択して使用します。 {{cssxref("margin")}} を参照してください。
-
- -

公式定義

- -

{{cssinfo}}

- -

形式文法

- -{{csssyntax}} - -

- -

正および負の数の下側のマージンの設定

- -

HTML

- -
<div class="container">
-<div class="box0">Box 0</div>
-<div class="box1">Box 1</div>
-<div class="box2">Box one's negative margin pulls me up</div>
-</div>
- -

CSS

- -

div に margin-bottom と height を設定する CSS です。

- -
.box0 {
-    margin-bottom:1em;
-    height:3em;
-}
-.box1 {
-    margin-bottom:-1.5em;
-    height:4em;
-}
-.box2 {
-    border:1px dashed black;
-    border-width:1px 0;
-    margin-bottom:2em;
-}
-
-
- -

包含要素と div の定義の一部です。これによって margin の効果がより明確に見えます。

- -
.container {
-    background-color:orange;
-    width:320px;
-    border:1px solid black;
-}
-div {
-    width:320px;
-    background-color:gold;
-}
- -

結果

- -

{{ EmbedLiveSample('Setting_positive_and_negative_bottom_margins',350,200) }}

- -

仕様書

- - - - - - - - - - - - - - - - - - - - - - - - - - -
仕様書状態備考
{{SpecName('CSS3 Box', '#propdef-margin-bottom', 'margin-bottom')}}{{Spec2('CSS3 Box')}}目立った変更なし。
{{SpecName('CSS2.1', 'box.html#margin-properties', 'margin-bottom')}}{{Spec2('CSS2.1')}}CSS1 と同様、ただしインライン要素での効果は削除。
{{SpecName('CSS1', '#margin-bottom', 'margin-bottom')}}{{Spec2('CSS1')}}初回定義
- -

ブラウザーの互換性

- -

{{Compat("css.properties.margin-bottom")}}

- -

関連情報

- - diff --git a/files/ja/web/css/margin-bottom/index.md b/files/ja/web/css/margin-bottom/index.md new file mode 100644 index 0000000000..f035539d6b --- /dev/null +++ b/files/ja/web/css/margin-bottom/index.md @@ -0,0 +1,146 @@ +--- +title: margin-bottom +slug: Web/CSS/margin-bottom +tags: + - CSS + - CSS Property + - Reference + - 'recipe:css-property' +translation_of: Web/CSS/margin-bottom +--- +
{{CSSRef}}
+ +

margin-bottomCSS のプロパティで、要素の下側のマージン領域を設定します。正の数を指定すると、隣との間が遠くなるように配置され、負の数を指定すると、近くなるように配置します。

+ +
{{EmbedInteractiveExample("pages/css/margin-bottom.html")}}
+ + + +

要素ボックスにおける CSS の margin-bottom プロパティの効果

+ +

このプロパティは、 {{HTMLElement("span")}} または {{HTMLElement("code")}} のような置換のインライン要素には効果がありません。

+ +

構文

+ +
/* <length> 値 */
+margin-bottom: 10px;  /* 絶対的な寸法 */
+margin-bottom: 1em;   /* 文字の寸法からの相対 */
+margin-bottom: 5%;    /* 直近のブロックコンテナーの幅からの相対 */
+
+/* キーワード値 */
+margin-bottom: auto;
+
+/* グローバル値 */
+margin-bottom: inherit;
+margin-bottom: initial;
+margin-bottom: unset;
+
+ +

margin-bottom プロパティは auto キーワード、または <length><percentage> で指定されます。正の数、ゼロ、負の数が指定できます。

+ +

+ +
+
{{cssxref("<length>")}}
+
固定値によるマージンの寸法です。
+
{{cssxref("<percentage>")}}
+
包含ブロックの width に対するパーセントによるマージンの寸法です。
+
auto
+
ブラウザ―が適切な値を選択して使用します。 {{cssxref("margin")}} を参照してください。
+
+ +

公式定義

+ +

{{cssinfo}}

+ +

形式文法

+ +{{csssyntax}} + +

+ +

正および負の数の下側のマージンの設定

+ +

HTML

+ +
<div class="container">
+<div class="box0">Box 0</div>
+<div class="box1">Box 1</div>
+<div class="box2">Box one's negative margin pulls me up</div>
+</div>
+ +

CSS

+ +

div に margin-bottom と height を設定する CSS です。

+ +
.box0 {
+    margin-bottom:1em;
+    height:3em;
+}
+.box1 {
+    margin-bottom:-1.5em;
+    height:4em;
+}
+.box2 {
+    border:1px dashed black;
+    border-width:1px 0;
+    margin-bottom:2em;
+}
+
+
+ +

包含要素と div の定義の一部です。これによって margin の効果がより明確に見えます。

+ +
.container {
+    background-color:orange;
+    width:320px;
+    border:1px solid black;
+}
+div {
+    width:320px;
+    background-color:gold;
+}
+ +

結果

+ +

{{ EmbedLiveSample('Setting_positive_and_negative_bottom_margins',350,200) }}

+ +

仕様書

+ + + + + + + + + + + + + + + + + + + + + + + + + + +
仕様書状態備考
{{SpecName('CSS3 Box', '#propdef-margin-bottom', 'margin-bottom')}}{{Spec2('CSS3 Box')}}目立った変更なし。
{{SpecName('CSS2.1', 'box.html#margin-properties', 'margin-bottom')}}{{Spec2('CSS2.1')}}CSS1 と同様、ただしインライン要素での効果は削除。
{{SpecName('CSS1', '#margin-bottom', 'margin-bottom')}}{{Spec2('CSS1')}}初回定義
+ +

ブラウザーの互換性

+ +

{{Compat("css.properties.margin-bottom")}}

+ +

関連情報

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