class Voom::Presenters::DSL::Components::Card::Actions
Attributes
switches[RW]
Public Class Methods
new(**attribs_, &block)
click to toggle source
Calls superclass method
Voom::Presenters::DSL::Components::Base::new
# File lib/voom/presenters/dsl/components/card.rb, line 110 def initialize(**attribs_, &block) super(type: :action, **attribs_, &block) @buttons = [] @switches = [] expand! end
Public Instance Methods
switch(text = nil, **options, &block)
click to toggle source
# File lib/voom/presenters/dsl/components/card.rb, line 122 def switch(text = nil, **options, &block) @switches << Components::Switch.new(parent: self, text: text, **options, &block) end