Sha256: 9b6b57a3cc7ec10a25532580d1a24cde63abd5f3e43081bfcb133c129923a096

Contents?: true

Size: 1.03 KB

Versions: 28

Compression:

Stored size: 1.03 KB

Contents

// CytoTable v0.1
// By MacKinley Smith
(function($){
	var defaults = {
		widget:{
			table:{
				cell:{
					padding:0,
					spacing:0
				}
			}
		},
		events:{
			create:function(cy){},
			change:function(cy,event){},
			destroy:function(cy){}
		}
	};
	
	var methods = {
		init:function(options){
			return this.each(function(){
				var $this = $(this);
				var settings = $.extend(true,{},defaults,options);
				
				// Setup table
				$this.attr({cellpadding:0,cellspacing:0});
				
				$this.data('cytoTable',settings);
			});
		},
		resize:function(){
			
		},
		destroy:function(){
			
		}
	};
	
	$.fn.cytoTable=function(method){
		if (methods[method]) return methods[method].apply(this,Array.prototype.slice.call(arguments,1));
		else if (typeof method == 'object' || !method) return methods.init.apply(this,arguments);
		else $.error('Method ' + method + ' does not exist on $.cytoTable!');
	};
	
	$(window).resize(function(){$('.cytoTable').cytoTable('resize');});
	$.Cytoplasm("ready",function(){$('.cytoTable').cytoTable();});
})(jQuery);

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
cytoplasm-0.2.6 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.2.5 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.2.4 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.2.3 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.2.2 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.2.1 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.2.0 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.9 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.8 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.7 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.6 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.5 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.4 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.3 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.2 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.1 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.1.0 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.0.9.3 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.0.9.2 app/assets/javascripts/cytoplasm/cytoTable.js.erb
cytoplasm-0.0.9.1 app/assets/javascripts/cytoplasm/cytoTable.js.erb