From 1bea9a06d67af561ca57d799ce713e5b6ed926c3 Mon Sep 17 00:00:00 2001 From: Shane Friedman Date: Tue, 17 Dec 2024 16:56:09 -0500 Subject: [PATCH] Build --- dist/cjs/hooks/useEditor.js | 4 +++- dist/esm/hooks/useEditor.js | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/dist/cjs/hooks/useEditor.js b/dist/cjs/hooks/useEditor.js index da95f2a..6710d97 100644 --- a/dist/cjs/hooks/useEditor.js +++ b/dist/cjs/hooks/useEditor.js @@ -68,7 +68,9 @@ let ReactEditorView = class ReactEditorView extends _prosemirrorview.EditorView // to an empty object to prevent an error from being thrown, and then // clean it up so that other isomorphic code doesn't get confused about // whether there's a functioning global window object - globalThis.window ??= {}; + globalThis.window ??= { + visualViewport: null + }; super(place, { state: _prosemirrorstate.EditorState.create({ schema: props.state.schema, diff --git a/dist/esm/hooks/useEditor.js b/dist/esm/hooks/useEditor.js index 57daaab..2471964 100644 --- a/dist/esm/hooks/useEditor.js +++ b/dist/esm/hooks/useEditor.js @@ -51,7 +51,9 @@ export class ReactEditorView extends EditorView { // to an empty object to prevent an error from being thrown, and then // clean it up so that other isomorphic code doesn't get confused about // whether there's a functioning global window object - globalThis.window ??= {}; + globalThis.window ??= { + visualViewport: null + }; super(place, { state: EditorState.create({ schema: props.state.schema,