@wangeditor-next/plugin-float-image 1.0.29 → 1.0.30

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.
@@ -6,7 +6,6 @@ import { Descendant, Element as SlateElement } from 'slate';
6
6
  import { IDomEditor } from '../editor/interface';
7
7
  import { DOMElement } from '../utils/dom';
8
8
  export declare const TEXT_TAGS: string[];
9
- export declare const SPAN_WITH_SPECIAL_TAGS: string[];
10
9
  export type PreParseHtmlFnType = ($node: DOMElement) => DOMElement;
11
10
  export interface IPreParseHtmlConf {
12
11
  selector: string;
@@ -24,6 +24,7 @@ export type TableCellElement = {
24
24
  export type TableRowElement = {
25
25
  type: 'table-row';
26
26
  children: TableCellElement[];
27
+ height?: number;
27
28
  };
28
29
  export type TableElement = {
29
30
  type: 'table';
@@ -36,4 +37,8 @@ export type TableElement = {
36
37
  isResizing?: boolean | null;
37
38
  isHoverCellBorder?: boolean;
38
39
  columnWidths?: number[];
40
+ /** row resize */
41
+ resizingRowIndex?: number;
42
+ isResizingRow?: boolean | null;
43
+ isHoverRowBorder?: boolean;
39
44
  };
@@ -11,7 +11,7 @@ export declare const parseCellHtmlConf: {
11
11
  selector: string;
12
12
  parseElemHtml: typeof parseCellHtml;
13
13
  };
14
- declare function parseRowHtml(_elem: DOMElement, children: Descendant[], _editor: IDomEditor): TableRowElement;
14
+ declare function parseRowHtml(elem: DOMElement, children: Descendant[], _editor: IDomEditor): TableRowElement;
15
15
  export declare const parseRowHtmlConf: {
16
16
  selector: string;
17
17
  parseElemHtml: typeof parseRowHtml;
@@ -5,5 +5,5 @@
5
5
  import { IDomEditor } from '@wangeditor-next/core';
6
6
  import { Element as SlateElement } from 'slate';
7
7
  import { VNode } from 'snabbdom';
8
- declare function renderTableRow(_elemNode: SlateElement, children: VNode[] | null, _editor: IDomEditor): VNode;
8
+ declare function renderTableRow(elemNode: SlateElement, children: VNode[] | null, _editor: IDomEditor): VNode;
9
9
  export default renderTableRow;
@@ -0,0 +1,15 @@
1
+ import { IDomEditor } from '@wangeditor-next/core';
2
+ import { Element as SlateElement } from 'slate';
3
+ /**
4
+ * 计算行高度的比例
5
+ */
6
+ export declare function getRowHeightRatios(rowHeights: number[]): number[];
7
+ /**
8
+ * 鼠标移动时,判断在哪个行边界上
9
+ */
10
+ export declare function handleRowBorderVisible(editor: IDomEditor, elemNode: SlateElement, e: MouseEvent): void;
11
+ /**
12
+ * 设置行拖拽高亮
13
+ */
14
+ export declare function handleRowBorderHighlight(editor: IDomEditor, e: MouseEvent): void;
15
+ export declare function handleRowBorderMouseDown(editor: IDomEditor, _elemNode: SlateElement): void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wangeditor-next/plugin-float-image",
3
- "version": "1.0.29",
3
+ "version": "1.0.30",
4
4
  "description": "wangEditor float image plugin",
5
5
  "author": "cycleccc <2991205548@qq.com>",
6
6
  "type": "module",
@@ -34,7 +34,7 @@
34
34
  "url": "https://github.com/wangeditor-next/wangeditor-next/issues"
35
35
  },
36
36
  "peerDependencies": {
37
- "@wangeditor-next/editor": "5.6.44",
37
+ "@wangeditor-next/editor": "5.6.45",
38
38
  "dom7": "^3.0.0 || ^4.0.0",
39
39
  "slate": "^0.82.0",
40
40
  "snabbdom": "^3.6.0"