diff --git a/src/docx/file.ts b/src/docx/file.ts index ef32c39c73..414639ea53 100644 --- a/src/docx/file.ts +++ b/src/docx/file.ts @@ -1,10 +1,10 @@ import { IPropertiesOptions, Properties } from "../properties"; -import { Styles } from "../styles"; -import { DefaultStylesFactory } from "../styles/factory"; import { Document } from "./document"; import { Media } from "./media"; import { Numbering } from "./numbering"; import { Paragraph } from "./paragraph"; +import { Styles } from "./styles"; +import { DefaultStylesFactory } from "./styles/factory"; import { Table } from "./table"; export class File { diff --git a/src/docx/index.ts b/src/docx/index.ts index 063242fd49..544723257e 100644 --- a/src/docx/index.ts +++ b/src/docx/index.ts @@ -5,3 +5,4 @@ export * from "./file"; export * from "./numbering"; export * from "./media"; export * from "./drawing"; +export * from "./styles"; diff --git a/src/styles/defaults/index.ts b/src/docx/styles/defaults/index.ts similarity index 91% rename from src/styles/defaults/index.ts rename to src/docx/styles/defaults/index.ts index 065ed785bd..074baea968 100644 --- a/src/styles/defaults/index.ts +++ b/src/docx/styles/defaults/index.ts @@ -1,4 +1,4 @@ -import { XmlComponent } from "../../docx/xml-components"; +import { XmlComponent } from "../../xml-components"; import { ParagraphPropertiesDefaults } from "./paragraph-properties"; import { RunPropertiesDefaults } from "./run-properties"; diff --git a/src/styles/defaults/paragraph-properties.ts b/src/docx/styles/defaults/paragraph-properties.ts similarity index 57% rename from src/styles/defaults/paragraph-properties.ts rename to src/docx/styles/defaults/paragraph-properties.ts index bac85aa796..f8641e3a85 100644 --- a/src/styles/defaults/paragraph-properties.ts +++ b/src/docx/styles/defaults/paragraph-properties.ts @@ -1,5 +1,5 @@ -import { ParagraphProperties } from "../../docx/paragraph/properties"; -import { XmlComponent } from "../../docx/xml-components"; +import { ParagraphProperties } from "../../paragraph/properties"; +import { XmlComponent } from "../../xml-components"; export class ParagraphPropertiesDefaults extends XmlComponent { diff --git a/src/styles/defaults/run-properties.ts b/src/docx/styles/defaults/run-properties.ts similarity index 67% rename from src/styles/defaults/run-properties.ts rename to src/docx/styles/defaults/run-properties.ts index 95bf678f3b..3a7c619417 100644 --- a/src/styles/defaults/run-properties.ts +++ b/src/docx/styles/defaults/run-properties.ts @@ -1,7 +1,7 @@ -import { Size } from "../../docx/paragraph/run/formatting"; -import { RunProperties } from "../../docx/paragraph/run/properties"; -import { RunFonts } from "../../docx/paragraph/run/run-fonts"; -import { XmlComponent } from "../../docx/xml-components"; +import { Size } from "../../paragraph/run/formatting"; +import { RunProperties } from "../../paragraph/run/properties"; +import { RunFonts } from "../../paragraph/run/run-fonts"; +import { XmlComponent } from "../../xml-components"; export class RunPropertiesDefaults extends XmlComponent { private properties: RunProperties; diff --git a/src/styles/factory.ts b/src/docx/styles/factory.ts similarity index 96% rename from src/styles/factory.ts rename to src/docx/styles/factory.ts index d76183644e..aeb06bedf6 100644 --- a/src/styles/factory.ts +++ b/src/docx/styles/factory.ts @@ -1,4 +1,4 @@ -import { Color, Italics, Size } from "../docx/paragraph/run/formatting"; +import { Color, Italics, Size } from "../paragraph/run/formatting"; import { Styles } from "./"; // import { DocumentDefaults } from "./defaults"; diff --git a/src/styles/index.ts b/src/docx/styles/index.ts similarity index 89% rename from src/styles/index.ts rename to src/docx/styles/index.ts index 4487d70083..f05afd8e68 100644 --- a/src/styles/index.ts +++ b/src/docx/styles/index.ts @@ -1,5 +1,5 @@ -import { DocumentAttributes } from "../docx/document/document-attributes"; -import { XmlComponent } from "../docx/xml-components"; +import { DocumentAttributes } from "../document/document-attributes"; +import { XmlComponent } from "../xml-components"; import { DocumentDefaults } from "./defaults"; import { ParagraphStyle } from "./style"; diff --git a/src/styles/latent-styles/exceptions.ts b/src/docx/styles/latent-styles/exceptions.ts similarity index 100% rename from src/styles/latent-styles/exceptions.ts rename to src/docx/styles/latent-styles/exceptions.ts diff --git a/src/styles/latent-styles/index.ts b/src/docx/styles/latent-styles/index.ts similarity index 100% rename from src/styles/latent-styles/index.ts rename to src/docx/styles/latent-styles/index.ts diff --git a/src/styles/sample/index.ts b/src/docx/styles/sample/index.ts similarity index 100% rename from src/styles/sample/index.ts rename to src/docx/styles/sample/index.ts diff --git a/src/styles/style/components.ts b/src/docx/styles/style/components.ts similarity index 94% rename from src/styles/style/components.ts rename to src/docx/styles/style/components.ts index 8980ee8a58..df5c8b62c1 100644 --- a/src/styles/style/components.ts +++ b/src/docx/styles/style/components.ts @@ -1,4 +1,4 @@ -import { XmlAttributeComponent, XmlComponent } from "../../docx/xml-components"; +import { XmlAttributeComponent, XmlComponent } from "../../xml-components"; interface IComponentAttributes { val: string; diff --git a/src/styles/style/index.ts b/src/docx/styles/style/index.ts similarity index 96% rename from src/styles/style/index.ts rename to src/docx/styles/style/index.ts index 6464886e2e..fc75bb99d9 100644 --- a/src/styles/style/index.ts +++ b/src/docx/styles/style/index.ts @@ -1,7 +1,7 @@ -import * as paragraph from "../../docx/paragraph"; -import * as formatting from "../../docx/paragraph/run/formatting"; -import { RunProperties } from "../../docx/paragraph/run/properties"; -import { XmlAttributeComponent, XmlComponent } from "../../docx/xml-components"; +import * as paragraph from "../../paragraph"; +import * as formatting from "../../paragraph/run/formatting"; +import { RunProperties } from "../../paragraph/run/properties"; +import { XmlAttributeComponent, XmlComponent } from "../../xml-components"; import { BasedOn, Name, Next, QuickFormat } from "./components"; diff --git a/src/styles/styles.spec.ts b/src/docx/styles/styles.spec.ts similarity index 99% rename from src/styles/styles.spec.ts rename to src/docx/styles/styles.spec.ts index 090b48dffe..40e87b8d9b 100644 --- a/src/styles/styles.spec.ts +++ b/src/docx/styles/styles.spec.ts @@ -1,5 +1,5 @@ import { assert, expect } from "chai"; -import { Formatter } from "../export/formatter"; +import { Formatter } from "../../export/formatter"; import { Styles } from "./"; import { ParagraphStyle, Style } from "./style"; import * as components from "./style/components"; diff --git a/src/index.ts b/src/index.ts index 0969794c83..83ebe0a886 100644 --- a/src/index.ts +++ b/src/index.ts @@ -1,3 +1,2 @@ export * from "./docx"; export * from "./export"; -export * from "./styles";