Class: Alchemy::Ingredients::HeadlineView
- Defined in:
- app/components/alchemy/ingredients/headline_view.rb
Instance Attribute Summary
Attributes inherited from BaseView
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(ingredient, level: nil, html_options: {}) ⇒ HeadlineView
constructor
A new instance of HeadlineView.
Methods inherited from BaseView
Constructor Details
#initialize(ingredient, level: nil, html_options: {}) ⇒ HeadlineView
Returns a new instance of HeadlineView.
4 5 6 7 |
# File 'app/components/alchemy/ingredients/headline_view.rb', line 4 def initialize(ingredient, level: nil, html_options: {}) super(ingredient, html_options: ) @level = level end |
Instance Method Details
#call ⇒ Object
9 10 11 12 13 |
# File 'app/components/alchemy/ingredients/headline_view.rb', line 9 def call content_tag tag_name, id: dom_id, class: css_classes do ingredient.value end.html_safe end |