mirror of
https://git.joinplu.me/Plume/Plume.git
synced 2024-11-25 13:01:08 +00:00
* Ensure footnotes classes generated are not filtered pulldown-cmark add somes classes when footnotes html is generated. This commit ensure they are not filtered by html sanitizer * Add some footnotes styling
This commit is contained in:
parent
7f296b2ef2
commit
3bd2305115
2 changed files with 12 additions and 0 deletions
|
@ -481,3 +481,12 @@ input:checked ~ .cw-container > .cw-text {
|
||||||
margin: auto $horizontal-margin;
|
margin: auto $horizontal-margin;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Footnote related styles
|
||||||
|
.footnote-definition {
|
||||||
|
p {
|
||||||
|
font-size: smaller;
|
||||||
|
// Make sur the definition is inline with the label-definition
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -31,6 +31,9 @@ lazy_static! {
|
||||||
.add_tag_attributes("label", ["for"].iter())
|
.add_tag_attributes("label", ["for"].iter())
|
||||||
.add_tag_attributes("input", ["type", "checked"].iter())
|
.add_tag_attributes("input", ["type", "checked"].iter())
|
||||||
.add_allowed_classes("input", ["cw-checkbox"].iter())
|
.add_allowed_classes("input", ["cw-checkbox"].iter())
|
||||||
|
// Related to https://github.com/Plume-org/Plume/issues/637
|
||||||
|
.add_allowed_classes("sup", ["footnote-reference", "footnote-definition-label"].iter())
|
||||||
|
.add_allowed_classes("div", ["footnote-definition"].iter())
|
||||||
.add_allowed_classes("span", ["cw-container", "cw-text"].iter())
|
.add_allowed_classes("span", ["cw-container", "cw-text"].iter())
|
||||||
.attribute_filter(|elem, att, val| match (elem, att) {
|
.attribute_filter(|elem, att, val| match (elem, att) {
|
||||||
("input", "type") => Some("checkbox".into()),
|
("input", "type") => Some("checkbox".into()),
|
||||||
|
|
Loading…
Reference in a new issue