class InlineSvg::TransformPipeline::Transformations::Transformation

def self.create_with_value(value)

def self.create_with_value(value)
  self.new(value)
end

def initialize(value)

def initialize(value)
  @value = value
end

def transform(*)

def transform(*)
  raise "#transform should be implemented by subclasses of Transformation"
end

def with_svg(doc)

Returns a Nokogiri::XML::Document.

if it exists.
Parses a document and yields the contained SVG nodeset to the given block
def with_svg(doc)
  doc = Nokogiri::XML::Document.parse(
    doc.to_html(encoding: "UTF-8"), nil, "UTF-8"
  )
  svg = doc.at_css "svg"
  yield svg if svg && block_given?
  doc
end