Now we can often see Full-screen web sites, especially foreign sites. These sites use a number of large pictures or color blocks to do the background, and then add some simple content, appear exceptionally high-end atmospheric grade
Fullpage.js is a jQuery based plug-in that makes it easy and easy to create full-screen Web sites, just as a recent company project uses an entire screen, and as long as
Home whole screen slide, other normal sliding; Of course, there are other needs, there is no nagging. Go straight to dry-----------
Options |
type |
Default Value |
Description |
Verticalcentered |
String |
True |
Whether the content is centered vertically |
Resize |
Boolean value |
False |
Whether the font is scaled as the window is scaled |
Slidescolor |
Function |
No |
Set Background color |
Anchors |
Array |
No |
Define Anchor chain Connection |
Scrollingspeed |
Integer |
700 |
Scrolling speed, in milliseconds |
Easing |
String |
Easeinquart |
Scrolling animation mode |
Menu |
Boolean value |
False |
Binding menu, the set of related properties corresponding to the value of anchors, the menu can control scrolling |
Navigation |
Boolean value |
False |
Whether to show project navigation |
Navigationposition |
String |
Right |
Location of project navigation, optional left or right |
Navigationcolor |
String |
#000 |
Color of Project Navigation |
Navigationtooltips |
Array |
Empty |
Tip for Project Navigation |
Slidesnavigation |
Boolean value |
False |
Show item navigation for left and right sliders |
Slidesnavposition |
String |
Bottom |
The location of the item navigation for the left and right slider, optional top or bottom |
Controlarrowcolor |
String |
#fff |
Background color of arrows for left and right sliders |
Loopbottom |
Boolean value |
False |
Roll back to top after scrolling to bottom |
Looptop |
Boolean value |
False |
Scroll bottom after scrolling to top |
Loophorizontal |
Boolean value |
True |
Whether the left and right sliders are recycled |
Autoscrolling |
Boolean value |
True |
Whether to use the scrolling method of the plug-in, if False, the browser will appear with its own scroll bar |
Scrolloverflow |
Boolean value |
False |
Whether the scroll bar is displayed when the content exceeds the full screen |
Css3 |
Boolean value |
False |
Whether to use CSS3 transforms scrolling |
Paddingtop |
String |
0 |
The distance from the top |
Paddingbottom |
String |
0 |
Distance from the bottom |
Fixedelements |
String |
No |
|
Normalscrollelements |
|
No |
|
Keyboardscrolling |
Boolean value |
True |
Whether to use keyboard arrow keys to navigate |
Touchsensitivity |
Integer |
5 |
|
Continuousvertical |
Boolean value |
False |
Whether to scroll, incompatible with Looptop and Loopbottom |
Animateanchor |
Boolean value |
True |
|
Normalscrollelementtouchthreshold |
Integer |
5 |
|
fullpage.js Chinese API Method
name |
Description |
Movesectionup () |
Scroll up |
Movesectiondown () |
Scroll down |
MoveTo (section, slide) |
Scroll to |
Moveslideright () |
Slide scroll to the right |
Moveslideleft () |
Slide Scroll Left |
Setautoscrolling () |
Set how the page scrolls and automatically scrolls when set to True |
Setallowscrolling () |
Add or remove mouse wheel/trackpad control |
Setkeyboardscrolling () |
Add or remove keyboard arrow keys control |
Setscrollingspeed () |
To define the scrolling speed in milliseconds |
fullpage.js Chinese API callback function
name |
Description |
Afterload |
Scroll to a screen after the callback function, receive Anchorlink and index two parameters, Anchorlink is the name of the anchor chain, index is the serial number, starting from 1 calculation |
Onleave |
The callback function before scrolling receives index, Nextindex, and direction 3 parameters: Index is the departure of the "page" ordinal number, starting from 1 calculation; Nextindex is the serial number of the "page" to scroll to, calculated from 1; Direction determines whether the scroll is up or down, and the value is up or down. |
AfterRender |
The callback function after the page structure is generated, or the callback function after the page initialization completes |
Afterslideload |
A callback function that scrolls to a water smooth block, similar to Afterload, receiving 4 parameters, Anchorlink, index, SlideIndex, direction |
Onslideleave |
A certain water smooth block before rolling the callback function, similar to Onleave, receive Anchorlink, index, SlideIndex, direction 4 parameters |
1. Afterload (Anchorlink, index)
Afterload:function (Anchorlink, index) {
console.log ("Anchorlink:" +anchorlink+ "\ T index:" +index);
2. Onleave (index, nextindex,direction)
Onleave:function (index,nextindex,direction) {
console.log ("Index: +index+" Nextindex: "+nextindex+" direction: "+direction);
},
3. AfterRender ()
Afterrender:function () {
console.log ("AfterRender");
},
4. Afterresize ()
Afterresize:function () {
console.log ("afterresize"); },
5. Afterslideload (Anchorlink, Index, Slideanchor, SlideIndex)
Afterslideload:function (Anchorlink, Index, Slideanchor, SlideIndex) {
console.log ("Anchorlink:" + Anchorlink + " Index: "+ index +" Slideanchor: "+ Slideanchor +" SlideIndex: "+ SlideIndex);
},