質問編集履歴
1
sass・compassで記述したものを追加しました。
title
CHANGED
File without changes
|
body
CHANGED
@@ -26,7 +26,33 @@
|
|
26
26
|
|
27
27
|
articleにdisplay: flex;を使用しています。a要素をとればサムネイル画像は表示されますが、a要素を入れてしまうとサムネイルは消えてしまいます。(flexboxが機能しません)
|
28
28
|
|
29
|
-
|
29
|
+
sass・compassでは下記のように記述しています。
|
30
|
+
```sass・compass
|
31
|
+
.loop-article{
|
32
|
+
padding-bottom: 40px;
|
33
|
+
@include display-flex();
|
34
|
+
|
35
|
+
.thumbnail-box{
|
36
|
+
background-position: 50% 50%;
|
37
|
+
background-repeat: no-repeat;
|
38
|
+
background-size: cover;
|
39
|
+
@include align-self(flex-start);
|
40
|
+
@include flex-basis(45%);
|
41
|
+
margin-right: 25px;
|
42
|
+
&:before{
|
43
|
+
content:'';
|
44
|
+
display: block;
|
45
|
+
padding-top: 60%;
|
46
|
+
@include box-sizing(border-box);
|
47
|
+
}
|
48
|
+
|
49
|
+
}
|
50
|
+
.text-box{
|
51
|
+
}
|
52
|
+
|
53
|
+
}
|
54
|
+
}
|
55
|
+
```
|
30
56
|
###補足情報(言語/FW/ツール等のバージョンなど)
|
31
57
|
今回はじめて、アイキャッチ画像をサムネイルの背景画像として設置したのですが、
|
32
58
|
サムネイルに記事へのリンクを張れなくて困っています。
|