Class: StimulusPlumbers::Components::Popover::Panel
- Inherits:
-
Plumber::Base
- Object
- Plumber::Base
- StimulusPlumbers::Components::Popover::Panel
- Defined in:
- lib/stimulus_plumbers/components/popover/panel.rb
Instance Attribute Summary
Attributes inherited from Plumber::Base
Instance Method Summary collapse
- #build(panel_id:, **kwargs, &block) ⇒ Object
- #render(panel_id:, tag: :div, **kwargs, &block) ⇒ Object
Methods inherited from Plumber::Base
Methods included from Plumber::Renderer
#set_slots, #slot_block_for, #slot_kwargs_for, #slot_renderable?
Methods included from Plumber::Options::Aria
Methods included from Plumber::Options::Html
Constructor Details
This class inherits a constructor from StimulusPlumbers::Plumber::Base
Instance Method Details
#build(panel_id:, **kwargs, &block) ⇒ Object
15 16 17 |
# File 'lib/stimulus_plumbers/components/popover/panel.rb', line 15 def build(panel_id:, **kwargs, &block) template.capture(panel_attrs(panel_id, **kwargs), &block) end |
#render(panel_id:, tag: :div, **kwargs, &block) ⇒ Object
7 8 9 10 11 12 13 |
# File 'lib/stimulus_plumbers/components/popover/panel.rb', line 7 def render(panel_id:, tag: :div, **kwargs, &block) template.content_tag( tag, block_given? ? template.capture(panel_id, &block) : nil, **panel_attrs(panel_id, **kwargs) ) end |