切换页面后返回,下方导航栏active没有更新问题修复
This commit is contained in:
		@@ -170,6 +170,8 @@
 | 
			
		||||
            // 切换页面
 | 
			
		||||
            switchPage(target, false);
 | 
			
		||||
            // 更新下方导航栏选中状态
 | 
			
		||||
            let oldActive = document.querySelector('.active')
 | 
			
		||||
            if (oldActive) oldActive.classList.remove('active');
 | 
			
		||||
            navbarItems.forEach(item => {
 | 
			
		||||
                if (item.getAttribute('targetPage') === target) {
 | 
			
		||||
                    item.classList.add('active');
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user