$(function() { //标题第一个字变色 $('.page-title-chinese').each(function() { var b = $('').html($(this).html().slice(0, 1)) $(this).html($(this).html().slice(1)) $(this).prepend(b) }) //招聘职位切换 var active = null $('.page-career-list li .page-career-title span a').click(function() { var index = $(this).parent().parent().parent().index() if (index !== active) { active = index $('.page-career-list>li').eq(index).find('.page-career-detail').stop().slidedown() $('.page-career-list>li').eq(index).siblings().find('.page-career-detail').stop().slideup() } else { active = null $('.page-career-list>li').eq(index).find('.page-career-detail').stop().slideup() } }) //卡片动画 $('.page-list.page-animate-list li').hover(function() { $(this).find('.page-animate-mask').animate({ top: "0" }, 'ease'); }, function() { $(this).find('.page-animate-mask').animate({ top: "75%" }, 'ease'); }) //侧边栏返回顶部 $('.aside_item:last-child').click(function() { var scrolltop = document.documentelement.scrolltop var timer = setinterval(function() { scrolltop -= 20 document.documentelement.scrolltop = scrolltop if (scrolltop <= 0) { clearinterval(timer) } }, 1) }) //公司简介弹窗 $(".span4").click(function() { $(".jianjie_nr").show(); }); $(".span5").click(function() { $(".jianjie_nr").hide(); }); $(".span3").click(function() { $(".speech").show(); }); $(".span5").click(function() { $(".speech").hide(); }); //导航栏 // $(".header_bottom ul li").hover(function() { // var _this = $(this); // if ($(this).index() !== 0) { // $(".bj").stop().slidedown(500, function() { // $(_this).find(".down").show(); // }); // } // }, function() { // $(".down").hide(); // $(".down").stop().slideup(500); // }); $(".header_bottom ul li").hover(function() { if ($(this).index() !== 0) { $(this).find(".down").stop().slidedown(500); } }, function() { $(".down").hide(); }); })