lakelib 0.1.6 → 0.1.7
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/dist/lake.css +4 -0
- package/dist/lake.min.js +5 -5
- package/dist/lake.min.js.map +1 -1
- package/lib/lake.css +4 -0
- package/lib/lake.js +17 -7
- package/lib/lake.js.map +1 -1
- package/lib/types/ui/button.d.ts +2 -1
- package/lib/types/ui/dropdown.d.ts +3 -1
- package/lib/types/ui/toolbar.d.ts +4 -1
- package/lib/types/ui/upload.d.ts +2 -2
- package/package.json +1 -1
package/lib/types/ui/button.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Nodes } from '../models/nodes';
|
|
2
|
-
|
|
2
|
+
type ButtonConfig = {
|
|
3
3
|
root: Nodes;
|
|
4
4
|
name: string;
|
|
5
5
|
icon?: string;
|
|
@@ -15,3 +15,4 @@ export declare class Button {
|
|
|
15
15
|
constructor(config: ButtonConfig);
|
|
16
16
|
render(): void;
|
|
17
17
|
}
|
|
18
|
+
export {};
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { TranslationFunctions } from '../i18n/types';
|
|
2
2
|
import { DropdownItem, DropdownMenuItem } from '../types/dropdown';
|
|
3
3
|
import { Nodes } from '../models/nodes';
|
|
4
|
-
|
|
4
|
+
type DropdownConfig = DropdownItem & {
|
|
5
5
|
root: Nodes;
|
|
6
6
|
locale?: TranslationFunctions;
|
|
7
7
|
tabIndex?: number;
|
|
8
|
+
placement?: 'top' | 'bottom';
|
|
8
9
|
onSelect: (value: string) => void;
|
|
9
10
|
};
|
|
10
11
|
export declare class Dropdown {
|
|
@@ -24,3 +25,4 @@ export declare class Dropdown {
|
|
|
24
25
|
render(): void;
|
|
25
26
|
unmount(): void;
|
|
26
27
|
}
|
|
28
|
+
export {};
|
|
@@ -3,13 +3,16 @@ import { NativeNode } from '../types/native';
|
|
|
3
3
|
import { SelectionState } from '../types/object';
|
|
4
4
|
import { ToolbarItem } from '../types/toolbar';
|
|
5
5
|
import { Nodes } from '../models/nodes';
|
|
6
|
+
type ToolbarPlacement = 'top' | 'bottom';
|
|
6
7
|
type ToolbarConfig = {
|
|
7
8
|
root: string | Nodes | NativeNode;
|
|
8
9
|
items?: (string | ToolbarItem)[];
|
|
10
|
+
placement?: ToolbarPlacement;
|
|
9
11
|
};
|
|
10
12
|
export declare class Toolbar {
|
|
11
|
-
private items;
|
|
12
13
|
private root;
|
|
14
|
+
private items;
|
|
15
|
+
private placement;
|
|
13
16
|
private allMenuMap;
|
|
14
17
|
private buttonItemList;
|
|
15
18
|
private dropdownItemList;
|
package/lib/types/ui/upload.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import type { Editor } from '../editor';
|
|
2
2
|
import { Box } from '../models/box';
|
|
3
|
-
type
|
|
3
|
+
type UploadConfig = {
|
|
4
4
|
editor: Editor;
|
|
5
5
|
file: File;
|
|
6
6
|
onError?: () => void;
|
|
7
7
|
onSuccess?: () => void;
|
|
8
8
|
};
|
|
9
|
-
export declare function uploadImage(config:
|
|
9
|
+
export declare function uploadImage(config: UploadConfig): Box;
|
|
10
10
|
export {};
|