jQuery(function($) {
'use strict';
/*-----------------------------------------------------------------
* Carousels
*-----------------------------------------------------------------
*/
if($("body").hasClass("rtl")) {
var rtlcheck = true;
}
else{
var rtlcheck = false;
}
var dd = $('.news-ticker').easyTicker({
direction: 'up',
easing: 'easeInOutBack',
speed: 'slow',
interval: 2000,
height: 'auto',
visible: 1,
mousePause: 0,
controls: {
up: '.up',
down: '.down',
toggle: '.toggle',
stopText: 'Stop !!!'
}
}).data('easyTicker');
owlFun( "#recent-slider" );
function owlFun( cowl ){
// Home post Slider
var nav = $(cowl).attr('data-nav');
var pag = $(cowl).attr('data-pag');
$(cowl).owlCarousel({
loop:true,
rtl:rtlcheck,
margin:10,
nav: parseInt(nav),
dots: parseInt(pag),
navText: ['',''],
responsive:{
0:{
items:1
},
600:{
items:1
},
1024:{
items:1
}
}
});
}
builderioFeatured( "#builderio-banner-slider" );
function builderioFeatured( cowl ){
// Home post Slider
var nav = $(cowl).attr('data-nav');
var pag = $(cowl).attr('data-pag');
$(cowl).owlCarousel({
loop:true,
rtl: rtlcheck,
margin:10,
nav: parseInt(nav),
dots: parseInt(pag),
navText: ['',''],
responsive:{
0:{
items:1
},
600:{
items:1
},
1024:{
items:1
}
}
});
}
latestPost( "#latest-slider" );
function latestPost( cowl ){
// Home post Slider
var date_item = $(cowl).attr('data-item');
$(cowl).owlCarousel({
loop:true,
rtl:rtlcheck,
margin:20,
nav: false,
dots: false,
navText: ['',''],
responsive:{
0:{
items:1
},
600:{
items:2
},
1024:{
items:parseInt(date_item)
}
}
});
}
$('.count').each(function () {
$(this).prop('Counter',0).animate({
Counter: $(this).text()
}, {
duration: 4000,
easing: 'swing',
step: function (now) {
$(this).text(Math.ceil(now));
}
});
});
});