Class: Slocks::ModalTemplateHandler
Class Method Summary
collapse
handles_encoding?, preamble, translate_location
Class Method Details
.call(template, source = nil) ⇒ Object
64
65
66
67
68
69
70
71
72
73
74
|
# File 'lib/slocks/template_handler.rb', line 64
def call(template, source = nil)
source ||= template.source
" @__slocks_modal_builder ||= Slocks::ModalBuilder.new(self)\n def method_missing(m, *a, **k, &b);\n @__slocks_modal_builder.respond_to?(m) ? @__slocks_modal_builder.public_send(m, *a, **k, &b) : super;\n end\n \#{source}\n @__slocks_modal_builder.to_h\n EOS\nend\n"
|
62
|
# File 'lib/slocks/template_handler.rb', line 62
def default_format = :slack_modal
|