这是我的代码:
<div class="wh_box" ng-model="change_div" ng-switch on="change_div">
<div ng-switch-when="unchanged">
<ul class="shar_list">
<li ng-repeat="dish_index in similar">
<h2><span>{{dish_index.Dish.name}}</span></h2>
<div>
<a><img no-image ng-src={{similarfull_image_url+dish_index.Dish.image}} alt=""></a>
</div>
</li>
<li ng-hide="similar.length" class="no_record">No record found</li>
</ul>
</div>
<div ng-switch-when="changed">
<div class="title">Comments</div>
<div class = "line"></div>
<ul class="comment_list">
<li ng-repeat="x in comments ">
<a><img no-image ng-src="{{profile_img_path.image_url_tiny+x.User.image}}" alt=""></a>
<div class="pro_deatil" >
<h2> {{x.User.name}} </h2>
<p>{{x.CommentDish.comment}}</p>
</div>
<div class="pro_like" >
</div>
</li>
</ul>
<div class="comment">
<textarea name="comment" rows="5" cols="10" ng-model="comment_data.comment" placeholder="Enter Comment" class="post_txt_area" ng-blur="blurred()" ></textarea>
<div> <a ng-click="postComment()" class="event_btn">Comment</a> </div>
</div>
</div>
</div>
我的问题: ng-switch工作正常但是当我切换到另一个div时,在新的切换div中仍然可以清楚地看到Previous div底部空间,请在这个问题上帮助我。