diff --git a/apps/app/components/rich-text-editor/index.tsx b/apps/app/components/rich-text-editor/index.tsx index 1413ed6cb..3f4cfc740 100644 --- a/apps/app/components/rich-text-editor/index.tsx +++ b/apps/app/components/rich-text-editor/index.tsx @@ -153,12 +153,11 @@ const RemirrorRichTextEditor: FC = (props) => { const updateState = useCallback( (value: any) => { - // Clear out old state when setting data from outside - // This prevents e.g. the user from using CTRL-Z to go back to the old state manager.view.updateState( manager.createState({ content: !value || (typeof value === "object" && Object.keys(value).length === 0) ? "" : value, + selection: value === "" ? "start" : manager.view.state.selection, }) ); },