0
我一直在研究手風琴,並將其與我需要的接近。但是,在點擊關閉「x」圖標後,我似乎無法將箭頭旋轉回0度。切換關閉,但箭頭停留在向下的位置。當點擊「x」關閉圖標時,有箭頭切換回(0deg)
$('#main').each(function() {
var $accordian = $(this);
$accordian.find('.view-m').on('click', function() {
$accordian.find('.mobile-content-body').slideUp();
$accordian.find('span').css('transform', 'rotate(0deg)');
if (!$(this).next().is(':visible')) {
$(this).next().slideDown();
$(this).find('span').css('transform', 'rotate(90deg)');
$(this).next().slideDown();
$accordian.find('.close').click(function() {
$(this).parent().slideUp(500);
$(this).find('span').css('transform', 'rotate(0deg)');
});
}
});
});