handle <br/> when rendering a single line
+ case-insensitive matching https://forums.ankiweb.net/t/html-editor-modifies-note-when-a-field-with-break-tags-is-opened/10772
This commit is contained in:
parent
a4dc8a0b82
commit
220fca9a1d
@ -106,7 +106,7 @@ lazy_static! {
|
|||||||
\[/anki:tts\]
|
\[/anki:tts\]
|
||||||
"#).unwrap();
|
"#).unwrap();
|
||||||
|
|
||||||
static ref PERSISTENT_HTML_SPACERS: Regex = Regex::new("<br>|<br />|<div>|\n").unwrap();
|
static ref PERSISTENT_HTML_SPACERS: Regex = Regex::new(r#"(?i)<br\s*/?>|<div>|\n"#).unwrap();
|
||||||
|
|
||||||
static ref UNPRINTABLE_TAGS: Regex = Regex::new(
|
static ref UNPRINTABLE_TAGS: Regex = Regex::new(
|
||||||
r"(?xs)
|
r"(?xs)
|
||||||
|
Loading…
Reference in New Issue
Block a user