クリックイベントで要素を非表示にしています。入力チェックボックス要素があり、クリックするとこれらの要素が非表示になります。Firefoxでは正常に動作していますが、クロムでは要素が非表示になりますが、スペースが残っています。画像を添付しました。誰かヒントあったら教えてください
!
コードはこのようなもので、
<div id="cat">
<div id="cat-head">
<img src="opeb-arrow.png"></img>
<h2 id="filter-heading"><b>Frame Styles</b></h2>
</div>
<input type="checkbox"><span>Geek (123)</span></input><br>
<input type="checkbox"><span>Round Eye (3435)</span></input><br>
<input type="checkbox"><span>Cat Eye (5675)</span></input><br>
<input type="checkbox"><span>Wayfarer (234)</span></input><br>
<input type="checkbox"><span>Aviator (545)</span></input><br>
</div>
ジャバスクリプト、
$(function(){
$("#cat-head img").each(function() {
$(this).click(function() {
if ($(this).attr("src") == "opeb-arrow.png") {
$(this).attr("src", "close-arrow.png");
}
else {$(this).attr("src", "opeb-arrow.png");}
$(this).closest("#cat-head").siblings().toggle('fast');
});
});
});