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: make the app compile
thecodrr2458237daa6c
diff --git a/apps/web/src/components/editor/header.js b/apps/web/src/components/editor/header.jsindex fd9090528..ddbfae967 100644--- a/apps/web/src/components/editor/header.js+++ b/apps/web/src/components/editor/header.js@@ -49,19 +49,19 @@ function Header() {marginBottom: dateEdited || text.length || id.length ? 2 : 0}}>- {dateEdited > 0 && (+ {dateEdited > 0 ? (<>{timeConverter(dateEdited)}<TextSeperator /></>- )}- {text.length > 0 && (+ ) : null}+ {text.length > 0 ? (<>{countWords(text) + " words"}<TextSeperator /></>- )}- {id && id.length > 0 && <>{isSaving ? "Saving" : "Saved"}</>}+ ) : null}+ {id && id.length > 0 ? <>{isSaving ? "Saving" : "Saved"}</> : null}</Text></>);diff --git a/apps/web/src/components/editor/index.js b/apps/web/src/components/editor/index.jsindex fef90bde5..3a96adf1d 100644--- a/apps/web/src/components/editor/index.js+++ b/apps/web/src/components/editor/index.js@@ -15,7 +15,7 @@ function Editor() {const sessionState = useStore(store => store.session.state);const setSession = useStore(store => store.setSession);const saveSession = useStore(store => store.saveSession);- const reopenLastSession = useStore(store => store.reopenLastSession);+ const openLastSession = useStore(store => store.openLastSession);const isFocusMode = useAppStore(store => store.isFocusMode);const quillRef = useRef();@@ -29,8 +29,8 @@ function Editor() {}, []);useEffect(() => {- reopenLastSession();- }, [reopenLastSession]);+ openLastSession();+ }, [openLastSession]);return (<Animated.Flex@@ -56,6 +56,7 @@ function Editor() {<Box id="toolbar" display={["none", "flex", "flex"]} /><EditorMenu quill={quillRef.current && quillRef.current.quill} /><ReactQuill+ id="quill"ref={quillRef}refresh={sessionState === SESSION_STATES.new}initialContent={delta}@@ -74,7 +75,7 @@ function Editor() {}}/></Flex>- {id && <Properties />}+ {id ? <Properties /> : null}</Animated.Flex>);}diff --git a/apps/web/src/stores/editor-store.js b/apps/web/src/stores/editor-store.jsindex 5dd7bd830..49864fd31 100644--- a/apps/web/src/stores/editor-store.js+++ b/apps/web/src/stores/editor-store.js@@ -3,12 +3,16 @@ import { store as noteStore } from "./note-store";import { store as appStore } from "./app-store";import { store as tagStore } from "./tag-store";import { db } from "../common";-import EditorNavigator from "../navigation/navigators/editornavigator";import BaseStore from ".";-import Vault from "../common/vault.ts";+import Vault from "../common/vault.js";const SESSION_STATES = { stale: "stale", new: "new" };-const DEFAULT_SESSION = { timeout: undefined, state: SESSION_STATES.new };+const DEFAULT_SESSION = {+ id: 0,+ timeout: undefined,+ state: SESSION_STATES.new,+ content: { delta: { ops: [] }, text: "" }+};class EditorStore extends BaseStore {session = DEFAULT_SESSION;@@ -21,11 +25,11 @@ class EditorStore extends BaseStore {openSession = async note => {clearTimeout(this.session.timeout);- if (note.conflicted) {+ /* if (note.conflicted) {return EditorNavigator.navigate("split", { note });} else {EditorNavigator.navigate("editor");- }+ } */let content = {};if (!note.locked) {@@ -152,4 +156,4 @@ function saveLastOpenedNote(id) {* @type {[import("zustand").UseStore<EditorStore>, EditorStore]}*/const [useStore, store] = createStore(EditorStore);-export { useStore, store };+export { useStore, store, SESSION_STATES };diff --git a/apps/web/src/stores/search-store.js b/apps/web/src/stores/search-store.jsindex 0eb47b43e..8756a2e29 100644--- a/apps/web/src/stores/search-store.js+++ b/apps/web/src/stores/search-store.js@@ -1,6 +1,6 @@import createStore from "../common/store";import { db } from "../common";-import BaseStore from "..ts";+import BaseStore from "./index";class SearchStore extends BaseStore {type = "";diff --git a/apps/web/yarn.lock b/apps/web/yarn.lockindex 331a9e3e5..a5dd4da00 100644--- a/apps/web/yarn.lock+++ b/apps/web/yarn.lock@@ -8372,18 +8372,7 @@ quill-markdown-shortcuts@^0.0.10:dependencies:quill "^1.3.1"-quill@^1.3.1:- version "1.3.7"- resolved "https://github.com/thecodrr/quill.git#4ff9cee6f27efb2a7bad5aef50b6af140b4629fb"- dependencies:- clone "^2.1.1"- deep-equal "^1.0.1"- eventemitter3 "^2.0.3"- extend "^3.0.2"- parchment "^1.1.4"- quill-delta "^3.6.2"--"quill@https://github.com/thecodrr/quill.git#1.3.7":+quill@^1.3.1, "quill@https://github.com/thecodrr/quill.git#1.3.7":version "1.3.7"resolved "https://github.com/thecodrr/quill.git#60cfa5a319b49760a0b0c7c4434068e2f117092f"dependencies: