Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: JSv4/Docxodus
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v5.3.0
Choose a base ref
...
head repository: JSv4/Docxodus
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v5.4.0
Choose a head ref
  • 19 commits
  • 9 files changed
  • 2 contributors

Commits on Dec 21, 2025

  1. test(converter): add feature verification tests for resolved gaps

    Add comprehensive test suite (FeatureVerificationTests.cs) that verifies
    all 8 resolved features in the WmlToHtmlConverter gaps document:
    
    - @page CSS rule generation (GeneratePageCss setting)
    - Table DXA width conversion (twips to points)
    - Borderless table detection (data-borderless attribute)
    - Theme color resolution (ResolveThemeColors setting)
    - Document language on <html> element
    - Foreign text language spans (lang attributes)
    - Font fallback improvements (serif/sans-serif/monospace)
    - CJK font-family fallback chains (Japanese, Chinese, Korean)
    
    All 15 tests pass, confirming the features work correctly.
    
    Also updates gaps document with verification summary table.
    JSv4 committed Dec 21, 2025
    Configuration menu
    Copy the full SHA
    a3faaf5 View commit details
    Browse the repository at this point in the history
  2. Merge pull request #88 from JSv4/feature/verify-resolved-gaps

    test(converter): add feature verification tests for resolved gaps
    JSv4 authored Dec 21, 2025
    Configuration menu
    Copy the full SHA
    b9df194 View commit details
    Browse the repository at this point in the history

Commits on Dec 22, 2025

  1. fix(converter): skip footnoteRef/endnoteRef runs to prevent empty spans

    When rendering footnotes/endnotes, Word documents contain runs with
    w:footnoteRef or w:endnoteRef elements that display the note number
    inside the note text. Since we add note numbers separately (via
    footnote-number span in paginated mode or <ol> value in non-paginated
    mode), these runs produced empty styled spans causing whitespace issues.
    
    This fix detects runs containing only w:footnoteRef or w:endnoteRef
    and returns null, preventing the creation of empty spans in the HTML
    output.
    
    - Add check in ConvertRun() to skip footnoteRef/endnoteRef-only runs
    - Add tests for both paginated and non-paginated footnote rendering
    JSv4 committed Dec 22, 2025
    Configuration menu
    Copy the full SHA
    4fe7906 View commit details
    Browse the repository at this point in the history
  2. feat(converter): align footnote/endnote rendering with LibreOffice

    - Remove brackets from footnote/endnote reference numbers ([2] → 2)
    - Put <sup> inside anchor tag like LibreOffice does
    - Skip span wrapper for runs containing only footnote/endnote references
      to prevent whitespace issues from nested elements
    - Move backref arrow inside last paragraph to prevent line breaks
    - Skip runs containing only w:footnoteRef/w:endnoteRef placeholders
    
    Before: <span class="pt-FootnoteReference"><sup><a>[2]</a></sup></span>
    After:  <a class="footnote-ref"><sup>2</sup></a>
    
    LibreOffice: <a class="sdfootnoteanc"><sup>1</sup></a>
    JSv4 committed Dec 22, 2025
    Configuration menu
    Copy the full SHA
    9aa0d01 View commit details
    Browse the repository at this point in the history
  3. Merge pull request #89 from JSv4/feature/fix-footnote-ref-empty-spans

    fix(converter): skip footnoteRef/endnoteRef runs to prevent empty spans
    JSv4 authored Dec 22, 2025
    Configuration menu
    Copy the full SHA
    df13c6f View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    69cb130 View commit details
    Browse the repository at this point in the history
  5. Merge pull request #90 from JSv4/feature/footnote-rendering-libreoffi…

    …ce-alignment
    
    feat(converter): align footnote/endnote rendering with LibreOffice
    JSv4 authored Dec 22, 2025
    Configuration menu
    Copy the full SHA
    c44fc55 View commit details
    Browse the repository at this point in the history

Commits on Dec 23, 2025

  1. feat(converter): align whitespace handling with LibreOffice HTML output

    - Remove white-space: pre-wrap from default CSS to match LibreOffice behavior
    - Add ConvertTextWithNbsp() to convert significant whitespace to &nbsp; entities
      (multiple consecutive spaces, leading/trailing spaces in text runs)
    - Add NormalizeInlineWhitespace() to remove whitespace text nodes between
      inline elements in the XElement tree
    - Add ToHtmlString() helper method for proper HTML serialization that removes
      formatting whitespace between inline elements while preserving indentation
    
    This ensures that HTML formatting (newlines/indentation) doesn't create visible
    spaces between adjacent spans/anchors in the rendered output, matching how
    LibreOffice generates HTML from DOCX documents.
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    6905587 View commit details
    Browse the repository at this point in the history
  2. fix: use Unicode non-breaking space for XML compatibility

    Use \u00A0 character instead of &nbsp; entity to ensure HTML output
    can be parsed as valid XML by tests.
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    977f372 View commit details
    Browse the repository at this point in the history
  3. Merge pull request #91 from JSv4/feature/nested-list-styles

    feat(converter): align whitespace handling with LibreOffice HTML output
    JSv4 authored Dec 23, 2025
    Configuration menu
    Copy the full SHA
    e448ece View commit details
    Browse the repository at this point in the history
  4. fix(converter): remove default 108% line-height to match LibreOffice …

    …output
    
    Previously, DefineLineHeight() unconditionally added `line-height: 108%`
    to all unidirectional paragraphs. This made text appear more compressed
    than LibreOffice's HTML output, which doesn't set any explicit line-height
    and lets browsers use their default (~120%).
    
    Changes:
    - Remove the hardcoded 108% line-height default from DefineLineHeight()
    - Line-height is now only set when explicitly specified via w:lineRule
      in the document (already handled by CreateStyleFromSpacing)
    
    This improves visual alignment with LibreOffice's HTML rendering for
    paragraph and line spacing.
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    6ec7a79 View commit details
    Browse the repository at this point in the history
  5. Merge pull request #92 from JSv4/feature/remove-default-line-height

    fix(converter): remove default 108% line-height to match LibreOffice output
    JSv4 authored Dec 23, 2025
    Configuration menu
    Copy the full SHA
    73c0ae3 View commit details
    Browse the repository at this point in the history
  6. fix(converter): handle legal numbering continuation pattern

    Fix incorrect multi-level list numbering when items continue a flat
    sequence at different indentation levels. Documents with items like
    1., 2., 3. at level 0 followed by item at level 1 (with start=4) now
    render as "4." instead of "3.4".
    
    The fix adds "continuation pattern" detection in ListItemRetriever.cs:
    - Detects when a deeper-level item continues a flat list sequence
      (start value equals parent counter + 1)
    - When detected, uses level 0's format string with current counter
    - Tracks continuation state per level with inheritance
    - Resets deeper level tracking when going to shallower levels
    
    Also adds:
    - docs/ooxml_corner_cases.md for documenting OOXML edge cases
    - CLAUDE.md section on documenting corner cases
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    d88aff6 View commit details
    Browse the repository at this point in the history
  7. fix(converter): use effective level for run/paragraph properties in c…

    …ontinuation patterns
    
    When a list item is detected as a "continuation pattern" (deeper-level
    item that continues a flat sequence), the converter now uses level 0's
    properties for:
    - Run properties (rPr) - fixes underline appearing incorrectly
    - Paragraph properties (pPr) - fixes tab stops and indentation
    
    Changes:
    - FormattingAssembler.cs: Use GetEffectiveLevel() in NormalizeListItemsTransform,
      ParaStyleParaPropsStack, and AnnotateParagraph functions
    - ListItemRetriever.cs: Made ContinuationInfo class internal for cross-file access
    - Updated CHANGELOG.md and docs/ooxml_corner_cases.md with fix details
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    4220569 View commit details
    Browse the repository at this point in the history
  8. test(converter): add continuation pattern tests for legal numbering

    Added two tests to verify the continuation pattern fix:
    - HC050_ContinuationPattern_RendersCorrectNumber: Verifies items at ilvl=1
      with start=4 render as "4." instead of "3.4"
    - HC051_ContinuationPattern_UsesLevel0Formatting: Verifies continuation items
      use level 0's run properties (no underline when level 1 has underline)
    
    These tests create programmatic documents with multi-level numbered lists
    to verify the fix handles the edge case correctly.
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    aa48357 View commit details
    Browse the repository at this point in the history
  9. fix(converter): prevent mutation of numbering definition during forma…

    …tting
    
    Clone numberingParaProps before removing non-indent elements to avoid
    mutating the original numbering definition. This was causing subsequent
    list items using the same numbering level to lose their tab definitions,
    resulting in inconsistent wrapper span widths (0.5in instead of 0.25in).
    
    Also updated CalculateSpanWidthTransform to check accumulated properties
    (pt:pPr) first for indentation and tabs, falling back to direct properties
    (w:pPr) if not found.
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    d2de7d2 View commit details
    Browse the repository at this point in the history
  10. Merge pull request #93 from JSv4/feature/fix-legal-numbering-continua…

    …tion
    
    fix(converter): handle legal numbering continuation pattern
    JSv4 authored Dec 23, 2025
    Configuration menu
    Copy the full SHA
    fa9facd View commit details
    Browse the repository at this point in the history
  11. fix(converter): use sequential display numbers for footnotes/endnotes

    Per ECMA-376, the w:id attribute on footnoteReference/endnoteReference
    elements is a reference identifier linking to definitions, not the
    display number. Display numbers should be sequential (1, 2, 3...) based
    on document order.
    
    Previously, we incorrectly used raw XML IDs (e.g., 2, 3, 4...) as
    display numbers, causing footnotes to be numbered starting from 2
    instead of 1.
    
    Changes:
    - Add FootnoteNumberingTracker class to map XML IDs to sequential
      display numbers based on document order
    - Update ProcessFootnoteReference/ProcessEndnoteReference to use
      display numbers instead of XML IDs
    - Update RenderFootnotesSection/RenderEndnotesSection to order notes
      by document order and use correct display numbers
    - Update RenderPaginatedFootnoteRegistry for pagination mode
    - Update documentation in docs/ooxml_corner_cases.md
    JSv4 committed Dec 23, 2025
    Configuration menu
    Copy the full SHA
    f70ad50 View commit details
    Browse the repository at this point in the history

Commits on Dec 24, 2025

  1. Merge pull request #94 from JSv4/feature/fix-footnote-numbering

    fix(converter): use sequential display numbers for footnotes/endnotes
    JSv4 authored Dec 24, 2025
    Configuration menu
    Copy the full SHA
    8942fc3 View commit details
    Browse the repository at this point in the history
Loading