Class: Coradoc::AsciiDoc::Model::List::Ordered
Overview
Ordered (numbered) list for AsciiDoc documents.
Ordered lists use numeric markers (1, 2, 3…) or custom markers and are typically used for sequential items.
Instance Attribute Summary
Attributes inherited from Core
#attrs, #id, #items, #marker, #ol_count
Attributes inherited from Base
Instance Method Summary collapse
-
#prefix ⇒ String
Generate the prefix marker for this list level.
Methods inherited from Core
Methods included from Anchorable
#default_anchor, #gen_anchor, included, #initialize
Methods inherited from Base
#block_level?, #inline?, #serialize_content, #simplify_block_content, #to_adoc, #to_h, visit, #visit
Instance Method Details
#prefix ⇒ String
Generate the prefix marker for this list level
25 26 27 28 29 |
# File 'lib/coradoc/asciidoc/model/list/ordered.rb', line 25 def prefix return marker if marker '.' * [ol_count, 1].max end |