pub enum MdBlock {
Heading {
level: u8,
spans: Vec<TextSpan>,
},
Paragraph {
spans: Vec<TextSpan>,
},
Blockquote {
spans: Vec<TextSpan>,
},
ListItem {
kind: ListKind,
depth: u32,
ordinal: Option<u32>,
spans: Vec<TextSpan>,
},
CodeBlock {
lang: Option<String>,
content: String,
},
HorizontalRule,
}Expand description
A parsed block-level markdown element.
Variants§
Heading
ATX heading (# … ######). level is 1–6.
Paragraph
One or more consecutive non-blank lines (not matching any other rule).
Blockquote
A > blockquote (consecutive lines merged with a space).
ListItem
A single list item (flat; depth encodes indentation level).
CodeBlock
A fenced code block (…). content is RAW — no inline parsing.
HorizontalRule
A horizontal rule (---, ***, ___, - - -, …).
Trait Implementations§
impl StructuralPartialEq for MdBlock
Auto Trait Implementations§
impl Freeze for MdBlock
impl RefUnwindSafe for MdBlock
impl Send for MdBlock
impl Sync for MdBlock
impl Unpin for MdBlock
impl UnsafeUnpin for MdBlock
impl UnwindSafe for MdBlock
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more