Created
March 10, 2017 11:17
-
-
Save Mohsen-Khakbiz/62e41f099daae7f4f11d83fce9f65898 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
please notice where we're using % basis value | |
we should use % in both from and to. e.g. check slideDownLong | |
======================== | |
*/ | |
// Default Values | |
Parallax.defaults = { | |
time: 1, | |
duration: '100%', | |
triggerHook: 1, | |
reverse: true | |
}; | |
Parallax.from = { | |
y: 35 | |
} | |
Parallax.to = { | |
y: 0, | |
x: 0, | |
z: 0, | |
scaleX: 1, | |
scaleY: 1, | |
scaleZ: 1, | |
rotationX: 0, | |
rotationY: 0, | |
rotationZ: 0, | |
opacity: 1, | |
ease: Linear.easeNone | |
} | |
// Default Effect slideDownShort | |
// slideDownLong | |
from: { | |
"y": "100%" | |
} | |
to: { | |
"y": "0%" | |
} | |
// slideUpShort | |
from: { | |
"y": 35 | |
} | |
// slideUpLong | |
from: { | |
"y": "-100%" | |
} | |
to: { | |
"y": "0%" | |
} | |
// slideRightShort | |
from: { | |
"y": 0, | |
"x": 35 | |
} | |
// slideRightLong | |
from: { | |
"y": 0, | |
"x": "100%" | |
} | |
to: { | |
"x": "0%" | |
} | |
// slideLeftShort | |
from: { | |
"y": 0, | |
"x": -35 | |
} | |
// slideLeftLong | |
from: { | |
"y": 0, | |
"x": "-100%" | |
} | |
to: { | |
"x": "0%" | |
} | |
// fadeIn | |
from: { | |
"opacity": 0, | |
"y": 0 | |
} | |
// fadeInDownShort | |
from: { | |
"opacity": 0 | |
} | |
// fadeInDownLong | |
from: { | |
"y": "100%", | |
"opacity": 0 | |
} | |
to: { | |
"y": "0%", | |
"opacity": 1 | |
} | |
// fadeInUpShort | |
from: { | |
"y": -35, | |
"opacity": 0 | |
} | |
// fadeInUpLong | |
from: { | |
"y": "-100%", | |
"opacity": 0 | |
} | |
to: { | |
"y": "0%", | |
"opacity": 1 | |
} | |
// fadeInLeftShort | |
from: { | |
"y": 0, | |
"x": -35, | |
"opacity": 0 | |
} | |
// fadeInLeftLong | |
from: { | |
"y": 0, | |
"x": "-100%", | |
"opacity": 0 | |
} | |
to: { | |
"x": "0%", | |
"opacity": 1 | |
} | |
// fadeInRightShort | |
from: { | |
"y": 0, | |
"x": 35, | |
"opacity": 0 | |
} | |
// fadeInRightLong | |
from: { | |
"y": 0, | |
"x": "100%", | |
"opacity": 0 | |
} | |
to: { | |
"x": "0%", | |
"opacity": 1 | |
} | |
// zoomOut | |
from: { | |
"scale": 1.25, | |
"y": 0 | |
} | |
// zoomIn | |
from: { | |
"scale": 0.75, | |
"y": 0 | |
} | |
// rotateIn | |
from: { | |
"y": 0, | |
"rotation": 179 | |
} | |
// rotateOut | |
from: { | |
"y": 0 | |
} | |
to: { | |
"rotation": 179 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment