class Voom::Presenters::DSL::Components::Drawer
Attributes
components[RW]
subtitle[RW]
title[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/drawer.rb, line 11 def initialize(**attribs_, &block) super(type: :drawer, **attribs_, &block) self.title(attribs.delete(:title)) if attribs.fetch(:title){nil} @components = [] expand! end
Public Instance Methods
attach(presenter, **params, &block)
click to toggle source
Calls superclass method
Voom::Presenters::DSL::Components::Mixins::Attaches#attach
# File lib/voom/presenters/dsl/components/drawer.rb, line 25 def attach(presenter, **params, &block) pom = super @menu = pom.components.select {|i| i.type == :menu}.first end