-
是否使用鍵盤方向鍵導航,默認true。keyboardscrolling查看全部
-
設置固定到頂部或者底部的導航欄查看全部
-
是否使用插件的滾動方式查看全部
-
配置項 滾動的方式查看全部
-
anchors 定義錨鏈接查看全部
-
配置項 verticalcentered查看全部
-
fullpage.js 的配置項 sectionsColor controlArrows查看全部
-
fullpage.js 需要引入的文件查看全部
-
move.js是一個js庫,支持css3 set(css屬性,屬性值) scale(縮放的倍數) rotate(旋轉的角度數);可正可負 end();用于結束move.js代碼片段的結束,標識動畫的結束。此方法可接受一個回調函數 給頁面添加動畫效果可利用回調函數(另外:要實現某一東西從某一方向飛入,則首先給其設置一個較大的margin,并設置overflow:hidden,使此東西在頁面中顯示不出來,然后通過回調函數應用move.js的set(‘margin-方向’,‘使此東西在正確位置的margin值’)) afterLoad(link,index){ switch: case 1:move(‘.section1 h1’).scale().end();//調用move.js方法實現動畫 break; case 2: break; case 3: break; case 4:move('.section4 img.primary').rotate(360).end(function(){ move('.section4 img.sport').rotate(360).end({ //利用end()可接受回調函數的方法實現動畫的先后順序 move.('.section4 img.eition').rotate(360).end(); }); }); break; default: break; } 若要實現動畫可每次在進入網頁時都可以顯示,則在離開這個頁面時將afterLoad()所做的設置還原 onLeave(link,index){ switch(index){ case 1: break; ...... case 4:move('section4 img.edition').rotate(-360).end(function(){ move('section4 img.sport').rotate(-360).end(function(){ }); }); break; default: break; } }查看全部
-
回調函數:寫在配置項的位置處 afterLoad(anchorLink,index) 滾動到某一section處,且滾動結束后,會觸發(fā)一次此回調函數,函數接收anchorLink和index 兩個參數,anchorLink是錨鏈接,index是序號(從1開始)。 作用:我們可以根據anchorLink和index的參數值的判斷,觸發(fā)相應的事件。 實例:afterLode:function(anchorLink,index){ console.log("afterLode:anchorLink"+anchorLink+";index:"+index);//將兩個參數打印出來,在控制臺可以看到 } onLeave(index,nextIndex,direction) 在離開一個頁面時,會觸發(fā)一次此回調函數,接收index(離開時頁面的序號)、nextIndex(滾動到的目標頁面的序號)和direction(滾動的方向,有up和down)3個參數 通過return false;可以取消滾動 afterRender() 頁面初始化完成后的回調函數 afterResize() 瀏覽器窗口尺寸改變后的回調函數 afterSlideLode(anchorLink,index,slideAnchor,slideIndex) 滾動到某一slide后的回調函數,與afterLode類似,接收anchorLink、index、slideIndex、direction4個參數 onSlideLeave(anchorLink,index,slideIndex,direction,nextSlideIndex) 在離開一個slide時會觸發(fā)此函數,與onLeave相似,接收anchorLink、index、slideIndex、direction4個參數查看全部
-
方法1查看全部
-
幻燈片的結構查看全部
-
首先建立一下基本的頁面結構查看全部
-
link導入js,jq文件查看全部
-
引入插件查看全部
舉報
0/150
提交
取消