Compare commits
4 Commits
Author | SHA1 | Date | |
---|---|---|---|
3006f4d2c1 | |||
7f88a38219 | |||
a481518470 | |||
2435ebf16e |
4
package-lock.json
generated
4
package-lock.json
generated
@ -1,12 +1,12 @@
|
||||
{
|
||||
"name": "docx",
|
||||
"version": "7.8.0",
|
||||
"version": "7.8.2",
|
||||
"lockfileVersion": 2,
|
||||
"requires": true,
|
||||
"packages": {
|
||||
"": {
|
||||
"name": "docx",
|
||||
"version": "7.8.0",
|
||||
"version": "7.8.2",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@types/node": "^18.0.0",
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "docx",
|
||||
"version": "7.8.0",
|
||||
"version": "7.8.2",
|
||||
"description": "Easily generate .docx files with JS/TS with a nice declarative API. Works for Node and on the Browser.",
|
||||
"main": "build/index.js",
|
||||
"scripts": {
|
||||
|
@ -75,7 +75,7 @@ export class PageBorders extends IgnoreIfEmptyXmlComponent {
|
||||
super("w:pgBorders");
|
||||
|
||||
if (!options) {
|
||||
return;
|
||||
return this;
|
||||
}
|
||||
|
||||
if (options.pageBorders) {
|
||||
|
@ -23,11 +23,11 @@ export class Text extends XmlComponent {
|
||||
if (typeof options === "string") {
|
||||
this.root.push(new TextAttributes({ space: SpaceType.PRESERVE }));
|
||||
this.root.push(options);
|
||||
return;
|
||||
return this;
|
||||
} else {
|
||||
this.root.push(new TextAttributes({ space: options.space ?? SpaceType.DEFAULT }));
|
||||
this.root.push(options.text);
|
||||
return;
|
||||
return this;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ export class SymbolRun extends Run {
|
||||
if (typeof options === "string") {
|
||||
super({});
|
||||
this.root.push(new Symbol(options));
|
||||
return;
|
||||
return this;
|
||||
}
|
||||
|
||||
super(options);
|
||||
|
Reference in New Issue
Block a user