Sha256: 9c4cf7e03941fd1bb037551ce73f03d1a731cc5b87a53e90dc8b79ac96cab4cf

Contents?: true

Size: 635 Bytes

Versions: 20

Compression:

Stored size: 635 Bytes

Contents

module Guilded
    
  class ComponentDef
    
    attr_reader :kind, :options, :libs, :styles
    attr_accessor :additional_js
  
    def initialize( kind, options={}, libs=[], styles=[], additional_js='' )
      @kind = kind
      @options = options
      @libs = libs
      @styles = styles
      @additional_js = additional_js
    end
    
    def exclude_css?
      options.include?( :exclude_css ) && ( options[:exclude_css] == 'true' || options[:exclude_css] == true )
    end
    
    def exclude_js?
      options.include?( :exclude_js ) && ( options[:exclude_js] == 'true' || options[:exclude_js] == true )
    end

  end

end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
midas-guilded-0.0.1 lib/guilded/component_def.rb
midas-guilded-0.0.2 lib/guilded/component_def.rb
midas-guilded-0.0.3 lib/guilded/component_def.rb
midas-guilded-0.0.4 lib/guilded/component_def.rb
midas-guilded-0.0.5 lib/guilded/component_def.rb
midas-guilded-0.0.6 lib/guilded/component_def.rb
midas-guilded-0.0.7 lib/guilded/component_def.rb
midas-guilded-0.0.8 lib/guilded/component_def.rb
midas-guilded-0.0.9 lib/guilded/component_def.rb
midas-guilded-0.1.0 lib/guilded/component_def.rb
midas-guilded-0.1.1 lib/guilded/component_def.rb
midas-guilded-0.1.2 lib/guilded/component_def.rb
midas-guilded-0.1.3 lib/guilded/component_def.rb
midas-guilded-0.1.4 lib/guilded/component_def.rb
midas-guilded-0.1.8 lib/guilded/component_def.rb
midas-guilded-0.1.9 lib/guilded/component_def.rb
midas-guilded-0.2.0 lib/guilded/component_def.rb
midas-guilded-0.2.1 lib/guilded/component_def.rb
midas-guilded-0.2.3 lib/guilded/component_def.rb
midas-guilded-0.2.4 lib/guilded/component_def.rb