mobile: add editor-mobile to deps

This commit is contained in:
ammarahm-ed
2022-08-30 16:59:43 +05:00
parent 57525169c2
commit d24eabf3aa
62 changed files with 5409 additions and 220 deletions

BIN
.DS_Store vendored Normal file

Binary file not shown.

View File

@@ -3,4 +3,4 @@ import { Platform } from "react-native";
export const EDITOR_URI =
Platform.OS === "android"
? "file:///android_asset/index.html"
: "web.bundle/index.html";
: "build.bundle/index.html";

View File

@@ -1,7 +1,7 @@
/* eslint-disable no-case-declarations */
/* eslint-disable @typescript-eslint/no-var-requires */
import { getDefaultPresets } from "@streetwriters/editor/dist/toolbar/tool-definitions";
import type { Attachment } from "@streetwriters/editor/dist/extensions/attachment/index";
import { getDefaultPresets } from "@notesnook/editor/dist/toolbar/tool-definitions";
import type { Attachment } from "@notesnook/editor/dist/extensions/attachment/index";
import { useCallback, useEffect, useRef } from "react";
import {
BackHandler,

View File

@@ -13,7 +13,7 @@ import { DraggableItem, useDragState } from "./state";
import ToolSheet from "./tool-sheet";
import Icon from "react-native-vector-icons/MaterialCommunityIcons";
import { ToolId } from "@streetwriters/editor/dist/toolbar/tools";
import { ToolId } from "@notesnook/editor/dist/toolbar/tools";
export const Group = ({
item,
index: groupIndex,

View File

@@ -15,7 +15,7 @@ import { findToolById, getToolIcon } from "./toolbar-definition";
import ToolSheet from "./tool-sheet";
import Icon from "react-native-vector-icons/MaterialCommunityIcons";
import { ToolId } from "@streetwriters/editor/dist/toolbar/tools";
import { ToolId } from "@notesnook/editor/dist/toolbar/tools";
export const Tool = ({
item,
index,

View File

@@ -1,5 +1,5 @@
import Clipboard from "@react-native-clipboard/clipboard";
import EventManager from "@notesnook/core/utils/eventmanager";
import EventManager from "@notesnook/core/utils/event-manager";
import { RefObject } from "react";
import ActionSheet from "react-native-actions-sheet";
import { Config } from "react-native-config";

View File

@@ -349,11 +349,16 @@ task copyDownloadableDepsToLibs(type: Copy) {
into 'libs'
}
task copyFiles(type: Copy) {
from '../../web.bundle'
into './src/main/assets'
task deleteFiles(type: Delete) {
delete './src/main/assets/static'
}
task copyFiles(type: Copy) {
from '../../../../../packages/editor-mobile/build.bundle'
into './src/main/assets'
}
copyFiles.dependsOn(deleteFiles)
preBuild.dependsOn(copyFiles)

View File

@@ -18,8 +18,8 @@
6510627527042893009661C3 /* OpenSans-Regular.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 6552012F27019F7700A43C51 /* OpenSans-Regular.ttf */; };
6510627627042895009661C3 /* OpenSans-SemiBold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 6552012E27019F6E00A43C51 /* OpenSans-SemiBold.ttf */; };
6510627727042896009661C3 /* OpenSans-SemiBold.ttf in Resources */ = {isa = PBXBuildFile; fileRef = 6552012E27019F6E00A43C51 /* OpenSans-SemiBold.ttf */; };
6510E6D72877215700DACAA9 /* web.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 6510E6D62877215700DACAA9 /* web.bundle */; };
6510E6D82877215700DACAA9 /* web.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 6510E6D62877215700DACAA9 /* web.bundle */; };
6510E6D72877215700DACAA9 /* build.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 6510E6D62877215700DACAA9 /* build.bundle */; };
6510E6D82877215700DACAA9 /* build.bundle in Resources */ = {isa = PBXBuildFile; fileRef = 6510E6D62877215700DACAA9 /* build.bundle */; };
6515C42F2580AA3000E83E39 /* StoreKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 6515C42E2580AA2F00E83E39 /* StoreKit.framework */; };
6529A13E279BC4C70048D4A8 /* BootSplash.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 6529A13D279BC4C70048D4A8 /* BootSplash.storyboard */; };
6593E4A3281C345400492C50 /* AppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 6593E4A2281C345400492C50 /* AppDelegate.mm */; };
@@ -107,7 +107,7 @@
41D57E9831C724F59F18FBAE /* libPods-Notesnook-Add to Notes.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Notesnook-Add to Notes.a"; sourceTree = BUILT_PRODUCTS_DIR; };
47AE097A087A651BD60CAD7B /* Pods-Notesnook-Make Note.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Notesnook-Make Note.release.xcconfig"; path = "Target Support Files/Pods-Notesnook-Make Note/Pods-Notesnook-Make Note.release.xcconfig"; sourceTree = "<group>"; };
4BD34AE0C0FD2416E48803B8 /* libPods-Notesnook.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Notesnook.a"; sourceTree = BUILT_PRODUCTS_DIR; };
6510E6D62877215700DACAA9 /* web.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = web.bundle; path = ../web.bundle; sourceTree = "<group>"; };
6510E6D62877215700DACAA9 /* build.bundle */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.plug-in"; name = build.bundle; path = "../../../../packages/editor-mobile/build.bundle"; sourceTree = "<group>"; };
6515C42E2580AA2F00E83E39 /* StoreKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = StoreKit.framework; path = System/Library/Frameworks/StoreKit.framework; sourceTree = SDKROOT; };
6529A13D279BC4C70048D4A8 /* BootSplash.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = BootSplash.storyboard; path = Notesnook/BootSplash.storyboard; sourceTree = "<group>"; };
6529D2B0257B4A2900B49BC3 /* NotesnookDebug.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = NotesnookDebug.entitlements; path = Notesnook/NotesnookDebug.entitlements; sourceTree = "<group>"; };
@@ -288,7 +288,7 @@
83CBB9F61A601CBA00E9B192 = {
isa = PBXGroup;
children = (
6510E6D62877215700DACAA9 /* web.bundle */,
6510E6D62877215700DACAA9 /* build.bundle */,
65EC5B71272A7EE200FB3748 /* NotesWidgetExtensionDebug.entitlements */,
6552012F27019F7700A43C51 /* OpenSans-Regular.ttf */,
6552012E27019F6E00A43C51 /* OpenSans-SemiBold.ttf */,
@@ -535,7 +535,7 @@
6510626F27042891009661C3 /* OpenSans-Regular.ttf in Resources */,
13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
6529A13E279BC4C70048D4A8 /* BootSplash.storyboard in Resources */,
6510E6D72877215700DACAA9 /* web.bundle in Resources */,
6510E6D72877215700DACAA9 /* build.bundle in Resources */,
6510627627042895009661C3 /* OpenSans-SemiBold.ttf in Resources */,
659BE46725E11A5100E05671 /* notesnook-text.png in Resources */,
);
@@ -568,7 +568,7 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
6510E6D82877215700DACAA9 /* web.bundle in Resources */,
6510E6D82877215700DACAA9 /* build.bundle in Resources */,
6510627727042896009661C3 /* OpenSans-SemiBold.ttf in Resources */,
6510627527042893009661C3 /* OpenSans-Regular.ttf in Resources */,
65B5014725A672B200E2D264 /* MainInterface.storyboard in Resources */,

View File

@@ -6,6 +6,7 @@
*/
// eslint-disable-next-line @typescript-eslint/no-var-requires
const path = require('path');
const nodeModulesPaths = [path.resolve(path.join(__dirname, '../node_modules'))];
module.exports = {
projectRoot: __dirname,
watchFolders: [
@@ -13,13 +14,15 @@ module.exports = {
path.join(__dirname, '../share'),
path.join(__dirname, '../node_modules'),
path.join(__dirname, '../e2e'),
path.join(__dirname, "../../../packages/editor")
path.join(__dirname, "../../../packages"),
],
resolver: {
sourceExts: ['jsx', 'js', 'ts', 'tsx', 'cjs'],
nodeModulesPaths,
extraNodeModules: {
"react": path.join(__dirname, "../node_modules/react"),
"react-dom": path.join(__dirname, "../node_modules/react-dom")
"react-dom": path.join(__dirname, "../node_modules/react-dom"),
"@notesnook": path.join(__dirname, "../../../packages"),
}
},
transformer: {

View File

@@ -1,23 +0,0 @@
{
"files": {
"static/js/0.91d7b8d5.chunk.js": "./static/js/0.91d7b8d5.chunk.js",
"main.css": "./static/css/main.f2465fba.chunk.css",
"main.js": "./static/js/main.63f81e65.chunk.js",
"runtime-main.js": "./static/js/runtime-main.9bd4fa53.js",
"static/css/3.526cedf0.chunk.css": "./static/css/3.526cedf0.chunk.css",
"static/js/3.7fb602fe.chunk.js": "./static/js/3.7fb602fe.chunk.js",
"static/js/4.7884bc18.chunk.js": "./static/js/4.7884bc18.chunk.js",
"static/js/5.077f361c.chunk.js": "./static/js/5.077f361c.chunk.js",
"index.html": "./index.html",
"static/js/3.7fb602fe.chunk.js.LICENSE.txt": "./static/js/3.7fb602fe.chunk.js.LICENSE.txt",
"static/media/katexfonts.mobile.css": "./static/media/KaTeX_Typewriter-Regular.c5c02d76.ttf",
"static/media/fonts.mobile.css": "./static/media/hack-regular.f2412cb7.ttf"
},
"entrypoints": [
"static/js/runtime-main.9bd4fa53.js",
"static/css/3.526cedf0.chunk.css",
"static/js/3.7fb602fe.chunk.js",
"static/css/main.f2465fba.chunk.css",
"static/js/main.63f81e65.chunk.js"
]
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

View File

@@ -1,71 +0,0 @@
/* open-sans-regular - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: normal;
font-weight: 400;
src: local('Open Sans'), url(./fonts/OpenSans-Regular.ttf) format('truetype');
}
/* open-sans-italic - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: italic;
font-weight: 400;
src: local('Open Sans'), url(./fonts/OpenSans-Italic.ttf) format('truetype');
}
/* open-sans-600 - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: normal;
font-weight: 500;
src: local('Open Sans'), url(./fonts/OpenSans-Medium.ttf) format('truetype');
}
/* open-sans-600italic - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: italic;
font-weight: 500;
src: local('Open Sans'), url(./fonts/OpenSans-MediumItalic.ttf) format('truetype');
}
/* open-sans-600 - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: normal;
font-weight: 600;
src: local('Open Sans'), url(./fonts/OpenSans-SemiBold.ttf) format('truetype');
}
/* open-sans-600italic - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: italic;
font-weight: 600;
src: local('Open Sans'), url(./fonts/OpenSans-SemiBoldItalic.ttf) format('truetype');
}
/* open-sans-700 - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: normal;
font-weight: 700;
src: local('Open Sans'), url(./fonts/OpenSans-Bold.ttf) format('truetype');
}
/* open-sans-700italic - latin */
@font-face {
font-family: 'Open Sans';
font-display: swap;
font-style: italic;
font-weight: 700;
src: local('Open Sans'), url(./fonts/OpenSans-BoldItalic.ttf) format('truetype');
}

View File

@@ -1 +0,0 @@
<!doctype html><html style="height:100%" lang="en"><head><meta charset="utf-8"/><link rel="icon" href="favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1,maximum-scale=1"/><meta name="theme-color" content="#000000"/><link href="fonts.css" rel="stylesheet"/><style>body{height:100%;font-family:"Open Sans"}p{font-family:"Open Sans"}::selection{color:#fff;background-color:var(--nn_accent)}::placeholder{color:var(--nn_placeholder)}p.is-editor-empty:first-child::before{color:var(--nn_placeholder)!important}h1,h2,h3,h4,h5,h6{font-family:"Open Sans";color:var(--nn_heading)}#root{height:100%;display:flex}</style><meta name="description" content="Notesnook editor for mobile"/><link rel="manifest" href="manifest.json"/><title>Notesnook editor</title><link href="./static/css/3.526cedf0.chunk.css" rel="stylesheet"><link href="./static/css/main.f2465fba.chunk.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><script>!function(e){function t(t){for(var n,i,a=t[0],c=t[1],l=t[2],p=0,s=[];p<a.length;p++)i=a[p],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&s.push(o[i][0]),o[i]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(f&&f(t);s.length;)s.shift()();return u.push.apply(u,l||[]),r()}function r(){for(var e,t=0;t<u.length;t++){for(var r=u[t],n=!0,a=1;a<r.length;a++){var c=r[a];0!==o[c]&&(n=!1)}n&&(u.splice(t--,1),e=i(i.s=r[0]))}return e}var n={},o={2:0},u=[];function i(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,i),r.l=!0,r.exports}i.e=function(e){var t=[],r=o[e];if(0!==r)if(r)t.push(r[2]);else{var n=new Promise((function(t,n){r=o[e]=[t,n]}));t.push(r[2]=n);var u,a=document.createElement("script");a.charset="utf-8",a.timeout=120,i.nc&&a.setAttribute("nonce",i.nc),a.src=function(e){return i.p+"static/js/"+({}[e]||e)+"."+{0:"91d7b8d5",4:"7884bc18",5:"077f361c"}[e]+".chunk.js"}(e);var c=new Error;u=function(t){a.onerror=a.onload=null,clearTimeout(l);var r=o[e];if(0!==r){if(r){var n=t&&("load"===t.type?"missing":t.type),u=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,r[1](c)}o[e]=void 0}};var l=setTimeout((function(){u({type:"timeout",target:a})}),12e4);a.onerror=a.onload=u,document.head.appendChild(a)}return Promise.all(t)},i.m=e,i.c=n,i.d=function(e,t,r){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},i.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(i.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)i.d(r,n,function(t){return e[t]}.bind(null,n));return r},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="./",i.oe=function(e){throw console.error(e),e};var a=this.webpackJsonptiptap=this.webpackJsonptiptap||[],c=a.push.bind(a);a.push=t,a=a.slice();for(var l=0;l<a.length;l++)t(a[l]);var f=c;r()}([])</script><script src="./static/js/3.7fb602fe.chunk.js"></script><script src="./static/js/main.63f81e65.chunk.js"></script></body></html>

View File

@@ -1,15 +0,0 @@
{
"short_name": "Notesnook editor",
"name": "Notesnook editor for mobile",
"icons": [
{
"src": "favicon.ico",
"sizes": "64x64 32x32 24x24 16x16",
"type": "image/x-icon"
}
],
"start_url": ".",
"display": "standalone",
"theme_color": "#000000",
"background_color": "#ffffff"
}

View File

@@ -1 +0,0 @@
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 135.47 135.47"><g fill="gray"><path d="M65.63 65.86a4.48 4.48 0 1 0-.01-8.96 4.48 4.48 0 0 0 0 8.96zm0-6.33a1.85 1.85 0 1 1 0 3.7 1.85 1.85 0 0 1 0-3.7zm0 0"/><path d="M88.49 48.53H46.98c-.9 0-1.64.73-1.64 1.64V85.3c0 .9.74 1.64 1.64 1.64h41.5c.91 0 1.64-.74 1.64-1.64V50.17c0-.9-.73-1.64-1.63-1.64Zm-.99 2.62v20.77l-8.25-8.25a1.38 1.38 0 0 0-1.95 0L65.63 75.34l-7.46-7.46a1.37 1.37 0 0 0-1.95 0l-8.25 8.25V51.15ZM47.97 84.31v-4.47l9.22-9.22 7.46 7.45a1.37 1.37 0 0 0 1.95 0L78.27 66.4l9.23 9.23v8.68zm0 0"/></g></svg>

Before

Width:  |  Height:  |  Size: 571 B

View File

@@ -1,3 +0,0 @@
# https://www.robotstxt.org/robotstxt.html
User-agent: *
Disallow:

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
body{margin:0;font-family:-apple-system,BlinkMacSystemFont,"Segoe UI","Roboto","Oxygen","Ubuntu","Cantarell","Fira Sans","Droid Sans","Helvetica Neue",sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}code{font-family:source-code-pro,Menlo,Monaco,Consolas,"Courier New",monospace}input:active,input:focus{outline:none}*{-webkit-tap-highlight-color:transparent}.App{flex:1 1}.ProseMirror:focus{outline:none}.ProseMirror p.is-editor-empty:first-child:before{color:#a9a9a9;content:attr(data-placeholder);float:left;height:0;pointer-events:none}.styles_btn__19MaA{background-color:var(--nn_nav)}.styles_btn__19MaA:active{background-color:var(--nn_transGray)}.styles_btn_header__2xGXR{width:40;height:40;background-color:transparent}.styles_btn_header__2xGXR:active{background-color:var(--nn_transGray)}.styles_titleBar__2hePW::-webkit-input-placeholder{color:var(--nn_placeholder)}.styles_titleBar__2hePW:-ms-input-placeholder{color:var(--nn_placeholder)}.styles_titleBar__2hePW::placeholder{color:var(--nn_placeholder)}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -1,70 +0,0 @@
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
/*!
Copyright (c) 2015 Jed Watson.
Based on code that is Copyright 2013-2015, Facebook, Inc.
All rights reserved.
*/
/*!
* Adapted from jQuery UI core
*
* http://jqueryui.com
*
* Copyright 2014 jQuery Foundation and other contributors
* Released under the MIT license.
* http://jquery.org/license
*
* http://api.jqueryui.com/category/ui-core/
*/
/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
/** @license React v0.20.2
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v16.13.1
* react-is.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
(this.webpackJsonptiptap=this.webpackJsonptiptap||[]).push([[5],{125:function(t,e,n){"use strict";n.r(e),n.d(e,"getCLS",(function(){return d})),n.d(e,"getFCP",(function(){return S})),n.d(e,"getFID",(function(){return F})),n.d(e,"getLCP",(function(){return k})),n.d(e,"getTTFB",(function(){return C}));var i,a,r,o,u=function(t,e){return{name:t,value:void 0===e?-1:e,delta:0,entries:[],id:"v1-".concat(Date.now(),"-").concat(Math.floor(8999999999999*Math.random())+1e12)}},c=function(t,e){try{if(PerformanceObserver.supportedEntryTypes.includes(t)){if("first-input"===t&&!("PerformanceEventTiming"in self))return;var n=new PerformanceObserver((function(t){return t.getEntries().map(e)}));return n.observe({type:t,buffered:!0}),n}}catch(t){}},f=function(t,e){var n=function n(i){"pagehide"!==i.type&&"hidden"!==document.visibilityState||(t(i),e&&(removeEventListener("visibilitychange",n,!0),removeEventListener("pagehide",n,!0)))};addEventListener("visibilitychange",n,!0),addEventListener("pagehide",n,!0)},s=function(t){addEventListener("pageshow",(function(e){e.persisted&&t(e)}),!0)},p="function"==typeof WeakSet?new WeakSet:new Set,m=function(t,e,n){var i;return function(){e.value>=0&&(n||p.has(e)||"hidden"===document.visibilityState)&&(e.delta=e.value-(i||0),(e.delta||void 0===i)&&(i=e.value,t(e)))}},d=function(t,e){var n,i=u("CLS",0),a=function(t){t.hadRecentInput||(i.value+=t.value,i.entries.push(t),n())},r=c("layout-shift",a);r&&(n=m(t,i,e),f((function(){r.takeRecords().map(a),n()})),s((function(){i=u("CLS",0),n=m(t,i,e)})))},v=-1,l=function(){return"hidden"===document.visibilityState?0:1/0},h=function(){f((function(t){var e=t.timeStamp;v=e}),!0)},g=function(){return v<0&&(v=l(),h(),s((function(){setTimeout((function(){v=l(),h()}),0)}))),{get timeStamp(){return v}}},S=function(t,e){var n,i=g(),a=u("FCP"),r=function(t){"first-contentful-paint"===t.name&&(f&&f.disconnect(),t.startTime<i.timeStamp&&(a.value=t.startTime,a.entries.push(t),p.add(a),n()))},o=performance.getEntriesByName("first-contentful-paint")[0],f=o?null:c("paint",r);(o||f)&&(n=m(t,a,e),o&&r(o),s((function(i){a=u("FCP"),n=m(t,a,e),requestAnimationFrame((function(){requestAnimationFrame((function(){a.value=performance.now()-i.timeStamp,p.add(a),n()}))}))})))},y={passive:!0,capture:!0},E=new Date,w=function(t,e){i||(i=e,a=t,r=new Date,b(removeEventListener),L())},L=function(){if(a>=0&&a<r-E){var t={entryType:"first-input",name:i.type,target:i.target,cancelable:i.cancelable,startTime:i.timeStamp,processingStart:i.timeStamp+a};o.forEach((function(e){e(t)})),o=[]}},T=function(t){if(t.cancelable){var e=(t.timeStamp>1e12?new Date:performance.now())-t.timeStamp;"pointerdown"==t.type?function(t,e){var n=function(){w(t,e),a()},i=function(){a()},a=function(){removeEventListener("pointerup",n,y),removeEventListener("pointercancel",i,y)};addEventListener("pointerup",n,y),addEventListener("pointercancel",i,y)}(e,t):w(e,t)}},b=function(t){["mousedown","keydown","touchstart","pointerdown"].forEach((function(e){return t(e,T,y)}))},F=function(t,e){var n,r=g(),d=u("FID"),v=function(t){t.startTime<r.timeStamp&&(d.value=t.processingStart-t.startTime,d.entries.push(t),p.add(d),n())},l=c("first-input",v);n=m(t,d,e),l&&f((function(){l.takeRecords().map(v),l.disconnect()}),!0),l&&s((function(){var r;d=u("FID"),n=m(t,d,e),o=[],a=-1,i=null,b(addEventListener),r=v,o.push(r),L()}))},k=function(t,e){var n,i=g(),a=u("LCP"),r=function(t){var e=t.startTime;e<i.timeStamp&&(a.value=e,a.entries.push(t)),n()},o=c("largest-contentful-paint",r);if(o){n=m(t,a,e);var d=function(){p.has(a)||(o.takeRecords().map(r),o.disconnect(),p.add(a),n())};["keydown","click"].forEach((function(t){addEventListener(t,d,{once:!0,capture:!0})})),f(d,!0),s((function(i){a=u("LCP"),n=m(t,a,e),requestAnimationFrame((function(){requestAnimationFrame((function(){a.value=performance.now()-i.timeStamp,p.add(a),n()}))}))}))}},C=function(t){var e,n=u("TTFB");e=function(){try{var e=performance.getEntriesByType("navigation")[0]||function(){var t=performance.timing,e={entryType:"navigation",startTime:0};for(var n in t)"navigationStart"!==n&&"toJSON"!==n&&(e[n]=Math.max(t[n]-t.navigationStart,0));return e}();if(n.value=n.delta=e.responseStart,n.value<0)return;n.entries=[e],t(n)}catch(t){}},"complete"===document.readyState?setTimeout(e,0):addEventListener("pageshow",e)}}}]);

File diff suppressed because one or more lines are too long

View File

@@ -1 +0,0 @@
!function(e){function t(t){for(var n,i,a=t[0],c=t[1],l=t[2],p=0,s=[];p<a.length;p++)i=a[p],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&s.push(o[i][0]),o[i]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(f&&f(t);s.length;)s.shift()();return u.push.apply(u,l||[]),r()}function r(){for(var e,t=0;t<u.length;t++){for(var r=u[t],n=!0,a=1;a<r.length;a++){var c=r[a];0!==o[c]&&(n=!1)}n&&(u.splice(t--,1),e=i(i.s=r[0]))}return e}var n={},o={2:0},u=[];function i(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,i),r.l=!0,r.exports}i.e=function(e){var t=[],r=o[e];if(0!==r)if(r)t.push(r[2]);else{var n=new Promise((function(t,n){r=o[e]=[t,n]}));t.push(r[2]=n);var u,a=document.createElement("script");a.charset="utf-8",a.timeout=120,i.nc&&a.setAttribute("nonce",i.nc),a.src=function(e){return i.p+"static/js/"+({}[e]||e)+"."+{0:"91d7b8d5",4:"7884bc18",5:"077f361c"}[e]+".chunk.js"}(e);var c=new Error;u=function(t){a.onerror=a.onload=null,clearTimeout(l);var r=o[e];if(0!==r){if(r){var n=t&&("load"===t.type?"missing":t.type),u=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+u+")",c.name="ChunkLoadError",c.type=n,c.request=u,r[1](c)}o[e]=void 0}};var l=setTimeout((function(){u({type:"timeout",target:a})}),12e4);a.onerror=a.onload=u,document.head.appendChild(a)}return Promise.all(t)},i.m=e,i.c=n,i.d=function(e,t,r){i.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},i.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},i.t=function(e,t){if(1&t&&(e=i(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(i.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)i.d(r,n,function(t){return e[t]}.bind(null,n));return r},i.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return i.d(t,"a",t),t},i.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},i.p="./",i.oe=function(e){throw console.error(e),e};var a=this.webpackJsonptiptap=this.webpackJsonptiptap||[],c=a.push.bind(a);a.push=t,a=a.slice();for(var l=0;l<a.length;l++)t(a[l]);var f=c;r()}([]);

View File

@@ -21,6 +21,8 @@
"typescript": "^4.8.2"
},
"dependencies": {
"@notesnook/editor": "*"
"@notesnook/editor": "*",
"@notesnook/editor-mobile": "*",
"@notesnook/core": "*"
}
}

View File

@@ -1,5 +1,5 @@
import { getPreviewData } from "@flyerhq/react-native-link-preview";
import { parseHTML } from "@notesnook/core/utils/htmlparser";
import { parseHTML } from "@notesnook/core/utils/html-parser";
import React, { useEffect, useRef, useState } from "react";
import {
ActivityIndicator,

BIN
packages/.DS_Store vendored Normal file

Binary file not shown.

View File

@@ -10,8 +10,8 @@
"dependencies": {
"framer-motion": "^4.1.17",
"mdi-react": "^8.4.0",
"react": "^17.0.1",
"react-dom": "^17.0.1",
"react": "^17.0.2",
"react-dom": "^17.0.2",
"zustand": "^3.6.8"
},
"devDependencies": {
@@ -20,8 +20,8 @@
"@testing-library/user-event": "^12.8.3",
"@types/jest": "^27.0.3",
"@types/node": "^16.11.11",
"@types/react": "^17.0.39",
"@types/react-dom": "^17.0.11",
"@types/react": "^17.0.2",
"@types/react-dom": "^17.0.2",
"patch-package": "^6.4.7",
"react-error-overlay": "6.0.9",
"react-scripts": "^4.0.3",

5376
packages/theme/package-lock.json generated Normal file

File diff suppressed because it is too large Load Diff