lakelib 0.1.0 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/lake.min.js +2 -2
- package/dist/lake.min.js.map +1 -1
- package/lib/lake.js +27 -12
- package/lib/lake.js.map +1 -1
- package/lib/types/editor.d.ts +14 -16
- package/package.json +1 -1
package/lib/types/editor.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import EventEmitter from 'eventemitter3';
|
|
2
2
|
import { NativeNode } from './types/native';
|
|
3
|
-
import { UploadRequestMethod } from './types/request';
|
|
4
3
|
import { Nodes } from './models/nodes';
|
|
5
4
|
import { Box } from './models/box';
|
|
6
5
|
import { insertBox } from './operations/insert-box';
|
|
@@ -12,6 +11,15 @@ import { Keystroke } from './managers/keystroke';
|
|
|
12
11
|
import { BoxManager } from './managers/box-manager';
|
|
13
12
|
import { Plugin } from './managers/plugin';
|
|
14
13
|
import { Toolbar } from './ui/toolbar';
|
|
14
|
+
type Config = {
|
|
15
|
+
value: string;
|
|
16
|
+
readonly: boolean;
|
|
17
|
+
spellcheck: boolean;
|
|
18
|
+
tabIndex: number;
|
|
19
|
+
indentWithTab: boolean;
|
|
20
|
+
minChangeSize: number;
|
|
21
|
+
[name: string]: any;
|
|
22
|
+
};
|
|
15
23
|
type EditorConfig = {
|
|
16
24
|
root: string | Nodes | NativeNode;
|
|
17
25
|
toolbar?: Toolbar;
|
|
@@ -21,20 +29,7 @@ type EditorConfig = {
|
|
|
21
29
|
tabIndex?: number;
|
|
22
30
|
indentWithTab?: boolean;
|
|
23
31
|
minChangeSize?: number;
|
|
24
|
-
|
|
25
|
-
imageRequestAction?: string;
|
|
26
|
-
imageRequestTypes?: string[];
|
|
27
|
-
};
|
|
28
|
-
declare const defaultConfig: {
|
|
29
|
-
value: string;
|
|
30
|
-
readonly: boolean;
|
|
31
|
-
spellcheck: boolean;
|
|
32
|
-
tabIndex: number;
|
|
33
|
-
indentWithTab: boolean;
|
|
34
|
-
minChangeSize: number;
|
|
35
|
-
imageRequestMethod: UploadRequestMethod;
|
|
36
|
-
imageRequestAction: string;
|
|
37
|
-
imageRequestTypes: string[];
|
|
32
|
+
[name: string]: any;
|
|
38
33
|
};
|
|
39
34
|
export declare class Editor {
|
|
40
35
|
static version: string;
|
|
@@ -44,7 +39,7 @@ export declare class Editor {
|
|
|
44
39
|
private stateData;
|
|
45
40
|
root: Nodes;
|
|
46
41
|
toolbar: Toolbar | undefined;
|
|
47
|
-
config:
|
|
42
|
+
config: Config;
|
|
48
43
|
containerWrapper: Nodes;
|
|
49
44
|
container: Nodes;
|
|
50
45
|
overlayContainer: Nodes;
|
|
@@ -73,6 +68,9 @@ export declare class Editor {
|
|
|
73
68
|
commitUnsavedInputData(): void;
|
|
74
69
|
prepareOperation(): void;
|
|
75
70
|
commitOperation(): void;
|
|
71
|
+
setPluginConfig(pluginName: string, pluginConfig: {
|
|
72
|
+
[key: string]: any;
|
|
73
|
+
}): void;
|
|
76
74
|
focus(): void;
|
|
77
75
|
blur(): void;
|
|
78
76
|
setValue(value: string): void;
|