xiezhiming il y a 3 ans
Parent
commit
1d8945e59f
1 fichiers modifiés avec 5 ajouts et 3 suppressions
  1. 5 3
      src/js/staticInfo.js

+ 5 - 3
src/js/staticInfo.js

@@ -215,14 +215,16 @@ function renderCalculate(){
 		}
 	})	
 	// 适配改变样式
-	$(window).bind('load resize',function(){
+	function Adaptation(){
 		let widths=$(document).width();
-		if(widths<=960) {
+		if(widths<=1025) {
 			$('.cgs_top').addClass('cgs_tops')
 		}else{
 			$('.cgs_top').removeClass('cgs_tops')
 		}
-	})	
+	}
+	Adaptation()
+	$(window).bind('load resize',Adaptation)		
 	
 }