Sha256: a2e2e98c24f5b2bb3138a637149c297bb85b3a4ca25b48afa94955b2c9585cc7

Contents?: true

Size: 1.36 KB

Versions: 1

Compression:

Stored size: 1.36 KB

Contents

(function($) {

	$.noty.themes.bootstrapTheme = {
		name: 'bootstrapTheme',
		modal: {
			css: {
				position: 'fixed',
				width: '100%',
				height: '100%',
				backgroundColor: '#000',
				zIndex: 10000,
				opacity: 0.6,
				display: 'none',
				left: 0,
				top: 0
			}
		},
		style: function() {
		
			var containerSelector = this.options.layout.container.selector;
			$(containerSelector).addClass('list-group');
			
			this.$closeButton.append('<span aria-hidden="true">&times;</span><span class="sr-only">Close</span>');
			this.$closeButton.addClass('close');
		
			this.$bar.addClass( "list-group-item" ).css('padding', '0px');

			switch (this.options.type) {
				case 'alert': case 'notification':
					this.$bar.addClass( "list-group-item-info" ); 
					break;
				case 'warning':
					this.$bar.addClass( "list-group-item-warning" );
					break;
				case 'error':
					this.$bar.addClass( "list-group-item-danger" );
					break;
				case 'information':
					this.$bar.addClass("list-group-item-info");
					break;
				case 'success':
					this.$bar.addClass( "list-group-item-success" );
					break;
			}
			
			this.$message.css({
				fontSize: '13px',
				lineHeight: '16px',
				textAlign: 'center',
				padding: '8px 10px 9px',
				width: 'auto',
				position: 'relative'
			});
		},
		callback: {
			onShow: function() {  },
			onClose: function() {  }
		}
	};

})(jQuery);

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
noty-rails-2.2.9 vendor/assets/javascripts/noty/themes/bootstrap.js