Class: Coradoc::AsciiDoc::Model::Image::BlockImage

Inherits:
Core
  • Object
show all
Defined in:
lib/coradoc/asciidoc/model/image/block_image.rb

Instance Attribute Summary

Attributes inherited from Base

#id

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Core

promoted_named, #to_adoc

Methods included from Anchorable

#default_anchor, #gen_anchor, included, #initialize

Methods inherited from Base

#inline?, #serialize_content, #simplify_block_content, #to_adoc, #to_h, visit, #visit

Class Method Details

Block images support the legacy positional form image::target[alt, caption, role, ...], so the 2nd positional is promoted to caption (Asciidoctor image block macro shorthand).

Returns:

  • (Array<Symbol>)


26
27
28
# File 'lib/coradoc/asciidoc/model/image/block_image.rb', line 26

def self.promoted_positional
  %i[alt caption]
end

Instance Method Details

#block_level?Boolean

Returns:

  • (Boolean)


8
9
10
# File 'lib/coradoc/asciidoc/model/image/block_image.rb', line 8

def block_level?
  true
end