aboutsummaryrefslogtreecommitdiff
path: root/assets/js/transition.js
diff options
context:
space:
mode:
authorAndrew Lee <alee14498@gmail.com>2019-11-09 15:45:48 -0500
committerAndrew Lee <alee14498@gmail.com>2019-11-09 15:45:48 -0500
commite92bad1fca8a2b6290af5dc73746f1acc72cfaf0 (patch)
tree216e4b3756ff4cf74c1c3b69c7246447c1b512a7 /assets/js/transition.js
parent7e6bb45d42517833be78a058dfd803f90cc7bd19 (diff)
downloadalp-website-e92bad1fca8a2b6290af5dc73746f1acc72cfaf0.tar.gz
alp-website-e92bad1fca8a2b6290af5dc73746f1acc72cfaf0.tar.bz2
alp-website-e92bad1fca8a2b6290af5dc73746f1acc72cfaf0.zip
Porting the website to jekyll....
Diffstat (limited to 'assets/js/transition.js')
-rw-r--r--assets/js/transition.js24
1 files changed, 24 insertions, 0 deletions
diff --git a/assets/js/transition.js b/assets/js/transition.js
new file mode 100644
index 0000000..25c62e1
--- /dev/null
+++ b/assets/js/transition.js
@@ -0,0 +1,24 @@
+$(document).ready(function() {
+ $(".animsition").animsition({
+ inClass: 'fade-in',
+ outClass: 'fade-out',
+ inDuration: 1500,
+ outDuration: 800,
+ linkElement: '.animsition-link',
+ // e.g. linkElement: 'a:not([target="_blank"]):not([href^="#"])'
+ loading: true,
+ loadingParentElement: 'body', //animsition wrapper element
+ loadingClass: 'animsition-loading',
+ loadingInner: '', // e.g '<img src="loading.svg" />'
+ timeout: true,
+ timeoutCountdown: 5000,
+ onLoadEvent: true,
+ browser: [ 'animation-duration', '-webkit-animation-duration'],
+ // "browser" option allows you to disable the "animsition" in case the css property in the array is not supported by your browser.
+ // The default setting is to disable the "animsition" in a browser that does not support "animation-duration".
+ overlay : false,
+ overlayClass : 'animsition-overlay-slide',
+ overlayParentElement : 'body',
+ transition: function(url){ window.location.href = url; }
+ });
+});