forked from coracle/flotilla
Clean up drafts implementation (#164)
This commit is contained in:
@@ -25,7 +25,6 @@ import {pushToast} from "@app/util/toast"
|
||||
export const makeEditor = async ({
|
||||
encryptFiles = false,
|
||||
aggressive = false,
|
||||
autofocus = false,
|
||||
charCount,
|
||||
content = "",
|
||||
onChange,
|
||||
@@ -37,10 +36,9 @@ export const makeEditor = async ({
|
||||
}: {
|
||||
encryptFiles?: boolean
|
||||
aggressive?: boolean
|
||||
autofocus?: boolean
|
||||
charCount?: Writable<number>
|
||||
content?: string | object
|
||||
onChange?: (json: unknown) => void
|
||||
onChange?: (json: object) => void
|
||||
placeholder?: string
|
||||
url?: string
|
||||
submit: () => void
|
||||
@@ -86,7 +84,6 @@ export const makeEditor = async ({
|
||||
|
||||
const ed = new Editor({
|
||||
content: typeof content === "string" ? escapeHtml(content) : content,
|
||||
autofocus: false,
|
||||
editorProps,
|
||||
element: document.createElement("div"),
|
||||
extensions: [
|
||||
@@ -148,7 +145,5 @@ export const makeEditor = async ({
|
||||
},
|
||||
})
|
||||
|
||||
;(ed as any)._shouldAutofocus = autofocus
|
||||
|
||||
return ed
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user