~bigbes/confluence-md-utilities

ref: 442bf5982d1e46a2737804b2f30a9b4895e9ac02 confluence-md-utilities/cmd/mdcx/verify_test.go -rw-r--r-- 10.9 KiB
701c5ef2 — Eugene Blikh 2 months ago
feat: improve round-trip fidelity for panels, tables, and verify

- Preserve panel name (info/note/warning), macro-id, parameters, and
  body-bare layout via HTML comment markers so blockquotes round-trip
  back to the original ac:structured-macro form.
- Serialize tables with complex cell content (nested lists, structured
  macros, row-header th, page links) as raw XML inside the markdown so
  GFM table limits don't lossily flatten them.
- Distinguish ac:toc inside <p> from bare ac:toc, restoring the wrapper.
- Strip inline-comment-marker wrappers and decorative <span>s inside
  code spans where markdown can't represent them.
- Normalize self-closing tags to "<tag />" and unify &#34;/&#39; with
  &quot;/' so the pretty printer doesn't introduce cosmetic diffs.
- Apply verify normalization to both input and round-trip output, and
  add rules for trailing whitespace, <br/> before </li>, <p>-wrapped
  image runs, and bare text after headings.
5fabfe01 — Eugene Blikh 4 months ago
feat: add verify command, improve round-trip fidelity

Add verify command for XML validation. Merge adjacent <code> elements
during XML→MD conversion. Preserve macro attribute order for round-trip
fidelity. Fix list item trailing whitespace and normalize <hr /> format.

false