diff --git a/README.md b/README.md new file mode 100644 index 0000000..b793318 --- /dev/null +++ b/README.md @@ -0,0 +1,10 @@ +# 水平垂直居中 + +- [lineheight](lineheight.html) +- [absolute + 负margin](absolute1.html) +- [absolute + margin auto](absolute2.html) +- [absolute + calc](absolute3.html) +- [absolute + transform](absolute4.html) +- [table](table.html) +- [css-table](css-table.html) +- [flex](flex.html) diff --git a/absolute1.html b/absolute1.html new file mode 100644 index 0000000..bd4d2e5 --- /dev/null +++ b/absolute1.html @@ -0,0 +1,25 @@ + + + + + absolute + 负margin + + + + +
+
123123
+
+ + diff --git a/absolute2.html b/absolute2.html new file mode 100644 index 0000000..e5c4751 --- /dev/null +++ b/absolute2.html @@ -0,0 +1,26 @@ + + + + + absolute + margin auto + + + + +
+
123123
+
+ + diff --git a/absolute3.html b/absolute3.html new file mode 100644 index 0000000..66f1fec --- /dev/null +++ b/absolute3.html @@ -0,0 +1,23 @@ + + + + + absolute + calc + + + + +
+
123123
+
+ + diff --git a/absolute4.html b/absolute4.html new file mode 100644 index 0000000..6575466 --- /dev/null +++ b/absolute4.html @@ -0,0 +1,24 @@ + + + + + absolute + transform + + + + +
+
123123
+
+ + diff --git a/common.css b/common.css new file mode 100644 index 0000000..73203aa --- /dev/null +++ b/common.css @@ -0,0 +1,11 @@ +.wp { + border: 1px solid red; + width: 300px; + height: 300px; +} + +.box { + width: 100px; + height: 100px; + background: green; +} diff --git a/css-table.html b/css-table.html new file mode 100644 index 0000000..eacd74a --- /dev/null +++ b/css-table.html @@ -0,0 +1,23 @@ + + + + + css-table + + + + +
+
123123
+
+ + diff --git a/flex.html b/flex.html new file mode 100644 index 0000000..951aaae --- /dev/null +++ b/flex.html @@ -0,0 +1,22 @@ + + + + + flex + + + + +
+
123123
+
+ + diff --git a/lineheight.html b/lineheight.html new file mode 100644 index 0000000..57d3d78 --- /dev/null +++ b/lineheight.html @@ -0,0 +1,19 @@ + + + + + lineheight + + + + +
+ 文本文本文本 +
+ + diff --git a/table.html b/table.html new file mode 100644 index 0000000..526c6bd --- /dev/null +++ b/table.html @@ -0,0 +1,28 @@ + + + + + table + + + + + + + + + + +
+
123123
+
+ + +