All Downloads are FREE. Search and download functionalities are using the official Maven repository.

public.component.assets.js.ace.ace.auto-container.js Maven / Gradle / Ivy

There is a newer version: 3.0.1.11
Show newest version
/**
 Auto Container Adds .container when window size is above 1140px.
 In Bootstrap you should stick with fixed width breakpoints.
 You can use this feature to enable fixed container only when window size is above 1140px
*/
(function($ , undefined) {

 $(window).on('resize.auto_container', function() {
	var enable = $(window).width() > 1140;
	try {
		ace.settings.main_container_fixed(enable, false, false);
	} catch(e) {
		if(enable) $('.main-container,.navbar-container').addClass('container');
		else $('.main-container,.navbar-container').removeClass('container');
		$(document).trigger('settings.ace', ['main_container_fixed' , enable]);
	}
 }).triggerHandler('resize.auto_container');

})(window.jQuery);




© 2015 - 2025 Weber Informatics LLC | Privacy Policy