Fix duplicated br tags (#2717)
* Adjust test to demo duplicated br tags * Fix patchDocument duplicating br tags * Only include w:Pr * Fix tag condition --------- Co-authored-by: Dolan <dolan_miu@hotmail.com>
This commit is contained in:
@ -62,6 +62,10 @@ export const MOCK_JSON = {
|
||||
name: "w:t",
|
||||
elements: [{ type: "text", text: "What a {{bold}} text!" }],
|
||||
},
|
||||
{
|
||||
type: "element",
|
||||
name: "w:br",
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
@ -176,6 +180,10 @@ describe("replacer", () => {
|
||||
name: "w:t",
|
||||
elements: [{ type: "text", text: " text!" }],
|
||||
},
|
||||
{
|
||||
name: "w:br",
|
||||
type: "element",
|
||||
},
|
||||
],
|
||||
},
|
||||
]);
|
||||
|
Reference in New Issue
Block a user