任何建议如何选择 Bootstrap 折叠模块的第一个和最后一个孩子?我需要首先和最后选择“.accordion-heading”..
<div id="accordion2" class="accordion">
<div class="accordion-group">
<div class="accordion-heading"><a class="accordion-toggle" href="#collapseOne" data-toggle="collapse" data-parent="#accordion2"><br />
Toggle Accordion 1<br />
</a></div>
<div id="collapseOne" class="accordion-body in collapse" style="height: auto;">
<div class="accordion-inner">
<p>Content 1</p>
</div>
</div>
</div>
<div class="accordion-group">
<div class="accordion-heading"><a class="accordion-toggle" href="#collapseTwo" data-toggle="collapse" data-parent="#accordion2"><br />
Toggle Accordion 2<br />
</a></div>
<div id="collapseTwo" class="accordion-body collapse" style="height: 0px;">
<div class="accordion-inner">
<p>Content 2</p>
</div>
</div>
</div>
<div class="accordion-group">
<div class="accordion-heading"><a class="accordion-toggle" href="#collapseThree" data-toggle="collapse" data-parent="#accordion2"><br />
Toggle Accordion 3<br />
</a></div>
<div id="collapseThree" class="accordion-body collapse" style="height: 0px;">
<div class="accordion-inner">
<p>Content 3</p>
</div>
</div>
</div>