Sha256: 0a965d28da8956946e4aaeca1f8807d01944d455fa81428694b036eb50f814a6

Contents?: true

Size: 1.11 KB

Versions: 28

Compression:

Stored size: 1.11 KB

Contents

(function($){

	$(document).ready(function (){
		homeDSA.handleEvents();
		$(".dsa-home-carousel").owlCarousel({
			autoPlay: 7000,
			addClassActive: true,
			mouseDrag: false,
			singleItem: true,
			slideSpeed: 700,
			touchDrag: false,
			transitionStyle: "fade"
		});		
	});

	var deviceWidth = $(window).width();

	var homeDSA = {
		
		handleEvents : function(){
			$('.iasd-global_navbar-main .more, .iasd-global_navbar-main .navbar-toggle, .iasd-global_navbar-main .search-link').on('click', homeDSA.applyBackgroundImage);		
		},

		applyBackgroundImage : function(){
			if (deviceWidth >= 768) {
				var imageURL = $(".dsa-home-carousel .active div").css('background-image');
				$('.iasd-global_navbar').css('background-image', imageURL);
				if( $('.iasd-global_navbar-more').hasClass('open') || $('.iasd-global_navbar-search').hasClass('open')){
					$('.dsa-home-carousel .owl-controls').addClass('hidden');
					$(".dsa-home-carousel").trigger('owl.stop');
				} else{
					$(".dsa-home-carousel").trigger('owl.play',7000);
					$('.dsa-home-carousel .owl-controls').removeClass('hidden');
				}
			}
		}
	};

})(jQuery);

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
iasd-bootstrap-sass-1.7.11 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.7.10 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.7.9 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.7.8 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.7.2 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.7.1 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.7.0 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.6.4 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.6.3 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.6.2 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.6.1 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.6.0 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.5.0 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.4.0 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.3.1 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.3.0 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.2.5 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.2.4 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.2.3 templates/project/lib/iasd_home_dsa.js
iasd-bootstrap-sass-1.2.2 templates/project/lib/iasd_home_dsa.js