Fix footnote reference type.
This commit is contained in:
@@ -69,6 +69,7 @@ pub use object::DayOfMonthInner;
|
||||
pub use object::Entity;
|
||||
pub use object::ExportSnippet;
|
||||
pub use object::FootnoteReference;
|
||||
pub use object::FootnoteReferenceType;
|
||||
pub use object::Hour;
|
||||
pub use object::HourInner;
|
||||
pub use object::InlineBabelCall;
|
||||
|
||||
@@ -764,3 +764,19 @@ impl<'s> OrgMacro<'s> {
|
||||
.map(|arg| coalesce_whitespace_escaped('\\', |c| ",".contains(c))(*arg))
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, PartialEq)]
|
||||
pub enum FootnoteReferenceType {
|
||||
Standard,
|
||||
Inline,
|
||||
}
|
||||
|
||||
impl<'s> FootnoteReference<'s> {
|
||||
pub fn get_type(&self) -> FootnoteReferenceType {
|
||||
if self.definition.is_empty() {
|
||||
FootnoteReferenceType::Standard
|
||||
} else {
|
||||
FootnoteReferenceType::Inline
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user