컨텐츠 여부에 따라 간격이 달라지는 경우 사용하면 유용
주의 사항 - 빈 공백이나 줄바꿈이 들어가면 적용되지 않음
<!-- 적용가능-->
<div></div>
<!-- 적용가능-->
<div><!--I'm still empty, even with this comment. --></div>
<!-- 줄바꿈으로 적용 안됨 -->
<div>
</div>
<!-- 공백으로 적용 안됨 -->
<div> </div>
.list {
display: flex;
&:not(:empty) {
margin-top: 12px;
margin-bottom: 7px;
}
...
&:not(:empty) + .notice {
display: block;
font-size: 12px;
font-weight: $fw-regular;
line-height: 1.33;
color: $color-d01f3c;
}
}