Method: IsoDoc::HtmlFunction::Html#image_body_parse
- Defined in:
- lib/isodoc/html_function/html.rb
#image_body_parse(node, attrs, out) ⇒ Object
101 102 103 104 105 106 107 108 109 110 |
# File 'lib/isodoc/html_function/html.rb', line 101 def image_body_parse(node, attrs, out) if svg = node.at("./m:svg", "m" => "http://www.w3.org/2000/svg") %i(height width).each do |k| v = attrs[k] and v != "auto" and !v.empty? and svg[k.to_s] = v end out.parent.add_child(svg) else super end end |