@beyondwork/docx-react-component 1.0.40 → 1.0.41

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,7 +1,7 @@
1
1
  {
2
2
  "name": "@beyondwork/docx-react-component",
3
3
  "publisher": "beyondwork",
4
- "version": "1.0.40",
4
+ "version": "1.0.41",
5
5
  "description": "Embeddable React Word (docx) editor with review, comments, tracked changes, and round-trip OOXML fidelity.",
6
6
  "packageManager": "pnpm@10.30.3",
7
7
  "type": "module",
@@ -69,7 +69,7 @@ interface MinimalFontFaceSet {
69
69
  }
70
70
 
71
71
  export function createDocxFontLoader(initial: FontLoaderInput): DocxFontLoader {
72
- const globalDocument = (globalThis as { document?: { fonts?: MinimalFontFaceSet } }).document;
72
+ const globalDocument = (globalThis as unknown as { document?: { fonts?: unknown } }).document;
73
73
  const supported =
74
74
  globalDocument !== undefined &&
75
75
  typeof (globalThis as { FontFace?: unknown }).FontFace !== "undefined" &&
@@ -81,7 +81,7 @@ export function createDocxFontLoader(initial: FontLoaderInput): DocxFontLoader {
81
81
 
82
82
  function run(input: FontLoaderInput): Promise<void> {
83
83
  if (!supported) return Promise.resolve();
84
- const fontSet = globalDocument?.fonts;
84
+ const fontSet = globalDocument?.fonts as MinimalFontFaceSet | undefined;
85
85
  if (!fontSet) return Promise.resolve();
86
86
 
87
87
  const pending: Array<Promise<unknown>> = [];