devexpress-richedit 24.1.1-alpha-24085-0102 → 24.1.2-beta
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bin/gulpfile.js +1 -1
- package/bin/index-custom.js +1 -1
- package/bin/localization-builder.js +1 -1
- package/bin/nspell-index.js +1 -1
- package/bin/nspell.webpack.config.js +1 -1
- package/bin/webpack-externals.js +3 -1
- package/bin/webpack.config.js +1 -1
- package/dist/dx.richedit.css +1 -0
- package/dist/dx.richedit.d.ts +17 -10
- package/dist/dx.richedit.js +52855 -51531
- package/dist/dx.richedit.min.js +2 -2
- package/index.d.ts +1 -1
- package/index.js +1 -1
- package/lib/client/bars/ribbon.js +2 -1
- package/lib/client/bars/rich-edit-ribbon/ribbon-items-data.js +2 -1
- package/lib/client/client-rich-edit.js +2 -1
- package/lib/client/commands/client-command-manager.js +2 -1
- package/lib/client/commands/commands.js +3 -0
- package/lib/client/commands/download-document-command.d.ts +3 -0
- package/lib/client/commands/download-document-command.js +13 -2
- package/lib/client/commands/export-document-command.js +4 -4
- package/lib/client/commands/mail-merge-command.js +7 -4
- package/lib/client/commands/open-document-command.d.ts +2 -1
- package/lib/client/commands/open-document-command.js +17 -12
- package/lib/client/default-localization.js +2 -1
- package/lib/client/dialogs/finish-and-merge-dialog.js +1 -0
- package/lib/client/document-processor/processor.d.ts +9 -2
- package/lib/client/document-processor/processor.js +18 -6
- package/lib/client/formats/docx/export/data.d.ts +4 -0
- package/lib/client/formats/docx/export/data.js +12 -0
- package/lib/client/formats/docx/export/exporter.d.ts +2 -0
- package/lib/client/formats/docx/export/exporter.js +15 -0
- package/lib/client/formats/docx/export/exporters/base/sections.js +5 -0
- package/lib/client/formats/docx/export/exporters/note-properties.d.ts +18 -0
- package/lib/client/formats/docx/export/exporters/note-properties.js +83 -0
- package/lib/client/formats/docx/export/exporters/settings.d.ts +2 -0
- package/lib/client/formats/docx/export/exporters/settings.js +11 -0
- package/lib/client/formats/docx/export/exporters/sub-document/base-sub-document.d.ts +15 -1
- package/lib/client/formats/docx/export/exporters/sub-document/base-sub-document.js +85 -3
- package/lib/client/formats/docx/export/exporters/sub-document/header-footer-sub-document-exporter.d.ts +2 -2
- package/lib/client/formats/docx/export/exporters/sub-document/header-footer-sub-document-exporter.js +2 -2
- package/lib/client/formats/docx/export/exporters/sub-document/main-sub-document.d.ts +2 -2
- package/lib/client/formats/docx/export/exporters/sub-document/main-sub-document.js +2 -2
- package/lib/client/formats/docx/export/exporters/sub-document/note-sub-document-exporter.d.ts +37 -0
- package/lib/client/formats/docx/export/exporters/sub-document/note-sub-document-exporter.js +71 -0
- package/lib/client/formats/docx/export/exporters/sub-document/text-box-content-exporter.d.ts +2 -2
- package/lib/client/formats/docx/export/exporters/sub-document/text-box-content-exporter.js +2 -2
- package/lib/client/formats/docx/import/destination/notes/endnotes/endnote-properties-destination.d.ts +16 -0
- package/lib/client/formats/docx/import/destination/notes/endnotes/endnote-properties-destination.js +48 -0
- package/lib/client/formats/docx/import/destination/notes/endnotes/endnote-reference-destination.d.ts +5 -0
- package/lib/client/formats/docx/import/destination/notes/endnotes/endnote-reference-destination.js +9 -0
- package/lib/client/formats/docx/import/destination/notes/endnotes/endnotes-destination.d.ts +5 -0
- package/lib/client/formats/docx/import/destination/notes/endnotes/endnotes-destination.js +39 -0
- package/lib/client/formats/docx/import/destination/notes/footnotes/footnote-properties-destination.d.ts +18 -0
- package/lib/client/formats/docx/import/destination/notes/footnotes/footnote-properties-destination.js +49 -0
- package/lib/client/formats/docx/import/destination/notes/footnotes/footnote-reference-destination.d.ts +5 -0
- package/lib/client/formats/docx/import/destination/notes/footnotes/footnote-reference-destination.js +9 -0
- package/lib/client/formats/docx/import/destination/notes/footnotes/footnotes-destination.d.ts +5 -0
- package/lib/client/formats/docx/import/destination/notes/footnotes/footnotes-destination.js +39 -0
- package/lib/client/formats/docx/import/destination/notes/note-destination.d.ts +18 -0
- package/lib/client/formats/docx/import/destination/notes/note-destination.js +45 -0
- package/lib/client/formats/docx/import/destination/notes/note-properties-destination.d.ts +32 -0
- package/lib/client/formats/docx/import/destination/notes/note-properties-destination.js +81 -0
- package/lib/client/formats/docx/import/destination/notes/note-reference-destination.d.ts +8 -0
- package/lib/client/formats/docx/import/destination/notes/note-reference-destination.js +21 -0
- package/lib/client/formats/docx/import/destination/notes/note-self-reference-destination.d.ts +5 -0
- package/lib/client/formats/docx/import/destination/notes/note-self-reference-destination.js +12 -0
- package/lib/client/formats/docx/import/destination/notes/note-separator-destination.d.ts +8 -0
- package/lib/client/formats/docx/import/destination/notes/note-separator-destination.js +20 -0
- package/lib/client/formats/docx/import/destination/paragraph-properties/paragraph-numbering-reference-destination.js +1 -1
- package/lib/client/formats/docx/import/destination/runs/run-destination.js +11 -5
- package/lib/client/formats/docx/import/destination/section/section-destination.js +5 -2
- package/lib/client/formats/docx/import/destination/settings/settings.js +4 -0
- package/lib/client/formats/docx/import/importer.d.ts +2 -0
- package/lib/client/formats/docx/import/importer.js +26 -0
- package/lib/client/formats/docx/import/importers/character-importer.d.ts +3 -0
- package/lib/client/formats/docx/import/importers/character-importer.js +12 -1
- package/lib/client/formats/docx/import/importers/end-notes-importer.d.ts +3 -4
- package/lib/client/formats/docx/import/importers/end-notes-importer.js +8 -3
- package/lib/client/formats/docx/import/importers/foot-notes-importer.d.ts +3 -5
- package/lib/client/formats/docx/import/importers/foot-notes-importer.js +8 -5
- package/lib/client/formats/docx/import/importers/notes-importer.d.ts +8 -0
- package/lib/client/formats/docx/import/importers/notes-importer.js +7 -0
- package/lib/client/formats/docx/translation-table/translation-tables.d.ts +7 -0
- package/lib/client/formats/docx/translation-table/translation-tables.js +27 -0
- package/lib/client/formats/docx/utils/constants.d.ts +2 -0
- package/lib/client/formats/docx/utils/constants.js +2 -0
- package/lib/client/model-api/formats/enum.d.ts +1 -0
- package/lib/client/model-api/formats/enum.js +1 -0
- package/lib/client/model-api/formats/exporter.d.ts +3 -4
- package/lib/client/model-api/formats/exporter.js +9 -6
- package/lib/client/model-api/formats/importer.js +2 -0
- package/lib/client/model-api/sub-document.d.ts +6 -2
- package/lib/client/model-api/sub-document.js +37 -35
- package/lib/client/model-api/table/table-borders.d.ts +1 -1
- package/lib/client/public/commands/enum.d.ts +1 -0
- package/lib/client/public/commands/enum.js +1 -0
- package/lib/client/public/document-processor.d.ts +3 -1
- package/lib/client/public/document-processor.js +2 -2
- package/lib/client/public/ribbon/item-ids.d.ts +1 -0
- package/lib/client/public/ribbon/item-ids.js +1 -0
- package/lib/client/public/rich-edit.d.ts +2 -1
- package/lib/client/public/rich-edit.js +16 -9
- package/lib/common/canvas/canvas-manager.js +2 -1
- package/lib/common/canvas/picture-renderer.d.ts +1 -1
- package/lib/common/canvas/renderes/common/document-renderer.d.ts +1 -1
- package/lib/common/canvas/renderes/common/document-renderer.js +6 -2
- package/lib/common/canvas/renderes/view-manager.js +3 -1
- package/lib/common/clipboard-content-inserter.js +2 -1
- package/lib/common/commands/client-command.d.ts +3 -1
- package/lib/common/commands/client-command.js +2 -0
- package/lib/common/commands/document/print-document-on-client-command.js +1 -1
- package/lib/common/commands/text/clipboard-commands.js +7 -5
- package/lib/common/document-format.d.ts +2 -0
- package/lib/common/document-format.js +2 -0
- package/lib/common/formats/document-importer-errors.d.ts +3 -1
- package/lib/common/formats/document-importer-errors.js +2 -0
- package/lib/common/formats/file-name-helper.d.ts +1 -0
- package/lib/common/formats/file-name-helper.js +7 -1
- package/lib/common/formats/html/export/get-html.d.ts +4 -0
- package/lib/common/formats/html/export/get-html.js +12 -0
- package/lib/common/formats/html/export/html-builder.d.ts +16 -0
- package/lib/common/formats/html/export/html-builder.js +98 -0
- package/lib/common/formats/html/export/html-document-exporter.d.ts +13 -0
- package/lib/common/formats/html/export/html-document-exporter.js +29 -0
- package/lib/common/formats/html/export/html-export.d.ts +25 -0
- package/lib/common/{html-export.js → formats/html/export/html-export.js} +115 -192
- package/lib/common/formats/html/import/html-document-importer.d.ts +15 -0
- package/lib/common/formats/html/import/html-document-importer.js +84 -0
- package/lib/common/formats/html/import/html-importer.d.ts +1 -0
- package/lib/common/formats/html/import/html-importer.js +13 -1
- package/lib/common/formats/html/import/insert-html.d.ts +4 -0
- package/lib/common/formats/html/import/insert-html.js +5 -0
- package/lib/common/formats/html/import/utils/paragraph-properties-utils.d.ts +1 -0
- package/lib/common/formats/html/import/utils/paragraph-properties-utils.js +17 -4
- package/lib/common/formats/i-document-exporter.d.ts +14 -0
- package/lib/common/formats/rtf/export/exporter.d.ts +1 -1
- package/lib/common/formats/rtf/export/exporter.js +1 -1
- package/lib/common/formats/rtf/importer-in-subdocument.d.ts +1 -1
- package/lib/common/formats/rtf/importer-in-subdocument.js +1 -1
- package/lib/common/formats/txt/txt-exporter.js +2 -1
- package/lib/common/input-controller.d.ts +2 -1
- package/lib/common/input-controller.js +5 -2
- package/lib/common/interfaces/i-rich-edit-core.d.ts +2 -0
- package/lib/common/layout/main-structures/layout-boxes/layout-anchored-picture-box.d.ts +2 -1
- package/lib/common/layout/main-structures/layout-boxes/layout-anchored-picture-box.js +4 -3
- package/lib/common/layout/main-structures/layout-boxes/layout-picture-box.d.ts +2 -1
- package/lib/common/layout/main-structures/layout-boxes/layout-picture-box.js +5 -4
- package/lib/common/layout/main-structures/layout-page.d.ts +1 -0
- package/lib/common/layout/main-structures/layout-page.js +5 -2
- package/lib/common/layout-formatter/box/generator/box-infos-generator.d.ts +1 -0
- package/lib/common/layout-formatter/box/generator/box-infos-generator.js +12 -2
- package/lib/common/layout-formatter/floating/page-anchored-object-holder.d.ts +5 -3
- package/lib/common/layout-formatter/floating/page-anchored-object-holder.js +7 -4
- package/lib/common/layout-formatter/formatter/base-formatter.js +0 -1
- package/lib/common/layout-formatter/formatter/main-formatter.js +1 -0
- package/lib/common/layout-formatter/managers/formatter-manager.d.ts +6 -2
- package/lib/common/layout-formatter/managers/formatter-manager.js +3 -1
- package/lib/common/layout-formatter/row/size-engine/row-sizes-manager.js +20 -4
- package/lib/common/measurer/measurer.js +2 -1
- package/lib/common/model/chunk.d.ts +1 -0
- package/lib/common/model/chunk.js +27 -2
- package/lib/common/model/document-model.d.ts +4 -0
- package/lib/common/model/document-model.js +4 -1
- package/lib/common/model/enums.d.ts +3 -1
- package/lib/common/model/enums.js +2 -0
- package/lib/common/model/footnotes/footnote.d.ts +46 -0
- package/lib/common/model/footnotes/footnote.js +100 -0
- package/lib/common/model/json/importers/sub-document/json-sub-document-importer.js +3 -3
- package/lib/common/model/json/importers/sub-document/run-importers.d.ts +6 -0
- package/lib/common/model/json/importers/sub-document/run-importers.js +9 -0
- package/lib/common/model/model-checks/position.d.ts +2 -1
- package/lib/common/model/model-checks/position.js +11 -2
- package/lib/common/model/numbering-lists/numbering-helper.d.ts +2 -1
- package/lib/common/model/numbering-lists/numbering-helper.js +3 -0
- package/lib/common/model/paragraph/paragraph-style.d.ts +1 -0
- package/lib/common/model/paragraph/paragraph-style.js +6 -2
- package/lib/common/model/properties-merger/paragraph-properties-merger.js +1 -1
- package/lib/common/model/runs/run-base.d.ts +1 -0
- package/lib/common/model/runs/simple-runs.d.ts +8 -2
- package/lib/common/model/runs/simple-runs.js +12 -6
- package/lib/common/model/section/section-properties.d.ts +3 -0
- package/lib/common/model/special-characters.d.ts +3 -0
- package/lib/common/model/special-characters.js +3 -0
- package/lib/common/model/sub-document-infos.d.ts +18 -0
- package/lib/common/model/sub-document-infos.js +39 -0
- package/lib/common/model/sub-document.d.ts +2 -0
- package/lib/common/model/sub-document.js +18 -16
- package/lib/common/mouse-handler/touch-handler/touch-handler-state-base.d.ts +1 -0
- package/lib/common/mouse-handler/touch-handler/touch-handler-state-base.js +21 -13
- package/lib/common/processor.d.ts +2 -0
- package/lib/common/rich-edit-core.d.ts +6 -2
- package/lib/common/rich-edit-core.js +20 -1
- package/lib/common/selection/selection-intervals-info.js +1 -1
- package/lib/common/utils/_license.d.ts +1 -0
- package/lib/common/utils/_license.js +2 -0
- package/lib/common/utils/size-utils.d.ts +3 -0
- package/lib/common/utils/size-utils.js +17 -4
- package/package.json +3 -3
- package/lib/common/html-export.d.ts +0 -32
@@ -0,0 +1,39 @@
|
|
1
|
+
import { MapCreator } from "../../../../../../../common/utils/map-creator";
|
2
|
+
import { ElementDestination } from "../../destination";
|
3
|
+
import { SubDocumentInfoType } from "../../../../../../../common/model/enums";
|
4
|
+
import { NoteType } from "../../../../../../../common/model/footnotes/footnote";
|
5
|
+
import { StringUtils } from "@devexpress/utils/lib/utils/string";
|
6
|
+
import { NoteDestination } from "../note-destination";
|
7
|
+
export class FootNotesDestination extends ElementDestination {
|
8
|
+
get elementHandlerTable() {
|
9
|
+
return FootNotesDestination.handlerTable;
|
10
|
+
}
|
11
|
+
}
|
12
|
+
FootNotesDestination.handlerTable = new MapCreator()
|
13
|
+
.add('footnote', (data) => new FootNoteDestination(data))
|
14
|
+
.get();
|
15
|
+
class FootNoteDestination extends NoteDestination {
|
16
|
+
get SubDocumentType() {
|
17
|
+
return SubDocumentInfoType.FootNote;
|
18
|
+
}
|
19
|
+
addNote(id, subDocId, type) {
|
20
|
+
if (!this.canAddFootNote(id, type))
|
21
|
+
return false;
|
22
|
+
if (type == NoteType.Normal)
|
23
|
+
this.data.footNotesImporter.notes[id] = subDocId;
|
24
|
+
else
|
25
|
+
this.documentModel.footNoteSeparators.setSeparator(subDocId, type);
|
26
|
+
return true;
|
27
|
+
}
|
28
|
+
canAddFootNote(id, type) {
|
29
|
+
if (StringUtils.isNullOrEmpty(id))
|
30
|
+
return false;
|
31
|
+
if (type == NoteType.Normal)
|
32
|
+
return !(id in this.data.footNotesImporter.notes);
|
33
|
+
else {
|
34
|
+
if (this.documentModel.footNoteSeparators.getSeparator(type))
|
35
|
+
return false;
|
36
|
+
return this.data.footNotesImporter.separatorIds.includes(id);
|
37
|
+
}
|
38
|
+
}
|
39
|
+
}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
import { SubDocumentInfoType } from "../../../../../../common/model/enums";
|
2
|
+
import { NoteType } from "../../../../../../common/model/footnotes/footnote";
|
3
|
+
import { XmlReader } from "../../../zip/xml-reader";
|
4
|
+
import { ElementHandlerTable } from "../destination";
|
5
|
+
import { BodyDestinationBase } from "../document/body-destination-base";
|
6
|
+
export declare type NoteSubDocumentType = SubDocumentInfoType.FootNote | SubDocumentInfoType.EndNote;
|
7
|
+
export declare abstract class NoteDestination extends BodyDestinationBase {
|
8
|
+
static handlerTable: ElementHandlerTable;
|
9
|
+
protected get elementHandlerTable(): ElementHandlerTable;
|
10
|
+
private id;
|
11
|
+
private subDocId;
|
12
|
+
private type;
|
13
|
+
protected abstract get SubDocumentType(): NoteSubDocumentType;
|
14
|
+
processElementOpen(reader: XmlReader): Promise<void>;
|
15
|
+
processElementClose(_reader: XmlReader): Promise<void>;
|
16
|
+
private createSubDocument;
|
17
|
+
protected abstract addNote(id: string, subDocId: number, type: NoteType): boolean;
|
18
|
+
}
|
@@ -0,0 +1,45 @@
|
|
1
|
+
import { __awaiter } from "tslib";
|
2
|
+
import { NoteType } from "../../../../../../common/model/footnotes/footnote";
|
3
|
+
import { SubDocument } from "../../../../../../common/model/sub-document";
|
4
|
+
import { MapCreator } from "../../../../../../common/utils/map-creator";
|
5
|
+
import { TranslationTables } from "../../../translation-table/translation-tables";
|
6
|
+
import { BodyDestinationBase } from "../document/body-destination-base";
|
7
|
+
import { ParagraphDestination } from "../paragraph/paragraph-destination";
|
8
|
+
import { HeaderFooterDestination } from "../section/header-footer/header-footer-destination";
|
9
|
+
import { TableDestination } from "../table/table/table-destination";
|
10
|
+
export class NoteDestination extends BodyDestinationBase {
|
11
|
+
get elementHandlerTable() {
|
12
|
+
return HeaderFooterDestination.handlerTable;
|
13
|
+
}
|
14
|
+
processElementOpen(reader) {
|
15
|
+
return __awaiter(this, void 0, void 0, function* () {
|
16
|
+
this.type = this.data.readerHelper.getWpEnumValue(reader, "type", TranslationTables.noteTypeTable.importMap, NoteType.Normal);
|
17
|
+
const note = this.createSubDocument(this.SubDocumentType);
|
18
|
+
note.info.noteType = this.type;
|
19
|
+
this.data.pushCurrentSubDocument(note);
|
20
|
+
this.id = reader.getAttributeNS("id", this.data.constants.wordProcessingNamespaceConst);
|
21
|
+
});
|
22
|
+
}
|
23
|
+
processElementClose(_reader) {
|
24
|
+
return __awaiter(this, void 0, void 0, function* () {
|
25
|
+
this.data.fixLastParagraph();
|
26
|
+
const subDoc = this.data.popCurrentSubDocument();
|
27
|
+
this.subDocId = subDoc.id;
|
28
|
+
if (!this.addNote(this.id, this.subDocId, this.type))
|
29
|
+
this.data.documentModel.subDocumentsCollection.delete(this.subDocId);
|
30
|
+
});
|
31
|
+
}
|
32
|
+
createSubDocument(type) {
|
33
|
+
return this.documentModel.createSubDocument(type, SubDocument.MAIN_SUBDOCUMENT_ID, true);
|
34
|
+
}
|
35
|
+
}
|
36
|
+
NoteDestination.handlerTable = new MapCreator()
|
37
|
+
.add('p', (data) => new ParagraphDestination(data))
|
38
|
+
.add('tbl', (data) => new TableDestination(data))
|
39
|
+
.add('bookmarkStart', BodyDestinationBase.onBookmarkStart)
|
40
|
+
.add('bookmarkEnd', BodyDestinationBase.onBookmarkEnd)
|
41
|
+
.add('permStart', BodyDestinationBase.onRangePermissionStart)
|
42
|
+
.add('permEnd', BodyDestinationBase.onRangePermissionEnd)
|
43
|
+
.add('sdt', BodyDestinationBase.onStructuredDocument)
|
44
|
+
.add('customXml', BodyDestinationBase.onCustomXml)
|
45
|
+
.get();
|
@@ -0,0 +1,32 @@
|
|
1
|
+
import { NoteProperties, NotePosition } from "../../../../../../common/model/footnotes/footnote";
|
2
|
+
import { NumberingFormat } from "../../../../../../common/model/numbering-lists/list-level-properties";
|
3
|
+
import { XmlReader } from "../../../zip/xml-reader";
|
4
|
+
import { Data } from "../../data";
|
5
|
+
import { LeafElementDestination, ElementDestination, ElementHandlerTable } from "../destination";
|
6
|
+
export declare abstract class NotePropertiesLeafElementDestination extends LeafElementDestination {
|
7
|
+
readonly footNote: NoteProperties;
|
8
|
+
constructor(data: Data, footNote: NoteProperties);
|
9
|
+
}
|
10
|
+
export declare abstract class NotePropertiesDestination extends ElementDestination {
|
11
|
+
static handlerTable: ElementHandlerTable;
|
12
|
+
static getThis(data: Data): NotePropertiesDestination;
|
13
|
+
readonly notes: NoteProperties;
|
14
|
+
private readonly defaultPosition;
|
15
|
+
private readonly defaultFormat;
|
16
|
+
constructor(data: Data, defaultPosition: NotePosition, defaultFormat: NumberingFormat);
|
17
|
+
protected get elementHandlerTable(): ElementHandlerTable;
|
18
|
+
processElementClose(_reader: XmlReader): Promise<void>;
|
19
|
+
protected createPlacementDestination(data: Data): ElementDestination;
|
20
|
+
protected createNumberingFormatDestination(data: Data): ElementDestination;
|
21
|
+
protected abstract setProperties(notes: NoteProperties): void;
|
22
|
+
}
|
23
|
+
export declare class NotePlacementDestination extends NotePropertiesLeafElementDestination {
|
24
|
+
readonly defaultPosition: NotePosition;
|
25
|
+
constructor(data: Data, footNote: NoteProperties, defaultPosition: NotePosition);
|
26
|
+
processElementOpen(reader: XmlReader): Promise<void>;
|
27
|
+
}
|
28
|
+
export declare class NoteNumberingFormatDestination extends NotePropertiesLeafElementDestination {
|
29
|
+
readonly defaultNumberingFormat: NumberingFormat;
|
30
|
+
constructor(data: Data, footNote: NoteProperties, defaultNumberingFormat: NumberingFormat);
|
31
|
+
processElementOpen(reader: XmlReader): Promise<void>;
|
32
|
+
}
|
@@ -0,0 +1,81 @@
|
|
1
|
+
var _a;
|
2
|
+
import { __awaiter } from "tslib";
|
3
|
+
import { NoteProperties, NoteNumberingRestartType } from "../../../../../../common/model/footnotes/footnote";
|
4
|
+
import { MapCreator } from "../../../../../../common/utils/map-creator";
|
5
|
+
import { TranslationTables } from "../../../translation-table/translation-tables";
|
6
|
+
import { LeafElementDestination, ElementDestination } from "../destination";
|
7
|
+
export class NotePropertiesLeafElementDestination extends LeafElementDestination {
|
8
|
+
constructor(data, footNote) {
|
9
|
+
super(data);
|
10
|
+
this.footNote = footNote;
|
11
|
+
}
|
12
|
+
}
|
13
|
+
class NoteNumberingStartDestination extends NotePropertiesLeafElementDestination {
|
14
|
+
processElementOpen(reader) {
|
15
|
+
return __awaiter(this, void 0, void 0, function* () {
|
16
|
+
this.footNote.startingNumber = this.data.readerHelper.getWpSTIntegerValue(reader, "val", 1);
|
17
|
+
});
|
18
|
+
}
|
19
|
+
}
|
20
|
+
class NoteNumberingRestartTypeDestination extends NotePropertiesLeafElementDestination {
|
21
|
+
processElementOpen(reader) {
|
22
|
+
return __awaiter(this, void 0, void 0, function* () {
|
23
|
+
this.footNote.numberingRestartType = this.data.readerHelper.getWpEnumValue(reader, "val", TranslationTables.noteNumberingRestartTypeTable.importMap, NoteNumberingRestartType.Continuous);
|
24
|
+
});
|
25
|
+
}
|
26
|
+
}
|
27
|
+
export class NotePropertiesDestination extends ElementDestination {
|
28
|
+
constructor(data, defaultPosition, defaultFormat) {
|
29
|
+
super(data);
|
30
|
+
this.notes = NoteProperties.createDefault();
|
31
|
+
this.defaultPosition = defaultPosition;
|
32
|
+
this.defaultFormat = defaultFormat;
|
33
|
+
}
|
34
|
+
static getThis(data) {
|
35
|
+
return data.destinationStack.getThis();
|
36
|
+
}
|
37
|
+
get elementHandlerTable() {
|
38
|
+
return NotePropertiesDestination.handlerTable;
|
39
|
+
}
|
40
|
+
processElementClose(_reader) {
|
41
|
+
return __awaiter(this, void 0, void 0, function* () {
|
42
|
+
this.setProperties(this.notes);
|
43
|
+
});
|
44
|
+
}
|
45
|
+
createPlacementDestination(data) {
|
46
|
+
return new NotePlacementDestination(data, this.notes, this.defaultPosition);
|
47
|
+
}
|
48
|
+
createNumberingFormatDestination(data) {
|
49
|
+
return new NoteNumberingFormatDestination(data, this.notes, this.defaultFormat);
|
50
|
+
}
|
51
|
+
}
|
52
|
+
_a = NotePropertiesDestination;
|
53
|
+
NotePropertiesDestination.handlerTable = new MapCreator()
|
54
|
+
.add('pos', (data) => _a.getThis(data).createPlacementDestination(data))
|
55
|
+
.add('numFmt', (data) => _a.getThis(data).createNumberingFormatDestination(data))
|
56
|
+
.add('numStart', (data) => new NoteNumberingStartDestination(data, _a.getThis(data).notes))
|
57
|
+
.add('numRestart', (data) => new NoteNumberingRestartTypeDestination(data, _a.getThis(data).notes))
|
58
|
+
.get();
|
59
|
+
export class NotePlacementDestination extends NotePropertiesLeafElementDestination {
|
60
|
+
constructor(data, footNote, defaultPosition) {
|
61
|
+
super(data, footNote);
|
62
|
+
this.defaultPosition = defaultPosition;
|
63
|
+
}
|
64
|
+
processElementOpen(reader) {
|
65
|
+
return __awaiter(this, void 0, void 0, function* () {
|
66
|
+
const footNotePosition = this.data.readerHelper.getWpEnumValue(reader, "val", TranslationTables.footNotePlacementTable.importMap, this.defaultPosition);
|
67
|
+
this.footNote.position = footNotePosition;
|
68
|
+
});
|
69
|
+
}
|
70
|
+
}
|
71
|
+
export class NoteNumberingFormatDestination extends NotePropertiesLeafElementDestination {
|
72
|
+
constructor(data, footNote, defaultNumberingFormat) {
|
73
|
+
super(data, footNote);
|
74
|
+
this.defaultNumberingFormat = defaultNumberingFormat;
|
75
|
+
}
|
76
|
+
processElementOpen(reader) {
|
77
|
+
return __awaiter(this, void 0, void 0, function* () {
|
78
|
+
this.footNote.numberingFormat = this.data.readerHelper.getWpEnumValue(reader, "val", TranslationTables.pageNumberingFormatTable.importMap, this.defaultNumberingFormat);
|
79
|
+
});
|
80
|
+
}
|
81
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import { XmlReader } from "../../../zip/xml-reader";
|
2
|
+
import { LeafElementDestination } from "../destination";
|
3
|
+
export declare abstract class NoteReferenceDestination extends LeafElementDestination {
|
4
|
+
protected abstract get notes(): Record<string, number>;
|
5
|
+
protected abstract insertNoteRun(subDocId: number): void;
|
6
|
+
protected processCustomNoteRun(subDocId: number): void;
|
7
|
+
processElementOpen(reader: XmlReader): Promise<void>;
|
8
|
+
}
|
@@ -0,0 +1,21 @@
|
|
1
|
+
import { __awaiter } from "tslib";
|
2
|
+
import { isDefined } from "@devexpress/utils/lib/utils/common";
|
3
|
+
import { LeafElementDestination } from "../destination";
|
4
|
+
export class NoteReferenceDestination extends LeafElementDestination {
|
5
|
+
processCustomNoteRun(subDocId) {
|
6
|
+
this.data.subDocumentInfo.characterImporter.noteDocumentId = subDocId;
|
7
|
+
}
|
8
|
+
processElementOpen(reader) {
|
9
|
+
return __awaiter(this, void 0, void 0, function* () {
|
10
|
+
const id = reader.getAttributeNS("id", this.data.constants.wordProcessingNamespaceConst);
|
11
|
+
let subDocId = this.notes[id];
|
12
|
+
if (!isDefined(subDocId))
|
13
|
+
return;
|
14
|
+
const customMarkFollows = this.data.readerHelper.getWpSTOnOffValue(reader, "customMarkFollows", false);
|
15
|
+
if (customMarkFollows)
|
16
|
+
this.processCustomNoteRun(subDocId);
|
17
|
+
else
|
18
|
+
this.insertNoteRun(subDocId);
|
19
|
+
});
|
20
|
+
}
|
21
|
+
}
|
@@ -0,0 +1,12 @@
|
|
1
|
+
import { __awaiter } from "tslib";
|
2
|
+
import { LeafElementDestination } from "../destination";
|
3
|
+
export class NoteSelfReferenceDestination extends LeafElementDestination {
|
4
|
+
processElementOpen(_reader) {
|
5
|
+
return __awaiter(this, void 0, void 0, function* () {
|
6
|
+
if (this.data.subDocument.isFootNote())
|
7
|
+
this.data.footNotesImporter.insertRun();
|
8
|
+
else
|
9
|
+
this.data.endNotesImporter.insertRun();
|
10
|
+
});
|
11
|
+
}
|
12
|
+
}
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import { XmlReader } from "../../../zip/xml-reader";
|
2
|
+
import { LeafElementDestination } from "../destination";
|
3
|
+
export declare class NoteSeparatorDestination extends LeafElementDestination {
|
4
|
+
processElementOpen(_reader: XmlReader): Promise<void>;
|
5
|
+
}
|
6
|
+
export declare class NoteContinuationSeparatorDestination extends LeafElementDestination {
|
7
|
+
processElementOpen(_reader: XmlReader): Promise<void>;
|
8
|
+
}
|
@@ -0,0 +1,20 @@
|
|
1
|
+
import { __awaiter } from "tslib";
|
2
|
+
import { NoteContinuationSeparatorRun, NoteSeparatorRun } from "../../../../../../common/model/runs/simple-runs";
|
3
|
+
import { LeafElementDestination } from "../destination";
|
4
|
+
import { RichUtils } from "../../../../../../common/model/rich-utils";
|
5
|
+
export class NoteSeparatorDestination extends LeafElementDestination {
|
6
|
+
processElementOpen(_reader) {
|
7
|
+
return __awaiter(this, void 0, void 0, function* () {
|
8
|
+
const run = new NoteSeparatorRun(this.data.subDocumentInfo.positionImporter.currPosition, this.data.subDocumentInfo.paragraphImporter.paragraph, this.data.subDocumentInfo.characterImporter.charPropsBundle);
|
9
|
+
this.data.subDocumentInfo.characterImporter.addRun(run, RichUtils.specialCharacters.ETX);
|
10
|
+
});
|
11
|
+
}
|
12
|
+
}
|
13
|
+
export class NoteContinuationSeparatorDestination extends LeafElementDestination {
|
14
|
+
processElementOpen(_reader) {
|
15
|
+
return __awaiter(this, void 0, void 0, function* () {
|
16
|
+
const run = new NoteContinuationSeparatorRun(this.data.subDocumentInfo.positionImporter.currPosition, this.data.subDocumentInfo.paragraphImporter.paragraph, this.data.subDocumentInfo.characterImporter.charPropsBundle);
|
17
|
+
this.data.subDocumentInfo.characterImporter.addRun(run, RichUtils.specialCharacters.EOT);
|
18
|
+
});
|
19
|
+
}
|
20
|
+
}
|
@@ -6,7 +6,7 @@ export class ParagraphNumberingReferenceDestination extends ElementDestination {
|
|
6
6
|
constructor(data, paragraphPropertiesDestination) {
|
7
7
|
super(data);
|
8
8
|
this.paragraphPropertiesDestination = paragraphPropertiesDestination;
|
9
|
-
this.paragraphPropertiesDestination.listLevelIndex =
|
9
|
+
this.paragraphPropertiesDestination.listLevelIndex = -1;
|
10
10
|
}
|
11
11
|
get listLevelIndex() { return this.paragraphPropertiesDestination.listLevelIndex; }
|
12
12
|
set listLevelIndex(value) { this.paragraphPropertiesDestination.listLevelIndex = value; }
|
@@ -17,15 +17,17 @@ import { RunTabDestination } from './run-tab-destination';
|
|
17
17
|
import { SeparatorDestination } from './separator-destination';
|
18
18
|
import { SymbolDestination } from './symbol-destination';
|
19
19
|
import { TextDestination } from './text-destination';
|
20
|
+
import { FootNoteReferenceDestination } from '../notes/footnotes/footnote-reference-destination';
|
21
|
+
import { NoteSelfReferenceDestination } from '../notes/note-self-reference-destination';
|
22
|
+
import { EndNoteReferenceDestination } from '../notes/endnotes/endnote-reference-destination';
|
23
|
+
import { NoteContinuationSeparatorDestination, NoteSeparatorDestination } from '../notes/note-separator-destination';
|
20
24
|
export class RunDestination extends ElementDestination {
|
21
25
|
constructor(data) {
|
22
26
|
super(data);
|
23
27
|
this.resetProperties();
|
24
28
|
}
|
25
29
|
resetProperties() {
|
26
|
-
this.data.subDocumentInfo.characterImporter
|
27
|
-
.resetProperties()
|
28
|
-
.resetStyle();
|
30
|
+
this.data.subDocumentInfo.characterImporter.reset();
|
29
31
|
}
|
30
32
|
get elementHandlerTable() {
|
31
33
|
return RunDestination.handlerTable;
|
@@ -55,8 +57,12 @@ RunDestination.handlerTable = new MapCreator()
|
|
55
57
|
.add('object', (data) => new InlineObjectDestination(data))
|
56
58
|
.add('fldChar', (data) => new FieldCharDestination(data))
|
57
59
|
.add('drawing', (data) => new DrawingDestination(data))
|
58
|
-
.add(
|
59
|
-
.add(
|
60
|
+
.add("footnoteReference", (data) => new FootNoteReferenceDestination(data))
|
61
|
+
.add("endnoteReference", (data) => new EndNoteReferenceDestination(data))
|
62
|
+
.add('footnoteRef', (data) => new NoteSelfReferenceDestination(data))
|
63
|
+
.add('endnoteRef', (data) => new NoteSelfReferenceDestination(data))
|
64
|
+
.add('separator', (data) => new NoteSeparatorDestination(data))
|
65
|
+
.add('continuationSeparator', (data) => new NoteContinuationSeparatorDestination(data))
|
60
66
|
.add('commentReference', (_data) => null)
|
61
67
|
.add('spr', (data) => new SeparatorDestination(data))
|
62
68
|
.add('customObject', (data) => new CustomRunDestination(data))
|
@@ -8,6 +8,8 @@ import { SectionPageNumberingDestination } from './section-page-numbering-destin
|
|
8
8
|
import { SectionPageSizeDestination } from './section-page-size-destination';
|
9
9
|
import { SectionStartTypeDestination } from './section-start-type-destination';
|
10
10
|
import { SectionLineNumberingDestination } from './section-line-numbering-destination';
|
11
|
+
import { SectionFootNoteColumnsCountDestination, SectionLevelFootNotePropertiesDestination } from '../notes/footnotes/footnote-properties-destination';
|
12
|
+
import { SectionLevelEndNotePropertiesDestination } from '../notes/endnotes/endnote-properties-destination';
|
11
13
|
export class SectionDestination extends ElementDestination {
|
12
14
|
get elementHandlerTable() {
|
13
15
|
return SectionDestination.handlerTable;
|
@@ -28,6 +30,7 @@ SectionDestination.handlerTable = new MapCreator()
|
|
28
30
|
.add('headerReference', (data) => new HeaderReferenceDestination(data))
|
29
31
|
.add('footerReference', (data) => new FooterReferenceDestination(data))
|
30
32
|
.add('titlePg', (data) => new SectionDifferentFirstPageDestination(data))
|
31
|
-
.add('footnotePr', (
|
32
|
-
.add('endnotePr', (
|
33
|
+
.add('footnotePr', (data) => new SectionLevelFootNotePropertiesDestination(data))
|
34
|
+
.add('endnotePr', (data) => new SectionLevelEndNotePropertiesDestination(data))
|
35
|
+
.add('footnoteColumns', (data) => new SectionFootNoteColumnsCountDestination(data))
|
33
36
|
.get();
|
@@ -6,6 +6,8 @@ import { DocumentSettingsDifferentOddAndEvenPagesDestination } from './different
|
|
6
6
|
import { DocumentProtectionDestination } from './document-protection';
|
7
7
|
import { DocumentSettingsDocVarsDestination } from './document-variables-destination';
|
8
8
|
import { DocumentSettingsMirrorMarginsDestination } from './mirror-margins-destination';
|
9
|
+
import { DocumentLevelFootNotePropertiesDestination } from '../notes/footnotes/footnote-properties-destination';
|
10
|
+
import { DocumentLevelEndNotePropertiesDestination } from '../notes/endnotes/endnote-properties-destination';
|
9
11
|
export class DocumentSettingsDestination extends ElementDestination {
|
10
12
|
get elementHandlerTable() {
|
11
13
|
return DocumentSettingsDestination.handlerTable;
|
@@ -18,4 +20,6 @@ DocumentSettingsDestination.handlerTable = new MapCreator()
|
|
18
20
|
.add('compat', (data) => new DocumentSettingsCompatDestination(data))
|
19
21
|
.add('docVars', (data) => new DocumentSettingsDocVarsDestination(data))
|
20
22
|
.add('mirrorMargins', (data) => new DocumentSettingsMirrorMarginsDestination(data))
|
23
|
+
.add('footnotePr', (data) => new DocumentLevelFootNotePropertiesDestination(data))
|
24
|
+
.add('endnotePr', (data) => new DocumentLevelEndNotePropertiesDestination(data))
|
21
25
|
.get();
|
@@ -13,6 +13,8 @@ export declare class Importer implements IDocumentImporter {
|
|
13
13
|
private importRootRelations;
|
14
14
|
private importMainSubDocument;
|
15
15
|
private importStyles;
|
16
|
+
private importFootNotes;
|
17
|
+
private importEndNotes;
|
16
18
|
private importThemes;
|
17
19
|
private importNumbering;
|
18
20
|
private importSettings;
|
@@ -16,6 +16,8 @@ import { NumberingsDestination } from './destination/numbering/numberings-destin
|
|
16
16
|
import { DocumentSettingsDestination } from './destination/settings/settings';
|
17
17
|
import { StylesDestination } from './destination/style/styles-destination';
|
18
18
|
import { OfficeThemeDestination } from './destination/themes/office-theme-destination';
|
19
|
+
import { FootNotesDestination } from './destination/notes/footnotes/footnotes-destination';
|
20
|
+
import { EndNotesDestination } from './destination/notes/endnotes/endnotes-destination';
|
19
21
|
export class Importer {
|
20
22
|
constructor(options) {
|
21
23
|
this.asyncImportFromFile = true;
|
@@ -64,6 +66,8 @@ export class Importer {
|
|
64
66
|
yield this.importThemes();
|
65
67
|
yield this.importNumbering();
|
66
68
|
yield this.importStyles();
|
69
|
+
yield this.importFootNotes();
|
70
|
+
yield this.importEndNotes();
|
67
71
|
this.linkNumberingListStyles();
|
68
72
|
const documentReader = yield this.data.archiveData.getXmlReader(documentFileName);
|
69
73
|
if (documentReader.readToFollowingNS('document', this.data.constants.wordProcessingNamespaceConst)) {
|
@@ -92,6 +96,28 @@ export class Importer {
|
|
92
96
|
}
|
93
97
|
});
|
94
98
|
}
|
99
|
+
importFootNotes() {
|
100
|
+
return __awaiter(this, void 0, void 0, function* () {
|
101
|
+
const footNotesFileName = 'footnotes.xml';
|
102
|
+
const footNotesFilePath = this.data.relationsStack.last.lookupRelationTargetByType(this.data.constants.rels.officeFootNoteType, this.data.documentRootFolder, footNotesFileName);
|
103
|
+
yield this.data.addRelations(`${this.data.documentRootFolder}/_rels/${footNotesFileName}.rels`);
|
104
|
+
const footNotesReader = yield this.data.archiveData.getXmlReader(footNotesFilePath);
|
105
|
+
if (footNotesReader && footNotesReader.readToFollowingNS('footnotes', this.data.constants.wordProcessingNamespaceConst))
|
106
|
+
yield this.data.importContent(footNotesReader, new FootNotesDestination(this.data));
|
107
|
+
this.data.relationsStack.pop();
|
108
|
+
});
|
109
|
+
}
|
110
|
+
importEndNotes() {
|
111
|
+
return __awaiter(this, void 0, void 0, function* () {
|
112
|
+
const endNotesFileName = 'endnotes.xml';
|
113
|
+
const endNotesFilePath = this.data.relationsStack.last.lookupRelationTargetByType(this.data.constants.rels.officeEndNoteType, this.data.documentRootFolder, endNotesFileName);
|
114
|
+
yield this.data.addRelations(`${this.data.documentRootFolder}/_rels/${endNotesFileName}.rels`);
|
115
|
+
const endNotesReader = yield this.data.archiveData.getXmlReader(endNotesFilePath);
|
116
|
+
if (endNotesReader && endNotesReader.readToFollowingNS('endnotes', this.data.constants.wordProcessingNamespaceConst))
|
117
|
+
yield this.data.importContent(endNotesReader, new EndNotesDestination(this.data));
|
118
|
+
this.data.relationsStack.pop();
|
119
|
+
});
|
120
|
+
}
|
95
121
|
importThemes() {
|
96
122
|
return __awaiter(this, void 0, void 0, function* () {
|
97
123
|
const themeFileName = this.data.relationsStack.last.lookupRelationTargetByType(this.data.constants.rels.officeThemesType, this.data.documentRootFolder, 'theme/theme1.xml');
|
@@ -5,6 +5,7 @@ import { MaskedCharacterPropertiesBundle } from '../../../../../common/rich-util
|
|
5
5
|
import { Data } from '../data';
|
6
6
|
export declare class CharacterImporter {
|
7
7
|
data: Data;
|
8
|
+
noteDocumentId: number;
|
8
9
|
_style: CharacterStyle;
|
9
10
|
get style(): CharacterStyle;
|
10
11
|
set style(value: CharacterStyle);
|
@@ -13,6 +14,8 @@ export declare class CharacterImporter {
|
|
13
14
|
constructor(data: Data);
|
14
15
|
resetProperties(): this;
|
15
16
|
resetStyle(): this;
|
17
|
+
resetNoteDocumentId(): this;
|
18
|
+
reset(): void;
|
16
19
|
insertText(text: string): void;
|
17
20
|
addRun(run: RunBase, text: string): void;
|
18
21
|
addRunAtPos(run: RunBase, text: string, pos: number): void;
|
@@ -29,9 +29,20 @@ export class CharacterImporter {
|
|
29
29
|
this._style = this.data.stylesImporter.characterManager.defaultStyle;
|
30
30
|
return this;
|
31
31
|
}
|
32
|
+
resetNoteDocumentId() {
|
33
|
+
delete this.noteDocumentId;
|
34
|
+
return this;
|
35
|
+
}
|
36
|
+
reset() {
|
37
|
+
this.resetProperties()
|
38
|
+
.resetStyle()
|
39
|
+
.resetNoteDocumentId();
|
40
|
+
}
|
32
41
|
insertText(text) {
|
33
42
|
const length = text.length;
|
34
|
-
|
43
|
+
const run = new TextRun(this.data.subDocumentInfo.positionImporter.currPosition, length, this.data.subDocumentInfo.paragraphImporter.paragraph, this.charPropsBundle);
|
44
|
+
run.noteDocumentId = this.noteDocumentId;
|
45
|
+
this.addRun(run, text);
|
35
46
|
}
|
36
47
|
addRun(run, text) {
|
37
48
|
const chunk = ListUtils.last(this.data.subDocument.chunks);
|
@@ -1,5 +1,4 @@
|
|
1
|
-
import {
|
2
|
-
export declare class EndNotesImporter {
|
3
|
-
|
4
|
-
constructor(data: Data);
|
1
|
+
import { NotesImporter } from './notes-importer';
|
2
|
+
export declare class EndNotesImporter extends NotesImporter {
|
3
|
+
insertRun(subDocId?: number): void;
|
5
4
|
}
|
@@ -1,5 +1,10 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
1
|
+
import { EndNoteRun } from '../../../../../common/model/runs/simple-runs';
|
2
|
+
import { RichUtils } from '../../../../../common/model/rich-utils';
|
3
|
+
import { NotesImporter } from './notes-importer';
|
4
|
+
export class EndNotesImporter extends NotesImporter {
|
5
|
+
insertRun(subDocId) {
|
6
|
+
const pos = this.data.subDocumentInfo.positionImporter.currPosition;
|
7
|
+
const run = new EndNoteRun(pos, this.data.subDocumentInfo.paragraphImporter.paragraph, this.data.subDocumentInfo.characterImporter.charPropsBundle, subDocId);
|
8
|
+
this.data.subDocumentInfo.characterImporter.addRun(run, RichUtils.specialCharacters.LayoutDependentText);
|
4
9
|
}
|
5
10
|
}
|
@@ -1,6 +1,4 @@
|
|
1
|
-
import {
|
2
|
-
export declare class FootNotesImporter {
|
3
|
-
|
4
|
-
constructor(data: Data);
|
5
|
-
import(): void;
|
1
|
+
import { NotesImporter } from './notes-importer';
|
2
|
+
export declare class FootNotesImporter extends NotesImporter {
|
3
|
+
insertRun(subDocId?: number): void;
|
6
4
|
}
|
@@ -1,7 +1,10 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
1
|
+
import { FootNoteRun } from '../../../../../common/model/runs/simple-runs';
|
2
|
+
import { RichUtils } from '../../../../../common/model/rich-utils';
|
3
|
+
import { NotesImporter } from './notes-importer';
|
4
|
+
export class FootNotesImporter extends NotesImporter {
|
5
|
+
insertRun(subDocId) {
|
6
|
+
const pos = this.data.subDocumentInfo.positionImporter.currPosition;
|
7
|
+
const run = new FootNoteRun(pos, this.data.subDocumentInfo.paragraphImporter.paragraph, this.data.subDocumentInfo.characterImporter.charPropsBundle, subDocId);
|
8
|
+
this.data.subDocumentInfo.characterImporter.addRun(run, RichUtils.specialCharacters.LayoutDependentText);
|
6
9
|
}
|
7
10
|
}
|
@@ -13,6 +13,7 @@ import { ConditionalTableStyleFormatting, HorizontalAlignMode, HorizontalAnchorT
|
|
13
13
|
import { TableHeightUnitType, TableWidthUnitType } from '../../../../common/model/tables/secondary-structures/table-units';
|
14
14
|
import { SchemeColorValues, SystemColorValues } from '../../../../common/model/themes/enums';
|
15
15
|
import { TranslationTablesData } from './translation-tables-data';
|
16
|
+
import { NoteNumberingRestartType, NotePosition, NoteType } from '../../../../common/model/footnotes/footnote';
|
16
17
|
export declare abstract class TranslationTables {
|
17
18
|
static readonly sectionStartTypeTable: TranslationTablesData<SectionStartType>;
|
18
19
|
static readonly lineNumberingRestartTable: TranslationTablesData<LineNumberingRestartType>;
|
@@ -64,6 +65,9 @@ export declare abstract class TranslationTables {
|
|
64
65
|
static readonly listNumberAlignmentTable: TranslationTablesData<ListNumberAlignment>;
|
65
66
|
static readonly schemeColorTable: TranslationTablesData<SchemeColorValues>;
|
66
67
|
static readonly systemColorTable: TranslationTablesData<SystemColorValues>;
|
68
|
+
static readonly noteNumberingRestartTypeTable: TranslationTablesData<NoteNumberingRestartType>;
|
69
|
+
static readonly footNotePlacementTable: TranslationTablesData<NotePosition>;
|
70
|
+
static readonly noteTypeTable: TranslationTablesData<NoteType>;
|
67
71
|
static horizontalPositionTypeAttributeTable: TranslationTablesData<AnchorObjectHorizontalPositionType>;
|
68
72
|
static verticalPositionTypeAttributeTable: TranslationTablesData<AnchorObjectVerticalPositionType>;
|
69
73
|
static createHorizontalPositionTypeAttributeTable(): TranslationTablesData<AnchorObjectHorizontalPositionType>;
|
@@ -118,4 +122,7 @@ export declare abstract class TranslationTables {
|
|
118
122
|
private static createFloatingObjectCssRelativeFromVerticalTable;
|
119
123
|
private static createThemeColorIndexTable;
|
120
124
|
private static createTextDirectionTable;
|
125
|
+
private static createNoteNumberingRestartTypeTable;
|
126
|
+
private static createFootNotePlacementTable;
|
127
|
+
private static createNoteTypeTable;
|
121
128
|
}
|
@@ -21,6 +21,7 @@ import { NumberMapUtils } from '@devexpress/utils/lib/utils/map/number';
|
|
21
21
|
import { MLTableData } from './ml-table-data';
|
22
22
|
import { TranslationTablesData } from './translation-tables-data';
|
23
23
|
import { WordProcessingMLValue } from './word-processing-mlvalue';
|
24
|
+
import { NoteNumberingRestartType, NotePosition, NoteType } from '../../../../common/model/footnotes/footnote';
|
24
25
|
export class TranslationTables {
|
25
26
|
static createHorizontalPositionTypeAttributeTable() {
|
26
27
|
const data = new TranslationTablesData();
|
@@ -855,6 +856,29 @@ export class TranslationTables {
|
|
855
856
|
TranslationTables.makeData(data, TextDirection.TopToBottomRightToLeftRotated, 'tbRlV');
|
856
857
|
return data;
|
857
858
|
}
|
859
|
+
static createNoteNumberingRestartTypeTable() {
|
860
|
+
const data = new TranslationTablesData();
|
861
|
+
TranslationTables.makeData(data, NoteNumberingRestartType.Continuous, 'continuous');
|
862
|
+
TranslationTables.makeData(data, NoteNumberingRestartType.NewPage, 'eachPage');
|
863
|
+
TranslationTables.makeData(data, NoteNumberingRestartType.NewSection, 'eachSect');
|
864
|
+
return data;
|
865
|
+
}
|
866
|
+
static createFootNotePlacementTable() {
|
867
|
+
const data = new TranslationTablesData();
|
868
|
+
TranslationTables.makeData(data, NotePosition.BelowText, 'beneathText');
|
869
|
+
TranslationTables.makeData(data, NotePosition.BottomOfPage, 'pageBottom');
|
870
|
+
TranslationTables.makeData(data, NotePosition.EndOfDocument, 'docEnd');
|
871
|
+
TranslationTables.makeData(data, NotePosition.EndOfSection, 'sectEnd');
|
872
|
+
return data;
|
873
|
+
}
|
874
|
+
static createNoteTypeTable() {
|
875
|
+
const data = new TranslationTablesData();
|
876
|
+
TranslationTables.makeData(data, NoteType.Normal, 'normal');
|
877
|
+
TranslationTables.makeData(data, NoteType.Separator, 'separator');
|
878
|
+
TranslationTables.makeData(data, NoteType.ContinuationSeparator, 'continuationSeparator');
|
879
|
+
TranslationTables.makeData(data, NoteType.ContinuationNotice, 'continuationNotice');
|
880
|
+
return data;
|
881
|
+
}
|
858
882
|
}
|
859
883
|
TranslationTables.sectionStartTypeTable = TranslationTables.createSectionStartTypeTable();
|
860
884
|
TranslationTables.lineNumberingRestartTable = TranslationTables.createLineNumberingRestartTable();
|
@@ -906,5 +930,8 @@ TranslationTables.listNumberSeparatorTable = TranslationTables.createListNumberS
|
|
906
930
|
TranslationTables.listNumberAlignmentTable = TranslationTables.createListNumberAlignmentTable();
|
907
931
|
TranslationTables.schemeColorTable = TranslationTables.createSchemeColorTable();
|
908
932
|
TranslationTables.systemColorTable = TranslationTables.createSystemColorTable();
|
933
|
+
TranslationTables.noteNumberingRestartTypeTable = TranslationTables.createNoteNumberingRestartTypeTable();
|
934
|
+
TranslationTables.footNotePlacementTable = TranslationTables.createFootNotePlacementTable();
|
935
|
+
TranslationTables.noteTypeTable = TranslationTables.createNoteTypeTable();
|
909
936
|
TranslationTables.horizontalPositionTypeAttributeTable = TranslationTables.createHorizontalPositionTypeAttributeTable();
|
910
937
|
TranslationTables.verticalPositionTypeAttributeTable = TranslationTables.createVerticalPositionTypeAttributeTable();
|