added numbering

This commit is contained in:
Dolan Miu
2016-05-21 00:02:46 +01:00
parent cf3cd6b6a2
commit 8dcdbeef2f
7 changed files with 168 additions and 6 deletions

27
ts/numbering/indent.ts Normal file
View File

@ -0,0 +1,27 @@
import {XmlComponent, XmlAttributeComponent} from "../docx/xml-components";
interface IndentAttributesProperties {
left: number;
hanging: number;
}
class IndentAttributes extends XmlAttributeComponent {
constructor(properties: IndentAttributesProperties) {
super({
left: "w:left",
hanging: "w:hanging"
}, properties);
}
}
export class Indent extends XmlComponent {
constructor(left: number, hanging: number) {
super("w:ind");
this.root.push(new IndentAttributes({
left: left,
hanging: hanging
}));
}
}