📅  最后修改于: 2022-03-11 15:03:41.134000             🧑  作者: Mango
// jQuery$('.tabs-wrapper').each(function() { let ths = $(this); ths.find('.tab-item').not(':first').hide(); ths.find('.tab').click(function() { ths.find('.tab').removeClass('active').eq($(this).index()).addClass('active'); ths.find('.tab-item').hide().eq($(this).index()).fadeIn() }).eq(0).addClass('active');});