Add content types initial files
This commit is contained in:
11
src/file/content-types/content-types-attributes.ts
Normal file
11
src/file/content-types/content-types-attributes.ts
Normal file
@ -0,0 +1,11 @@
|
||||
import { XmlAttributeComponent } from "file/xml-components";
|
||||
|
||||
export interface IContentTypeAttributes {
|
||||
xmlns?: string;
|
||||
}
|
||||
|
||||
export class ContentTypeAttributes extends XmlAttributeComponent<IContentTypeAttributes> {
|
||||
protected xmlKeys = {
|
||||
xmlns: "xmlns",
|
||||
};
|
||||
}
|
14
src/file/content-types/content-types.ts
Normal file
14
src/file/content-types/content-types.ts
Normal file
@ -0,0 +1,14 @@
|
||||
import { XmlComponent } from "file/xml-components";
|
||||
import { ContentTypeAttributes } from "./content-types-attributes";
|
||||
|
||||
export class ContentTypes extends XmlComponent {
|
||||
constructor() {
|
||||
super("Types");
|
||||
|
||||
this.root.push(
|
||||
new ContentTypeAttributes({
|
||||
xmlns: "http://schemas.openxmlformats.org/package/2006/content-types",
|
||||
}),
|
||||
);
|
||||
}
|
||||
}
|
9
src/file/content-types/default/default.ts
Normal file
9
src/file/content-types/default/default.ts
Normal file
@ -0,0 +1,9 @@
|
||||
import { XmlComponent } from "file/xml-components";
|
||||
|
||||
export class Default extends XmlComponent {
|
||||
constructor() {
|
||||
super("Types");
|
||||
|
||||
this.root.push();
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user