Module: Components::DialogHelper
- Defined in:
- app/helpers/components/dialog_helper.rb
Instance Method Summary collapse
- #dialog_content(&block) ⇒ Object
- #dialog_trigger(&block) ⇒ Object
- #render_dialog(**options, &block) ⇒ Object
Instance Method Details
#dialog_content(&block) ⇒ Object
11 12 13 |
# File 'app/helpers/components/dialog_helper.rb', line 11 def dialog_content(&block) content_for :dialog_content, capture(&block), flush: true end |
#dialog_trigger(&block) ⇒ Object
7 8 9 |
# File 'app/helpers/components/dialog_helper.rb', line 7 def dialog_trigger(&block) content_for :dialog_trigger, capture(&block), flush: true end |
#render_dialog(**options, &block) ⇒ Object
2 3 4 5 |
# File 'app/helpers/components/dialog_helper.rb', line 2 def render_dialog(**, &block) content = capture(&block) if block render "components/ui/dialog", content: content, ** end |