Improve import alias

@file/ and @export/ instead of file/ and export/ etc
This commit is contained in:
Dolan Miu
2022-06-26 23:26:42 +01:00
parent c19bc6b4b3
commit 982d923553
380 changed files with 758 additions and 521 deletions

View File

@ -1,10 +1,10 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { GridCol, TableGrid } from "./grid";
import { EMPTY_OBJECT } from "file/xml-components";
import { EMPTY_OBJECT } from "@file/xml-components";
describe("GridCol", () => {
describe("#constructor", () => {

View File

@ -9,8 +9,8 @@
// </xsd:sequence>
// </xsd:complexType>
import { twipsMeasureValue } from "file/values";
import { XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { XmlAttributeComponent, XmlComponent } from "@file/xml-components";
import { twipsMeasureValue } from "@util/values";
export class TableGrid extends XmlComponent {
constructor(widths: number[] | string[]) {

View File

@ -1,6 +1,6 @@
import { BorderElement, IBorderOptions } from "file/border";
import { decimalNumber } from "file/values";
import { IgnoreIfEmptyXmlComponent, XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { BorderElement, IBorderOptions } from "@file/border";
import { IgnoreIfEmptyXmlComponent, XmlAttributeComponent, XmlComponent } from "@file/xml-components";
import { decimalNumber } from "@util/values";
// <xsd:complexType name="CT_TcBorders">
// <xsd:sequence>

View File

@ -1,8 +1,8 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { BorderStyle } from "file/border";
import { VerticalAlign } from "file/vertical-align";
import { Formatter } from "@export/formatter";
import { BorderStyle } from "@file/border";
import { VerticalAlign } from "@file/vertical-align";
import { WidthType } from "../table-width";

View File

@ -1,5 +1,5 @@
import { VerticalAlign, VerticalAlignElement } from "file/vertical-align";
import { IgnoreIfEmptyXmlComponent } from "file/xml-components";
import { VerticalAlign, VerticalAlignElement } from "@file/vertical-align";
import { IgnoreIfEmptyXmlComponent } from "@file/xml-components";
import { IShadingAttributesProperties, Shading } from "../../shading";
import { ITableCellMarginOptions, TableCellMargin, TableCellMarginElementType } from "../table-properties/table-cell-margin";

View File

@ -1,9 +1,9 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { BorderStyle } from "file/border";
import { ShadingType } from "file/shading";
import { VerticalAlign } from "file/vertical-align";
import { Formatter } from "@export/formatter";
import { BorderStyle } from "@file/border";
import { ShadingType } from "@file/shading";
import { VerticalAlign } from "@file/vertical-align";
import { WidthType } from "../table-width";
import { TableCell } from "./table-cell";

View File

@ -1,6 +1,6 @@
// http://officeopenxml.com/WPtableGrid.php
import { Paragraph } from "file/paragraph";
import { IContext, IXmlableObject, XmlComponent } from "file/xml-components";
import { Paragraph } from "@file/paragraph";
import { IContext, IXmlableObject, XmlComponent } from "@file/xml-components";
import { Table } from "../table";
import { ITableCellPropertiesOptions, TableCellProperties } from "./table-cell-properties";

View File

@ -1,7 +1,7 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { BorderStyle } from "file/border";
import { Formatter } from "@export/formatter";
import { BorderStyle } from "@file/border";
import { TableBorders } from "./table-borders";

View File

@ -1,6 +1,6 @@
// http://officeopenxml.com/WPtableBorders.php
import { BorderElement, BorderStyle, IBorderOptions } from "file/border";
import { XmlComponent } from "file/xml-components";
import { BorderElement, BorderStyle, IBorderOptions } from "@file/border";
import { XmlComponent } from "@file/xml-components";
export interface ITableBordersOptions {
readonly top?: IBorderOptions;

View File

@ -1,6 +1,6 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { WidthType } from "../table-width";
import { TableCellMargin, TableCellMarginElementType } from "./table-cell-margin";

View File

@ -1,4 +1,4 @@
import { IgnoreIfEmptyXmlComponent } from "file/xml-components";
import { IgnoreIfEmptyXmlComponent } from "@file/xml-components";
import { TableWidthElement, WidthType } from "../table-width";
export interface ITableCellMarginOptions {

View File

@ -1,6 +1,6 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { RelativeHorizontalPosition, RelativeVerticalPosition, TableAnchorType, TableFloatProperties } from "./table-float-properties";
import { OverlapType } from "./table-overlap";

View File

@ -1,5 +1,5 @@
import { signedTwipsMeasureValue, twipsMeasureValue } from "file/values";
import { XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { XmlAttributeComponent, XmlComponent } from "@file/xml-components";
import { signedTwipsMeasureValue, twipsMeasureValue } from "@util/values";
import { OverlapType, TableOverlap } from "./table-overlap";

View File

@ -1,4 +1,4 @@
import { XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { XmlAttributeComponent, XmlComponent } from "@file/xml-components";
// <xsd:simpleType name="ST_TblLayoutType">
// <xsd:restriction base="xsd:string">

View File

@ -1,6 +1,6 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { OverlapType, TableOverlap } from "./table-overlap";

View File

@ -1,4 +1,4 @@
import { XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { XmlAttributeComponent, XmlComponent } from "@file/xml-components";
// <xsd:simpleType name="ST_TblOverlap">
// <xsd:restriction base="xsd:string">

View File

@ -1,9 +1,9 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { AlignmentType } from "file/paragraph";
import { ShadingType } from "file/shading";
import { AlignmentType } from "@file/paragraph";
import { ShadingType } from "@file/shading";
import { WidthType } from "../table-width";
import { TableLayoutType } from "./table-layout";

View File

@ -21,7 +21,7 @@
// <xsd:element name="tblDescription" type="CT_String" minOccurs="0" maxOccurs="1"/>
// </xsd:sequence>
// </xsd:complexType>
import { IgnoreIfEmptyXmlComponent, OnOffElement, StringValueElement } from "file/xml-components";
import { IgnoreIfEmptyXmlComponent, OnOffElement, StringValueElement } from "@file/xml-components";
import { Alignment, AlignmentType } from "../../paragraph";
import { IShadingAttributesProperties, Shading } from "../../shading";

View File

@ -1,5 +1,5 @@
import { twipsMeasureValue } from "file/values";
import { XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { XmlAttributeComponent, XmlComponent } from "@file/xml-components";
import { twipsMeasureValue } from "@util/values";
// <xsd:complexType name="CT_Height">
// <xsd:attribute name="val" type="s:ST_TwipsMeasure"/>

View File

@ -1,6 +1,8 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { HeightRule } from "file/table/table-row/table-row-height";
import { Formatter } from "@export/formatter";
import { HeightRule } from "@file/table/table-row/table-row-height";
import { TableRowProperties } from "./table-row-properties";
describe("TableRowProperties", () => {

View File

@ -27,7 +27,7 @@
// </xsd:extension>
// </xsd:complexContent>
// </xsd:complexType>
import { IgnoreIfEmptyXmlComponent, OnOffElement } from "file/xml-components";
import { IgnoreIfEmptyXmlComponent, OnOffElement } from "@file/xml-components";
import { HeightRule, TableRowHeight } from "./table-row-height";

View File

@ -1,10 +1,10 @@
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { Paragraph } from "file/paragraph";
import { HeightRule } from "file/table/table-row/table-row-height";
import { EMPTY_OBJECT } from "file/xml-components";
import { Paragraph } from "@file/paragraph";
import { HeightRule } from "@file/table/table-row/table-row-height";
import { EMPTY_OBJECT } from "@file/xml-components";
import { TableCell } from "../table-cell";
import { TableRow } from "./table-row";

View File

@ -1,4 +1,4 @@
import { XmlComponent } from "file/xml-components";
import { XmlComponent } from "@file/xml-components";
import { TableCell } from "../table-cell";
import { ITableRowPropertiesOptions, TableRowProperties } from "./table-row-properties";

View File

@ -1,6 +1,6 @@
// http://officeopenxml.com/WPtableWidth.php
import { measurementOrPercentValue } from "file/values";
import { XmlAttributeComponent, XmlComponent } from "file/xml-components";
import { XmlAttributeComponent, XmlComponent } from "@file/xml-components";
import { measurementOrPercentValue } from "@util/values";
// <xsd:simpleType name="ST_TblWidth">
// <xsd:restriction base="xsd:string">

View File

@ -1,7 +1,7 @@
/* tslint:disable:no-unused-expression */
import { expect } from "chai";
import { Formatter } from "export/formatter";
import { Formatter } from "@export/formatter";
import { AlignmentType, Paragraph } from "../paragraph";
import { Table } from "./table";

View File

@ -1,5 +1,5 @@
// http://officeopenxml.com/WPtableGrid.php
import { XmlComponent } from "file/xml-components";
import { XmlComponent } from "@file/xml-components";
import { AlignmentType } from "../paragraph";
import { TableGrid } from "./grid";