@ones-editor/editor 1.0.2-beta.14 → 1.0.2-beta.16

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.
@@ -1,4 +1,4 @@
1
- import type { OnesEditor, EditorInputHandlers } from '../../../../@ones-editor/core';
2
- export declare function handleCopyAction(editor: OnesEditor, inputHandlers: EditorInputHandlers | null, id: 'copy' | 'copy-markdown'): Promise<void>;
3
- export declare function handleCutAction(editor: OnesEditor, inputHandlers: EditorInputHandlers | null): Promise<void>;
4
- export declare function handlePasteAction(editor: OnesEditor, inputHandlers: EditorInputHandlers | null): Promise<void>;
1
+ import type { OnesEditor } from '../../../../@ones-editor/core';
2
+ export declare function handleCopyAction(editor: OnesEditor): Promise<void>;
3
+ export declare function handleCopyMarkdownAction(editor: OnesEditor): Promise<void>;
4
+ export declare function handleCutAction(editor: OnesEditor): Promise<void>;
@@ -1,16 +1,13 @@
1
- import { EditorInputHandlers } from '../../../../@ones-editor/core';
2
1
  import type { OnesEditor, OnesEditorContextMenuInstance } from '../../../../@ones-editor/core';
3
2
  import './context-menu.scss';
4
3
  declare class OnesEditorContextMenu implements OnesEditorContextMenuInstance {
5
4
  private editor;
6
5
  private contextMenu;
7
6
  private contextMenuCommandItems;
8
- contextMenuInputHandlers: EditorInputHandlers | null;
9
7
  constructor(editor: OnesEditor);
10
8
  destroy(): void;
11
9
  show(event: MouseEvent): void;
12
10
  private updateEditorCaret;
13
- private initInputHandlers;
14
11
  private handleContextMenu;
15
12
  private isInMenu;
16
13
  private isInEditor;
@@ -4,10 +4,5 @@ export declare function injectDocToHtmlFragment(htmlFragment: string, doc: DocOb
4
4
  export declare function addMetaToDoc(editor: OnesEditor, doc: DocObject): void;
5
5
  export type BeforeCopyCallback = (editor: OnesEditor, event: ClipboardEvent, doc: DocObject) => DocObject | boolean | undefined;
6
6
  export declare function editorCopy(editor: OnesEditor, event: ClipboardEvent, beforeCopy?: BeforeCopyCallback): void;
7
- type EditorCopyWithoutEventOptions = {
8
- copyAsMarkdown?: boolean;
9
- beforeCopy?: BeforeCopyCallback;
10
- };
11
- export declare function editorCopyWithoutEvent(editor: OnesEditor, options?: EditorCopyWithoutEventOptions): void;
7
+ export declare function editorCopyWithoutEvent(editor: OnesEditor): void;
12
8
  export declare function editorCopyBlock(editor: OnesEditor, block: BlockElement): Promise<boolean>;
13
- export {};
@@ -12,4 +12,3 @@ export * from './keyboard';
12
12
  export * from './converter';
13
13
  export * from './command-providers';
14
14
  export * from './composition';
15
- export { EditorInputHandlers } from './input-handler/input-handler';
@@ -29,4 +29,5 @@ export declare class EditorInputHandlers implements EditorInputCallbacks {
29
29
  pasteDocs(docs: OnesEditorDocs, event: ClipboardEvent | null, files: File[]): Promise<void>;
30
30
  destroy(): void;
31
31
  forEach(cb: (handler: OnesEditorInputHandler) => void): void;
32
+ private getClipboardData;
32
33
  }
@@ -1,3 +1,4 @@
1
+ import * as inputActions from '../input-handler/actions';
1
2
  import { ShortcutRecords } from '../types';
2
3
  declare const DefaultShortcuts: ShortcutRecords;
3
- export { DefaultShortcuts };
4
+ export { DefaultShortcuts, inputActions };
@@ -0,0 +1 @@
1
+ export declare function blob2String(blob: Blob): Promise<string>;
@@ -31,6 +31,7 @@ export * from './number';
31
31
  export * from './string';
32
32
  export * from './overflow-text';
33
33
  export * from './abbreviation';
34
+ export * from './blob-to-string';
34
35
  export { genId };
35
36
  export { assert };
36
37
  export { SimpleCache };