Class: LeanCms::EditableContentComponent
- Inherits:
-
BaseComponent
- Object
- ViewComponent::Base
- BaseComponent
- LeanCms::EditableContentComponent
- Defined in:
- app/components/lean_cms/editable_content_component.rb
Instance Attribute Summary collapse
-
#default ⇒ Object
readonly
Returns the value of attribute default.
-
#html_options ⇒ Object
readonly
Returns the value of attribute html_options.
-
#key ⇒ Object
readonly
Returns the value of attribute key.
-
#section ⇒ Object
readonly
Returns the value of attribute section.
-
#tag ⇒ Object
readonly
Returns the value of attribute tag.
Attributes inherited from BaseComponent
Instance Method Summary collapse
-
#initialize(section:, key:, tag: :span, default: nil, page: nil, **html_options) ⇒ EditableContentComponent
constructor
A new instance of EditableContentComponent.
Constructor Details
#initialize(section:, key:, tag: :span, default: nil, page: nil, **html_options) ⇒ EditableContentComponent
Returns a new instance of EditableContentComponent.
5 6 7 8 9 10 11 12 |
# File 'app/components/lean_cms/editable_content_component.rb', line 5 def initialize(section:, key:, tag: :span, default: nil, page: nil, **) super(page: page) @section = section @key = key @tag = tag @default = default @html_options = end |
Instance Attribute Details
#default ⇒ Object (readonly)
Returns the value of attribute default.
3 4 5 |
# File 'app/components/lean_cms/editable_content_component.rb', line 3 def default @default end |
#html_options ⇒ Object (readonly)
Returns the value of attribute html_options.
3 4 5 |
# File 'app/components/lean_cms/editable_content_component.rb', line 3 def @html_options end |
#key ⇒ Object (readonly)
Returns the value of attribute key.
3 4 5 |
# File 'app/components/lean_cms/editable_content_component.rb', line 3 def key @key end |
#section ⇒ Object (readonly)
Returns the value of attribute section.
3 4 5 |
# File 'app/components/lean_cms/editable_content_component.rb', line 3 def section @section end |
#tag ⇒ Object (readonly)
Returns the value of attribute tag.
3 4 5 |
# File 'app/components/lean_cms/editable_content_component.rb', line 3 def tag @tag end |