fix: multiple def of header/footer attributes
This commit is contained in:
@ -10,6 +10,7 @@ export class Footer extends InitializableXmlComponent {
|
|||||||
constructor(referenceNumber: number, initContent?: XmlComponent) {
|
constructor(referenceNumber: number, initContent?: XmlComponent) {
|
||||||
super("w:ftr", initContent);
|
super("w:ftr", initContent);
|
||||||
this.refId = referenceNumber;
|
this.refId = referenceNumber;
|
||||||
|
if (!initContent) {
|
||||||
this.root.push(
|
this.root.push(
|
||||||
new FooterAttributes({
|
new FooterAttributes({
|
||||||
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
||||||
@ -31,6 +32,7 @@ export class Footer extends InitializableXmlComponent {
|
|||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public get ReferenceId(): number {
|
public get ReferenceId(): number {
|
||||||
return this.refId;
|
return this.refId;
|
||||||
|
@ -11,7 +11,7 @@ export class Header extends InitializableXmlComponent {
|
|||||||
super("w:hdr", initContent);
|
super("w:hdr", initContent);
|
||||||
|
|
||||||
this.refId = referenceNumber;
|
this.refId = referenceNumber;
|
||||||
|
if (!initContent) {
|
||||||
this.root.push(
|
this.root.push(
|
||||||
new HeaderAttributes({
|
new HeaderAttributes({
|
||||||
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
wpc: "http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",
|
||||||
@ -44,6 +44,7 @@ export class Header extends InitializableXmlComponent {
|
|||||||
}),
|
}),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public get ReferenceId(): number {
|
public get ReferenceId(): number {
|
||||||
return this.refId;
|
return this.refId;
|
||||||
|
Reference in New Issue
Block a user