私は:last-child自分の状況で仕事をするのに苦労しています。
HTML:
<div class="test">Some content</div>
<div class="test">Some content</div>
<div class="test">Some content</div>
<div class="action">Some other content</div>
CSS:
div.topic {
border-bottom: 1px solid black;
}
div.topic:last-child {
border-bottom: none;
}
最後div.testはまだ下部に境界線があります。私が思う問題は、クラステストの最後のdivではなくborder-bottom: none最後のdivに適用されることです。div.action
どうすれば解決できますか?