@ones-editor/editor 1.1.0-beta.1 → 1.1.0-beta.2

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 { OnesEditor, BlockElement } from '../../types';
1
+ import { OnesEditor, BlockElement, InsertTextOptions } from '../../types';
2
2
  import { DocBlockText, DocBlockTextActions } from '../../doc';
3
- export declare function editorUpdateBlockText(editor: OnesEditor, block: BlockElement, ops: DocBlockTextActions): DocBlockText;
4
- export declare function editorSetBlockText(editor: OnesEditor, block: BlockElement, newText: DocBlockText): void;
3
+ export declare function editorUpdateBlockText(editor: OnesEditor, block: BlockElement, ops: DocBlockTextActions, options?: InsertTextOptions): DocBlockText;
4
+ export declare function editorSetBlockText(editor: OnesEditor, block: BlockElement, newText: DocBlockText, options?: InsertTextOptions): void;
@@ -1,3 +1,3 @@
1
- import { OnesEditor } from '../../types';
1
+ import { InsertTextOptions, OnesEditor } from '../../types';
2
2
  import { DocBox } from '../../doc';
3
- export declare function editorUpdateBoxData(editor: OnesEditor, boxData: DocBox): void;
3
+ export declare function editorUpdateBoxData(editor: OnesEditor, boxData: DocBox, options?: InsertTextOptions): void;
@@ -537,7 +537,7 @@ export interface OnesEditor extends TypedEmitter<OnesEditorEvents> {
537
537
  deleteChildContainers: (containerIds: string[]) => void;
538
538
  updateBlockData: (block: BlockElement, data: DocBlockAttributes, newRange?: SelectionRange) => DocBlock;
539
539
  updateEmbedData: (block: BlockElement, data: DocEmbedData, newRange?: SelectionRange) => DocBlock;
540
- updateBoxData: (boxData: DocBox) => void;
540
+ updateBoxData: (boxData: DocBox, options?: InsertTextOptions) => void;
541
541
  updateCompositionText: (text: string, end: boolean) => void;
542
542
  getColor: (index: number, type?: string) => string;
543
543
  }
@@ -0,0 +1,7 @@
1
+ import { BoxContentElement, OnesEditor } from '../../../../@ones-editor/core';
2
+ import { OverflowTooltipTag } from './overflow-tooltip-tag';
3
+ import { StatusBoxData } from '../types';
4
+ export declare class CreateStatusTag {
5
+ static tagRef: Map<string, OverflowTooltipTag>;
6
+ static create(editor: OnesEditor, classes: string[], data: StatusBoxData, boxContent: BoxContentElement): OverflowTooltipTag | undefined;
7
+ }
@@ -0,0 +1,17 @@
1
+ import { OnesEditor } from '../../../../@ones-editor/core';
2
+ export declare class OverflowTooltipTag {
3
+ private editor;
4
+ root: HTMLElement;
5
+ private ro?;
6
+ private mo?;
7
+ constructor(editor: OnesEditor, title: string, classes: string[], parent: HTMLElement);
8
+ private replaceTitleSpace;
9
+ private check;
10
+ private observeResize;
11
+ private handleContentChange;
12
+ private observeRemoval;
13
+ private unbindResizeObserver;
14
+ private unbindMutationObserver;
15
+ rebind(root: HTMLElement): void;
16
+ changeTag(title: string, classes: string[]): void;
17
+ }
@@ -1,6 +1,5 @@
1
1
  declare const _default: {
2
2
  status: {
3
- defaultTitle: string;
4
3
  empty: string;
5
4
  command: {
6
5
  name: string;
@@ -1,6 +1,5 @@
1
1
  declare const _default: {
2
2
  status: {
3
- defaultTitle: string;
4
3
  empty: string;
5
4
  command: {
6
5
  name: string;
@@ -1,6 +1,5 @@
1
1
  declare const _default: {
2
2
  status: {
3
- defaultTitle: string;
4
3
  empty: string;
5
4
  command: {
6
5
  name: string;
@@ -14,7 +14,7 @@ export declare class StatusBoxEditor {
14
14
  handClose: () => void;
15
15
  handleKeyDown: (e: KeyboardEvent) => void;
16
16
  createPopupContent(title: string, color: StatusColor, subtle: boolean): HTMLDivElement;
17
- changeColor: (e: Event) => void;
17
+ onColorChange: (e: Event) => void;
18
18
  changeTitle: (e: Event) => void;
19
19
  destroy(): void;
20
20
  }