docx
Version:
Easily generate .docx files with JS/TS with a nice declarative API. Works for Node and on the Browser.
19 lines (14 loc) • 466 B
text/typescript
// http://officeopenxml.com/drwSp-size.php
import { XmlComponent } from "file/xml-components";
import { ExtentsAttributes } from "./extents-attributes";
export class Extents extends XmlComponent {
private readonly attributes: ExtentsAttributes;
constructor(x: number, y: number) {
super("a:ext");
this.attributes = new ExtentsAttributes({
cx: x,
cy: y,
});
this.root.push(this.attributes);
}
}