UNPKG

1.91 kBTypeScriptView Raw
1/**
2 * @description 编辑器配置
3 * @author wangfupeng
4 */
5import { EmotionsType, FontSizeConfType, IndentationType } from './menus';
6import { UploadImageHooksType } from './image';
7import langConfig from './lang';
8export declare type DicType = {
9 [key: string]: string;
10};
11export declare type ConfigType = {
12 height: number;
13 languageType: string[];
14 languageTab: string;
15 menus: string[];
16 fontNames: string[];
17 lineHeights: string[];
18 indentation: IndentationType;
19 fontSizes: FontSizeConfType;
20 colors: string[];
21 emotions: EmotionsType[];
22 zIndex: number;
23 onchange: Function;
24 onfocus: Function;
25 onblur: Function;
26 onchangeTimeout: number;
27 pasteFilterStyle: boolean;
28 pasteIgnoreImg: boolean;
29 pasteTextHandle: Function;
30 styleWithCSS: boolean;
31 linkImgCallback: Function;
32 placeholder: string;
33 zIndexFullScreen: number;
34 showFullScreen: boolean;
35 showLinkImg: boolean;
36 uploadImgServer: string;
37 uploadImgShowBase64: boolean;
38 uploadImgMaxSize: number;
39 uploadImgMaxLength: number;
40 uploadFileName: string;
41 uploadImgParams: DicType;
42 uploadImgParamsWithUrl: boolean;
43 uploadImgHeaders: DicType;
44 uploadImgHooks: UploadImageHooksType;
45 uploadImgTimeout: number;
46 withCredentials: boolean;
47 customUploadImg: Function | null;
48 customAlert: Function | null;
49 onCatalogChange: Function | null;
50 lang: string;
51 languages: typeof langConfig;
52 linkCheck: Function;
53 linkImgCheck: Function;
54 compatibleMode: () => boolean;
55 historyMaxSize: number;
56 focus: boolean;
57};
58export declare type Resource = {
59 [language: string]: ResourceLanguage;
60};
61export declare type ResourceLanguage = {
62 [namespace: string]: ResourceKey;
63};
64export declare type ResourceKey = string | {
65 [key: string]: any;
66};
67declare const defaultConfig: any;
68export default defaultConfig;