A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
fix: conflict editors are not scrollable
thecodrrc8513f792e39
diff --git a/apps/web/src/components/editor/react-quill.js b/apps/web/src/components/editor/react-quill.jsindex dd8cd6444..9f76ea5bf 100644--- a/apps/web/src/components/editor/react-quill.js+++ b/apps/web/src/components/editor/react-quill.js@@ -173,7 +173,7 @@ export default class ReactQuill extends Component {);}- onQuillInitialized();+ if (onQuillInitialized) onQuillInitialized();}componentWillUnmount() {diff --git a/apps/web/src/components/spliteditor/index.js b/apps/web/src/components/spliteditor/index.jsindex 6fde21c95..500e8e7b2 100644--- a/apps/web/src/components/spliteditor/index.js+++ b/apps/web/src/components/spliteditor/index.js@@ -43,12 +43,13 @@ function SplitEditor(props) {if (!conflictedNote || !localDelta || !remoteDelta) return null;return (- <Flex width="100%" flex="1 1 auto" flexDirection="column">+ <Flex width="100%" flex="1 1 auto" flexDirection="column" overflow="hidden"><Textmt={2}variant="heading"textAlign="center"sx={{+ flexShrink: 0,whiteSpace: "nowrap",overflow: "hidden",textOverflow: "ellipsis",@@ -56,10 +57,15 @@ function SplitEditor(props) {>{conflictedNote.title}</Text>- <Flex flex="1 1 auto" flexDirection={["column", "column", "row"]}>+ <Flex+ flex="1 1 auto"+ flexDirection={["column", "column", "row"]}+ overflow="hidden"+ ><FlexflexDirection="column"className="firstEditor"+ height={["50%", "50%", "100%"]}width={["100%", "100%", "50%"]}flex="1 1 auto">@@ -86,6 +92,7 @@ function SplitEditor(props) {<Boxpx={2}flex={1}+ overflowY="auto"sx={{borderStyle: "solid",borderWidth: 0,@@ -110,6 +117,7 @@ function SplitEditor(props) {flexDirection="column"className="secondEditor"flex="1 1 auto"+ height={["50%", "50%", "100%"]}width={["100%", "100%", "50%"]}><DeltaToggle@@ -134,7 +142,7 @@ function SplitEditor(props) {otherEditor: remoteEditor.current.quill,})}/>- <Box px={2}>+ <Box px={2} overflowY="auto"><SimpleEditorpref={remoteEditor}container=".secondEditor"diff --git a/apps/web/src/components/spliteditor/simpleeditor.js b/apps/web/src/components/spliteditor/simpleeditor.jsindex b7c3b01d1..b63c7c1d1 100644--- a/apps/web/src/components/spliteditor/simpleeditor.js+++ b/apps/web/src/components/spliteditor/simpleeditor.js@@ -1,13 +1,10 @@-import React, { useEffect, Suspense } from "react";+import React, { Suspense } from "react";import EditorLoading from "../editor/loading";const ReactQuill = React.lazy(() => import("../editor/react-quill"));function SimpleEditor(props) {const { delta, container, id, pref } = props;- useEffect(() => {- const toolbar = document.querySelector(`${container} .ql-toolbar.ql-snow`);- if (toolbar) toolbar.remove();- }, [container]);+return (<Suspense fallback={<EditorLoading />}><ReactQuill@@ -15,6 +12,12 @@ function SimpleEditor(props) {id={id}modules={{ toolbar: [] }}initialContent={delta}+ onQuillInitialized={() => {+ const toolbar = document.querySelector(+ `${container} .ql-toolbar.ql-snow`+ );+ if (toolbar) toolbar.remove();+ }}placeholder="Type anything here"container={container}/>