Skip to content

test(docx-core): characterize terminal paragraph-mark cleanup parity #982

Description

@stevenobiajulu

Characterize terminal paragraph-mark cleanup parity

Independent dynamic Opus 5 review of PR #980 at d943a53 found a low-severity, pre-existing difference between native primitives and comparison AST when resolving a paragraph-mark revision with no following paragraph sibling:

<!-- primitives -->
<w:pPr><w:jc w:val="right"/><w:rPr/></w:pPr>
<!-- comparison AST -->
<w:pPr><w:jc w:val="right"/></w:pPr>

The empty mark properties are schema-valid. The early-return marker cleanup in packages/docx-core/src/primitives/accept_changes.ts predates PR #980's shared formatting repair. Do not conflate XML canonical parity with a demonstrated text, numbering or reader corruption.

  • Reproduce independently on main with synthetic terminal paragraph input for both Accept and Reject.
  • Check table-cell terminal paragraphs and filtered single-author projections.
  • Decide whether normalized structural equality should ignore empty rPr or both engines should remove it consistently.
  • Add parity regression plus schema validation without changing paragraph-removal semantics.

No Word behavior has been verified. No private inputs are needed. Keep separate from #980, #891/#973 terminal empty-paragraph behavior and #979 note reader gaps.

Ref: #941, PR #980 (review finding F4).

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions