This commit is contained in:
@ -60,6 +60,7 @@ impl Liste {
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Self { content }
|
||||
}
|
||||
}
|
||||
|
@ -201,7 +201,14 @@ pub(crate) struct Ziffernliste {
|
||||
impl Ziffernliste {
|
||||
pub(crate) fn test(n: &Node) -> bool {
|
||||
// strichliste -> § 194b FSG
|
||||
["ziffernliste", "aufzaehlung", "literaliste", "strichliste"].contains(&n.tag_name().name())
|
||||
[
|
||||
"ziffernliste",
|
||||
"aufzaehlung",
|
||||
"literaliste",
|
||||
"strichliste",
|
||||
"erlliste",
|
||||
]
|
||||
.contains(&n.tag_name().name())
|
||||
}
|
||||
|
||||
pub(crate) fn test_with_level(n: &Node, level: usize) -> bool {
|
||||
@ -216,7 +223,11 @@ impl Ziffernliste {
|
||||
|
||||
assert!(Self::test(&n));
|
||||
|
||||
let ebene = n.attribute("ebene").unwrap().parse::<usize>().unwrap();
|
||||
let ebene = n
|
||||
.attribute("ebene")
|
||||
.unwrap_or("1")
|
||||
.parse::<usize>()
|
||||
.unwrap();
|
||||
|
||||
let mut listelems = Vec::new();
|
||||
|
||||
|
Reference in New Issue
Block a user