@@ -4110,36 +4110,37 @@ <h4 class="text-gray"><i class="linecons-tag" style="margin-right: 7px;" id="UED
4110
4110
</ div >
4111
4111
</ div >
4112
4112
<!-- 锚点平滑移动 -->
4113
- < script type ="text/javascript ">
4114
- // $(document).ready(function() {
4115
- // $("#main-menu li ul li").click(function() {
4116
- // $(this).siblings('li').removeClass('active'); // 删除其他兄弟元素的样式
4117
- // $(this).addClass('active'); // 添加当前元素的样式
4118
- // });
4119
- // $("a.smooth").click(function() {
4120
- // $("html, body").animate({
4121
- // scrollTop: $($(this).attr("href")).offset().top - 30
4122
- // }, {
4123
- // duration: 500,
4124
- // easing: "swing"
4125
- // });
4126
- // });
4127
- // return false;
4128
- // });
4113
+ < script type =”text/javascript“ >
4114
+ $ ( document ) . ready ( function ( ) {
4115
+ $ ( ” #main - menu li ul li“ ) . click ( function ( ) {
4116
+ $ ( this ) . siblings ( ’li‘ ) . removeClass ( ’active‘ ) ; // 删除其他兄弟元素的样式
4117
+ $ ( this ) . addClass ( ’active‘ ) ; // 添加当前元素的样式
4118
+ } ) ;
4119
+ $ ( ”a . smooth“ ) . click ( function ( ev ) {
4120
+ ev . preventDefault ( ) ;
4121
+
4122
+ public_vars . $mainMenu . add ( public_vars . $sidebarProfile ) . toggleClass ( ’mobile - is - visible‘ ) ;
4123
+ ps_destroy ( ) ;
4124
+ $ ( ”html , body“ ) . animate ( {
4125
+ scrollTop : $ ( $ ( this ) . attr ( ”href“ ) ) . offset ( ) . top - 30
4126
+ } , {
4127
+ duration : 500 ,
4128
+ easing : ”swing“
4129
+ } ) ;
4130
+ } ) ;
4131
+ return false ;
4132
+ } ) ;
4129
4133
4130
- var href = "" ;
4134
+ var href = ”“ ;
4131
4135
var pos = 0 ;
4132
- $ ( " a.smooth" ) . click ( function ( e ) {
4133
- $ ( " #main- menu li" ) . each ( function ( ) {
4134
- $ ( this ) . removeClass ( " active" ) ;
4136
+ $ ( ” a. smooth“ ) . click ( function ( e ) {
4137
+ $ ( ” #main - menu li“ ) . each ( function ( ) {
4138
+ $ ( this ) . removeClass ( ” active“ ) ;
4135
4139
} ) ;
4136
- $ ( this ) . parent ( "li" ) . addClass ( " active" ) ;
4140
+ $ ( this ) . parent ( ”li“ ) . addClass ( ” active“ ) ;
4137
4141
e . preventDefault ( ) ;
4138
- href = $ ( this ) . attr ( " href" ) ;
4142
+ href = $ ( this ) . attr ( ” href“ ) ;
4139
4143
pos = $ ( href ) . position ( ) . top - 30 ;
4140
- $ ( "html,body" ) . animate ( {
4141
- scrollTop : pos
4142
- } , 500 ) ;
4143
4144
} ) ;
4144
4145
</ script >
4145
4146
<!-- Global site tag (gtag.js) - Google Analytics -->
0 commit comments