要素の後ろにアイコンを付ける
aタグに付ける別窓指定アイコンなど、要素の後ろに画像を入れたい場合に用いる。
span {
position: relative;
&:after {
background: url(../images/common/icon-window.png) no-repeat;
@include background-size(cover);
bottom: 50%;
content: '';
display: inline-block;
height: 10px;
margin-bottom: -9px;
position: absolute;
right: 5%;
width: 12px;
}
}
-
前の記事
表示内容をURL内のディレクトリ名を元に分岐する 2016.10.24
-
次の記事
スマートフォンをを回転させた際に、absluteしている配置がずれる(縦横変更) 2016.10.24