UNPKG

@opentiny/fluent-editor

Version:

A rich text editor based on Quill 2.0, which extends rich modules and formats on the basis of Quill. It's powerful and out-of-the-box.

113 lines (112 loc) 3.92 kB
const BIG_DELTA_LIMIT = 2e3; const CHANGE_LANGUAGE_EVENT = "change-language"; const defaultLanguage = "zh-CN"; const IMAGE_UPLOADER_MIME_TYPES = [ "image/png", "image/jpeg", "image/gif", "image/svg+xml" ]; const OTHER_FILE_UPLOADER_MIME_TYPES = [ "text/plain", "application/json", "application/pdf" ]; const AUDIO_VIDEO_UPLOADER_MIME_TYPES = [ "audio/wave", "audio/wav", "audio/x-wav", "audio/x-pn-wav", "audio/mpeg", "video/mpeg", "video/x-msvideo" ]; const DOC_UPLOADER_MIME_TYPES = [ "application/msword", "application/msword", "application/vnd.openxmlformats-officedocument.wordprocessingml.document", "application/vnd.openxmlformats-officedocument.wordprocessingml.template", "application/vnd.ms-word.document.macroEnabled.12", "application/vnd.ms-word.template.macroEnabled.12" ]; const XSL_UPLOADER_MIME_TYPES = [ "application/vnd.ms-excel", "application/vnd.ms-excel", "application/vnd.ms-excel", "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", "application/vnd.openxmlformats-officedocument.spreadsheetml.template", "application/vnd.ms-excel.sheet.macroEnabled.12", "application/vnd.ms-excel.template.macroEnabled.12", "application/vnd.ms-excel.addin.macroEnabled.12", "application/vnd.ms-excel.sheet.binary.macroEnabled.12" ]; const PPT_UPLOADER_MIME_TYPES = [ "application/vnd.ms-powerpoint", "application/vnd.ms-powerpoint", "application/vnd.ms-powerpoint", "application/vnd.ms-powerpoint", "application/vnd.openxmlformats-officedocument.presentationml.presentation", "application/vnd.openxmlformats-officedocument.presentationml.template", "application/vnd.openxmlformats-officedocument.presentationml.slideshow", "application/vnd.ms-powerpoint.addin.macroEnabled.12", "application/vnd.ms-powerpoint.presentation.macroEnabled.12", "application/vnd.ms-powerpoint.presentation.macroEnabled.12", "application/vnd.ms-powerpoint.slideshow.macroEnabled.12" ]; const COMPRESSED_UPLOADER_MIME_TYPES = [ "application/x-tar", "application/x-zip-compressed", "application/zip-compressed", "application/gzip", ".rar", ".7z" ]; const FILE_UPLOADER_MIME_TYPES = [ ...OTHER_FILE_UPLOADER_MIME_TYPES, ...AUDIO_VIDEO_UPLOADER_MIME_TYPES, ...DOC_UPLOADER_MIME_TYPES, ...XSL_UPLOADER_MIME_TYPES, ...PPT_UPLOADER_MIME_TYPES, ...COMPRESSED_UPLOADER_MIME_TYPES ]; const DEFAULT_TOOLBAR = [ [{ header: [] }], ["bold", "italic", "underline", "link"], [{ list: "ordered" }, { list: "bullet" }], ["clean"] ]; const FULL_TOOLBAR = [ ["undo", "redo", "clean", "format-painter"], [ { header: [1, 2, 3, 4, 5, 6, false] }, { font: [false, "宋体", "微软雅黑", "楷体", "黑体", "隶书", "andale mono", "arial", "arial black", "comic sans ms", "impact", "times new roman"] }, { size: [false, "12px", "14px", "16px", "18px", "20px", "24px", "32px", "36px", "48px", "72px"] }, { "line-height": [false, "1.2", "1.5", "1.75", "2", "3", "4", "5"] } ], ["bold", "italic", "strike", "underline", "divider"], [{ color: [] }, { background: [] }], [{ align: ["", "center", "right"] }, { align: "" }, { align: "center" }, { align: "right" }, { align: "justify" }], [{ list: "ordered" }, { list: "bullet" }, { list: "check" }], [{ script: "sub" }, { script: "super" }], [{ indent: "-1" }, { indent: "+1" }], [{ direction: "rtl" }], ["link", "blockquote", "code", "code-block"], ["image", "file", { "table-up": [] }], ["emoji", "video", "formula", "screenshot", "fullscreen"] ]; export { AUDIO_VIDEO_UPLOADER_MIME_TYPES, BIG_DELTA_LIMIT, CHANGE_LANGUAGE_EVENT, COMPRESSED_UPLOADER_MIME_TYPES, DEFAULT_TOOLBAR, DOC_UPLOADER_MIME_TYPES, FILE_UPLOADER_MIME_TYPES, FULL_TOOLBAR, IMAGE_UPLOADER_MIME_TYPES, OTHER_FILE_UPLOADER_MIME_TYPES, PPT_UPLOADER_MIME_TYPES, XSL_UPLOADER_MIME_TYPES, defaultLanguage }; //# sourceMappingURL=editor.config.es.js.map