Class: Onebox::Engine::AudioOnebox
- Inherits:
-
Object
- Object
- Onebox::Engine::AudioOnebox
show all
- Includes:
- Onebox::Engine
- Defined in:
- lib/onebox/engine/audio_onebox.rb
Constant Summary
DEFAULT
Instance Attribute Summary
#errors, #options, #timeout, #uri, #url
Instance Method Summary
collapse
all_iframe_origins, engines, included, #initialize, origins_to_regexes
Instance Method Details
#placeholder_html ⇒ Object
#to_html ⇒ Object
14
15
16
17
18
19
20
21
22
23
|
# File 'lib/onebox/engine/audio_onebox.rb', line 14
def to_html
escaped_url = ::Onebox::Helpers.normalize_url_for_output(@url)
<<-HTML
<audio controls #{@options[:disable_media_download_controls] ? 'controlslist="nodownload"' : ""}>
<source src="#{escaped_url}">
<a href="#{escaped_url}">#{@url}</a>
</audio>
HTML
end
|