Skip to content

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

mobile: ensure that font size is always number

ammarahm-ed7577adf09d69
diff --git a/apps/mobile/app/screens/editor/tiptap/use-editor-events.ts b/apps/mobile/app/screens/editor/tiptap/use-editor-events.ts
index 4ddccdcc2..f54ad72c5 100644
--- a/apps/mobile/app/screens/editor/tiptap/use-editor-events.ts
+++ b/apps/mobile/app/screens/editor/tiptap/use-editor-events.ts
@@ -189,7 +189,10 @@ export const useEditorEvents = (
noToolbar: readonly || editorPropReadonly || noToolbar,
doubleSpacedLines: doubleSpacedLines,
corsProxy: corsProxy,
- fontSize: defaultFontSize,
+ fontSize:
+ typeof defaultFontSize === "string"
+ ? parseInt(defaultFontSize)
+ : defaultFontSize,
fontFamily: SettingsService.get().defaultFontFamily,
dateFormat: db.settings?.getDateFormat(),
timeFormat: db.settings?.getTimeFormat()