@stll/docx-core 0.35.0 → 0.36.0
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/dist/docx_kernel_bg.wasm +0 -0
- package/dist/projection.d.ts +8 -7
- package/package.json +1 -1
package/dist/docx_kernel_bg.wasm
CHANGED
|
Binary file
|
package/dist/projection.d.ts
CHANGED
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
type DocxProjectionFormattingSpan = readonly [startUtf16: number, endUtf16: number, style: "bold" | "highlight" | "superscript"];
|
|
5
5
|
type DocxProjectionStructure = readonly [] | readonly [type: "table", tableId: string, row: number, column: number];
|
|
6
6
|
type DocxProjectionAlignmentValue = "center" | "justify" | "left" | "right";
|
|
7
|
-
type DocxProjectionAlignmentSource = "direct" | "style";
|
|
7
|
+
type DocxProjectionAlignmentSource = "direct" | "style" | "docDefaults";
|
|
8
8
|
type DocxProjectionAlignment = readonly [value: DocxProjectionAlignmentValue, source: DocxProjectionAlignmentSource] | null;
|
|
9
|
-
type DocxProjectionParagraph = readonly [ordinal: number, text: string, packageParagraphId: string | null, formatting: readonly DocxProjectionFormattingSpan[], structure: DocxProjectionStructure, styleId: string | null, alignment: DocxProjectionAlignment];
|
|
10
|
-
type DocxProjectionFormattingFamily = DocxProjectionFormattingSpan[2];
|
|
11
|
-
type DocxProjectionFormattingUnknownReason = "document-part-only" | "styles-part-unavailable" | "unsupported-styles";
|
|
12
|
-
type DocxProjectionFormattingFamilyStatus = readonly [status: "known"] | readonly [status: "unknown-missing-styles", reason: "document-part-only" | "styles-part-unavailable"] | readonly [status: "unknown-unread", reason: "unsupported-styles"];
|
|
9
|
+
type DocxProjectionParagraph = readonly [ordinal: number, text: string, packageParagraphId: string | null, formatting: readonly DocxProjectionFormattingSpan[], structure: DocxProjectionStructure, styleId: string | null, alignment: DocxProjectionAlignment, container: DocxProjectionContainer];
|
|
10
|
+
type DocxProjectionFormattingFamily = DocxProjectionFormattingSpan[2] | "alignment";
|
|
11
|
+
type DocxProjectionFormattingUnknownReason = "document-part-only" | "styles-part-unavailable" | "unsupported-styles" | "unsupported-alignment";
|
|
12
|
+
type DocxProjectionFormattingFamilyStatus = readonly [status: "known"] | readonly [status: "unknown-missing-styles", reason: "document-part-only" | "styles-part-unavailable"] | readonly [status: "unknown-unread", reason: "unsupported-styles" | "unsupported-alignment"];
|
|
13
13
|
type DocxProjectionFormattingCompleteness = Readonly<Record<DocxProjectionFormattingFamily, DocxProjectionFormattingFamilyStatus>>;
|
|
14
14
|
type DocxProjectionFactSet<T> = readonly [status: "known", items: readonly T[]] | readonly [status: "unknown", reason: DocxProjectionUnknownReason];
|
|
15
15
|
type DocxProjectionUnknownReason = "paragraph-fragment" | "document-part-only" | "styles-part-unavailable" | "unsupported-styles" | "unsupported-numbering" | "incomplete-bookmark-ranges" | "unsupported-internal-references";
|
|
@@ -22,7 +22,7 @@ type DocxProjectionStructuralSpan = readonly [startUtf8: number, endUtf8: number
|
|
|
22
22
|
type DocxProjectionStructuralFacts = readonly [indentation: DocxProjectionFactSet<DocxProjectionIndentationFact>, numberingHierarchy: DocxProjectionFactSet<DocxProjectionNumberingFact>, bookmarks: DocxProjectionFactSet<DocxProjectionBookmarkFact>, internalReferences: DocxProjectionFactSet<DocxProjectionReferenceFact>, outlineLevels: DocxProjectionFactSet<DocxProjectionOutlineLevelFact>];
|
|
23
23
|
type DocxProjectionRevisionUnsupportedReason = "incompatible-paragraph-merge" | "structural-table-revision" | "unsupported-revision-markup";
|
|
24
24
|
type DocxProjectionRevisionStatus = readonly [status: "complete"] | readonly [status: "incomplete", reasons: readonly DocxProjectionRevisionUnsupportedReason[]];
|
|
25
|
-
type DocxProjectionWire = readonly [schemaVersion:
|
|
25
|
+
type DocxProjectionWire = readonly [schemaVersion: 7, paragraphs: readonly DocxProjectionParagraph[], structuralFacts: DocxProjectionStructuralFacts, revisionStatus: DocxProjectionRevisionStatus, formattingCompleteness: DocxProjectionFormattingCompleteness];
|
|
26
26
|
type DocxParagraphFragmentFacts<T extends readonly unknown[]> = { readonly [Key in keyof T]: readonly [status: "unknown", reason: "paragraph-fragment"]; };
|
|
27
27
|
type DocxParagraphFragmentWire = readonly [schemaVersion: DocxProjectionWire[0], paragraphs: readonly [DocxProjectionParagraph], structuralFacts: DocxParagraphFragmentFacts<DocxProjectionStructuralFacts>, revisionStatus: DocxProjectionWire[3], formattingCompleteness: DocxProjectionWire[4]];
|
|
28
28
|
type DocxReviewUnknownReason = "invalid-document" | "invalid-comments" | "invalid-comments-extended" | "resource-limit" | "unsupported-location";
|
|
@@ -42,6 +42,7 @@ type DocxAttributedComment = readonly [commentId: string, author: string, initia
|
|
|
42
42
|
type DocxReviewFactsWire = readonly [schemaVersion: 2, revisions: DocxReviewFactSet<DocxAttributedRevision>, comments: DocxReviewFactSet<DocxAttributedComment>];
|
|
43
43
|
/** Fused package wire schema. A new tuple layout requires a schema-version bump. */
|
|
44
44
|
type DocxPackageProjectionWire = readonly [schemaVersion: 2, document: DocxProjectionWire, reviewFacts: DocxReviewFactsWire];
|
|
45
|
+
type DocxProjectionContainer = "body" | "tableCell";
|
|
45
46
|
//#endregion
|
|
46
47
|
//#region src/projection.d.ts
|
|
47
48
|
declare const DocxProjectionInitializationError_base: import("better-result").TaggedErrorClass<"DocxProjectionInitializationError">;
|
|
@@ -83,4 +84,4 @@ declare const projectParagraphFragment: (bytes: Uint8Array) => Promise<DocxParag
|
|
|
83
84
|
*/
|
|
84
85
|
declare const projectCompressedDocxWithReviewFacts: (bytes: Uint8Array, { textMaterialization }?: ProjectCompressedDocxWithReviewFactsOptions) => Promise<DocxPackageProjectionWire>;
|
|
85
86
|
//#endregion
|
|
86
|
-
export { type DocxAttributedComment, type DocxAttributedRevision, type DocxPackageProjectionWire, type DocxParagraphFragmentWire, type DocxProjectionAlignment, type DocxProjectionAlignmentSource, type DocxProjectionAlignmentValue, type DocxProjectionBookmarkFact, DocxProjectionError, type DocxProjectionFactSet, type DocxProjectionFormattingCompleteness, type DocxProjectionFormattingFamily, type DocxProjectionFormattingFamilyStatus, type DocxProjectionFormattingSpan, type DocxProjectionFormattingUnknownReason, type DocxProjectionIndentationFact, DocxProjectionInitializationError, type DocxProjectionNumberingFact, type DocxProjectionOutlineLevelFact, type DocxProjectionParagraph, type DocxProjectionReferenceFact, type DocxProjectionRevisionStatus, type DocxProjectionRevisionUnsupportedReason, type DocxProjectionStructuralFacts, type DocxProjectionStructuralSpan, type DocxProjectionStructure, type DocxProjectionUnknownReason, DocxProjectionWasmSource, type DocxProjectionWire, type DocxReviewFactSet, type DocxReviewFactsWire, type DocxReviewUnknownReason, type DocxRevisionKind, InitializeDocxProjectionOptions, ProjectCompressedDocxWithReviewFactsOptions, docxProjectionSchemaVersion, initializeDocxProjection, projectCompressedDocx, projectCompressedDocxWithReviewFacts, projectMainDocumentXml, projectParagraphFragment };
|
|
87
|
+
export { type DocxAttributedComment, type DocxAttributedRevision, type DocxPackageProjectionWire, type DocxParagraphFragmentWire, type DocxProjectionAlignment, type DocxProjectionAlignmentSource, type DocxProjectionAlignmentValue, type DocxProjectionBookmarkFact, type DocxProjectionContainer, DocxProjectionError, type DocxProjectionFactSet, type DocxProjectionFormattingCompleteness, type DocxProjectionFormattingFamily, type DocxProjectionFormattingFamilyStatus, type DocxProjectionFormattingSpan, type DocxProjectionFormattingUnknownReason, type DocxProjectionIndentationFact, DocxProjectionInitializationError, type DocxProjectionNumberingFact, type DocxProjectionOutlineLevelFact, type DocxProjectionParagraph, type DocxProjectionReferenceFact, type DocxProjectionRevisionStatus, type DocxProjectionRevisionUnsupportedReason, type DocxProjectionStructuralFacts, type DocxProjectionStructuralSpan, type DocxProjectionStructure, type DocxProjectionUnknownReason, DocxProjectionWasmSource, type DocxProjectionWire, type DocxReviewFactSet, type DocxReviewFactsWire, type DocxReviewUnknownReason, type DocxRevisionKind, InitializeDocxProjectionOptions, ProjectCompressedDocxWithReviewFactsOptions, docxProjectionSchemaVersion, initializeDocxProjection, projectCompressedDocx, projectCompressedDocxWithReviewFacts, projectMainDocumentXml, projectParagraphFragment };
|
package/package.json
CHANGED