mirror of
				https://github.com/invoiceninja/invoiceninja.git
				synced 2025-11-04 11:13:33 -05:00 
			
		
		
		
	
		
			
				
	
	
		
			12 lines
		
	
	
		
			381 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			12 lines
		
	
	
		
			381 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
(function ($) {
 | 
						|
$.fn.vAlign = function() {
 | 
						|
	return this.each(function(i){
 | 
						|
        $(this).children().wrapAll('<div class="nitinh-vAlign" style="position:relative;"></div>');
 | 
						|
        var div = $(this).children('div.nitinh-vAlign');
 | 
						|
        var ph = $(this).innerHeight();
 | 
						|
        var dh = div.height();
 | 
						|
        var mh = (ph - dh) / 2;
 | 
						|
        div.css('top', mh);
 | 
						|
	});
 | 
						|
};
 | 
						|
})(jQuery); |