feature: add support to add mutiple sections to the document inc. headers and footers
- write missing tests
This commit is contained in:
@ -6,8 +6,10 @@ import { Table } from "../table";
|
||||
import { HeaderAttributes } from "./header-attributes";
|
||||
|
||||
export class Header extends XmlComponent {
|
||||
constructor() {
|
||||
private refId: number;
|
||||
constructor(referenceNumber: number) {
|
||||
super("w:hdr");
|
||||
this.refId = referenceNumber;
|
||||
this.root.push(
|
||||
new HeaderAttributes({
|
||||
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
||||
@ -30,6 +32,10 @@ export class Header extends XmlComponent {
|
||||
);
|
||||
}
|
||||
|
||||
get referenceId() {
|
||||
return this.refId;
|
||||
}
|
||||
|
||||
public addParagraph(paragraph: Paragraph): void {
|
||||
this.root.push(paragraph);
|
||||
}
|
||||
|
Reference in New Issue
Block a user