@beyondwork/docx-react-component 1.0.123 → 1.0.125
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/api/public-types.cjs +147 -35
- package/dist/api/public-types.d.cts +2 -2
- package/dist/api/public-types.d.ts +2 -2
- package/dist/api/public-types.js +3 -3
- package/dist/api/v3.cjs +797 -99
- package/dist/api/v3.d.cts +3 -3
- package/dist/api/v3.d.ts +3 -3
- package/dist/api/v3.js +10 -10
- package/dist/{canonical-document-CG2TgAzj.d.cts → canonical-document-CXCFCbAz.d.cts} +2 -0
- package/dist/{canonical-document-CG2TgAzj.d.ts → canonical-document-CXCFCbAz.d.ts} +2 -0
- package/dist/{chunk-PFYUJU3Q.js → chunk-2QL5DAKF.js} +98 -43
- package/dist/{chunk-4IPEZYQX.js → chunk-4EENH4FG.js} +1 -1
- package/dist/{chunk-BOHHIVQ2.js → chunk-4G3OS2H6.js} +3 -3
- package/dist/{chunk-MB7RJBSN.js → chunk-4YJVRIUB.js} +58 -19
- package/dist/{chunk-FNWKE74J.js → chunk-5DGKFNQT.js} +5 -1
- package/dist/{chunk-RSYN6FTS.js → chunk-6F5QW44A.js} +2 -2
- package/dist/{chunk-KOHQFZMM.js → chunk-BYSRJ4FE.js} +1 -1
- package/dist/{chunk-H6IL5ABU.js → chunk-CXSYRB37.js} +64 -20
- package/dist/{chunk-32ZAOQ54.js → chunk-D5HYZQTG.js} +1 -1
- package/dist/{chunk-ML4A4WUN.js → chunk-ESJ2MES5.js} +1 -1
- package/dist/{chunk-H2YQKA55.js → chunk-JN444Z5S.js} +505 -44
- package/dist/{chunk-IR7QV2BX.js → chunk-KV435YXO.js} +2 -2
- package/dist/{chunk-N4VIXI2Z.js → chunk-MWSBGJQO.js} +137 -18
- package/dist/{chunk-UHJLCPLU.js → chunk-OHTK7F3F.js} +96 -13
- package/dist/{chunk-SGSJ4DQA.js → chunk-QT3LX4FA.js} +321 -51
- package/dist/{chunk-NNPVA5VL.js → chunk-TQDQU2E3.js} +2 -2
- package/dist/{chunk-E5IBDE5E.js → chunk-V6XVZFFH.js} +2 -2
- package/dist/{chunk-RWERZWHR.js → chunk-YD2JE54B.js} +1 -1
- package/dist/{chunk-ZRHLLPSJ.js → chunk-YHZHPXDB.js} +85 -18
- package/dist/{chunk-HXHQA4BU.js → chunk-YIYM4ZAP.js} +1 -1
- package/dist/{chunk-LGWNN3L2.js → chunk-ZDOAUP3V.js} +2 -2
- package/dist/compare.d.cts +1 -1
- package/dist/compare.d.ts +1 -1
- package/dist/core/commands/formatting-commands.d.cts +2 -2
- package/dist/core/commands/formatting-commands.d.ts +2 -2
- package/dist/core/commands/image-commands.cjs +65 -20
- package/dist/core/commands/image-commands.d.cts +2 -2
- package/dist/core/commands/image-commands.d.ts +2 -2
- package/dist/core/commands/image-commands.js +5 -5
- package/dist/core/commands/section-layout-commands.d.cts +2 -2
- package/dist/core/commands/section-layout-commands.d.ts +2 -2
- package/dist/core/commands/style-commands.d.cts +2 -2
- package/dist/core/commands/style-commands.d.ts +2 -2
- package/dist/core/commands/table-structure-commands.cjs +65 -20
- package/dist/core/commands/table-structure-commands.d.cts +2 -2
- package/dist/core/commands/table-structure-commands.d.ts +2 -2
- package/dist/core/commands/table-structure-commands.js +4 -4
- package/dist/core/commands/text-commands.cjs +66 -21
- package/dist/core/commands/text-commands.d.cts +2 -2
- package/dist/core/commands/text-commands.d.ts +2 -2
- package/dist/core/commands/text-commands.js +5 -5
- package/dist/core/selection/mapping.d.cts +2 -2
- package/dist/core/selection/mapping.d.ts +2 -2
- package/dist/core/state/editor-state.d.cts +2 -2
- package/dist/core/state/editor-state.d.ts +2 -2
- package/dist/index.cjs +1347 -191
- package/dist/index.d.cts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +39 -21
- package/dist/io/docx-session.cjs +57 -18
- package/dist/io/docx-session.d.cts +4 -4
- package/dist/io/docx-session.d.ts +4 -4
- package/dist/io/docx-session.js +4 -4
- package/dist/legal.cjs +42 -10
- package/dist/legal.d.cts +1 -1
- package/dist/legal.d.ts +1 -1
- package/dist/legal.js +3 -3
- package/dist/{loader-D9y4ZRjj.d.ts → loader-B1MxvbeV.d.ts} +3 -3
- package/dist/{loader-D9KCtj4m.d.cts → loader-CJXsswcd.d.cts} +3 -3
- package/dist/{public-types-DajNGKV4.d.cts → public-types-BEGhv2YR.d.ts} +108 -6
- package/dist/{public-types-CNnMHZM9.d.ts → public-types-DrhlQ5Zy.d.cts} +108 -6
- package/dist/public-types.cjs +147 -35
- package/dist/public-types.d.cts +2 -2
- package/dist/public-types.d.ts +2 -2
- package/dist/public-types.js +3 -3
- package/dist/runtime/collab.d.cts +3 -3
- package/dist/runtime/collab.d.ts +3 -3
- package/dist/runtime/document-runtime.cjs +685 -98
- package/dist/runtime/document-runtime.d.cts +2 -2
- package/dist/runtime/document-runtime.d.ts +2 -2
- package/dist/runtime/document-runtime.js +14 -14
- package/dist/{session-DyQGlryH.d.cts → session-Bp3zqnkS.d.cts} +3 -3
- package/dist/{session-DEmaOEjA.d.ts → session-xMOU_NtL.d.ts} +3 -3
- package/dist/session.cjs +57 -18
- package/dist/session.d.cts +5 -5
- package/dist/session.d.ts +5 -5
- package/dist/session.js +5 -5
- package/dist/tailwind.cjs +238 -73
- package/dist/tailwind.d.cts +2 -2
- package/dist/tailwind.d.ts +2 -2
- package/dist/tailwind.js +7 -7
- package/dist/{types-DjJNaE9c.d.ts → types-BFT8536T.d.ts} +2 -2
- package/dist/{types-CxE1aZiv.d.cts → types-DDPxEygX.d.cts} +2 -2
- package/dist/ui-tailwind/editor-surface/search-plugin.d.cts +3 -3
- package/dist/ui-tailwind/editor-surface/search-plugin.d.ts +3 -3
- package/dist/ui-tailwind/editor-surface/search-plugin.js +4 -4
- package/dist/ui-tailwind.cjs +238 -73
- package/dist/ui-tailwind.d.cts +3 -3
- package/dist/ui-tailwind.d.ts +3 -3
- package/dist/ui-tailwind.js +7 -7
- package/package.json +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { gz as ActiveStoryTextCommand, gA as CommandAppliedMeta, gB as CreateDocumentRuntimeOptions, gC as DocumentRuntime, gD as DocumentRuntimeEvent, gE as RemoteCommandEnvelope, gF as Unsubscribe, gG as __buildTocInlineNodes, gH as __collectFontLoaderInputUncached, gI as __fontFamiliesEqual, gJ as createDocumentRuntime, gK as getThemeColorResolver } from '../public-types-
|
|
2
|
-
import '../canonical-document-
|
|
1
|
+
export { gz as ActiveStoryTextCommand, gA as CommandAppliedMeta, gB as CreateDocumentRuntimeOptions, gC as DocumentRuntime, gD as DocumentRuntimeEvent, gE as RemoteCommandEnvelope, gF as Unsubscribe, gG as __buildTocInlineNodes, gH as __collectFontLoaderInputUncached, gI as __fontFamiliesEqual, gJ as createDocumentRuntime, gK as getThemeColorResolver } from '../public-types-DrhlQ5Zy.cjs';
|
|
2
|
+
import '../canonical-document-CXCFCbAz.cjs';
|
|
3
3
|
import 'react';
|
|
4
4
|
import 'yjs';
|
|
5
5
|
import 'y-protocols/awareness';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { gz as ActiveStoryTextCommand, gA as CommandAppliedMeta, gB as CreateDocumentRuntimeOptions, gC as DocumentRuntime, gD as DocumentRuntimeEvent, gE as RemoteCommandEnvelope, gF as Unsubscribe, gG as __buildTocInlineNodes, gH as __collectFontLoaderInputUncached, gI as __fontFamiliesEqual, gJ as createDocumentRuntime, gK as getThemeColorResolver } from '../public-types-
|
|
2
|
-
import '../canonical-document-
|
|
1
|
+
export { gz as ActiveStoryTextCommand, gA as CommandAppliedMeta, gB as CreateDocumentRuntimeOptions, gC as DocumentRuntime, gD as DocumentRuntimeEvent, gE as RemoteCommandEnvelope, gF as Unsubscribe, gG as __buildTocInlineNodes, gH as __collectFontLoaderInputUncached, gI as __fontFamiliesEqual, gJ as createDocumentRuntime, gK as getThemeColorResolver } from '../public-types-BEGhv2YR.js';
|
|
2
|
+
import '../canonical-document-CXCFCbAz.js';
|
|
3
3
|
import 'react';
|
|
4
4
|
import 'yjs';
|
|
5
5
|
import 'y-protocols/awareness';
|
|
@@ -4,27 +4,27 @@ import {
|
|
|
4
4
|
__fontFamiliesEqual,
|
|
5
5
|
createDocumentRuntime,
|
|
6
6
|
getThemeColorResolver
|
|
7
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-QT3LX4FA.js";
|
|
8
8
|
import "../chunk-6EXNNAO6.js";
|
|
9
9
|
import "../chunk-M6XR534O.js";
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
10
|
+
import "../chunk-YD2JE54B.js";
|
|
11
|
+
import "../chunk-4G3OS2H6.js";
|
|
12
12
|
import "../chunk-Y4XZCMCS.js";
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-
|
|
15
|
-
import "../chunk-
|
|
16
|
-
import "../chunk-
|
|
17
|
-
import "../chunk-
|
|
18
|
-
import "../chunk-
|
|
19
|
-
import "../chunk-
|
|
13
|
+
import "../chunk-6F5QW44A.js";
|
|
14
|
+
import "../chunk-KV435YXO.js";
|
|
15
|
+
import "../chunk-ZDOAUP3V.js";
|
|
16
|
+
import "../chunk-BYSRJ4FE.js";
|
|
17
|
+
import "../chunk-MWSBGJQO.js";
|
|
18
|
+
import "../chunk-OHTK7F3F.js";
|
|
19
|
+
import "../chunk-YHZHPXDB.js";
|
|
20
20
|
import "../chunk-KFCQYZXR.js";
|
|
21
21
|
import "../chunk-QIO6V46H.js";
|
|
22
|
-
import "../chunk-
|
|
22
|
+
import "../chunk-CXSYRB37.js";
|
|
23
23
|
import "../chunk-CX42VC67.js";
|
|
24
24
|
import "../chunk-OYGMRRR7.js";
|
|
25
|
-
import "../chunk-
|
|
26
|
-
import "../chunk-
|
|
27
|
-
import "../chunk-
|
|
25
|
+
import "../chunk-ESJ2MES5.js";
|
|
26
|
+
import "../chunk-4YJVRIUB.js";
|
|
27
|
+
import "../chunk-5DGKFNQT.js";
|
|
28
28
|
import "../chunk-EB6M3GE6.js";
|
|
29
29
|
import "../chunk-IHE7YOAY.js";
|
|
30
30
|
import "../chunk-UTL65BUI.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as CanonicalDocument } from './canonical-document-
|
|
2
|
-
import { a as EditorSessionState, c as ExportResult, P as PersistedEditorSnapshot } from './public-types-
|
|
3
|
-
import { O as OpenOptions, b as OpenResult, a as ExportOptions, R as ReopenBarrier, V as ValidateOptions, d as ValidationReport } from './types-
|
|
1
|
+
import { C as CanonicalDocument } from './canonical-document-CXCFCbAz.cjs';
|
|
2
|
+
import { a as EditorSessionState, c as ExportResult, P as PersistedEditorSnapshot } from './public-types-DrhlQ5Zy.cjs';
|
|
3
|
+
import { O as OpenOptions, b as OpenResult, a as ExportOptions, R as ReopenBarrier, V as ValidateOptions, d as ValidationReport } from './types-DDPxEygX.cjs';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* `DocxSession` — the Layer-01 package/session public entry class.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as CanonicalDocument } from './canonical-document-
|
|
2
|
-
import { a as EditorSessionState, c as ExportResult, P as PersistedEditorSnapshot } from './public-types-
|
|
3
|
-
import { O as OpenOptions, b as OpenResult, a as ExportOptions, R as ReopenBarrier, V as ValidateOptions, d as ValidationReport } from './types-
|
|
1
|
+
import { C as CanonicalDocument } from './canonical-document-CXCFCbAz.js';
|
|
2
|
+
import { a as EditorSessionState, c as ExportResult, P as PersistedEditorSnapshot } from './public-types-BEGhv2YR.js';
|
|
3
|
+
import { O as OpenOptions, b as OpenResult, a as ExportOptions, R as ReopenBarrier, V as ValidateOptions, d as ValidationReport } from './types-BFT8536T.js';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* `DocxSession` — the Layer-01 package/session public entry class.
|
package/dist/session.cjs
CHANGED
|
@@ -14825,6 +14825,8 @@ function resolveContentType(path, contentTypes) {
|
|
|
14825
14825
|
// src/io/ooxml/parse-bookmark-references.ts
|
|
14826
14826
|
var HYPERLINK_ANCHOR_RE = /<(?:\w+:)?hyperlink\b[^>]*\bw:anchor\s*=\s*"([^"]*)"/gi;
|
|
14827
14827
|
var INSTR_TEXT_RE = /<(?:\w+:)?instrText\b[^>]*>([\s\S]*?)<\/(?:\w+:)?instrText>/gi;
|
|
14828
|
+
var FLD_SIMPLE_INSTR_DOUBLE_RE = /<(?:\w+:)?fldSimple\b[^>]*?\b(?:w:)?instr\s*=\s*"([^"]*)"/gi;
|
|
14829
|
+
var FLD_SIMPLE_INSTR_SINGLE_RE = /<(?:\w+:)?fldSimple\b[^>]*?\b(?:w:)?instr\s*=\s*'([^']*)'/gi;
|
|
14828
14830
|
var TOC_FIELD_RE = /\bTOC\b/;
|
|
14829
14831
|
var REFLIKE_FIELD_RE = /\b(?:HYPERLINK|REF|PAGEREF|NOTEREF)\s+([A-Za-z0-9_:.\-]+)/g;
|
|
14830
14832
|
var DATA_BINDING_RE = /<(?:\w+:)?dataBinding\b/i;
|
|
@@ -14844,12 +14846,21 @@ function scanBookmarkReferences(documentXml, callerAllowlist = []) {
|
|
|
14844
14846
|
INSTR_TEXT_RE.lastIndex = 0;
|
|
14845
14847
|
while ((m = INSTR_TEXT_RE.exec(documentXml)) !== null) {
|
|
14846
14848
|
const instrText = m[1] ?? "";
|
|
14847
|
-
|
|
14848
|
-
|
|
14849
|
-
|
|
14850
|
-
|
|
14851
|
-
|
|
14852
|
-
|
|
14849
|
+
scanFieldInstruction(instrText, retained, () => {
|
|
14850
|
+
retainAllToc = true;
|
|
14851
|
+
});
|
|
14852
|
+
}
|
|
14853
|
+
FLD_SIMPLE_INSTR_DOUBLE_RE.lastIndex = 0;
|
|
14854
|
+
while ((m = FLD_SIMPLE_INSTR_DOUBLE_RE.exec(documentXml)) !== null) {
|
|
14855
|
+
scanFieldInstruction(decodeXmlAttribute(m[1] ?? ""), retained, () => {
|
|
14856
|
+
retainAllToc = true;
|
|
14857
|
+
});
|
|
14858
|
+
}
|
|
14859
|
+
FLD_SIMPLE_INSTR_SINGLE_RE.lastIndex = 0;
|
|
14860
|
+
while ((m = FLD_SIMPLE_INSTR_SINGLE_RE.exec(documentXml)) !== null) {
|
|
14861
|
+
scanFieldInstruction(decodeXmlAttribute(m[1] ?? ""), retained, () => {
|
|
14862
|
+
retainAllToc = true;
|
|
14863
|
+
});
|
|
14853
14864
|
}
|
|
14854
14865
|
retainRevisionBoundedBookmarks(documentXml, retained);
|
|
14855
14866
|
return {
|
|
@@ -14858,6 +14869,17 @@ function scanBookmarkReferences(documentXml, callerAllowlist = []) {
|
|
|
14858
14869
|
retainAll
|
|
14859
14870
|
};
|
|
14860
14871
|
}
|
|
14872
|
+
function scanFieldInstruction(instrText, retained, retainToc) {
|
|
14873
|
+
if (TOC_FIELD_RE.test(instrText)) retainToc();
|
|
14874
|
+
REFLIKE_FIELD_RE.lastIndex = 0;
|
|
14875
|
+
let r;
|
|
14876
|
+
while ((r = REFLIKE_FIELD_RE.exec(instrText)) !== null) {
|
|
14877
|
+
if (r[1]) retained.add(r[1]);
|
|
14878
|
+
}
|
|
14879
|
+
}
|
|
14880
|
+
function decodeXmlAttribute(value) {
|
|
14881
|
+
return value.replace(/"/g, '"').replace(/'/g, "'").replace(/</g, "<").replace(/>/g, ">").replace(/&/g, "&");
|
|
14882
|
+
}
|
|
14861
14883
|
function retainRevisionBoundedBookmarks(documentXml, retained) {
|
|
14862
14884
|
const starts = /* @__PURE__ */ new Map();
|
|
14863
14885
|
BOOKMARK_START_RE.lastIndex = 0;
|
|
@@ -15209,18 +15231,23 @@ function parseNumberingXml(xml, context) {
|
|
|
15209
15231
|
const abstractDefinitions = {};
|
|
15210
15232
|
const instances = {};
|
|
15211
15233
|
const numPicBullets = {};
|
|
15234
|
+
const topLevelOrdinals = /* @__PURE__ */ new Map();
|
|
15212
15235
|
for (const child of numberingElement.children) {
|
|
15213
15236
|
if (child.type !== "element") {
|
|
15214
15237
|
continue;
|
|
15215
15238
|
}
|
|
15216
|
-
|
|
15239
|
+
const childName = localName(child.name);
|
|
15240
|
+
const childOrdinal = (topLevelOrdinals.get(childName) ?? 0) + 1;
|
|
15241
|
+
topLevelOrdinals.set(childName, childOrdinal);
|
|
15242
|
+
const childXmlPath = `/numbering[1]/${childName}[${childOrdinal}]`;
|
|
15243
|
+
if (childName === "numPicBullet") {
|
|
15217
15244
|
const rawId = readStringAttr(child, "w:numPicBulletId");
|
|
15218
15245
|
if (rawId) {
|
|
15219
|
-
numPicBullets[rawId] = readNumPicBullet(child, rawId, context);
|
|
15246
|
+
numPicBullets[rawId] = readNumPicBullet(child, rawId, context, childXmlPath);
|
|
15220
15247
|
}
|
|
15221
15248
|
continue;
|
|
15222
15249
|
}
|
|
15223
|
-
switch (
|
|
15250
|
+
switch (childName) {
|
|
15224
15251
|
case "abstractNum": {
|
|
15225
15252
|
const rawId = readStringAttr(child, "w:abstractNumId");
|
|
15226
15253
|
if (!rawId) {
|
|
@@ -15240,7 +15267,7 @@ function parseNumberingXml(xml, context) {
|
|
|
15240
15267
|
const numStyleLink = numStyleLinkEl ? readStringAttr(numStyleLinkEl, "w:val") : void 0;
|
|
15241
15268
|
abstractDefinitions[abstractNumberingId] = {
|
|
15242
15269
|
abstractNumberingId,
|
|
15243
|
-
...context?.partPath !== void 0 ? { sourceRef: createNumberingSourceRef(context.partPath, "abstractNum", rawId) } : {},
|
|
15270
|
+
...context?.partPath !== void 0 ? { sourceRef: createNumberingSourceRef(context.partPath, "abstractNum", rawId, childXmlPath) } : {},
|
|
15244
15271
|
levels: readLevels(child),
|
|
15245
15272
|
...nsid ? { nsid } : {},
|
|
15246
15273
|
...multiLevelType ? { multiLevelType } : {},
|
|
@@ -15260,7 +15287,7 @@ function parseNumberingXml(xml, context) {
|
|
|
15260
15287
|
const numberingInstanceId = toCanonicalNumberingInstanceId(rawId);
|
|
15261
15288
|
instances[numberingInstanceId] = {
|
|
15262
15289
|
numberingInstanceId,
|
|
15263
|
-
...context?.partPath !== void 0 ? { sourceRef: createNumberingSourceRef(context.partPath, "num", rawId) } : {},
|
|
15290
|
+
...context?.partPath !== void 0 ? { sourceRef: createNumberingSourceRef(context.partPath, "num", rawId, childXmlPath) } : {},
|
|
15264
15291
|
abstractNumberingId: toCanonicalAbstractNumberingId(rawAbstractId),
|
|
15265
15292
|
overrides: readOverrides(child)
|
|
15266
15293
|
};
|
|
@@ -15274,15 +15301,16 @@ function parseNumberingXml(xml, context) {
|
|
|
15274
15301
|
...Object.keys(numPicBullets).length > 0 ? { numPicBullets } : {}
|
|
15275
15302
|
};
|
|
15276
15303
|
}
|
|
15277
|
-
function createNumberingSourceRef(partPath, element, rawId) {
|
|
15304
|
+
function createNumberingSourceRef(partPath, element, rawId, xmlPath) {
|
|
15278
15305
|
return {
|
|
15279
15306
|
sourceId: `part:${partPath}#${element}:${rawId}`,
|
|
15280
15307
|
partPath,
|
|
15281
15308
|
storyKind: "numbering",
|
|
15282
|
-
element
|
|
15309
|
+
element,
|
|
15310
|
+
...xmlPath !== void 0 ? { xmlPath } : {}
|
|
15283
15311
|
};
|
|
15284
15312
|
}
|
|
15285
|
-
function readNumPicBullet(node, numPicBulletId, context) {
|
|
15313
|
+
function readNumPicBullet(node, numPicBulletId, context, xmlPath) {
|
|
15286
15314
|
let widthEmu;
|
|
15287
15315
|
let heightEmu;
|
|
15288
15316
|
let mediaId;
|
|
@@ -15345,6 +15373,7 @@ function readNumPicBullet(node, numPicBulletId, context) {
|
|
|
15345
15373
|
}
|
|
15346
15374
|
return {
|
|
15347
15375
|
numPicBulletId,
|
|
15376
|
+
...context?.partPath !== void 0 ? { sourceRef: createNumberingSourceRef(context.partPath, "numPicBullet", numPicBulletId, xmlPath) } : {},
|
|
15348
15377
|
rawXml: serializeXmlElementToString(node),
|
|
15349
15378
|
...widthEmu !== void 0 ? { widthEmu } : {},
|
|
15350
15379
|
...heightEmu !== void 0 ? { heightEmu } : {},
|
|
@@ -19317,7 +19346,11 @@ function parseBodyChild(node, sourceXml, relationshipMap, relationships, mediaPa
|
|
|
19317
19346
|
switch (localName(child.name)) {
|
|
19318
19347
|
case "pPr":
|
|
19319
19348
|
styleId = readParagraphStyleId(child);
|
|
19320
|
-
numbering = readParagraphNumbering(
|
|
19349
|
+
numbering = readParagraphNumbering(
|
|
19350
|
+
child,
|
|
19351
|
+
sourcePartPath,
|
|
19352
|
+
`${sourceXmlPath}/pPr[${countPriorElementSiblingsByName(node, child) + 1}]`
|
|
19353
|
+
);
|
|
19321
19354
|
alignment = readParagraphAlignment(child);
|
|
19322
19355
|
spacing = readParagraphSpacing2(child);
|
|
19323
19356
|
contextualSpacing = readOptionalOnOffParagraphProperty(child, "contextualSpacing");
|
|
@@ -20400,7 +20433,7 @@ function readParagraphStyleId(node) {
|
|
|
20400
20433
|
}
|
|
20401
20434
|
return void 0;
|
|
20402
20435
|
}
|
|
20403
|
-
function readParagraphNumbering(node, sourcePartPath) {
|
|
20436
|
+
function readParagraphNumbering(node, sourcePartPath, sourceXmlPath) {
|
|
20404
20437
|
const numberingProperties = node.children.find(
|
|
20405
20438
|
(child) => child.type === "element" && localName(child.name) === "numPr"
|
|
20406
20439
|
);
|
|
@@ -20420,16 +20453,22 @@ function readParagraphNumbering(node, sourcePartPath) {
|
|
|
20420
20453
|
}
|
|
20421
20454
|
return {
|
|
20422
20455
|
numberingInstanceId: toCanonicalNumberingInstanceId(rawInstanceId),
|
|
20423
|
-
sourceRef: createElementSourceRef(
|
|
20456
|
+
sourceRef: createElementSourceRef(
|
|
20457
|
+
sourcePartPath,
|
|
20458
|
+
"numPr",
|
|
20459
|
+
numberingProperties,
|
|
20460
|
+
sourceXmlPath !== void 0 ? `${sourceXmlPath}/numPr[${countPriorElementSiblingsByName(node, numberingProperties) + 1}]` : void 0
|
|
20461
|
+
),
|
|
20424
20462
|
level: Number.parseInt(rawLevel, 10)
|
|
20425
20463
|
};
|
|
20426
20464
|
}
|
|
20427
|
-
function createElementSourceRef(partPath, element, node) {
|
|
20465
|
+
function createElementSourceRef(partPath, element, node, xmlPath) {
|
|
20428
20466
|
return {
|
|
20429
20467
|
sourceId: `part:${partPath}#${element}:${node.start}`,
|
|
20430
20468
|
partPath,
|
|
20431
20469
|
storyKind: storyKindFromPartPath(partPath),
|
|
20432
20470
|
element,
|
|
20471
|
+
...xmlPath !== void 0 ? { xmlPath } : {},
|
|
20433
20472
|
startOffset: node.start,
|
|
20434
20473
|
endOffset: node.end
|
|
20435
20474
|
};
|
package/dist/session.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { D as DocxSession, S as SessionNotOpenError, a as SessionNotWiredError } from './session-
|
|
2
|
-
export { L as LoadedDocxEditorSession, l as loadDocxSessionAsync } from './loader-
|
|
3
|
-
export { E as EmbeddedDocumentManifest, a as ExportOptions, O as OpenOptions, b as OpenResult, P as PreservationSnapshot, R as ReopenBarrier, V as ValidateOptions, c as ValidationFinding, d as ValidationReport, i as isReopenBarrier } from './types-
|
|
4
|
-
export { E as EditorHostAdapter, a as EditorSessionState, b as ExportDocxOptions, c as ExportResult, L as LoadStage, P as PersistedEditorSnapshot } from './public-types-
|
|
5
|
-
import './canonical-document-
|
|
1
|
+
export { D as DocxSession, S as SessionNotOpenError, a as SessionNotWiredError } from './session-Bp3zqnkS.cjs';
|
|
2
|
+
export { L as LoadedDocxEditorSession, l as loadDocxSessionAsync } from './loader-CJXsswcd.cjs';
|
|
3
|
+
export { E as EmbeddedDocumentManifest, a as ExportOptions, O as OpenOptions, b as OpenResult, P as PreservationSnapshot, R as ReopenBarrier, V as ValidateOptions, c as ValidationFinding, d as ValidationReport, i as isReopenBarrier } from './types-DDPxEygX.cjs';
|
|
4
|
+
export { E as EditorHostAdapter, a as EditorSessionState, b as ExportDocxOptions, c as ExportResult, L as LoadStage, P as PersistedEditorSnapshot } from './public-types-DrhlQ5Zy.cjs';
|
|
5
|
+
import './canonical-document-CXCFCbAz.cjs';
|
|
6
6
|
import 'react';
|
|
7
7
|
import 'yjs';
|
|
8
8
|
import 'y-protocols/awareness';
|
package/dist/session.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { D as DocxSession, S as SessionNotOpenError, a as SessionNotWiredError } from './session-
|
|
2
|
-
export { L as LoadedDocxEditorSession, l as loadDocxSessionAsync } from './loader-
|
|
3
|
-
export { E as EmbeddedDocumentManifest, a as ExportOptions, O as OpenOptions, b as OpenResult, P as PreservationSnapshot, R as ReopenBarrier, V as ValidateOptions, c as ValidationFinding, d as ValidationReport, i as isReopenBarrier } from './types-
|
|
4
|
-
export { E as EditorHostAdapter, a as EditorSessionState, b as ExportDocxOptions, c as ExportResult, L as LoadStage, P as PersistedEditorSnapshot } from './public-types-
|
|
5
|
-
import './canonical-document-
|
|
1
|
+
export { D as DocxSession, S as SessionNotOpenError, a as SessionNotWiredError } from './session-xMOU_NtL.js';
|
|
2
|
+
export { L as LoadedDocxEditorSession, l as loadDocxSessionAsync } from './loader-B1MxvbeV.js';
|
|
3
|
+
export { E as EmbeddedDocumentManifest, a as ExportOptions, O as OpenOptions, b as OpenResult, P as PreservationSnapshot, R as ReopenBarrier, V as ValidateOptions, c as ValidationFinding, d as ValidationReport, i as isReopenBarrier } from './types-BFT8536T.js';
|
|
4
|
+
export { E as EditorHostAdapter, a as EditorSessionState, b as ExportDocxOptions, c as ExportResult, L as LoadStage, P as PersistedEditorSnapshot } from './public-types-BEGhv2YR.js';
|
|
5
|
+
import './canonical-document-CXCFCbAz.js';
|
|
6
6
|
import 'react';
|
|
7
7
|
import 'yjs';
|
|
8
8
|
import 'y-protocols/awareness';
|
package/dist/session.js
CHANGED
|
@@ -3,14 +3,14 @@ import {
|
|
|
3
3
|
SessionNotOpenError,
|
|
4
4
|
SessionNotWiredError,
|
|
5
5
|
isReopenBarrier
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-TQDQU2E3.js";
|
|
7
7
|
import {
|
|
8
8
|
loadDocxSessionAsync
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import "./chunk-
|
|
11
|
-
import "./chunk-
|
|
9
|
+
} from "./chunk-V6XVZFFH.js";
|
|
10
|
+
import "./chunk-ESJ2MES5.js";
|
|
11
|
+
import "./chunk-4YJVRIUB.js";
|
|
12
12
|
import "./chunk-4BJ6K26R.js";
|
|
13
|
-
import "./chunk-
|
|
13
|
+
import "./chunk-5DGKFNQT.js";
|
|
14
14
|
import "./chunk-OL2UEHRP.js";
|
|
15
15
|
import "./chunk-EB6M3GE6.js";
|
|
16
16
|
import "./chunk-IHE7YOAY.js";
|