Class: Onebox::Engine::TypeformOnebox

Inherits:
Object
  • Object
show all
Includes:
Onebox::Engine
Defined in:
lib/onebox/engine/typeform_onebox.rb

Constant Summary

Constants included from Onebox::Engine

DEFAULT

Instance Attribute Summary

Attributes included from Onebox::Engine

#errors, #timeout, #uri, #url

Instance Method Summary collapse

Methods included from Onebox::Engine

all_iframe_origins, engines, included, #initialize, #options, #options=, origins_to_regexes

Instance Method Details

#placeholder_htmlObject



25
26
27
# File 'lib/onebox/engine/typeform_onebox.rb', line 25

def placeholder_html
  ::Onebox::Helpers.generic_placeholder_html
end

#to_htmlObject



12
13
14
15
16
17
18
19
20
21
22
23
# File 'lib/onebox/engine/typeform_onebox.rb', line 12

def to_html
  typeform_src = build_typeform_src

  <<~HTML
    <iframe src="#{typeform_src}"
            width="100%"
            height="600px"
            scrolling="no"
            frameborder="0">
    </iframe>
  HTML
end