Class: Component::Buttongroup::Cell
- Inherits:
-
Cell
- Object
- Cell
- Component::Buttongroup::Cell
- Defined in:
- app/cells/lato_view/component/buttongroup/cell.rb
Constant Summary collapse
- @@styles =
VIEW_COMPONENTSTYLES
- @@sizes =
%w()
Instance Attribute Summary collapse
-
#links ⇒ Object
NB: links must be an array of hash ‘name’, url: ‘url’.
-
#size ⇒ Object
NB: links must be an array of hash ‘name’, url: ‘url’.
-
#style ⇒ Object
NB: links must be an array of hash ‘name’, url: ‘url’.
Instance Method Summary collapse
-
#initialize(links: [], size: '', style: 'normal') ⇒ Cell
constructor
A new instance of Cell.
- #show ⇒ Object
Constructor Details
#initialize(links: [], size: '', style: 'normal') ⇒ Cell
Returns a new instance of Cell.
10 11 12 13 14 15 16 17 |
# File 'app/cells/lato_view/component/buttongroup/cell.rb', line 10 def initialize(links: [], size: '', style: 'normal') # save params @links = links @size = size @style = style # check params check_params end |
Instance Attribute Details
#links ⇒ Object
NB: links must be an array of hash ‘name’, url: ‘url’
8 9 10 |
# File 'app/cells/lato_view/component/buttongroup/cell.rb', line 8 def links @links end |
#size ⇒ Object
NB: links must be an array of hash ‘name’, url: ‘url’
8 9 10 |
# File 'app/cells/lato_view/component/buttongroup/cell.rb', line 8 def size @size end |
#style ⇒ Object
NB: links must be an array of hash ‘name’, url: ‘url’
8 9 10 |
# File 'app/cells/lato_view/component/buttongroup/cell.rb', line 8 def style @style end |
Instance Method Details
#show ⇒ Object
19 20 21 |
# File 'app/cells/lato_view/component/buttongroup/cell.rb', line 19 def show render 'show.html' end |