From 6e21cdbf17a01f182aa3f220ae158255ac4ddc40 Mon Sep 17 00:00:00 2001 From: Dolan Date: Thu, 18 Mar 2021 03:28:29 +0000 Subject: [PATCH] Fix demos --- demo/11-declaritive-styles-2.ts | 60 ++++++++++++++++++--------------- 1 file changed, 33 insertions(+), 27 deletions(-) diff --git a/demo/11-declaritive-styles-2.ts b/demo/11-declaritive-styles-2.ts index 3dac550288..ddb25a5445 100644 --- a/demo/11-declaritive-styles-2.ts +++ b/demo/11-declaritive-styles-2.ts @@ -178,15 +178,17 @@ doc.addSection({ }), }, children: [ - new Paragraph( - new ImageRun({ - data: fs.readFileSync("./demo/images/pizza.gif"), - transformation: { - width: 100, - height: 100, - }, - }), - ), + new Paragraph({ + children: [ + new ImageRun({ + data: fs.readFileSync("./demo/images/pizza.gif"), + transformation: { + width: 100, + height: 100, + }, + }), + ], + }), new Paragraph({ text: "HEADING", heading: HeadingLevel.HEADING_1, @@ -225,28 +227,32 @@ doc.addSection({ style: "normalPara", }), table, - new Paragraph( - new ImageRun({ - data: fs.readFileSync("./demo/images/pizza.gif"), - transformation: { - width: 100, - height: 100, - }, - }), - ), + new Paragraph({ + children: [ + new ImageRun({ + data: fs.readFileSync("./demo/images/pizza.gif"), + transformation: { + width: 100, + height: 100, + }, + }), + ], + }), new Paragraph({ text: "Test", style: "normalPara2", }), - new Paragraph( - new ImageRun({ - data: fs.readFileSync("./demo/images/pizza.gif"), - transformation: { - width: 100, - height: 100, - }, - }), - ), + new Paragraph({ + children: [ + new ImageRun({ + data: fs.readFileSync("./demo/images/pizza.gif"), + transformation: { + width: 100, + height: 100, + }, + }), + ], + }), new Paragraph({ text: "Test 2", style: "normalPara2",