Files
docx-js/src/file/paragraph/run/sequential-identifier-instruction.ts

14 lines
467 B
TypeScript
Raw Normal View History

// http://officeopenxml.com/WPfieldInstructions.php
import { SpaceType } from "file/space-type";
2022-06-15 00:07:12 +01:00
import { XmlComponent } from "file/xml-components";
2022-06-15 00:07:12 +01:00
import { TextAttributes } from "./text-attributes";
export class SequentialIdentifierInstruction extends XmlComponent {
constructor(identifier: string) {
super("w:instrText");
this.root.push(new TextAttributes({ space: SpaceType.PRESERVE }));
this.root.push(`SEQ ${identifier}`);
}
}