@beyondwork/docx-react-component 1.0.121 → 1.0.123
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 +318 -32
- 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 +349 -62
- 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-ByIqTd4s.d.cts → canonical-document-CG2TgAzj.d.cts} +1 -1
- package/dist/{canonical-document-ByIqTd4s.d.ts → canonical-document-CG2TgAzj.d.ts} +1 -1
- package/dist/{chunk-B4YHWFE3.js → chunk-32ZAOQ54.js} +1 -1
- package/dist/{chunk-QNGJRZ2D.js → chunk-4IPEZYQX.js} +1 -1
- package/dist/{chunk-3OFSP2IX.js → chunk-BOHHIVQ2.js} +3 -3
- package/dist/{chunk-EMDH4IQN.js → chunk-E5IBDE5E.js} +4 -3
- package/dist/{chunk-TFSXOIAI.js → chunk-FNWKE74J.js} +43 -3
- package/dist/{chunk-IT2DK3A7.js → chunk-H2YQKA55.js} +9 -7
- package/dist/{chunk-3TUQCHYT.js → chunk-H6IL5ABU.js} +47 -7
- package/dist/{chunk-GON2DNTE.js → chunk-HXHQA4BU.js} +1 -1
- package/dist/{chunk-3OHVK2D6.js → chunk-IR7QV2BX.js} +17 -1
- package/dist/{chunk-ZKSDVHGH.js → chunk-KOHQFZMM.js} +1 -1
- package/dist/{chunk-XVFENXLK.js → chunk-LGWNN3L2.js} +2 -2
- package/dist/{chunk-TMU7JMXX.js → chunk-MB7RJBSN.js} +9 -21
- package/dist/{chunk-UWDWGQH5.js → chunk-ML4A4WUN.js} +1 -1
- package/dist/{chunk-GZW2ERUO.js → chunk-N4VIXI2Z.js} +3 -3
- package/dist/{chunk-S4ANOS2M.js → chunk-NNPVA5VL.js} +2 -2
- package/dist/{chunk-QFU7ZOAD.js → chunk-PFYUJU3Q.js} +176 -36
- package/dist/{chunk-37SEJQ3G.js → chunk-RSYN6FTS.js} +2 -2
- package/dist/{chunk-OBCP6VTG.js → chunk-RWERZWHR.js} +1 -1
- package/dist/{chunk-UHQOUTAX.js → chunk-SGSJ4DQA.js} +377 -50
- package/dist/{chunk-PCXTMEGY.js → chunk-UHJLCPLU.js} +24 -14
- package/dist/{chunk-G3B2OBCZ.js → chunk-ZRHLLPSJ.js} +271 -26
- 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 +50 -9
- 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 +50 -9
- 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 -9
- package/dist/core/commands/text-commands.d.cts +3 -2
- package/dist/core/commands/text-commands.d.ts +3 -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 +1196 -197
- package/dist/index.d.cts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.js +278 -85
- package/dist/io/docx-session.cjs +10 -21
- 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 +8 -20
- package/dist/legal.d.cts +1 -1
- package/dist/legal.d.ts +1 -1
- package/dist/legal.js +3 -3
- package/dist/{loader-BF8ju_LK.d.ts → loader-D9KCtj4m.d.cts} +4 -22
- package/dist/{loader-g54WRvj1.d.cts → loader-D9y4ZRjj.d.ts} +4 -22
- package/dist/{public-types-Dl1jiWjk.d.ts → public-types-CNnMHZM9.d.ts} +263 -213
- package/dist/{public-types-D_y4Ptcj.d.cts → public-types-DajNGKV4.d.cts} +263 -213
- package/dist/public-types.cjs +318 -32
- 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 +752 -77
- 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-C1EPAkcI.d.ts → session-DEmaOEjA.d.ts} +3 -3
- package/dist/{session-D15QOO0Q.d.cts → session-DyQGlryH.d.cts} +3 -3
- package/dist/session.cjs +12 -618
- package/dist/session.d.cts +5 -5
- package/dist/session.d.ts +5 -5
- package/dist/session.js +7 -9
- package/dist/tailwind.cjs +489 -63
- package/dist/tailwind.d.cts +2 -2
- package/dist/tailwind.d.ts +2 -2
- package/dist/tailwind.js +7 -7
- package/dist/{types-BoSRp2Vg.d.cts → types-CxE1aZiv.d.cts} +2 -2
- package/dist/{types-DEvRwq9C.d.ts → types-DjJNaE9c.d.ts} +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/theme/tokens.css +387 -0
- package/dist/ui-tailwind.cjs +489 -63
- 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 +7 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export {
|
|
2
|
-
import { R as RevisionStoryTargetRecord, O as OpaqueFragmentRecord } from '../canonical-document-
|
|
3
|
-
import { a$ as EditorAnchorProjection } from '../public-types-
|
|
4
|
-
import '../types-
|
|
1
|
+
export { a as LoadDocxEditorSessionAsyncOptions, b as LoadDocxEditorSessionOptions, L as LoadedDocxEditorSession, l as loadDocxEditorSessionAsync } from '../loader-D9KCtj4m.cjs';
|
|
2
|
+
import { R as RevisionStoryTargetRecord, O as OpaqueFragmentRecord } from '../canonical-document-CG2TgAzj.cjs';
|
|
3
|
+
import { a$ as EditorAnchorProjection } from '../public-types-DajNGKV4.cjs';
|
|
4
|
+
import '../types-CxE1aZiv.cjs';
|
|
5
5
|
import 'react';
|
|
6
6
|
import 'yjs';
|
|
7
7
|
import 'y-protocols/awareness';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export {
|
|
2
|
-
import { R as RevisionStoryTargetRecord, O as OpaqueFragmentRecord } from '../canonical-document-
|
|
3
|
-
import { a$ as EditorAnchorProjection } from '../public-types-
|
|
4
|
-
import '../types-
|
|
1
|
+
export { a as LoadDocxEditorSessionAsyncOptions, b as LoadDocxEditorSessionOptions, L as LoadedDocxEditorSession, l as loadDocxEditorSessionAsync } from '../loader-D9y4ZRjj.js';
|
|
2
|
+
import { R as RevisionStoryTargetRecord, O as OpaqueFragmentRecord } from '../canonical-document-CG2TgAzj.js';
|
|
3
|
+
import { a$ as EditorAnchorProjection } from '../public-types-CNnMHZM9.js';
|
|
4
|
+
import '../types-DjJNaE9c.js';
|
|
5
5
|
import 'react';
|
|
6
6
|
import 'yjs';
|
|
7
7
|
import 'y-protocols/awareness';
|
package/dist/io/docx-session.js
CHANGED
|
@@ -2,11 +2,11 @@ import {
|
|
|
2
2
|
loadDocxSessionAsync,
|
|
3
3
|
normalizeImportedCommentThreads,
|
|
4
4
|
stripCommentMarkup
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-E5IBDE5E.js";
|
|
6
|
+
import "../chunk-ML4A4WUN.js";
|
|
7
|
+
import "../chunk-MB7RJBSN.js";
|
|
8
8
|
import "../chunk-4BJ6K26R.js";
|
|
9
|
-
import "../chunk-
|
|
9
|
+
import "../chunk-FNWKE74J.js";
|
|
10
10
|
import "../chunk-OL2UEHRP.js";
|
|
11
11
|
import "../chunk-EB6M3GE6.js";
|
|
12
12
|
import "../chunk-IHE7YOAY.js";
|
package/dist/legal.cjs
CHANGED
|
@@ -1017,7 +1017,6 @@ var SCOPE_MARKER_BOOKMARK_PREFIX = "bw:scope:";
|
|
|
1017
1017
|
// src/io/ooxml/parse-bookmark-references.ts
|
|
1018
1018
|
var HYPERLINK_ANCHOR_RE = /<(?:\w+:)?hyperlink\b[^>]*\bw:anchor\s*=\s*"([^"]*)"/gi;
|
|
1019
1019
|
var INSTR_TEXT_RE = /<(?:\w+:)?instrText\b[^>]*>([\s\S]*?)<\/(?:\w+:)?instrText>/gi;
|
|
1020
|
-
var SIMPLE_FIELD_INSTR_RE = /<(?:\w+:)?fldSimple\b[^>]*\bw:instr\s*=\s*"([^"]*)"/gi;
|
|
1021
1020
|
var TOC_FIELD_RE = /\bTOC\b/;
|
|
1022
1021
|
var REFLIKE_FIELD_RE = /\b(?:HYPERLINK|REF|PAGEREF|NOTEREF)\s+([A-Za-z0-9_:.\-]+)/g;
|
|
1023
1022
|
var DATA_BINDING_RE = /<(?:\w+:)?dataBinding\b/i;
|
|
@@ -1036,14 +1035,12 @@ function scanBookmarkReferences(documentXml, callerAllowlist = []) {
|
|
|
1036
1035
|
}
|
|
1037
1036
|
INSTR_TEXT_RE.lastIndex = 0;
|
|
1038
1037
|
while ((m = INSTR_TEXT_RE.exec(documentXml)) !== null) {
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
if (scanInstructionForRetainedBookmarks(m[1] ?? "", retained)) {
|
|
1046
|
-
retainAllToc = true;
|
|
1038
|
+
const instrText = m[1] ?? "";
|
|
1039
|
+
if (TOC_FIELD_RE.test(instrText)) retainAllToc = true;
|
|
1040
|
+
REFLIKE_FIELD_RE.lastIndex = 0;
|
|
1041
|
+
let r;
|
|
1042
|
+
while ((r = REFLIKE_FIELD_RE.exec(instrText)) !== null) {
|
|
1043
|
+
if (r[1]) retained.add(r[1]);
|
|
1047
1044
|
}
|
|
1048
1045
|
}
|
|
1049
1046
|
retainRevisionBoundedBookmarks(documentXml, retained);
|
|
@@ -1053,15 +1050,6 @@ function scanBookmarkReferences(documentXml, callerAllowlist = []) {
|
|
|
1053
1050
|
retainAll
|
|
1054
1051
|
};
|
|
1055
1052
|
}
|
|
1056
|
-
function scanInstructionForRetainedBookmarks(instruction, retained) {
|
|
1057
|
-
const hasTocField = TOC_FIELD_RE.test(instruction);
|
|
1058
|
-
REFLIKE_FIELD_RE.lastIndex = 0;
|
|
1059
|
-
let r;
|
|
1060
|
-
while ((r = REFLIKE_FIELD_RE.exec(instruction)) !== null) {
|
|
1061
|
-
if (r[1]) retained.add(r[1]);
|
|
1062
|
-
}
|
|
1063
|
-
return hasTocField;
|
|
1064
|
-
}
|
|
1065
1053
|
function retainRevisionBoundedBookmarks(documentXml, retained) {
|
|
1066
1054
|
const starts = /* @__PURE__ */ new Map();
|
|
1067
1055
|
BOOKMARK_START_RE.lastIndex = 0;
|
|
@@ -3863,7 +3851,7 @@ var SAFE_TABLE_FIELD_FAMILIES = /* @__PURE__ */ new Set([
|
|
|
3863
3851
|
"FORMULA"
|
|
3864
3852
|
]);
|
|
3865
3853
|
var RISKY_TABLE_MARKUP_RE = /<w:(ins|del|moveFrom|moveTo|rPrChange|pPrChange|tblPrChange|trPrChange|tcPrChange|sectPrChange|cellIns|cellDel|cellMerge|smartTag)\b/;
|
|
3866
|
-
var
|
|
3854
|
+
var SIMPLE_FIELD_INSTR_RE = /\bw:instr="([^"]*)"/g;
|
|
3867
3855
|
var COMPLEX_FIELD_TOKEN_RE = /<(?:\w+:)?fldChar\b[^>]*?(?:\w+:)?fldCharType="(begin|separate|end)"[^>]*?(?:\/>|>[\s\S]*?<\/(?:\w+:)?fldChar>)|<(?:\w+:)?instrText\b[^>]*>([\s\S]*?)<\/(?:\w+:)?instrText>/gu;
|
|
3868
3856
|
function decodeXmlEntities2(text) {
|
|
3869
3857
|
return text.replace(/</g, "<").replace(/>/g, ">").replace(/"/g, '"').replace(/'/g, "'").replace(/&/g, "&");
|
|
@@ -3904,7 +3892,7 @@ function isSafeTableFieldInstruction(instruction) {
|
|
|
3904
3892
|
}
|
|
3905
3893
|
function tableRequiresOpaquePreservation(rawXml) {
|
|
3906
3894
|
if (RISKY_TABLE_MARKUP_RE.test(rawXml)) return true;
|
|
3907
|
-
const simpleInstructions = [...rawXml.matchAll(
|
|
3895
|
+
const simpleInstructions = [...rawXml.matchAll(SIMPLE_FIELD_INSTR_RE)].map(
|
|
3908
3896
|
(match) => match[1] ?? ""
|
|
3909
3897
|
);
|
|
3910
3898
|
const complexInstructions = extractComplexFieldInstructionsFromRaw(rawXml);
|
package/dist/legal.d.cts
CHANGED
package/dist/legal.d.ts
CHANGED
package/dist/legal.js
CHANGED
|
@@ -4,13 +4,13 @@ import {
|
|
|
4
4
|
isHiddenBookmarkName,
|
|
5
5
|
parseBookmarksFromDocumentXml,
|
|
6
6
|
resolveWalkableRoot
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-RWERZWHR.js";
|
|
8
8
|
import {
|
|
9
9
|
extractComplexFieldsFromBodyXml,
|
|
10
10
|
parseFieldsFromParagraphXml,
|
|
11
11
|
parseMainDocumentXml
|
|
12
|
-
} from "./chunk-
|
|
13
|
-
import "./chunk-
|
|
12
|
+
} from "./chunk-MB7RJBSN.js";
|
|
13
|
+
import "./chunk-FNWKE74J.js";
|
|
14
14
|
import "./chunk-IHE7YOAY.js";
|
|
15
15
|
import "./chunk-UTL65BUI.js";
|
|
16
16
|
import "./chunk-DNXYUIIS.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as CanonicalDocument } from './canonical-document-
|
|
2
|
-
import { ar as EditorStateNamespace, as as EditorStateLocation, a as EditorSessionState, P as PersistedEditorSnapshot, r as EditorError, t as ProtectionSnapshot, b as ExportDocxOptions, c as ExportResult, L as LoadStage, E as EditorHostAdapter, at as LoadScheduler, o as EditorSurfaceSnapshot } from './public-types-
|
|
3
|
-
import { E as EmbeddedDocumentManifest, e as ProgressiveSurfaceProjector } from './types-
|
|
1
|
+
import { C as CanonicalDocument } from './canonical-document-CG2TgAzj.cjs';
|
|
2
|
+
import { ar as EditorStateNamespace, as as EditorStateLocation, a as EditorSessionState, P as PersistedEditorSnapshot, r as EditorError, t as ProtectionSnapshot, b as ExportDocxOptions, c as ExportResult, L as LoadStage, E as EditorHostAdapter, at as LoadScheduler, o as EditorSurfaceSnapshot } from './public-types-DajNGKV4.cjs';
|
|
3
|
+
import { E as EmbeddedDocumentManifest, e as ProgressiveSurfaceProjector } from './types-CxE1aZiv.cjs';
|
|
4
4
|
|
|
5
5
|
interface EditorStatePayloadNamespaceEntry {
|
|
6
6
|
namespace: EditorStateNamespace;
|
|
@@ -271,23 +271,5 @@ interface LoadedDocxEditorSession {
|
|
|
271
271
|
* `src/session/export/stateful-export.ts` and is imported directly.
|
|
272
272
|
*/
|
|
273
273
|
declare function loadDocxSessionAsync(options: LoadDocxEditorSessionAsyncOptions): Promise<LoadedDocxEditorSession>;
|
|
274
|
-
/**
|
|
275
|
-
* Session-layer owner of the sync load path.
|
|
276
|
-
*
|
|
277
|
-
* Slice 5e-7.e.2 relocates the body of `loadDocxEditorSession` from
|
|
278
|
-
* `src/io/docx-session.ts` into this module. Body mirrors
|
|
279
|
-
* `loadDocxSessionAsync` minus the async-only orchestration shell:
|
|
280
|
-
* - No `scheduler.yield()` calls (sync execution).
|
|
281
|
-
* - No laycache short-circuit branch (`laycacheEnvelope` is not on
|
|
282
|
-
* `LoadDocxEditorSessionOptions`).
|
|
283
|
-
* - No progressive-snapshot branch (`onProgressiveSnapshot` /
|
|
284
|
-
* `surfaceProjector` not on `LoadDocxEditorSessionOptions`).
|
|
285
|
-
* - Uses `normalizeParsedTextDocument` (sync).
|
|
286
|
-
*
|
|
287
|
-
* Byte-equivalence with the async path is asserted by
|
|
288
|
-
* `test/io/fastload-parity.test.ts` on every F*.docx fixture. Drift
|
|
289
|
-
* between the two sync/async bodies will fail that test.
|
|
290
|
-
*/
|
|
291
|
-
declare function loadDocxSessionSync(options: LoadDocxEditorSessionOptions): LoadedDocxEditorSession;
|
|
292
274
|
|
|
293
|
-
export { type LoadedDocxEditorSession as L,
|
|
275
|
+
export { type LoadedDocxEditorSession as L, type LoadDocxEditorSessionAsyncOptions as a, type LoadDocxEditorSessionOptions as b, loadDocxSessionAsync as l };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { C as CanonicalDocument } from './canonical-document-
|
|
2
|
-
import { ar as EditorStateNamespace, as as EditorStateLocation, a as EditorSessionState, P as PersistedEditorSnapshot, r as EditorError, t as ProtectionSnapshot, b as ExportDocxOptions, c as ExportResult, L as LoadStage, E as EditorHostAdapter, at as LoadScheduler, o as EditorSurfaceSnapshot } from './public-types-
|
|
3
|
-
import { E as EmbeddedDocumentManifest, e as ProgressiveSurfaceProjector } from './types-
|
|
1
|
+
import { C as CanonicalDocument } from './canonical-document-CG2TgAzj.js';
|
|
2
|
+
import { ar as EditorStateNamespace, as as EditorStateLocation, a as EditorSessionState, P as PersistedEditorSnapshot, r as EditorError, t as ProtectionSnapshot, b as ExportDocxOptions, c as ExportResult, L as LoadStage, E as EditorHostAdapter, at as LoadScheduler, o as EditorSurfaceSnapshot } from './public-types-CNnMHZM9.js';
|
|
3
|
+
import { E as EmbeddedDocumentManifest, e as ProgressiveSurfaceProjector } from './types-DjJNaE9c.js';
|
|
4
4
|
|
|
5
5
|
interface EditorStatePayloadNamespaceEntry {
|
|
6
6
|
namespace: EditorStateNamespace;
|
|
@@ -271,23 +271,5 @@ interface LoadedDocxEditorSession {
|
|
|
271
271
|
* `src/session/export/stateful-export.ts` and is imported directly.
|
|
272
272
|
*/
|
|
273
273
|
declare function loadDocxSessionAsync(options: LoadDocxEditorSessionAsyncOptions): Promise<LoadedDocxEditorSession>;
|
|
274
|
-
/**
|
|
275
|
-
* Session-layer owner of the sync load path.
|
|
276
|
-
*
|
|
277
|
-
* Slice 5e-7.e.2 relocates the body of `loadDocxEditorSession` from
|
|
278
|
-
* `src/io/docx-session.ts` into this module. Body mirrors
|
|
279
|
-
* `loadDocxSessionAsync` minus the async-only orchestration shell:
|
|
280
|
-
* - No `scheduler.yield()` calls (sync execution).
|
|
281
|
-
* - No laycache short-circuit branch (`laycacheEnvelope` is not on
|
|
282
|
-
* `LoadDocxEditorSessionOptions`).
|
|
283
|
-
* - No progressive-snapshot branch (`onProgressiveSnapshot` /
|
|
284
|
-
* `surfaceProjector` not on `LoadDocxEditorSessionOptions`).
|
|
285
|
-
* - Uses `normalizeParsedTextDocument` (sync).
|
|
286
|
-
*
|
|
287
|
-
* Byte-equivalence with the async path is asserted by
|
|
288
|
-
* `test/io/fastload-parity.test.ts` on every F*.docx fixture. Drift
|
|
289
|
-
* between the two sync/async bodies will fail that test.
|
|
290
|
-
*/
|
|
291
|
-
declare function loadDocxSessionSync(options: LoadDocxEditorSessionOptions): LoadedDocxEditorSession;
|
|
292
274
|
|
|
293
|
-
export { type LoadedDocxEditorSession as L,
|
|
275
|
+
export { type LoadedDocxEditorSession as L, type LoadDocxEditorSessionAsyncOptions as a, type LoadDocxEditorSessionOptions as b, loadDocxSessionAsync as l };
|