Create the accordion first and then add the hover functionality. below code maybe helpful:
$('.ui-accordion-header').on('mouseenter',function(){
if(!($(this).next('.ui-accordion-content').css('display')=="block"))
{
$(this).next('.ui-accordion-content').addClass('hover');
}
});
$('.ui-accordion-header').on('mouseleave',function(){
$(this).next('.ui-accordion-content').removeClass('hover');
});
The .hover class may look something like this:
.hover{display:block !important; height:50px !important;}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…