Add frontend assets and plugin bundles
Add the legacy frontend themes, scripts, and plugin assets required by the main SPOTA interfaces.
This commit is contained in:
126
asetlanding/js/main.js
Normal file
126
asetlanding/js/main.js
Normal file
@@ -0,0 +1,126 @@
|
||||
(function($) {
|
||||
|
||||
"use strict";
|
||||
|
||||
$(window).on('load', function() {
|
||||
|
||||
|
||||
|
||||
/*Page Loader active
|
||||
========================================================*/
|
||||
$('#preloader').fadeOut();
|
||||
|
||||
// Sticky Nav
|
||||
$(window).on('scroll', function() {
|
||||
if ($(window).scrollTop() > 100) {
|
||||
$('.scrolling-navbar').addClass('top-nav-collapse');
|
||||
} else {
|
||||
$('.scrolling-navbar').removeClass('top-nav-collapse');
|
||||
}
|
||||
});
|
||||
|
||||
/* Auto Close Responsive Navbar on Click
|
||||
========================================================*/
|
||||
function close_toggle() {
|
||||
if ($(window).width() <= 768) {
|
||||
$('.navbar-collapse a').on('click', function () {
|
||||
$('.navbar-collapse').collapse('hide');
|
||||
});
|
||||
}
|
||||
else {
|
||||
$('.navbar .navbar-inverse a').off('click');
|
||||
}
|
||||
}
|
||||
close_toggle();
|
||||
$(window).resize(close_toggle);
|
||||
|
||||
// one page navigation
|
||||
$('.navbar-nav').onePageNav({
|
||||
currentClass: 'active'
|
||||
});
|
||||
|
||||
/* slicknav mobile menu active */
|
||||
$('.mobile-menu').slicknav({
|
||||
prependTo: '.navbar-header',
|
||||
parentTag: 'liner',
|
||||
allowParentLinks: true,
|
||||
duplicate: true,
|
||||
label: '',
|
||||
closedSymbol: '<i class="lni-chevron-right"></i>',
|
||||
openedSymbol: '<i class="lni-chevron-down"></i>',
|
||||
});
|
||||
|
||||
/* WOW Scroll Spy
|
||||
========================================================*/
|
||||
var wow = new WOW({
|
||||
//disabled for mobile
|
||||
mobile: false
|
||||
});
|
||||
|
||||
wow.init();
|
||||
|
||||
/*
|
||||
CounterUp
|
||||
========================================================================== */
|
||||
$('.counter').counterUp({
|
||||
time: 1000
|
||||
});
|
||||
|
||||
/* Testimonials Carousel
|
||||
========================================================*/
|
||||
var owl = $("#testimonials");
|
||||
owl.owlCarousel({
|
||||
loop: true,
|
||||
nav: false,
|
||||
dots: true,
|
||||
center: true,
|
||||
margin: 15,
|
||||
slideSpeed: 1000,
|
||||
stopOnHover: true,
|
||||
autoPlay: true,
|
||||
responsiveClass: true,
|
||||
responsiveRefreshRate: true,
|
||||
responsive : {
|
||||
0 : {
|
||||
items: 1
|
||||
},
|
||||
768 : {
|
||||
items: 1
|
||||
},
|
||||
960 : {
|
||||
items: 1
|
||||
},
|
||||
1200 : {
|
||||
items: 1
|
||||
},
|
||||
1920 : {
|
||||
items: 1
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
/* Back Top Link active
|
||||
========================================================*/
|
||||
var offset = 200;
|
||||
var duration = 500;
|
||||
$(window).scroll(function() {
|
||||
if ($(this).scrollTop() > offset) {
|
||||
$('.back-to-top').fadeIn(400);
|
||||
} else {
|
||||
$('.back-to-top').fadeOut(400);
|
||||
}
|
||||
});
|
||||
|
||||
$('.back-to-top').on('click',function(event) {
|
||||
event.preventDefault();
|
||||
$('html, body').animate({
|
||||
scrollTop: 0
|
||||
}, 600);
|
||||
return false;
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
}(jQuery));
|
||||
Reference in New Issue
Block a user