1 回答

TA貢獻1條經(jīng)驗 獲得超0個贊
.animated {
? ?opacity: 0;
? ?animation: fade-in 3s ease-out 0s 1;
? ?-webkit-animation: fade-in 3s ease-out 0s 1;
? ?-moz-animation: fade-in 3s ease-out 0s 1;
? ?-o-animation: fade-in 3s ease-out 0s 1;
? ?-ms-animation:fade-in 3s ease-out 0s 1;
? ?/*規(guī)定動畫的最后狀態(tài)為結(jié)束狀態(tài)*/
? ?animation-fill-mode:forwards;
? ?-webkit-animation-fill-mode: forwards;
? ?-o-animation-fill-mode: forwards;
? ?-ms-animation-fill-mode: forwards;
? ?-moz-animation-fill-mode: forwards;
}
$.fn.fullpage({
? ? ? ?scrollOverflow:true,//當為true時如果頁面數(shù)據(jù)太多可以下滑出現(xiàn),頁腳使用
? ? ?anchors: ['page1', 'page2', 'page3', 'page4', 'page5', 'page6', 'page7', 'page8'],
? ? ?resize:true,
? ? ?navigation: true, ?
? ? ?navigationTooltips: ['page1', 'page2', 'page3', 'page4', 'page5', 'page6', 'page7', 'page8'],
? ? ? ?// 滾動到某一屏后的回調(diào)函數(shù),接收 anchorLink 和 index 兩個參數(shù),anchorLink 是錨鏈接的名稱,index 是序號,從1開始計算
? ? ? ?// onLeave 滾動前的回調(diào)函數(shù),接收 index、nextIndex 和 direction 3個參數(shù):
? ? ? ?//index 是離開的“頁面”的序號,從1開始計算;
? ? ? ?afterLoad: function(anchorLink, index){
? ? ? ? ? ?//section 2
? ? ? ? ? ?if(index==2){
// ? ? ? ? ? ? ? ?第一張圖片顯示
? ? ? ? ? ? ? ?$("#animated-01").removeClass("animated");
? ? ? ? ? ? ? ?$("#animated-01").addClass("animated");
? ? ? ? ? ? ? ?$(".icc").removeClass("icc-hover");
? ? ? ? ? ? ? ?$(".icon-01").removeClass("icc-01-ami");
? ? ? ? ? ? ? ?$(".icon-01").addClass("icc-01-ami");
? ? ? ? ? ? ? ?$(".icon-02").removeClass("icc-02-ami");
? ? ? ? ? ? ? ?$(".icon-02").addClass("icc-02-ami");
? ? ? ? ? ? ? ?$(".icon-03").removeClass("icc-03-ami");
? ? ? ? ? ? ? ?$(".icon-03").addClass("icc-03-ami");
? ? ? ? ? ? ? ?$(".icc").removeClass("icc-action");
? ? ? ? ? ? ? ?$(".lamp-icon >ul >li").removeClass("hover-bgn");
? ? ? ? ? ? ? ?$(".icc").eq(0).addClass("icc-action");
? ? ? ? ? ?}
? ? ? ? ? ?if(index==3){
? ? ? ? ? ? ? ?$("#lamp-03-1").css("display","block");
? ? ? ? ? ? ? ?$('#section3')
? ? ? ? ? ? ? ? ? ? ? ?.mousewheel(function(event, delta) {
? ? ? ? ? ? ? ? ? ? ? ? ? ?event.preventDefault();
? ? ? ? ? ? ? ? ? ? ? ? ? ?if (delta > 0){
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?if ($( "#lamp-03-1" ).css("display")=="none") {
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$( "#lamp-03-1" ).css("display","block");
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$( "#lamp-03-2" ).css("display","none");
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?return false;
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?}else{
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$('#section3').unmousewheel();
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?}
? ? ? ? ? ? ? ? ? ? ? ? ? ?}
? ? ? ? ? ? ? ? ? ? ? ? ? ?else if (delta < 0){
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?if ($( "#lamp-03-1" ).css("display")=="block") {
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$( "#lamp-03-1" ).css("display","none");
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$( "#lamp-03-2" ).css("display","block");
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?return false;
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?}else{
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?$('#section3').unmousewheel();
? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ?}
? ? ? ? ? ? ? ? ? ? ? ? ? ?}
? ? ? ? ? ? ? ? ? ? ? ?});
? ? ? ? ? ? ? ?$(".lamp-03").removeClass("icc-01-ami");
? ? ? ? ? ? ? ?$(".lamp-03-text").removeClass("icc-02-ami");
? ? ? ? ? ? ? ?$(".lamp-03").addClass("icc-01-ami");
? ? ? ? ? ? ? ?$(".lamp-03-text").addClass("icc-02-ami");
? ? ? ? ? ?}
- 1 回答
- 0 關注
- 5059 瀏覽
添加回答
舉報