Inline HTML-to-format converters consolideren (DOCX en ODT) #2080
Labels
No labels
accepted
bug
declined
docs
duplicate
enhancement
good first issue
in-progress
needs-info
privacy
security
triage
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
LibreKAT/Ocideck#2080
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Probleem
DOCX en ODT hebben dezelfde strategie voor inline markdown-conversie: markdown naar inline HTML via
md.markdownToHtml(...), dan regex-replace naar formaat-specifieke tags. Beide verwerken strong, em, del, code, a, br op identieke wijze, alleen de target XML-tags verschillen.Betrokken bestanden
lib/services/docx/markdown_to_docx.dart:241-279(_htmlInlineToDocx)lib/services/odt/markdown_to_odt.dart:121-159(_htmlInlineToOdt)Voorstel
Extraheer naar een generieke
htmlInlineTo(String html, Map<String, String> tags)helper, waarbij elke converter een tag-map meegeeft.Schatting
~30 regels verwijderbaar.
Labels
duplicate, enhancement