From a90f957aa403c9f0b34f32385dcf9a8e471c6005 Mon Sep 17 00:00:00 2001 From: ammarahm-ed Date: Tue, 23 May 2023 08:05:21 +0500 Subject: [PATCH] mobile: always check editor is ready on enter foreground --- apps/mobile/app/screens/editor/wrapper.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/apps/mobile/app/screens/editor/wrapper.js b/apps/mobile/app/screens/editor/wrapper.js index b2671720a..03c5072ae 100644 --- a/apps/mobile/app/screens/editor/wrapper.js +++ b/apps/mobile/app/screens/editor/wrapper.js @@ -35,7 +35,7 @@ import { useSettingStore } from "../../stores/use-setting-store"; import { useThemeStore } from "../../stores/use-theme-store"; import { editorRef } from "../../utils/global-refs"; import { ProgressBar } from "./progress"; -import { editorController, editorState, textInput } from "./tiptap/utils"; +import { editorController, textInput } from "./tiptap/utils"; export const EditorWrapper = ({ width }) => { const colors = useThemeStore((state) => state.colors); const deviceMode = useSettingStore((state) => state.deviceMode); @@ -48,7 +48,6 @@ export const EditorWrapper = ({ width }) => { const keyboard = useKeyboard(); const onAppStateChanged = async (state) => { - if (editorState().movedAway) return; if (state === "active") { editorController.current.onReady(); editorController.current.overlay(false);