Module: Vedeu::DSL::Border::InstanceMethods
- Defined in:
- lib/vedeu/dsl/border.rb
Overview
Provide additional behaviour as instance methods to the including class or module.
Instance Method Summary collapse
-
#border(name = nil, &block) ⇒ Vedeu::Borders::Border
Specify the border of an interface or view with a simple DSL.
-
#border! ⇒ Vedeu::Borders::Border
Applies the default border to the interface or view.
Instance Method Details
#border(name = nil, &block) ⇒ Vedeu::Borders::Border
41 42 43 44 45 46 47 48 |
# File 'lib/vedeu/dsl/border.rb', line 41 def border(name = nil, &block) raise Vedeu::Error::RequiresBlock unless block_given? model_name = name ? name : model.name Vedeu::Borders::Border.build(enabled: true, name: model_name, &block).store end |
#border! ⇒ Vedeu::Borders::Border
69 70 71 72 73 |
# File 'lib/vedeu/dsl/border.rb', line 69 def border! border do # adds default border end end |