diff --git a/src/convert.rs b/src/convert.rs index d8e190f..0edec33 100644 --- a/src/convert.rs +++ b/src/convert.rs @@ -49,6 +49,18 @@ pub fn to_tumblr_npf<'a>(ast: &'a Node<'a, RefCell>) -> Result }); text.push_str(&format!("{} ", &t)) } + NodeValue::Emph => { + let t = utils::extract_text(node); + formatting.push(Formatting { + r#type: FormattingType::Italic, + start: text.chars().count(), + end: text.chars().count() + t.chars().count() + 1, + url: None, + color: None, + blog: None, + }); + text.push_str(&format!("{} ", &t)) + } NodeValue::Text(t) => text.push_str(&format!("{} ", &t)), _ => (), }