mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-16 19:57:52 +01:00
refactor: rename core, theme, and logger
This commit is contained in:
11
.eslintrc.js
11
.eslintrc.js
@@ -2,13 +2,16 @@ module.exports = {
|
|||||||
env: {
|
env: {
|
||||||
browser: true,
|
browser: true,
|
||||||
es2021: true,
|
es2021: true,
|
||||||
node: true
|
node: true,
|
||||||
|
jest: true,
|
||||||
|
"jest/globals": true
|
||||||
},
|
},
|
||||||
extends: [
|
extends: [
|
||||||
"eslint:recommended",
|
"eslint:recommended",
|
||||||
"plugin:react/recommended",
|
"plugin:react/recommended",
|
||||||
"plugin:@typescript-eslint/recommended",
|
"plugin:@typescript-eslint/recommended",
|
||||||
"plugin:react/jsx-runtime"
|
"plugin:react/jsx-runtime",
|
||||||
|
"plugin:jest/style"
|
||||||
],
|
],
|
||||||
parser: "@typescript-eslint/parser",
|
parser: "@typescript-eslint/parser",
|
||||||
parserOptions: {
|
parserOptions: {
|
||||||
@@ -40,6 +43,8 @@ module.exports = {
|
|||||||
}
|
}
|
||||||
],
|
],
|
||||||
"linebreak-style": ["error", "unix"],
|
"linebreak-style": ["error", "unix"],
|
||||||
|
"jest/no-mocks-import": 0,
|
||||||
|
"@typescript-eslint/no-var-requires": 0,
|
||||||
quotes: [
|
quotes: [
|
||||||
"error",
|
"error",
|
||||||
"double",
|
"double",
|
||||||
@@ -61,8 +66,6 @@ module.exports = {
|
|||||||
"react-native/react-native": true,
|
"react-native/react-native": true,
|
||||||
es2021: true,
|
es2021: true,
|
||||||
browser: true,
|
browser: true,
|
||||||
jest: true,
|
|
||||||
"jest/globals": true,
|
|
||||||
"detox/detox": true
|
"detox/detox": true
|
||||||
},
|
},
|
||||||
rules: {
|
rules: {
|
||||||
|
|||||||
5
apps/mobile/package-lock.json
generated
5
apps/mobile/package-lock.json
generated
@@ -7,7 +7,6 @@
|
|||||||
"": {
|
"": {
|
||||||
"name": "@notesnook/mobile",
|
"name": "@notesnook/mobile",
|
||||||
"version": "2.1.7",
|
"version": "2.1.7",
|
||||||
"hasInstallScript": true,
|
|
||||||
"workspaces": [
|
"workspaces": [
|
||||||
"native/",
|
"native/",
|
||||||
"app/"
|
"app/"
|
||||||
@@ -26258,9 +26257,9 @@
|
|||||||
"react-test-renderer": "18.0.0",
|
"react-test-renderer": "18.0.0",
|
||||||
"rn-extensions-share": "^2.4.0",
|
"rn-extensions-share": "^2.4.0",
|
||||||
"rn-fetch-blob": "^0.12.0",
|
"rn-fetch-blob": "^0.12.0",
|
||||||
"terser-webpack-plugin": "5.3.5",
|
"terser-webpack-plugin": "^5.3.5",
|
||||||
"ts-jest": "^28.0.7",
|
"ts-jest": "^28.0.7",
|
||||||
"webpack": "5.74.0"
|
"webpack": "^5.74.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"@pmmmwh/react-refresh-webpack-plugin": {
|
"@pmmmwh/react-refresh-webpack-plugin": {
|
||||||
|
|||||||
14811
apps/web/package-lock.json
generated
14811
apps/web/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -11,22 +11,24 @@
|
|||||||
"@dnd-kit/core": "^6.0.5",
|
"@dnd-kit/core": "^6.0.5",
|
||||||
"@dnd-kit/modifiers": "^6.0.0",
|
"@dnd-kit/modifiers": "^6.0.0",
|
||||||
"@dnd-kit/sortable": "^7.0.1",
|
"@dnd-kit/sortable": "^7.0.1",
|
||||||
|
"@emotion/react": "^11.10.0",
|
||||||
"@mdi/js": "^6.5.95",
|
"@mdi/js": "^6.5.95",
|
||||||
"@mdi/react": "^1.4.0",
|
"@mdi/react": "^1.4.0",
|
||||||
|
"@notesnook/core": "*",
|
||||||
"@notesnook/crypto": "*",
|
"@notesnook/crypto": "*",
|
||||||
"@notesnook/crypto-worker": "*",
|
"@notesnook/crypto-worker": "*",
|
||||||
"@notesnook/desktop": "file:desktop",
|
"@notesnook/desktop": "file:desktop",
|
||||||
|
"@notesnook/editor": "*",
|
||||||
|
"@notesnook/logger": "*",
|
||||||
"@notesnook/streamable-fs": "*",
|
"@notesnook/streamable-fs": "*",
|
||||||
"@notesnook/theme": "*",
|
"@notesnook/theme": "*",
|
||||||
|
"@streetwriters/rebass": "^5.0.0",
|
||||||
"@streetwriters/rebass-forms": "^5.0.0",
|
"@streetwriters/rebass-forms": "^5.0.0",
|
||||||
"@streetwriters/editor": "*",
|
|
||||||
"@streetwriters/notesnook-core": "^7.3.6",
|
|
||||||
"allotment": "^1.12.1",
|
"allotment": "^1.12.1",
|
||||||
"async-mutex": "^0.3.2",
|
"async-mutex": "^0.3.2",
|
||||||
"axios": "^0.21.4",
|
"axios": "^0.21.4",
|
||||||
"clipboard-polyfill": "^3.0.3",
|
"clipboard-polyfill": "^3.0.3",
|
||||||
"dayjs": "^1.10.4",
|
"dayjs": "^1.10.4",
|
||||||
"@emotion/react": "^11.10.0",
|
|
||||||
"event-source-polyfill": "^1.0.25",
|
"event-source-polyfill": "^1.0.25",
|
||||||
"fflate": "^0.7.2",
|
"fflate": "^0.7.2",
|
||||||
"file-saver": "^2.0.5",
|
"file-saver": "^2.0.5",
|
||||||
@@ -53,7 +55,6 @@
|
|||||||
"react-scroll-sync": "^0.9.0",
|
"react-scroll-sync": "^0.9.0",
|
||||||
"react-toggle": "^4.1.2",
|
"react-toggle": "^4.1.2",
|
||||||
"react-virtuoso": "^2.4.0",
|
"react-virtuoso": "^2.4.0",
|
||||||
"@streetwriters/rebass": "^5.0.0",
|
|
||||||
"showdown": "github:thecodrr/showdown",
|
"showdown": "github:thecodrr/showdown",
|
||||||
"timeago.js": "^4.0.2",
|
"timeago.js": "^4.0.2",
|
||||||
"web-streams-polyfill": "^3.1.1",
|
"web-streams-polyfill": "^3.1.1",
|
||||||
@@ -67,7 +68,8 @@
|
|||||||
"@types/node-fetch": "^2.5.10",
|
"@types/node-fetch": "^2.5.10",
|
||||||
"@types/platform": "^1.3.4",
|
"@types/platform": "^1.3.4",
|
||||||
"@types/quill": "^2.0.5",
|
"@types/quill": "^2.0.5",
|
||||||
"@types/react-dom": "^18.0.0",
|
"@types/react": "17.0.2",
|
||||||
|
"@types/react-dom": "17.0.2",
|
||||||
"@types/react-modal": "^3.13.1",
|
"@types/react-modal": "^3.13.1",
|
||||||
"@types/rebass": "^4.0.10",
|
"@types/rebass": "^4.0.10",
|
||||||
"@types/rebass__forms": "^4.0.6",
|
"@types/rebass__forms": "^4.0.6",
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import { resetReminders } from "./common/reminders";
|
|||||||
import { introduceFeatures, showUpgradeReminderDialogs } from "./common";
|
import { introduceFeatures, showUpgradeReminderDialogs } from "./common";
|
||||||
import { AppEventManager, AppEvents } from "./common/app-events";
|
import { AppEventManager, AppEvents } from "./common/app-events";
|
||||||
import { db } from "./common/db";
|
import { db } from "./common/db";
|
||||||
import { CHECK_IDS, EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { CHECK_IDS, EV, EVENTS } from "@notesnook/core/common";
|
||||||
import { registerKeyMap } from "./common/key-map";
|
import { registerKeyMap } from "./common/key-map";
|
||||||
import { isUserPremium } from "./hooks/use-is-user-premium";
|
import { isUserPremium } from "./hooks/use-is-user-premium";
|
||||||
import useAnnouncements from "./hooks/use-announcements";
|
import useAnnouncements from "./hooks/use-announcements";
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import EventManager from "@streetwriters/notesnook-core/utils/event-manager";
|
import EventManager from "@notesnook/core/utils/event-manager";
|
||||||
|
|
||||||
export const AppEventManager = new EventManager();
|
export const AppEventManager = new EventManager();
|
||||||
export const AppEvents = {
|
export const AppEvents = {
|
||||||
|
|||||||
@@ -3,15 +3,13 @@ import { NNStorage } from "../interfaces/storage";
|
|||||||
import { logger } from "../utils/logger";
|
import { logger } from "../utils/logger";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @type {import("@streetwriters/notesnook-core/api").default}
|
* @type {import("@notesnook/core/api").default}
|
||||||
*/
|
*/
|
||||||
var db;
|
var db;
|
||||||
async function initializeDatabase(persistence) {
|
async function initializeDatabase(persistence) {
|
||||||
logger.measure("Database initialization");
|
logger.measure("Database initialization");
|
||||||
|
|
||||||
const { default: Database } = await import(
|
const { default: Database } = await import("@notesnook/core/api");
|
||||||
"@streetwriters/notesnook-core/api"
|
|
||||||
);
|
|
||||||
const { default: FS } = await import("../interfaces/fs");
|
const { default: FS } = await import("../interfaces/fs");
|
||||||
db = new Database(new NNStorage("Notesnook", persistence), EventSource, FS);
|
db = new Database(new NNStorage("Notesnook", persistence), EventSource, FS);
|
||||||
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ import { showToast } from "../utils/toast";
|
|||||||
import { Box, Flex, Text } from "@streetwriters/rebass";
|
import { Box, Flex, Text } from "@streetwriters/rebass";
|
||||||
import * as Icon from "../components/icons";
|
import * as Icon from "../components/icons";
|
||||||
import Config from "../utils/config";
|
import Config from "../utils/config";
|
||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import downloadUpdate from "../commands/download-update";
|
import downloadUpdate from "../commands/download-update";
|
||||||
import installUpdate from "../commands/install-update";
|
import installUpdate from "../commands/install-update";
|
||||||
import { AppVersion, getChangelog } from "../utils/version";
|
import { AppVersion, getChangelog } from "../utils/version";
|
||||||
|
|||||||
@@ -1,7 +1,4 @@
|
|||||||
import {
|
import { getDefaultPresets, ToolbarGroupDefinition } from "@notesnook/editor";
|
||||||
getDefaultPresets,
|
|
||||||
ToolbarGroupDefinition
|
|
||||||
} from "@streetwriters/editor";
|
|
||||||
import { db } from "./db";
|
import { db } from "./db";
|
||||||
|
|
||||||
const defaultPresets = getDefaultPresets();
|
const defaultPresets = getDefaultPresets();
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ import {
|
|||||||
ToolbarGroupDefinition,
|
ToolbarGroupDefinition,
|
||||||
ToolDefinition,
|
ToolDefinition,
|
||||||
ToolId
|
ToolId
|
||||||
} from "@streetwriters/editor";
|
} from "@notesnook/editor";
|
||||||
import {
|
import {
|
||||||
closestCenter,
|
closestCenter,
|
||||||
DndContext,
|
DndContext,
|
||||||
@@ -30,7 +30,7 @@ import {
|
|||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
import { CSS } from "@dnd-kit/utilities";
|
import { CSS } from "@dnd-kit/utilities";
|
||||||
import { createPortal } from "react-dom";
|
import { createPortal } from "react-dom";
|
||||||
import id from "@streetwriters/notesnook-core/utils/id";
|
import id from "@notesnook/core/utils/id";
|
||||||
import { Label, Radio } from "@streetwriters/rebass-forms";
|
import { Label, Radio } from "@streetwriters/rebass-forms";
|
||||||
import { db } from "../../common/db";
|
import { db } from "../../common/db";
|
||||||
import { useToolbarConfig } from "../editor/context";
|
import { useToolbarConfig } from "../editor/context";
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import { Flex, Button } from "@streetwriters/rebass";
|
import { Flex, Button } from "@streetwriters/rebass";
|
||||||
|
|
||||||
function ContentToggle(props) {
|
function ContentToggle(props) {
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import createStore from "../../common/store";
|
|||||||
import BaseStore from "../../stores";
|
import BaseStore from "../../stores";
|
||||||
import { UseBoundStore } from "zustand";
|
import { UseBoundStore } from "zustand";
|
||||||
import shallow from "zustand/shallow";
|
import shallow from "zustand/shallow";
|
||||||
import type { ToolbarDefinition } from "@streetwriters/editor";
|
import type { ToolbarDefinition } from "@notesnook/editor";
|
||||||
|
|
||||||
type EditorSubState = {
|
type EditorSubState = {
|
||||||
editor?: IEditor;
|
editor?: IEditor;
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import { Flex, Text } from "@streetwriters/rebass";
|
import { Flex, Text } from "@streetwriters/rebass";
|
||||||
import { useStore } from "../../stores/editor-store";
|
import { useStore } from "../../stores/editor-store";
|
||||||
import { Loading, Saved, NotSaved } from "../icons";
|
import { Loading, Saved, NotSaved } from "../icons";
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ import { useStore, store as editorstore } from "../../stores/editor-store";
|
|||||||
import Toolbar from "./toolbar";
|
import Toolbar from "./toolbar";
|
||||||
import { AppEventManager, AppEvents } from "../../common/app-events";
|
import { AppEventManager, AppEvents } from "../../common/app-events";
|
||||||
import { FlexScrollContainer } from "../scroll-container";
|
import { FlexScrollContainer } from "../scroll-container";
|
||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import { debounceWithId } from "../../utils/debounce";
|
import { debounceWithId } from "../../utils/debounce";
|
||||||
import Tiptap from "./tiptap";
|
import Tiptap from "./tiptap";
|
||||||
import Header from "./header";
|
import Header from "./header";
|
||||||
@@ -20,7 +20,7 @@ import { useEditorInstance } from "./context";
|
|||||||
import { attachFile, AttachmentProgress, insertAttachment } from "./picker";
|
import { attachFile, AttachmentProgress, insertAttachment } from "./picker";
|
||||||
import { DropEvent } from "react-dropzone";
|
import { DropEvent } from "react-dropzone";
|
||||||
import { downloadAttachment } from "../../common/attachments";
|
import { downloadAttachment } from "../../common/attachments";
|
||||||
import { EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { EV, EVENTS } from "@notesnook/core/common";
|
||||||
import { db } from "../../common/db";
|
import { db } from "../../common/db";
|
||||||
import useMobile from "../../hooks/use-mobile";
|
import useMobile from "../../hooks/use-mobile";
|
||||||
import Titlebox from "./title-box";
|
import Titlebox from "./title-box";
|
||||||
@@ -74,7 +74,7 @@ export default function EditorManager({
|
|||||||
const isReadonly = useStore((store) => store.session.readonly);
|
const isReadonly = useStore((store) => store.session.readonly);
|
||||||
const isPreviewSession = !!previewSession.current;
|
const isPreviewSession = !!previewSession.current;
|
||||||
|
|
||||||
const openSession = useCallback(async (noteId) => {
|
const openSession = useCallback(async (noteId: string | number) => {
|
||||||
await editorstore.get().openSession(noteId);
|
await editorstore.get().openSession(noteId);
|
||||||
|
|
||||||
const { getSessionContent, session } = editorstore.get();
|
const { getSessionContent, session } = editorstore.get();
|
||||||
@@ -336,7 +336,7 @@ type PreviewModeNoticeProps = PreviewSession & {
|
|||||||
function PreviewModeNotice(props: PreviewModeNoticeProps) {
|
function PreviewModeNotice(props: PreviewModeNoticeProps) {
|
||||||
const { dateCreated, dateEdited, content, onDiscard } = props;
|
const { dateCreated, dateEdited, content, onDiscard } = props;
|
||||||
const disablePreviewMode = useCallback(
|
const disablePreviewMode = useCallback(
|
||||||
async (cancelled) => {
|
async (cancelled: boolean) => {
|
||||||
const { id, sessionId } = editorstore.get().session;
|
const { id, sessionId } = editorstore.get().session;
|
||||||
if (!cancelled) {
|
if (!cancelled) {
|
||||||
await editorstore.saveSessionContent(id, sessionId, content);
|
await editorstore.saveSessionContent(id, sessionId, content);
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
import "@streetwriters/editor/styles/styles.css";
|
import "@notesnook/editor/styles/styles.css";
|
||||||
import "@streetwriters/editor/styles/katex.min.css";
|
import "@notesnook/editor/styles/katex.min.css";
|
||||||
import "@streetwriters/editor/styles/katex-fonts.css";
|
import "@notesnook/editor/styles/katex-fonts.css";
|
||||||
import "@streetwriters/editor/styles/fonts.css";
|
import "@notesnook/editor/styles/fonts.css";
|
||||||
import "@streetwriters/editor/styles/prism-theme.css";
|
import "@notesnook/editor/styles/prism-theme.css";
|
||||||
import { Theme } from "@notesnook/theme";
|
import { Theme } from "@notesnook/theme";
|
||||||
import { useTheme } from "@emotion/react";
|
import { useTheme } from "@emotion/react";
|
||||||
import {
|
import {
|
||||||
@@ -12,7 +12,7 @@ import {
|
|||||||
Editor,
|
Editor,
|
||||||
AttachmentType,
|
AttachmentType,
|
||||||
usePermissionHandler
|
usePermissionHandler
|
||||||
} from "@streetwriters/editor";
|
} from "@notesnook/editor";
|
||||||
import { Box, Flex } from "@streetwriters/rebass";
|
import { Box, Flex } from "@streetwriters/rebass";
|
||||||
import { PropsWithChildren, useEffect, useRef, useState } from "react";
|
import { PropsWithChildren, useEffect, useRef, useState } from "react";
|
||||||
import useMobile from "../../hooks/use-mobile";
|
import useMobile from "../../hooks/use-mobile";
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ import Toggle from "./toggle";
|
|||||||
import { navigate } from "../../navigation";
|
import { navigate } from "../../navigation";
|
||||||
import IconTag from "../icon-tag";
|
import IconTag from "../icon-tag";
|
||||||
import ScrollContainer from "../scroll-container";
|
import ScrollContainer from "../scroll-container";
|
||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import Vault from "../../common/vault";
|
import Vault from "../../common/vault";
|
||||||
import TimeAgo from "../time-ago";
|
import TimeAgo from "../time-ago";
|
||||||
import Attachment from "../attachment";
|
import Attachment from "../attachment";
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ import { db } from "../../common/db";
|
|||||||
import * as clipboard from "clipboard-polyfill/text";
|
import * as clipboard from "clipboard-polyfill/text";
|
||||||
import ThemeProvider from "../theme-provider";
|
import ThemeProvider from "../theme-provider";
|
||||||
import { showToast } from "../../utils/toast";
|
import { showToast } from "../../utils/toast";
|
||||||
import { EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { EV, EVENTS } from "@notesnook/core/common";
|
||||||
import { useStore } from "../../stores/monograph-store";
|
import { useStore } from "../../stores/monograph-store";
|
||||||
import { closeOpenedDialog } from "../../common/dialog-controller";
|
import { closeOpenedDialog } from "../../common/dialog-controller";
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import React, { useEffect, useRef } from "react";
|
import React, { useEffect, useRef } from "react";
|
||||||
import { Text } from "@streetwriters/rebass";
|
import { Text } from "@streetwriters/rebass";
|
||||||
import { register, format, cancel, render } from "timeago.js";
|
import { register, format, cancel, render } from "timeago.js";
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import "@streetwriters/notesnook-core/types";
|
import "@notesnook/core/types";
|
||||||
import { EVENTS } from "@notesnook/desktop/events";
|
import { EVENTS } from "@notesnook/desktop/events";
|
||||||
import { AppEventManager } from "./common/app-events";
|
import { AppEventManager } from "./common/app-events";
|
||||||
import { render } from "react-dom";
|
import { render } from "react-dom";
|
||||||
|
|||||||
@@ -5,8 +5,8 @@ import axios from "axios";
|
|||||||
import { AppEventManager, AppEvents } from "../common/app-events";
|
import { AppEventManager, AppEvents } from "../common/app-events";
|
||||||
import { StreamableFS } from "@notesnook/streamable-fs";
|
import { StreamableFS } from "@notesnook/streamable-fs";
|
||||||
import { getNNCrypto } from "./nncrypto.stub";
|
import { getNNCrypto } from "./nncrypto.stub";
|
||||||
import hosts from "@streetwriters/notesnook-core/utils/constants";
|
import hosts from "@notesnook/core/utils/constants";
|
||||||
import { sendAttachmentsProgressEvent } from "@streetwriters/notesnook-core/common";
|
import { sendAttachmentsProgressEvent } from "@notesnook/core/common";
|
||||||
import { saveAs } from "file-saver";
|
import { saveAs } from "file-saver";
|
||||||
import { showToast } from "../utils/toast";
|
import { showToast } from "../utils/toast";
|
||||||
import { db } from "../common/db";
|
import { db } from "../common/db";
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import { useState } from "react";
|
import { useState } from "react";
|
||||||
import EventManager from "@streetwriters/notesnook-core/utils/event-manager";
|
import EventManager from "@notesnook/core/utils/event-manager";
|
||||||
import Config from "../utils/config";
|
import Config from "../utils/config";
|
||||||
|
|
||||||
export function navigate(url, replaceOrQuery, replace) {
|
export function navigate(url, replaceOrQuery, replace) {
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import { store as monographStore } from "./monograph-store";
|
|||||||
import BaseStore from "./index";
|
import BaseStore from "./index";
|
||||||
import { showToast } from "../utils/toast";
|
import { showToast } from "../utils/toast";
|
||||||
import { resetReminders } from "../common/reminders";
|
import { resetReminders } from "../common/reminders";
|
||||||
import { EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { EV, EVENTS } from "@notesnook/core/common";
|
||||||
import { logger } from "../utils/logger";
|
import { logger } from "../utils/logger";
|
||||||
|
|
||||||
var syncStatusTimeout = 0;
|
var syncStatusTimeout = 0;
|
||||||
|
|||||||
@@ -5,7 +5,7 @@ import { store as appStore } from "./app-store";
|
|||||||
import { store as tagStore } from "./tag-store";
|
import { store as tagStore } from "./tag-store";
|
||||||
import { db } from "../common/db";
|
import { db } from "../common/db";
|
||||||
import BaseStore from ".";
|
import BaseStore from ".";
|
||||||
import { EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { EV, EVENTS } from "@notesnook/core/common";
|
||||||
import { hashNavigate } from "../navigation";
|
import { hashNavigate } from "../navigation";
|
||||||
import { logger } from "../utils/logger";
|
import { logger } from "../utils/logger";
|
||||||
|
|
||||||
|
|||||||
@@ -5,10 +5,10 @@ import { store as appStore } from "./app-store";
|
|||||||
import { store as selectionStore } from "./selection-store";
|
import { store as selectionStore } from "./selection-store";
|
||||||
import Vault from "../common/vault";
|
import Vault from "../common/vault";
|
||||||
import BaseStore from ".";
|
import BaseStore from ".";
|
||||||
import { EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { EV, EVENTS } from "@notesnook/core/common";
|
||||||
import Config from "../utils/config";
|
import Config from "../utils/config";
|
||||||
import { hashNavigate } from "../navigation";
|
import { hashNavigate } from "../navigation";
|
||||||
import { groupArray } from "@streetwriters/notesnook-core/utils/grouping";
|
import { groupArray } from "@notesnook/core/utils/grouping";
|
||||||
|
|
||||||
class NoteStore extends BaseStore {
|
class NoteStore extends BaseStore {
|
||||||
notes = [];
|
notes = [];
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import createStore from "../common/store";
|
|||||||
import { store as appStore } from "./app-store";
|
import { store as appStore } from "./app-store";
|
||||||
import { store as noteStore } from "./note-store";
|
import { store as noteStore } from "./note-store";
|
||||||
import BaseStore from "./index";
|
import BaseStore from "./index";
|
||||||
import { groupArray } from "@streetwriters/notesnook-core/utils/grouping";
|
import { groupArray } from "@notesnook/core/utils/grouping";
|
||||||
import Config from "../utils/config";
|
import Config from "../utils/config";
|
||||||
|
|
||||||
class NotebookStore extends BaseStore {
|
class NotebookStore extends BaseStore {
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import createStore from "../common/store";
|
import createStore from "../common/store";
|
||||||
import { db } from "../common/db";
|
import { db } from "../common/db";
|
||||||
import BaseStore from "./index";
|
import BaseStore from "./index";
|
||||||
import { groupArray } from "@streetwriters/notesnook-core/utils/grouping";
|
import { groupArray } from "@notesnook/core/utils/grouping";
|
||||||
|
|
||||||
class TagStore extends BaseStore {
|
class TagStore extends BaseStore {
|
||||||
tags = [];
|
tags = [];
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import createStore from "../common/store";
|
|||||||
import BaseStore from "./index";
|
import BaseStore from "./index";
|
||||||
import { store as appStore } from "./app-store";
|
import { store as appStore } from "./app-store";
|
||||||
import { store as notestore } from "./note-store";
|
import { store as notestore } from "./note-store";
|
||||||
import { groupArray } from "@streetwriters/notesnook-core/utils/grouping";
|
import { groupArray } from "@notesnook/core/utils/grouping";
|
||||||
|
|
||||||
class TrashStore extends BaseStore {
|
class TrashStore extends BaseStore {
|
||||||
trash = [];
|
trash = [];
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import createStore from "../common/store";
|
|||||||
import { db } from "../common/db";
|
import { db } from "../common/db";
|
||||||
import BaseStore from "./index";
|
import BaseStore from "./index";
|
||||||
import config from "../utils/config";
|
import config from "../utils/config";
|
||||||
import { EV, EVENTS } from "@streetwriters/notesnook-core/common";
|
import { EV, EVENTS } from "@notesnook/core/common";
|
||||||
import {
|
import {
|
||||||
showAccountLoggedOutNotice,
|
showAccountLoggedOutNotice,
|
||||||
showOnboardingDialog
|
showOnboardingDialog
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
import EventManager from "@streetwriters/notesnook-core/utils/event-manager";
|
import EventManager from "@notesnook/core/utils/event-manager";
|
||||||
|
|
||||||
const GlobalKeyboard = {};
|
const GlobalKeyboard = {};
|
||||||
|
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ import {
|
|||||||
initalize,
|
initalize,
|
||||||
logger as _logger,
|
logger as _logger,
|
||||||
logManager
|
logManager
|
||||||
} from "@streetwriters/notesnook-core/logger";
|
} from "@notesnook/core/logger";
|
||||||
import FileSaver from "file-saver";
|
import FileSaver from "file-saver";
|
||||||
import { DatabasePersistence, NNStorage } from "../interfaces/storage";
|
import { DatabasePersistence, NNStorage } from "../interfaces/storage";
|
||||||
import { zip } from "./zip";
|
import { zip } from "./zip";
|
||||||
|
|||||||
@@ -536,7 +536,7 @@ function MFACode(props: BaseAuthComponentProps<"mfa:code">) {
|
|||||||
);
|
);
|
||||||
|
|
||||||
const sendCode = useCallback(
|
const sendCode = useCallback(
|
||||||
async (selectedMethod, token) => {
|
async (selectedMethod: "sms" | "email", token: string) => {
|
||||||
setIsSending(true);
|
setIsSending(true);
|
||||||
try {
|
try {
|
||||||
await db.mfa!.sendCode(selectedMethod, token);
|
await db.mfa!.sendCode(selectedMethod, token);
|
||||||
@@ -561,7 +561,10 @@ function MFACode(props: BaseAuthComponentProps<"mfa:code">) {
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
(async function () {
|
(async function () {
|
||||||
await sendCode(formData.selectedMethod, formData.token);
|
await sendCode(
|
||||||
|
formData.selectedMethod as "sms" | "email",
|
||||||
|
formData.token
|
||||||
|
);
|
||||||
})();
|
})();
|
||||||
}, [formData, sendCode]);
|
}, [formData, sendCode]);
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ import { useStore as useNotesStore } from "../stores/note-store";
|
|||||||
import NotesPlaceholder from "../components/placeholders/notesplacholder";
|
import NotesPlaceholder from "../components/placeholders/notesplacholder";
|
||||||
import { hashNavigate, navigate } from "../navigation";
|
import { hashNavigate, navigate } from "../navigation";
|
||||||
import FavoritesPlaceholder from "../components/placeholders/favorites-placeholder";
|
import FavoritesPlaceholder from "../components/placeholders/favorites-placeholder";
|
||||||
import { groupArray } from "@streetwriters/notesnook-core/utils/grouping";
|
import { groupArray } from "@notesnook/core/utils/grouping";
|
||||||
import { db } from "../common/db";
|
import { db } from "../common/db";
|
||||||
import { Flex, Text } from "@streetwriters/rebass";
|
import { Flex, Text } from "@streetwriters/rebass";
|
||||||
import { SyncError } from "../components/icons";
|
import { SyncError } from "../components/icons";
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ import ScrollContainer from "../components/scroll-container";
|
|||||||
import { showToast } from "../utils/toast";
|
import { showToast } from "../utils/toast";
|
||||||
import { hardNavigate, hashNavigate } from "../navigation";
|
import { hardNavigate, hashNavigate } from "../navigation";
|
||||||
import { appVersion } from "../utils/version";
|
import { appVersion } from "../utils/version";
|
||||||
import { CHECK_IDS } from "@streetwriters/notesnook-core/common";
|
import { CHECK_IDS } from "@notesnook/core/common";
|
||||||
import Tip from "../components/tip";
|
import Tip from "../components/tip";
|
||||||
import Toggle from "../components/toggle";
|
import Toggle from "../components/toggle";
|
||||||
import { isDesktop } from "../utils/platform";
|
import { isDesktop } from "../utils/platform";
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import TopicsPlaceholder from "../components/placeholders/topics-placeholder";
|
|||||||
import { Button, Flex, Text } from "@streetwriters/rebass";
|
import { Button, Flex, Text } from "@streetwriters/rebass";
|
||||||
import { Edit, RemoveShortcutLink, ShortcutLink } from "../components/icons";
|
import { Edit, RemoveShortcutLink, ShortcutLink } from "../components/icons";
|
||||||
import { getTotalNotes } from "../common";
|
import { getTotalNotes } from "../common";
|
||||||
import { formatDate } from "@streetwriters/notesnook-core/utils/date";
|
import { formatDate } from "@notesnook/core/utils/date";
|
||||||
import { db } from "../common/db";
|
import { db } from "../common/db";
|
||||||
import { pluralize } from "../utils/string";
|
import { pluralize } from "../utils/string";
|
||||||
|
|
||||||
|
|||||||
@@ -19,10 +19,12 @@ const SCOPES = [
|
|||||||
"editor",
|
"editor",
|
||||||
"logger",
|
"logger",
|
||||||
"theme",
|
"theme",
|
||||||
|
"core",
|
||||||
"config",
|
"config",
|
||||||
"ci",
|
"ci",
|
||||||
"setup",
|
"setup",
|
||||||
"docs"
|
"docs",
|
||||||
|
"refactor"
|
||||||
];
|
];
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
|
|||||||
@@ -1,21 +0,0 @@
|
|||||||
module.exports = {
|
|
||||||
env: {
|
|
||||||
browser: true,
|
|
||||||
es2021: true,
|
|
||||||
node: true,
|
|
||||||
"jest/globals": true,
|
|
||||||
},
|
|
||||||
extends: [
|
|
||||||
"eslint:recommended",
|
|
||||||
"plugin:jest/recommended",
|
|
||||||
"plugin:jest/style",
|
|
||||||
],
|
|
||||||
parserOptions: {
|
|
||||||
ecmaVersion: "latest",
|
|
||||||
sourceType: "module",
|
|
||||||
},
|
|
||||||
plugins: ["jest"],
|
|
||||||
rules: {
|
|
||||||
"jest/no-mocks-import": 0,
|
|
||||||
},
|
|
||||||
};
|
|
||||||
@@ -1,13 +1,4 @@
|
|||||||
import { groupArray } from "../utils/grouping";
|
import { StorageInterface, databaseTest } from "./utils";
|
||||||
import {
|
|
||||||
StorageInterface,
|
|
||||||
databaseTest,
|
|
||||||
noteTest,
|
|
||||||
groupedTest,
|
|
||||||
TEST_NOTE,
|
|
||||||
TEST_NOTEBOOK,
|
|
||||||
IMG_CONTENT,
|
|
||||||
} from "./utils";
|
|
||||||
|
|
||||||
beforeEach(() => {
|
beforeEach(() => {
|
||||||
StorageInterface.clear();
|
StorageInterface.clear();
|
||||||
@@ -21,7 +12,7 @@ test("adding a deleted content should not throw", () =>
|
|||||||
deleted: true,
|
deleted: true,
|
||||||
dateEdited: new Date(),
|
dateEdited: new Date(),
|
||||||
id: "hello",
|
id: "hello",
|
||||||
data: "YOYO!",
|
data: "YOYO!"
|
||||||
})
|
})
|
||||||
).resolves.toBeUndefined();
|
).resolves.toBeUndefined();
|
||||||
}));
|
}));
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ import {
|
|||||||
consoleReporter,
|
consoleReporter,
|
||||||
format,
|
format,
|
||||||
LogLevel,
|
LogLevel,
|
||||||
NoopLogger,
|
NoopLogger
|
||||||
} from "@streetwriters/logger";
|
} from "@notesnook/logger";
|
||||||
|
|
||||||
// Database logger reporter:
|
// Database logger reporter:
|
||||||
// 1. Log to new key on every instance
|
// 1. Log to new key on every instance
|
||||||
@@ -26,7 +26,7 @@ class DatabaseLogReporter {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {import("@streetwriters/logger").LogMessage} log
|
* @param {import("@notesnook/logger").LogMessage} log
|
||||||
*/
|
*/
|
||||||
write(log) {
|
write(log) {
|
||||||
this.writer.push(log);
|
this.writer.push(log);
|
||||||
@@ -127,14 +127,14 @@ function initalize(storage) {
|
|||||||
if (process.env.NODE_ENV !== "production") reporters.push(consoleReporter);
|
if (process.env.NODE_ENV !== "production") reporters.push(consoleReporter);
|
||||||
logger = new Logger({
|
logger = new Logger({
|
||||||
reporter: combineReporters(reporters),
|
reporter: combineReporters(reporters),
|
||||||
lastTime: Date.now(),
|
lastTime: Date.now()
|
||||||
});
|
});
|
||||||
logManager = new DatabaseLogManager(storage);
|
logManager = new DatabaseLogManager(storage);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @type {import("@streetwriters/logger").ILogger}
|
* @type {import("@notesnook/logger").ILogger}
|
||||||
*/
|
*/
|
||||||
var logger = new NoopLogger();
|
var logger = new NoopLogger();
|
||||||
|
|
||||||
|
|||||||
9675
packages/core/package-lock.json
generated
9675
packages/core/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "@streetwriters/notesnook-core",
|
"name": "@notesnook/core",
|
||||||
"version": "7.3.6",
|
"version": "7.3.6",
|
||||||
"main": "./api/index.js",
|
"main": "./api/index.js",
|
||||||
"license": "GPL-3.0",
|
"license": "GPL-3.0",
|
||||||
@@ -22,8 +22,6 @@
|
|||||||
"babel-polyfill": "^6.26.0",
|
"babel-polyfill": "^6.26.0",
|
||||||
"babel-preset-env": "^1.7.0",
|
"babel-preset-env": "^1.7.0",
|
||||||
"dotenv": "^16.0.1",
|
"dotenv": "^16.0.1",
|
||||||
"eslint": "^8.20.0",
|
|
||||||
"eslint-plugin-jest": "^26.6.0",
|
|
||||||
"eventsource": "^2.0.2",
|
"eventsource": "^2.0.2",
|
||||||
"jest": "^28.1.3",
|
"jest": "^28.1.3",
|
||||||
"jest-fetch-mock": "^3.0.3",
|
"jest-fetch-mock": "^3.0.3",
|
||||||
@@ -35,7 +33,7 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@microsoft/signalr": "^6.0.7",
|
"@microsoft/signalr": "^6.0.7",
|
||||||
"@microsoft/signalr-protocol-msgpack": "^6.0.7",
|
"@microsoft/signalr-protocol-msgpack": "^6.0.7",
|
||||||
"@streetwriters/logger": "^1.0.3",
|
"@notesnook/logger": "*",
|
||||||
"async-mutex": "^0.3.2",
|
"async-mutex": "^0.3.2",
|
||||||
"base64-arraybuffer": "^1.0.2",
|
"base64-arraybuffer": "^1.0.2",
|
||||||
"dayjs": "^1.11.3",
|
"dayjs": "^1.11.3",
|
||||||
|
|||||||
89
packages/crypto-worker/package-lock.json
generated
89
packages/crypto-worker/package-lock.json
generated
@@ -1,89 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "@notesnook/crypto-worker",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"lockfileVersion": 2,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"name": "@notesnook/crypto-worker",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"comlink": "^4.3.1"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"typescript": "^4.8.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"../nncrypto": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"extraneous": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"libsodium-wrappers": "^0.7.9"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/libsodium-wrappers": "^0.7.9",
|
|
||||||
"streamablefs": "file:../streamablefs"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"../streamable-fs": {
|
|
||||||
"name": "@notesnook/streamable-fs",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"extraneous": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"@notesnook/crypto": "^1.0.0",
|
|
||||||
"localforage": "^1.10.0"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/localforage": "^0.0.34",
|
|
||||||
"typescript": "^4.4.3"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"../streamablefs": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"extraneous": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"@notesnook/crypto": "^1.0.0",
|
|
||||||
"localforage": "^1.10.0"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/localforage": "^0.0.34",
|
|
||||||
"typescript": "^4.4.3"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/comlink": {
|
|
||||||
"version": "4.3.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/comlink/-/comlink-4.3.1.tgz",
|
|
||||||
"integrity": "sha512-+YbhUdNrpBZggBAHWcgQMLPLH1KDF3wJpeqrCKieWQ8RL7atmgsgTQko1XEBK6PsecfopWNntopJ+ByYG1lRaA=="
|
|
||||||
},
|
|
||||||
"node_modules/typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true,
|
|
||||||
"bin": {
|
|
||||||
"tsc": "bin/tsc",
|
|
||||||
"tsserver": "bin/tsserver"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4.2.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"comlink": {
|
|
||||||
"version": "4.3.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/comlink/-/comlink-4.3.1.tgz",
|
|
||||||
"integrity": "sha512-+YbhUdNrpBZggBAHWcgQMLPLH1KDF3wJpeqrCKieWQ8RL7atmgsgTQko1XEBK6PsecfopWNntopJ+ByYG1lRaA=="
|
|
||||||
},
|
|
||||||
"typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
91
packages/crypto/package-lock.json
generated
91
packages/crypto/package-lock.json
generated
@@ -1,91 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "@notesnook/crypto",
|
|
||||||
"version": "1.0.1",
|
|
||||||
"lockfileVersion": 2,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"name": "@notesnook/crypto",
|
|
||||||
"version": "1.0.1",
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"libsodium-wrappers": "0.7.9"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/libsodium-wrappers": "0.7.9",
|
|
||||||
"typescript": "^4.8.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"../streamablefs": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"extraneous": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"localforage": "^1.10.0"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/localforage": "^0.0.34",
|
|
||||||
"typescript": "^4.4.3"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@types/libsodium-wrappers": {
|
|
||||||
"version": "0.7.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/@types/libsodium-wrappers/-/libsodium-wrappers-0.7.9.tgz",
|
|
||||||
"integrity": "sha512-LisgKLlYQk19baQwjkBZZXdJL0KbeTpdEnrAfz5hQACbklCY0gVFnsKUyjfNWF1UQsCSjw93Sj5jSbiO8RPfdw==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"node_modules/libsodium": {
|
|
||||||
"version": "0.7.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/libsodium/-/libsodium-0.7.9.tgz",
|
|
||||||
"integrity": "sha512-gfeADtR4D/CM0oRUviKBViMGXZDgnFdMKMzHsvBdqLBHd9ySi6EtYnmuhHVDDYgYpAO8eU8hEY+F8vIUAPh08A=="
|
|
||||||
},
|
|
||||||
"node_modules/libsodium-wrappers": {
|
|
||||||
"version": "0.7.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/libsodium-wrappers/-/libsodium-wrappers-0.7.9.tgz",
|
|
||||||
"integrity": "sha512-9HaAeBGk1nKTRFRHkt7nzxqCvnkWTjn1pdjKgcUnZxj0FyOP4CnhgFhMdrFfgNsukijBGyBLpP2m2uKT1vuWhQ==",
|
|
||||||
"dependencies": {
|
|
||||||
"libsodium": "^0.7.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true,
|
|
||||||
"bin": {
|
|
||||||
"tsc": "bin/tsc",
|
|
||||||
"tsserver": "bin/tsserver"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4.2.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"@types/libsodium-wrappers": {
|
|
||||||
"version": "0.7.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/@types/libsodium-wrappers/-/libsodium-wrappers-0.7.9.tgz",
|
|
||||||
"integrity": "sha512-LisgKLlYQk19baQwjkBZZXdJL0KbeTpdEnrAfz5hQACbklCY0gVFnsKUyjfNWF1UQsCSjw93Sj5jSbiO8RPfdw==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"libsodium": {
|
|
||||||
"version": "0.7.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/libsodium/-/libsodium-0.7.9.tgz",
|
|
||||||
"integrity": "sha512-gfeADtR4D/CM0oRUviKBViMGXZDgnFdMKMzHsvBdqLBHd9ySi6EtYnmuhHVDDYgYpAO8eU8hEY+F8vIUAPh08A=="
|
|
||||||
},
|
|
||||||
"libsodium-wrappers": {
|
|
||||||
"version": "0.7.9",
|
|
||||||
"resolved": "https://registry.npmjs.org/libsodium-wrappers/-/libsodium-wrappers-0.7.9.tgz",
|
|
||||||
"integrity": "sha512-9HaAeBGk1nKTRFRHkt7nzxqCvnkWTjn1pdjKgcUnZxj0FyOP4CnhgFhMdrFfgNsukijBGyBLpP2m2uKT1vuWhQ==",
|
|
||||||
"requires": {
|
|
||||||
"libsodium": "^0.7.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
2746
packages/editor/package-lock.json
generated
2746
packages/editor/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -1,5 +1,5 @@
|
|||||||
{
|
{
|
||||||
"name": "@streetwriters/editor",
|
"name": "@notesnook/editor",
|
||||||
"version": "1.3.1",
|
"version": "1.3.1",
|
||||||
"main": "dist/index.js",
|
"main": "dist/index.js",
|
||||||
"license": "GPL-3.0",
|
"license": "GPL-3.0",
|
||||||
@@ -9,10 +9,13 @@
|
|||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@_ueberdosis/prosemirror-tables": "^1.1.3",
|
"@_ueberdosis/prosemirror-tables": "^1.1.3",
|
||||||
|
"@emotion/react": "^11.10.0",
|
||||||
"@mdi/js": "^6.9.96",
|
"@mdi/js": "^6.9.96",
|
||||||
"@mdi/react": "^1.6.0",
|
"@mdi/react": "^1.6.0",
|
||||||
"@streetwriters/rebass-forms": "^5.0.0",
|
"@notesnook/theme": "*",
|
||||||
"@social-embed/lib": "^0.0.1-next.12",
|
"@social-embed/lib": "^0.0.1-next.12",
|
||||||
|
"@streetwriters/rebass": "^5.0.0",
|
||||||
|
"@streetwriters/rebass-forms": "^5.0.0",
|
||||||
"@tiptap/core": "^2.0.0-beta.181",
|
"@tiptap/core": "^2.0.0-beta.181",
|
||||||
"@tiptap/extension-character-count": "^2.0.0-beta.31",
|
"@tiptap/extension-character-count": "^2.0.0-beta.31",
|
||||||
"@tiptap/extension-color": "^2.0.0-beta.12",
|
"@tiptap/extension-color": "^2.0.0-beta.12",
|
||||||
@@ -34,41 +37,40 @@
|
|||||||
"@tiptap/extension-underline": "^2.0.0-beta.25",
|
"@tiptap/extension-underline": "^2.0.0-beta.25",
|
||||||
"@tiptap/starter-kit": "^2.0.0-beta.190",
|
"@tiptap/starter-kit": "^2.0.0-beta.190",
|
||||||
"detect-indent": "^7.0.0",
|
"detect-indent": "^7.0.0",
|
||||||
"@emotion/react": "^11.10.0",
|
|
||||||
"katex": "^0.16.0",
|
"katex": "^0.16.0",
|
||||||
"prism-themes": "^1.9.0",
|
"prism-themes": "^1.9.0",
|
||||||
"prosemirror-codemark": "^0.4.0",
|
"prosemirror-codemark": "^0.4.0",
|
||||||
|
"prosemirror-commands": "^1.3.0",
|
||||||
"prosemirror-utils": "github:atlassian/prosemirror-utils",
|
"prosemirror-utils": "github:atlassian/prosemirror-utils",
|
||||||
|
"prosemirror-view": "^1.26.2",
|
||||||
"re-resizable": "^6.9.9",
|
"re-resizable": "^6.9.9",
|
||||||
"react-colorful": "^5.5.1",
|
"react-colorful": "^5.5.1",
|
||||||
"react-modal": "^3.15.1",
|
"react-modal": "^3.15.1",
|
||||||
"@streetwriters/rebass": "^5.0.0",
|
|
||||||
"redent": "^4.0.0",
|
"redent": "^4.0.0",
|
||||||
"refractor": "^4.7.0",
|
"refractor": "^4.7.0",
|
||||||
"strip-indent": "^4.0.0",
|
"strip-indent": "^4.0.0",
|
||||||
"tinycolor2": "^1.4.2",
|
"tinycolor2": "^1.4.2",
|
||||||
"unfurl.js": "^5.7.0",
|
"unfurl.js": "^5.7.0",
|
||||||
"zustand": "^3.7.2",
|
"zustand": "^3.7.2"
|
||||||
"@notesnook/theme": "*"
|
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/katex": "^0.14.0",
|
"@types/katex": "^0.14.0",
|
||||||
"@types/prismjs": "^1.26.0",
|
"@types/prismjs": "^1.26.0",
|
||||||
"@types/react": "^17.0.37",
|
|
||||||
"@types/react-color": "^3.0.6",
|
"@types/react-color": "^3.0.6",
|
||||||
"@types/react-dom": "^17.0.11",
|
"@types/react": "17.0.2",
|
||||||
|
"@types/react-dom": "17.0.2",
|
||||||
"@types/react-modal": "^3.13.1",
|
"@types/react-modal": "^3.13.1",
|
||||||
"@types/rebass": "^4.0.10",
|
"@types/rebass": "^4.0.10",
|
||||||
"@types/rebass__forms": "^4.0.6",
|
"@types/rebass__forms": "^4.0.6",
|
||||||
"@types/tinycolor2": "^1.4.3",
|
"@types/tinycolor2": "^1.4.3",
|
||||||
|
"framer-motion": "^4.1.17",
|
||||||
"isomorphic-fetch": "^3.0.0",
|
"isomorphic-fetch": "^3.0.0",
|
||||||
"typescript": "^4.8.2",
|
"typescript": "^4.8.2",
|
||||||
"web-vitals": "^2.1.4",
|
"web-vitals": "^2.1.4"
|
||||||
"framer-motion": "^4.1.17"
|
|
||||||
},
|
},
|
||||||
"peerDependencies": {
|
"peerDependencies": {
|
||||||
"react": "^17.0.2",
|
"react": ">=17.0.0",
|
||||||
"react-dom": "^17.0.2"
|
"react-dom": ">=17.0.0"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "./scripts/build.sh",
|
"build": "./scripts/build.sh",
|
||||||
|
|||||||
37
packages/logger/package-lock.json
generated
37
packages/logger/package-lock.json
generated
@@ -1,37 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "@streetwriters/logger",
|
|
||||||
"version": "1.0.3",
|
|
||||||
"lockfileVersion": 2,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"name": "@streetwriters/logger",
|
|
||||||
"version": "1.0.3",
|
|
||||||
"license": "MIT",
|
|
||||||
"devDependencies": {
|
|
||||||
"typescript": "^4.8.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true,
|
|
||||||
"bin": {
|
|
||||||
"tsc": "bin/tsc",
|
|
||||||
"tsserver": "bin/tsserver"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4.2.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,10 +1,11 @@
|
|||||||
{
|
{
|
||||||
"name": "@streetwriters/logger",
|
"name": "@notesnook/logger",
|
||||||
"version": "1.0.3",
|
"version": "1.0.3",
|
||||||
"description": "A really simple logger with a pluggable interface.",
|
"description": "A really simple logger with a pluggable interface.",
|
||||||
"main": "dist/index.js",
|
"main": "dist/index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"pub": "tsc && np"
|
"pub": "tsc && np",
|
||||||
|
"build": "tsc"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|||||||
113
packages/streamable-fs/package-lock.json
generated
113
packages/streamable-fs/package-lock.json
generated
@@ -1,113 +0,0 @@
|
|||||||
{
|
|
||||||
"name": "@notesnook/streamable-fs",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"lockfileVersion": 2,
|
|
||||||
"requires": true,
|
|
||||||
"packages": {
|
|
||||||
"": {
|
|
||||||
"name": "@notesnook/streamable-fs",
|
|
||||||
"version": "1.0.0",
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"localforage": "^1.10.0"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/localforage": "^0.0.34",
|
|
||||||
"typescript": "^4.8.2"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"../nncrypto": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"extraneous": true,
|
|
||||||
"license": "ISC",
|
|
||||||
"dependencies": {
|
|
||||||
"libsodium-wrappers": "^0.7.9"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@types/libsodium-wrappers": "^0.7.9"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@types/localforage": {
|
|
||||||
"version": "0.0.34",
|
|
||||||
"resolved": "https://registry.npmjs.org/@types/localforage/-/localforage-0.0.34.tgz",
|
|
||||||
"integrity": "sha1-XjHDLdh5HsS5/z70fJy1Wy0NlDg=",
|
|
||||||
"deprecated": "This is a stub types definition for localforage (https://github.com/localForage/localForage). localforage provides its own type definitions, so you don't need @types/localforage installed!",
|
|
||||||
"dev": true,
|
|
||||||
"dependencies": {
|
|
||||||
"localforage": "*"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/immediate": {
|
|
||||||
"version": "3.0.6",
|
|
||||||
"resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz",
|
|
||||||
"integrity": "sha1-nbHb0Pr43m++D13V5Wu2BigN5ps="
|
|
||||||
},
|
|
||||||
"node_modules/lie": {
|
|
||||||
"version": "3.1.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/lie/-/lie-3.1.1.tgz",
|
|
||||||
"integrity": "sha1-mkNrLMd0bKWd56QfpGmz77dr2H4=",
|
|
||||||
"dependencies": {
|
|
||||||
"immediate": "~3.0.5"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/localforage": {
|
|
||||||
"version": "1.10.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/localforage/-/localforage-1.10.0.tgz",
|
|
||||||
"integrity": "sha512-14/H1aX7hzBBmmh7sGPd+AOMkkIrHM3Z1PAyGgZigA1H1p5O5ANnMyWzvpAETtG68/dC4pC0ncy3+PPGzXZHPg==",
|
|
||||||
"dependencies": {
|
|
||||||
"lie": "3.1.1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true,
|
|
||||||
"bin": {
|
|
||||||
"tsc": "bin/tsc",
|
|
||||||
"tsserver": "bin/tsserver"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4.2.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"@types/localforage": {
|
|
||||||
"version": "0.0.34",
|
|
||||||
"resolved": "https://registry.npmjs.org/@types/localforage/-/localforage-0.0.34.tgz",
|
|
||||||
"integrity": "sha1-XjHDLdh5HsS5/z70fJy1Wy0NlDg=",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"localforage": "*"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"immediate": {
|
|
||||||
"version": "3.0.6",
|
|
||||||
"resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz",
|
|
||||||
"integrity": "sha1-nbHb0Pr43m++D13V5Wu2BigN5ps="
|
|
||||||
},
|
|
||||||
"lie": {
|
|
||||||
"version": "3.1.1",
|
|
||||||
"resolved": "https://registry.npmjs.org/lie/-/lie-3.1.1.tgz",
|
|
||||||
"integrity": "sha1-mkNrLMd0bKWd56QfpGmz77dr2H4=",
|
|
||||||
"requires": {
|
|
||||||
"immediate": "~3.0.5"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"localforage": {
|
|
||||||
"version": "1.10.0",
|
|
||||||
"resolved": "https://registry.npmjs.org/localforage/-/localforage-1.10.0.tgz",
|
|
||||||
"integrity": "sha512-14/H1aX7hzBBmmh7sGPd+AOMkkIrHM3Z1PAyGgZigA1H1p5O5ANnMyWzvpAETtG68/dC4pC0ncy3+PPGzXZHPg==",
|
|
||||||
"requires": {
|
|
||||||
"lie": "3.1.1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"typescript": {
|
|
||||||
"version": "4.8.2",
|
|
||||||
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.8.2.tgz",
|
|
||||||
"integrity": "sha512-C0I1UsrrDHo2fYI5oaCGbSejwX4ch+9Y5jTQELvovfmFkK3HHSZJB8MSJcWLmCUBzQBchCrZ9rMRV6GuNrvGtw==",
|
|
||||||
"dev": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
5588
packages/theme/package-lock.json
generated
5588
packages/theme/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -13,7 +13,6 @@
|
|||||||
"tinycolor2": "^1.4.2"
|
"tinycolor2": "^1.4.2"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/styled-components": "^5.1.26",
|
|
||||||
"@types/tinycolor2": "^1.4.3",
|
"@types/tinycolor2": "^1.4.3",
|
||||||
"typescript": "^4.8.2"
|
"typescript": "^4.8.2"
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user