@ones-editor/editor 0.0.3-beta.147 → 0.0.3-beta.149
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/@ones-editor/block-menu/src/block-menu/index.d.ts +2 -1
- package/@ones-editor/block-menu/src/block-menu-button/drag-drop/drag-handler.d.ts +1 -0
- package/@ones-editor/core/src/core/editor/actions/insert-text.d.ts +1 -0
- package/@ones-editor/core/src/utils/abbreviation.d.ts +14 -0
- package/@ones-editor/tsconfig.tsbuildinfo +1 -1
- package/@ones-editor/ui-base/src/auto-suggest/auto-suggest-menu.d.ts +1 -0
- package/@ones-editor/ui-base/src/dropdown/index.d.ts +1 -0
- package/@ones-editor/versions/src/locale/en-us.d.ts +1 -0
- package/@ones-editor/versions/src/locale/ja-jp.d.ts +1 -0
- package/@ones-editor/versions/src/locale/zh-cn.d.ts +1 -0
- package/@ones-editor/versions/src/version-dialog/size-limit-textarea.d.ts +1 -0
- package/dist/index.js +154 -154
- package/dist/link-input-handler.d.ts +5 -0
- package/package.json +1 -1
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { BlockElement, OnesEditor, CommandItem } from '../../../../@ones-editor/core';
|
|
2
|
+
import type { ManualShowCommandBarOptions } from '../../../../@ones-editor/ui-base';
|
|
2
3
|
export default class BlockMenu {
|
|
3
4
|
private editor;
|
|
4
5
|
private menu;
|
|
5
6
|
currentBlock: BlockElement | null;
|
|
6
7
|
private commandBlock;
|
|
7
8
|
constructor(editor: OnesEditor);
|
|
8
|
-
show(target: HTMLElement): void;
|
|
9
|
+
show(target: HTMLElement, options?: ManualShowCommandBarOptions): void;
|
|
9
10
|
isInMenu(eventTarget: EventTarget | null): boolean;
|
|
10
11
|
handleShow: () => void;
|
|
11
12
|
handleClose: () => void;
|
|
@@ -12,6 +12,7 @@ export default class BlockMenuButtonDragHandler {
|
|
|
12
12
|
};
|
|
13
13
|
constructor(editor: OnesEditor, button: OnesEditorBlockMenuButton);
|
|
14
14
|
destroy(): void;
|
|
15
|
+
handleMouseDown: (event: MouseEvent) => void;
|
|
15
16
|
handleDragStart: (event: MouseEvent) => void;
|
|
16
17
|
handleDrag: (event: MouseEvent) => void;
|
|
17
18
|
handleDragEnd: (event: MouseEvent) => void;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { OnesEditor, BlockElement, InsertTextOptions } from '../../types';
|
|
2
2
|
import { DocBlockText, DocBox } from '../../doc';
|
|
3
|
+
export declare function getTextAttributes(editor: OnesEditor, containerId: string, blockIndex: number, offset: number): import("quill-delta/dist/AttributeMap").default | undefined;
|
|
3
4
|
export declare function editorInsertTextToBlock(editor: OnesEditor, block: BlockElement, offset: number, text: string | DocBlockText, options?: InsertTextOptions): DocBlockText;
|
|
4
5
|
export declare function editorInsertBoxToBlock(editor: OnesEditor, block: BlockElement, offset: number, boxData: DocBox): DocBlockText;
|
|
5
6
|
export declare function editorInsertTextToBlockEx(editor: OnesEditor, text: string | DocBlockText, containerId: string, blockIndex: number, offset: number): DocBlockText;
|
|
@@ -11,3 +11,17 @@ export declare function hashCode(str: string): number;
|
|
|
11
11
|
* 4. 默认处理从前取
|
|
12
12
|
*/
|
|
13
13
|
export declare function abbreviation(name: string, maxLength?: number): string;
|
|
14
|
+
declare enum EColor {
|
|
15
|
+
blue = "#338FE5",
|
|
16
|
+
cyan = "#34AFDE",
|
|
17
|
+
teal = "#2CB2AE",
|
|
18
|
+
green = "#24B47E",
|
|
19
|
+
kelly = "#8AAB3F",
|
|
20
|
+
yellow = "#F0A100",
|
|
21
|
+
orange = "#EB6414",
|
|
22
|
+
red = "#E52727",
|
|
23
|
+
fuchsia = "#BE507D",
|
|
24
|
+
purple = "#9678D3"
|
|
25
|
+
}
|
|
26
|
+
export declare function getColorFromContent(content: string): EColor;
|
|
27
|
+
export {};
|