?
| Current Path : /home/webyoo/www/backup/allback/docteur-site/cv/sym/a/events/crm/dark-creative/js/ |
| Current File : /home/webyoo/www/backup/allback/docteur-site/cv/sym/a/events/crm/dark-creative/js/script.js |
$(window).on("load", function () {
"use strict";
/* ===================================
Loading Timeout
====================================== */
$('.side-menu').removeClass('hidden');
setTimeout(function(){
$('.loader').fadeOut();
}, 1000);
});
/* ===================================
Side Menu
====================================== */
if ($(".sidemenu_toggle").length) {
$(".sidemenu_toggle").on("click", function () {
$(".side-menu").removeClass("side-menu-opacity");
$(".pushwrap").toggleClass("active");
$(".side-menu").addClass("side-menu-active"), $("#close_side_menu").fadeIn(700)
}), $("#close_side_menu").on("click", function () {
$(".side-menu").removeClass("side-menu-active"), $(this).fadeOut(200), $(".pushwrap").removeClass("active");
setTimeout(function(){
$(".side-menu").addClass("side-menu-opacity");
}, 500);
}), $(".side-nav .navbar-nav .nav-link").on("click", function () {
$(".side-menu").removeClass("side-menu-active"), $("#close_side_menu").fadeOut(200), $(".pushwrap").removeClass("active");
setTimeout(function(){
$(".side-menu").addClass("side-menu-opacity");
}, 500);
}), $(".btn_sideNavClose").on("click", function () {
$(".side-menu").removeClass("side-menu-active"), $("#close_side_menu").fadeOut(200), $(".pushwrap").removeClass("active");
setTimeout(function(){
$(".side-menu").addClass("side-menu-opacity");
}, 500);
});
}
/* ===================================
Nav Scroll
====================================== */
jQuery(function ($) {
"use strict";
$(window).on('scroll', function () {
if ($(this).scrollTop() > 260) { // Set position from top to add class
$('.fixed-nav-on-scroll').removeClass('d-none');
}
else {
$('.fixed-nav-on-scroll').addClass('d-none');
}
});
});
$(".scroll").on("click", function(event){
event.preventDefault();
$('html,body').animate({
scrollTop: $(this.hash).offset().top - 0}, 800);
});
/*===================================
Go Top Scroll
====================================== */
$(function(){
// Scroll Event
$(window).on('scroll', function(){
var scrolled = $(window).scrollTop();
if (scrolled > 260) $('.go-top').addClass('active');
if (scrolled < 260) $('.go-top').removeClass('active');
});
// Click Event
$('.go-top').on('click', function() {
$("html, body").animate({ scrollTop: "0" }, 500);
});
});
/* =====================================
Wow Animations
======================================== */
if ($(window).width() > 767) {
var wow = new WOW({
boxClass: 'wow',
animateClass: 'animated',
offset: 0,
mobile: false,
live: true
});
new WOW().init();
}
/* ===================================
Rotating Text
====================================== */
if ($(".js-rotating").length) {
$(".js-rotating").Morphext({
// The [in] animation type. Refer to Animate.css for a list of available animations.
animation: "flipInX",
// An array of phrases to rotate are created based on this separator. Change it if you wish to separate the phrases differently (e.g. So Simple | Very Doge | Much Wow | Such Cool).
separator: ",",
// The delay between the changing of each phrase in milliseconds.
speed: 3000,
complete: function () {
// Called after the entrance animation is executed.
}
});
}
/* ===================================
Cube Portfolio
====================================== */
$('#js-grid-mosaic-flat').cubeportfolio({
filters: '#js-filters-mosaic-flat',
layoutMode: 'mosaic',
sortByDimension: true,
mediaQueries: [{
width: 1600,
cols: 6,
}, {
width: 991,
cols: 4,
}, {
width: 767,
cols: 2,
}, {
width: 480,
cols: 1,
options: {
caption: '',
gapHorizontal: 15,
gapVertical: 15,
}
}],
defaultFilter: '*',
animationType: 'fadeOutTop',
gapHorizontal: 0,
gapVertical: 0,
gridAdjustment: 'responsive',
caption: 'zoom',
displayType: 'fadeIn',
displayTypeSpeed: 100,
// lightbox
lightboxDelegate: '.cbp-lightbox',
lightboxGallery: true,
lightboxTitleSrc: 'data-title',
lightboxCounter: '<div class="cbp-popup-lightbox-counter">{{current}} of {{total}}</div>',
plugins: {
loadMore: {
element: '#js-loadMore-mosaic-flat',
action: 'click',
loadItems: 3,
}
},
});
/* ===================================
Counter
====================================== */
$('.count').each(function () {
$(this).appear(function () {
$(this).prop('Counter', 0).animate({
Counter: $(this).text()
}, {
duration: 3000,
easing: 'swing',
step: function (now) {
$(this).text(Math.ceil(now));
}
});
});
});
/* ===================================
Reviews
====================================== */
$('.testimonial #testimonial-carousal').owlCarousel({
loop:true,
margin:120,
nav:false,
dots:true,
autoplay:true,
responsive:{
0:{
items:1
},
600:{
items:1
},
1000:{
items:2
}
}
});
if ($(window).width() > 992) {
$(".parallax").parallaxie({
speed: 0.55,
offset: 0,
});
}