@beyondwork/docx-react-component 1.0.51 → 1.0.52

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/package.json CHANGED
@@ -1,8 +1,9 @@
1
1
  {
2
2
  "name": "@beyondwork/docx-react-component",
3
3
  "publisher": "beyondwork",
4
- "version": "1.0.51",
4
+ "version": "1.0.52",
5
5
  "description": "Embeddable React Word (docx) editor with review, comments, tracked changes, and round-trip OOXML fidelity.",
6
+ "packageManager": "pnpm@10.30.3",
6
7
  "type": "module",
7
8
  "sideEffects": [
8
9
  "**/*.css"
@@ -92,6 +93,35 @@
92
93
  "./ui-tailwind/theme/editor-theme.css": "./src/ui-tailwind/theme/editor-theme.css"
93
94
  },
94
95
  "types": "./src/index.ts",
96
+ "scripts": {
97
+ "build": "tsup",
98
+ "test": "bash scripts/run-workspace-tests.sh",
99
+ "test:repo": "node scripts/ci-check-layout-engine-version.mjs && node scripts/run-repo-tests.mjs core",
100
+ "test:repo:all": "node scripts/run-repo-tests.mjs all",
101
+ "test:repo:optional": "node scripts/run-repo-tests.mjs optional",
102
+ "test:repo:browser-ui": "node scripts/run-repo-tests.mjs browser-ui",
103
+ "test:wcag-audit": "node scripts/run-repo-tests.mjs wcag-audit",
104
+ "test:harness": "pnpm --filter @docx-react-component/react-word-editor-harness test",
105
+ "test:visual": "VISUAL_SMOKE_PROFILE=bare pnpm exec playwright test --project=chromium",
106
+ "test:visual:chrome": "VISUAL_SMOKE_PROFILE=chrome-cycle pnpm exec playwright test --project=chromium",
107
+ "visual:list-runs": "node scripts/visual-smoke-list-runs.mjs",
108
+ "mcp:visual-smoke": "node scripts/visual-smoke-mcp.mjs",
109
+ "lint": "pnpm run lint:no-authored-js && pnpm run lint:docs-contracts && pnpm run lint:tsgo && pnpm run lint:tsgo:harness",
110
+ "lint:docs-contracts": "bash scripts/check-reference-load-contract.sh",
111
+ "lint:no-authored-js": "bash scripts/check-no-authored-js.sh",
112
+ "lint:tsgo": "tsgo --noEmit -p tsconfig.build.json",
113
+ "lint:tsgo:harness": "pnpm --filter @docx-react-component/react-word-editor-harness lint:tsgo",
114
+ "context7:api-check": "bash scripts/context7-export-env.sh run bash scripts/context7-api-check.sh",
115
+ "wave:doctor": "bash scripts/context7-export-env.sh run pnpm exec wave doctor --json",
116
+ "wave:dry-run": "bash scripts/context7-export-env.sh run pnpm exec wave launch --lane main --dry-run --no-dashboard",
117
+ "wave:launch": "bash scripts/context7-export-env.sh run pnpm exec wave launch --lane main",
118
+ "wave:launch:managed": "bash scripts/wave-launch.sh",
119
+ "wave:status": "bash scripts/wave-status.sh",
120
+ "wave:watch": "bash scripts/wave-watch.sh --follow",
121
+ "wave:dashboard:current": "bash scripts/wave-dashboard-attach.sh current",
122
+ "wave:dashboard:global": "bash scripts/wave-dashboard-attach.sh global",
123
+ "harness:dev": "pnpm --filter @docx-react-component/react-word-editor-harness dev"
124
+ },
95
125
  "keywords": [
96
126
  "docx",
97
127
  "word",
@@ -175,33 +205,14 @@
175
205
  "y-protocols": "^1.0.7",
176
206
  "yjs": "^13.6.30"
177
207
  },
178
- "scripts": {
179
- "build": "tsup",
180
- "test": "bash scripts/run-workspace-tests.sh",
181
- "test:repo": "node scripts/ci-check-layout-engine-version.mjs && node scripts/run-repo-tests.mjs core",
182
- "test:repo:all": "node scripts/run-repo-tests.mjs all",
183
- "test:repo:optional": "node scripts/run-repo-tests.mjs optional",
184
- "test:repo:browser-ui": "node scripts/run-repo-tests.mjs browser-ui",
185
- "test:wcag-audit": "node scripts/run-repo-tests.mjs wcag-audit",
186
- "test:harness": "pnpm --filter @docx-react-component/react-word-editor-harness test",
187
- "test:visual": "VISUAL_SMOKE_PROFILE=bare pnpm exec playwright test --project=chromium",
188
- "test:visual:chrome": "VISUAL_SMOKE_PROFILE=chrome-cycle pnpm exec playwright test --project=chromium",
189
- "visual:list-runs": "node scripts/visual-smoke-list-runs.mjs",
190
- "mcp:visual-smoke": "node scripts/visual-smoke-mcp.mjs",
191
- "lint": "pnpm run lint:no-authored-js && pnpm run lint:docs-contracts && pnpm run lint:tsgo && pnpm run lint:tsgo:harness",
192
- "lint:docs-contracts": "bash scripts/check-reference-load-contract.sh",
193
- "lint:no-authored-js": "bash scripts/check-no-authored-js.sh",
194
- "lint:tsgo": "tsgo --noEmit -p tsconfig.build.json",
195
- "lint:tsgo:harness": "pnpm --filter @docx-react-component/react-word-editor-harness lint:tsgo",
196
- "context7:api-check": "bash scripts/context7-export-env.sh run bash scripts/context7-api-check.sh",
197
- "wave:doctor": "bash scripts/context7-export-env.sh run pnpm exec wave doctor --json",
198
- "wave:dry-run": "bash scripts/context7-export-env.sh run pnpm exec wave launch --lane main --dry-run --no-dashboard",
199
- "wave:launch": "bash scripts/context7-export-env.sh run pnpm exec wave launch --lane main",
200
- "wave:launch:managed": "bash scripts/wave-launch.sh",
201
- "wave:status": "bash scripts/wave-status.sh",
202
- "wave:watch": "bash scripts/wave-watch.sh --follow",
203
- "wave:dashboard:current": "bash scripts/wave-dashboard-attach.sh current",
204
- "wave:dashboard:global": "bash scripts/wave-dashboard-attach.sh global",
205
- "harness:dev": "pnpm --filter @docx-react-component/react-word-editor-harness dev"
208
+ "pnpm": {
209
+ "onlyBuiltDependencies": [
210
+ "esbuild",
211
+ "sharp"
212
+ ],
213
+ "overrides": {
214
+ "react": "19.2.4",
215
+ "react-dom": "19.2.4"
216
+ }
206
217
  }
207
218
  }
@@ -3025,6 +3025,15 @@ export interface WordReviewEditorRef {
3025
3025
  setImageFrame(mediaId: string, offsets: { horizontalOffsetEmu?: number; verticalOffsetEmu?: number }): void;
3026
3026
  setWorkflowOverlay(overlay: WorkflowOverlay): void;
3027
3027
  clearWorkflowOverlay(): void;
3028
+ /**
3029
+ * Read the current runtime-backed `WorkflowOverlay`, or `null` when no
3030
+ * overlay is active. Hosts use this for read-modify-write flows against
3031
+ * `setWorkflowOverlay(...)` — notably to preserve engine-authored scopes
3032
+ * minted via `addScope(...)` when updating candidates / work items.
3033
+ * Returns a defensive clone; mutating the returned object does not affect
3034
+ * runtime state.
3035
+ */
3036
+ getWorkflowOverlay(): WorkflowOverlay | null;
3028
3037
  setSharedWorkflowState(state: SharedWorkflowState | null): void;
3029
3038
  getWorkflowScopeSnapshot(): WorkflowScopeSnapshot | null;
3030
3039
  getInteractionGuardSnapshot(): InteractionGuardSnapshot;
@@ -782,6 +782,7 @@ export function __createWordReviewEditorRefBridge(
782
782
  clearWorkflowOverlay: () => {
783
783
  runtime.clearWorkflowOverlay();
784
784
  },
785
+ getWorkflowOverlay: () => clonePublicValue(runtime.getWorkflowOverlay()),
785
786
  setSharedWorkflowState: (state) => {
786
787
  runtime.setSharedWorkflowState(state === null ? null : clonePublicValue(state));
787
788
  },
@@ -1833,6 +1834,8 @@ export const WordReviewEditor = forwardRef<WordReviewEditorRef, WordReviewEditor
1833
1834
  clearWorkflowOverlay: () => {
1834
1835
  activeRuntime.clearWorkflowOverlay();
1835
1836
  },
1837
+ getWorkflowOverlay: () =>
1838
+ clonePublicValue(activeRuntime.getWorkflowOverlay()),
1836
1839
  setSharedWorkflowState: (state) => {
1837
1840
  activeRuntime.setSharedWorkflowState(state === null ? null : clonePublicValue(state));
1838
1841
  },