feat: transfer comments property to File CoreProperties like numbering.

This commit is contained in:
Chen Yuncai
2022-03-07 20:02:14 +08:00
parent b2a09b512f
commit b81086ab7a
7 changed files with 32 additions and 25 deletions

View File

@ -71,6 +71,10 @@ export class File {
},
);
if (options.comments) {
this.comments = options.comments;
}
this.fileRelationships = new Relationships();
this.customProperties = new CustomProperties(options.customProperties ?? []);
this.appProperties = new AppProperties();
@ -136,9 +140,6 @@ export class File {
this.footnotesWrapper.View.createFootNote(parseFloat(key), options.footnotes[key].children);
}
}
if (fileProperties.template && fileProperties.template.comments) {
this.comments = fileProperties.template.comments;
}
}
private addSection({ headers = {}, footers = {}, children, properties }: ISectionOptions): void {