Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

editor: minor refactor

Abdullah Attaeaea7bdd2ae7
diff --git a/packages/editor/src/index.ts b/packages/editor/src/index.ts
index ab09b5fc6..4025f1451 100644
--- a/packages/editor/src/index.ts
+++ b/packages/editor/src/index.ts
@@ -112,12 +112,6 @@ declare global {
var keyboardShown: boolean;
}
-function hasStyle(element: HTMLElement | string) {
- const style = (element as HTMLElement).getAttribute("style");
- if (!style || style === "font-family: inherit;") return false;
- return true;
-}
-
globalThis["keyboardShown"] = true;
const CoreExtensions = Object.entries(TiptapCoreExtensions)
// we will implement our own customized clipboard serializer
@@ -407,3 +401,9 @@ export {
getHTMLFromFragment,
type DownloadOptions
};
+
+function hasStyle(element: HTMLElement | string) {
+ const style = (element as HTMLElement).getAttribute("style");
+ if (!style || style === "font-family: inherit;") return false;
+ return true;
+}