質問編集履歴

1

コードの追加

2018/03/26 02:54

投稿

退会済みユーザー
test CHANGED
File without changes
test CHANGED
@@ -7,3 +7,95 @@
7
7
 
8
8
 
9
9
  ![イメージ説明](d1043d499149a778084831fcfa65465f.jpeg)
10
+
11
+
12
+
13
+ ```index.html
14
+
15
+ <div class="flexbox">
16
+
17
+ <div class="item">
18
+
19
+ <img src="http://placehold.it/240x150" alt="" />
20
+
21
+ <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit...</p>
22
+
23
+ </div>
24
+
25
+ <div class="item">
26
+
27
+ <img src="http://placehold.it/240x150" alt="" />
28
+
29
+ <p>Nulla pharetra porta sagittis. Mauris et suscipit diam...</p>
30
+
31
+ </div>
32
+
33
+ <div class="item">
34
+
35
+ <img src="http://placehold.it/240x150" alt="" />
36
+
37
+ <p>Integer ornare felis eu risus ultrices pharetra eu non velit...</p>
38
+
39
+ </div>
40
+
41
+ </div>
42
+
43
+ ```
44
+
45
+ ```style.css
46
+
47
+ .item {
48
+
49
+ border-radius: 10px;
50
+
51
+ background: #edf;
52
+
53
+ padding: 15px;
54
+
55
+ margin: 5px;
56
+
57
+ text-align: center;
58
+
59
+ }
60
+
61
+ img {
62
+
63
+ max-width: 100%;
64
+
65
+ height: auto;
66
+
67
+ }
68
+
69
+ p {
70
+
71
+ text-align: left;
72
+
73
+ }
74
+
75
+
76
+
77
+ /* Responsive */
78
+
79
+ @media ( min-width : 600px ){
80
+
81
+ .flexbox {
82
+
83
+ display: -webkit-flex;
84
+
85
+ display: flex;
86
+
87
+ -webkit-flex-wrap: wrap;
88
+
89
+ flex-wrap: wrap;
90
+
91
+ }
92
+
93
+ .item {
94
+
95
+ width: 25%;
96
+
97
+ }
98
+
99
+ }
100
+
101
+ ```