Sha256: a271cbc7ae78a93524c65290193456b7aa2db74fe7d397a171f29ad318a44c1c

Contents?: true

Size: 385 Bytes

Versions: 5

Compression:

Stored size: 385 Bytes

Contents

module Asciidoctor
module Image
  class << self
    def image_type path
      (::File.extname path).downcase[1..-1]
    end
  end

  def image_type
    ::File.extname(inline? ? target : (attr 'target')).downcase[1..-1]
  end

  def target_with_image_type
    image_path = inline? ? (target) : (attr 'target')
    [image_path, (::File.extname image_path).downcase[1..-1]]
  end
end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
asciidoctor-pdf-1.5.0.alpha.12 lib/asciidoctor-pdf/asciidoctor_ext/image.rb
asciidoctor-pdf-1.5.0.alpha.11 lib/asciidoctor-pdf/asciidoctor_ext/image.rb
asciidoctor-pdf-1.5.0.alpha.10 lib/asciidoctor-pdf/asciidoctor_ext/image.rb
asciidoctor-pdf-1.5.0.alpha.9 lib/asciidoctor-pdf/asciidoctor_ext/image.rb
asciidoctor-pdf-1.5.0.alpha.8 lib/asciidoctor-pdf/asciidoctor_ext/image.rb