Class: Voom::Presenters::DSL::Components::Progress

Inherits:
Base
  • Object
show all
Defined in:
lib/voom/presenters/dsl/components/progress.rb

Instance Attribute Summary collapse

Attributes inherited from Base

#attributes, #css_class, #draggable, #drop_zone, #id, #tag, #type

Instance Method Summary collapse

Methods inherited from Base

#expand!

Methods included from Pluggable

#include_plugins, #plugin, #plugin_module

Methods included from Mixins::YieldTo

#yield_to

Methods included from Serializer

#to_hash

Methods included from Lockable

#locked?

Constructor Details

#initialize(**attribs_, &block) ⇒ Progress

Returns a new instance of Progress.



8
9
10
11
12
13
# File 'lib/voom/presenters/dsl/components/progress.rb', line 8

def initialize(**attribs_, &block)
  super(type: :progress, **attribs_, &block)
  @hidden = attribs.delete(:hidden) {true}
  @position = attribs.delete(:position) {:top}
  validate_position(@position)
end

Instance Attribute Details

#hiddenObject (readonly)

Returns the value of attribute hidden.



6
7
8
# File 'lib/voom/presenters/dsl/components/progress.rb', line 6

def hidden
  @hidden
end

#positionObject (readonly)

Returns the value of attribute position.



6
7
8
# File 'lib/voom/presenters/dsl/components/progress.rb', line 6

def position
  @position
end