@worktile/theia 17.5.0 → 18.0.0-next.0

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.
Files changed (105) hide show
  1. package/esm2022/components/action/prevent-default.mjs +3 -3
  2. package/esm2022/components/column-resize/column-resize-notifier.mjs +3 -3
  3. package/esm2022/components/column-resize/column-resize.directive.mjs +3 -3
  4. package/esm2022/components/column-resize/event-dispatcher.mjs +3 -3
  5. package/esm2022/components/column-resize/overlay-handle.component.mjs +3 -3
  6. package/esm2022/components/column-resize/resizing.store.mjs +3 -3
  7. package/esm2022/components/contextmenu/contextmenu.component.mjs +4 -4
  8. package/esm2022/components/conversion-hint/conversion-hint.component.mjs +3 -3
  9. package/esm2022/components/element/element.component.mjs +3 -3
  10. package/esm2022/components/inline-toolbar/inline-toolbar.component.mjs +3 -3
  11. package/esm2022/components/listbox/listbox.mjs +9 -9
  12. package/esm2022/components/plugin-menu/plugin-menu.component.mjs +3 -3
  13. package/esm2022/components/table-select/table-select.component.mjs +3 -3
  14. package/esm2022/components/template/template.component.mjs +3 -3
  15. package/esm2022/components/text/text.component.mjs +3 -3
  16. package/esm2022/components/toolbar/toolbar.component.mjs +3 -3
  17. package/esm2022/components/toolbar-dropdown/toolbar-dropdown.component.mjs +3 -3
  18. package/esm2022/components/toolbar-group/toolbar-group.component.mjs +3 -3
  19. package/esm2022/components/toolbar-item/toolbar-item.component.mjs +3 -3
  20. package/esm2022/core/toolbar-item/base-toolbar-item.mjs +6 -6
  21. package/esm2022/editor.component.mjs +3 -3
  22. package/esm2022/editor.module.mjs +4 -4
  23. package/esm2022/interfaces/view-base.mjs +3 -3
  24. package/esm2022/pipes.mjs +9 -9
  25. package/esm2022/plugins/blockquote/blockquote.component.mjs +3 -3
  26. package/esm2022/plugins/code/code.component.mjs +3 -3
  27. package/esm2022/plugins/color/toolbar-item.component.mjs +3 -3
  28. package/esm2022/plugins/hr/hr.component.mjs +3 -3
  29. package/esm2022/plugins/image/image.component.mjs +3 -3
  30. package/esm2022/plugins/inline-code/inline-code.component.mjs +3 -3
  31. package/esm2022/plugins/link/edit/link-edit.component.mjs +3 -3
  32. package/esm2022/plugins/link/hover/link-hover.component.mjs +3 -3
  33. package/esm2022/plugins/link/link.component.mjs +6 -6
  34. package/esm2022/plugins/list/components/bulleted-list.component.mjs +3 -3
  35. package/esm2022/plugins/list/components/list-item.component.mjs +3 -3
  36. package/esm2022/plugins/list/components/numbered-list.component.mjs +3 -3
  37. package/esm2022/plugins/mention/suggestion.component.mjs +3 -3
  38. package/esm2022/plugins/quick-insert/components/quick-insert.component.mjs +3 -3
  39. package/esm2022/plugins/table/components/insert-mark/insert-mark.component.mjs +3 -3
  40. package/esm2022/plugins/table/components/row/row.component.mjs +3 -3
  41. package/esm2022/plugins/table/components/table.component.mjs +3 -3
  42. package/esm2022/plugins/table/components/td/td.component.mjs +3 -3
  43. package/esm2022/plugins/table/components/toolbar/table-options.component.mjs +3 -3
  44. package/esm2022/plugins/table/components/toolbar/table-toolbar.component.mjs +3 -3
  45. package/esm2022/plugins/table/table.pipe.mjs +9 -9
  46. package/esm2022/plugins/table/table.service.mjs +3 -3
  47. package/esm2022/plugins/table/table.store.mjs +3 -3
  48. package/esm2022/plugins/table/toolbar-item.component.mjs +3 -3
  49. package/esm2022/plugins/todo-item/todo-item.component.mjs +3 -3
  50. package/esm2022/plugins/vertical-align/toolbar-item.component.mjs +3 -3
  51. package/esm2022/services/context.service.mjs +3 -3
  52. package/esm2022/services/table-contextmenu.service.mjs +3 -3
  53. package/esm2022/services/toolbar.service.mjs +3 -3
  54. package/esm2022/test/basic/basic.component.mjs +3 -3
  55. package/esm2022/test/faker/tethys-icon-faker.mjs +3 -3
  56. package/fesm2022/worktile-theia.mjs +190 -190
  57. package/fesm2022/worktile-theia.mjs.map +1 -1
  58. package/interfaces/editor.d.ts +6 -6
  59. package/package.json +5 -5
  60. package/plugins/align/align.plugin.d.ts +2 -1
  61. package/plugins/autoformat/autoformat.plugin.d.ts +2 -1
  62. package/plugins/blockquote/blockquote.plugin.d.ts +2 -1
  63. package/plugins/code/code.plugin.d.ts +2 -1
  64. package/plugins/common/block-card.plugin.d.ts +2 -1
  65. package/plugins/common/common.plugin.d.ts +2 -1
  66. package/plugins/common/get-fragment.plugin.d.ts +2 -1
  67. package/plugins/common/history.plugin.d.ts +1 -1
  68. package/plugins/common/insert-data-by-invalid-type.d.ts +2 -1
  69. package/plugins/common/move-selection.plugin.d.ts +2 -1
  70. package/plugins/common/remove-empty.plugin.d.ts +2 -1
  71. package/plugins/common/remove-void.plugin.d.ts +2 -1
  72. package/plugins/common/reset-type.plugin.d.ts +2 -1
  73. package/plugins/deserialize/deserialize-html.plugin.d.ts +2 -1
  74. package/plugins/deserialize/deserialize-md.plugin.d.ts +1 -1
  75. package/plugins/heading/heading.plugin.d.ts +2 -1
  76. package/plugins/hr/hr.plugin.d.ts +2 -1
  77. package/plugins/image/image.plugin.d.ts +2 -1
  78. package/plugins/indent/indent.plugin.d.ts +2 -1
  79. package/plugins/inline-code/inline-code.plugin.d.ts +2 -1
  80. package/plugins/link/link.plugin.d.ts +2 -1
  81. package/plugins/list/list.plugin.d.ts +2 -1
  82. package/plugins/list/queries/is-node-type-list.d.ts +2 -2
  83. package/plugins/mark/mark.plugin.d.ts +2 -1
  84. package/plugins/mention/mention.plugin.d.ts +2 -1
  85. package/plugins/node-id/node-id.plugin.d.ts +2 -1
  86. package/plugins/normalizers/insert-paragraph-nodes.d.ts +2 -1
  87. package/plugins/normalizers/trailing-node.plugin.d.ts +2 -1
  88. package/plugins/paint-format/paint-format.editor.d.ts +1 -9
  89. package/plugins/quick-insert/quick-insert.plugin.d.ts +1 -1
  90. package/plugins/table/table.editor.d.ts +4 -12
  91. package/plugins/todo-item/todo-item.plugin.d.ts +2 -1
  92. package/queries/find-descendant.d.ts +1 -1
  93. package/queries/find-node.d.ts +1 -1
  94. package/queries/get-above-by-type.d.ts +1 -1
  95. package/queries/get-anchor-block-entry.d.ts +2 -2
  96. package/queries/get-block-above.d.ts +1 -1
  97. package/queries/get-block-card-above.d.ts +1 -1
  98. package/queries/get-nodes-by-type.d.ts +1 -1
  99. package/queries/get-rang-from-block-start.d.ts +1 -1
  100. package/queries/get-selection-marks.d.ts +1 -9
  101. package/queries/is-node-type-in.d.ts +1 -1
  102. package/queries/is-range-across-blocks.d.ts +1 -1
  103. package/transforms/merge-deep-to-nodes.d.ts +1 -1
  104. package/transforms/set-marks.d.ts +1 -9
  105. package/transforms/unwrap-nodes-by-type.d.ts +1 -1
@@ -48,14 +48,14 @@ export declare const TheEditor: {
48
48
  setFragmentData(editor: AngularEditor, data: DataTransfer, originEvent?: import("slate-angular").OriginEvent): void;
49
49
  deleteCutData(editor: AngularEditor): void;
50
50
  toDOMNode(editor: AngularEditor, node: Node): HTMLElement;
51
- toDOMPoint(editor: AngularEditor, point: import("slate").BasePoint, options: {
52
- range: import("slate").BaseRange;
51
+ toDOMPoint(editor: AngularEditor, point: Point, options: {
52
+ range: Range;
53
53
  }): import("slate-angular").DOMPoint;
54
- toDOMRange(editor: AngularEditor, range: import("slate").BaseRange): globalThis.Range;
54
+ toDOMRange(editor: AngularEditor, range: Range): globalThis.Range;
55
55
  toSlateNode<T extends boolean>(editor: AngularEditor, domNode: globalThis.Node, options?: {
56
56
  suppressThrow: T;
57
57
  }): T extends true ? Node : Node;
58
- findEventRange(editor: AngularEditor, event: any): import("slate").BaseRange;
58
+ findEventRange(editor: AngularEditor, event: any): Range;
59
59
  isLeafInEditor(editor: AngularEditor, leafNode: globalThis.Element, options: {
60
60
  suppressThrow: boolean;
61
61
  }): boolean;
@@ -71,7 +71,7 @@ export declare const TheEditor: {
71
71
  isBlockCardLeftCursor(editor: AngularEditor): boolean;
72
72
  isBlockCardRightCursor(editor: AngularEditor): boolean;
73
73
  getCardCursorNode(editor: AngularEditor, blockCardNode: Node, options: {
74
- direction: "center" | "left" | "right";
74
+ direction: "left" | "right" | "center";
75
75
  }): ChildNode;
76
76
  toSlateCardEntry(editor: AngularEditor, node: globalThis.Node): NodeEntry;
77
77
  moveBlockCard(editor: AngularEditor, blockCardNode: Node, options: {
@@ -80,7 +80,7 @@ export declare const TheEditor: {
80
80
  moveBlockCardCursor(editor: AngularEditor, path: Path, options: {
81
81
  direction: "left" | "right";
82
82
  }): void;
83
- hasRange(editor: AngularEditor, range: import("slate").BaseRange): boolean;
83
+ hasRange(editor: AngularEditor, range: Range): boolean;
84
84
  };
85
85
  export declare enum TheDataMode {
86
86
  json = "json",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@worktile/theia",
3
- "version": "17.5.0",
3
+ "version": "18.0.0-next.0",
4
4
  "description": "theia editor",
5
5
  "author": "YanDong <nanianqiumo@foxmail.com>",
6
6
  "homepage": "https://github.com/atinc/theia#readme",
@@ -37,12 +37,12 @@
37
37
  "marked": "^12.0.2"
38
38
  },
39
39
  "peerDependencies": {
40
- "@angular/core": "^17.2.4",
40
+ "@angular/core": "^18.0.0",
41
41
  "date-fns": ">= 2.6.0",
42
- "slate-angular": ">= 17.4.0",
42
+ "slate-angular": ">= 18.0.0-next.0",
43
43
  "slate": ">= 0.103.0",
44
- "ngx-tethys": "^17.0.0",
45
- "ng-codemirror": "^17.0.0",
44
+ "ngx-tethys": "^18.0.0",
45
+ "ng-codemirror": "^18.0.0",
46
46
  "lodash": "3.10.1",
47
47
  "marked": "^12.0.2"
48
48
  },
@@ -1,2 +1,3 @@
1
- export declare const withAlign: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withAlign: <T extends Editor>(editor: T) => T;
2
3
  export declare const createAlignPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,6 +1,7 @@
1
+ import { Editor } from 'slate';
1
2
  import { AutoFormatRule } from '../../interfaces/auto-format';
2
3
  export interface AutoFormatOptions {
3
4
  autoFormatRules?: AutoFormatRule[];
4
5
  }
5
- export declare const withAutoFormat: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
6
+ export declare const withAutoFormat: <T extends Editor>(editor: T) => T;
6
7
  export declare const createAutoFormatPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, AutoFormatOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, AutoFormatOptions>;
@@ -1,2 +1,3 @@
1
- export declare const withBlockquote: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withBlockquote: <T extends Editor>(editor: T) => T;
2
3
  export declare const createBlockquotePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withCode: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withCode: <T extends Editor>(editor: T) => T;
2
3
  export declare const createCodePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withBlockCard: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withBlockCard: <T extends Editor>(editor: T) => T;
2
3
  export declare const createBlockCardPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withInternalCommon: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withInternalCommon: <T extends Editor>(editor: T) => T;
2
3
  export declare const createCommonPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,6 +1,7 @@
1
+ import { Editor } from 'slate';
1
2
  import { CustomElementKinds } from '../../custom-types';
2
3
  export interface GetFragmentPluginOptions {
3
4
  types?: CustomElementKinds[];
4
5
  }
5
- export declare const withGetFragment: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
6
+ export declare const withGetFragment: <T extends Editor>(editor: T) => T;
6
7
  export declare const createGetFragmentPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, GetFragmentPluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, GetFragmentPluginOptions>;
@@ -1,7 +1,7 @@
1
1
  import { Editor } from 'slate';
2
2
  export declare const UNDOING: WeakMap<import("../../interfaces").TheEditor, boolean>;
3
3
  export declare const REDOING: WeakMap<import("../../interfaces").TheEditor, boolean>;
4
- export declare const withTheHistory: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
4
+ export declare const withTheHistory: <T extends Editor>(editor: T) => T;
5
5
  export declare const TheHistoryEditor: {
6
6
  isUndoing(editor: Editor): boolean | undefined;
7
7
  isRedoing(editor: Editor): boolean | undefined;
@@ -1,2 +1,3 @@
1
- export declare const withInsertDataByInvalidType: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withInsertDataByInvalidType: <T extends Editor>(editor: T) => T;
2
3
  export declare const createInsertDataByInvalidTypePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withMoveSelection: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withMoveSelection: <T extends Editor>(editor: T) => T;
2
3
  export declare const createMoveSelectionPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withRemoveEmpty: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withRemoveEmpty: <T extends Editor>(editor: T) => T;
2
3
  export declare const createRemoveEmptyPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withRemoveVoid: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withRemoveVoid: <T extends Editor>(editor: T) => T;
2
3
  export declare const createRemoveVoidPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withResetType: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withResetType: <T extends Editor>(editor: T) => T;
2
3
  export declare const createResetTypePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withDeserializeHTML: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withDeserializeHTML: <T extends Editor>(editor: T) => T;
2
3
  export declare const createDeserializeHTMLPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,4 +1,4 @@
1
1
  import { Editor } from 'slate';
2
2
  export declare const closeConversionHint: (editor: Editor) => void;
3
- export declare const withDeserializeMd: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
3
+ export declare const withDeserializeMd: <T extends Editor>(editor: T) => T;
4
4
  export declare const createDeserializeMdPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,7 +1,8 @@
1
+ import { Editor } from 'slate';
1
2
  import { CustomElementKinds } from '../../custom-types';
2
3
  import { ThePluginBaseOption } from '../../interfaces';
3
4
  export type HeadingPluginOptions = {
4
5
  cleanupTypes: CustomElementKinds[];
5
6
  } & ThePluginBaseOption;
6
- export declare const withHeading: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
7
+ export declare const withHeading: <T extends Editor>(editor: T) => T;
7
8
  export declare const createHeadingPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, HeadingPluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, HeadingPluginOptions>;
@@ -1,2 +1,3 @@
1
- export declare const withHr: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withHr: <T extends Editor>(editor: T) => T;
2
3
  export declare const createHrPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,3 +1,4 @@
1
+ import { Editor } from 'slate';
1
2
  import { ImagePluginOptions } from '../../interfaces';
2
- export declare const withImage: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
3
+ export declare const withImage: <T extends Editor>(editor: T) => T;
3
4
  export declare const createImagePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, ImagePluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, ImagePluginOptions>;
@@ -1,8 +1,9 @@
1
+ import { Editor } from 'slate';
1
2
  import { CustomElementKinds } from '../../custom-types';
2
3
  export interface IndentPluginOptions {
3
4
  maxIndent?: number;
4
5
  allowedTypes?: CustomElementKinds[];
5
6
  disableIndentTypes?: CustomElementKinds[];
6
7
  }
7
- export declare const withIndent: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
8
+ export declare const withIndent: <T extends Editor>(editor: T) => T;
8
9
  export declare const createIndentPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, IndentPluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, IndentPluginOptions>;
@@ -1,2 +1,3 @@
1
- export declare const withInlineCode: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withInlineCode: <T extends Editor>(editor: T) => T;
2
3
  export declare const createInlineCodePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,2 +1,3 @@
1
- export declare const withLink: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
1
+ import { Editor } from 'slate';
2
+ export declare const withLink: <T extends Editor>(editor: T) => T;
2
3
  export declare const createLinkPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,3 +1,4 @@
1
+ import { Editor } from 'slate';
1
2
  import { WithListOptions } from './types';
2
- export declare const withList: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
3
+ export declare const withList: <T extends Editor>(editor: T) => T;
3
4
  export declare const createListPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, WithListOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, WithListOptions>;
@@ -1,2 +1,2 @@
1
- import { Node } from 'slate';
2
- export declare const isNodeTypeList: (n: Node) => n is import("@worktile/theia").CustomElement;
1
+ import { Element, Node } from 'slate';
2
+ export declare const isNodeTypeList: (n: Node) => n is Element;
@@ -1,3 +1,4 @@
1
+ import { Editor } from 'slate';
1
2
  import { MarkEditor } from './mark.editor';
2
- export declare const withMark: <T extends import("../../interfaces").TheEditor & MarkEditor>(editor: T) => T;
3
+ export declare const withMark: <T extends Editor & MarkEditor>(editor: T) => T;
3
4
  export declare const createMarkPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,3 +1,4 @@
1
+ import { Editor } from 'slate';
1
2
  import { MentionPluginOptions } from './mention.type';
2
- export declare const withMention: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
3
+ export declare const withMention: <T extends Editor>(editor: T) => T;
3
4
  export declare const createMentionPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, MentionPluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, MentionPluginOptions>;
@@ -1,8 +1,9 @@
1
+ import { Editor } from 'slate';
1
2
  import { QueryOptions } from '../../interfaces';
2
3
  export interface WithNodeIDProps extends QueryOptions {
3
4
  idKey?: string;
4
5
  idCreator?: () => void;
5
6
  filterText?: boolean;
6
7
  }
7
- export declare const withNodeID: <T extends import("../../interfaces").TheEditor>(e: T) => T;
8
+ export declare const withNodeID: <T extends Editor>(e: T) => T;
8
9
  export declare const createNodeIDPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, WithNodeIDProps>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, WithNodeIDProps>;
@@ -1,6 +1,7 @@
1
+ import { Editor } from 'slate';
1
2
  import { CustomElementKinds } from '../../custom-types';
2
3
  export interface InsertParagraphNodesOptions {
3
4
  types: CustomElementKinds[];
4
5
  }
5
- export declare const withInsertParagraphNodes: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
6
+ export declare const withInsertParagraphNodes: <T extends Editor>(editor: T) => T;
6
7
  export declare const createInsertParagraphNodesPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, InsertParagraphNodesOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, InsertParagraphNodesOptions>;
@@ -1,8 +1,9 @@
1
+ import { Editor } from 'slate';
1
2
  import { CustomElementKinds } from '../../custom-types';
2
3
  import { QueryOptions } from '../../interfaces';
3
4
  export interface WithTrailingNode extends QueryOptions {
4
5
  type?: CustomElementKinds;
5
6
  level?: number;
6
7
  }
7
- export declare const withTrailingNode: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
8
+ export declare const withTrailingNode: <T extends Editor>(editor: T) => T;
8
9
  export declare const createTrailingNodePlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, {}>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, {}>;
@@ -1,15 +1,7 @@
1
1
  import { MarkTypes } from '../../constants';
2
2
  import { TheEditor } from '../../interfaces';
3
3
  export declare const PaintFormatEditor: {
4
- formatBrush(editor: TheEditor, marks: {
5
- bold?: any;
6
- italic?: any;
7
- underlined?: any;
8
- strike?: any;
9
- color?: any;
10
- "background-color"?: any;
11
- "font-size"?: any;
12
- }): void;
4
+ formatBrush(editor: TheEditor, marks: { [key in MarkTypes]?: any; }): void;
13
5
  isActive(editor: TheEditor): boolean;
14
6
  enableFormatBrush(editor: TheEditor): void;
15
7
  cancelFormatBrushStatus(editor: TheEditor): void;
@@ -6,6 +6,6 @@ export interface QuickInsertPluginOptions {
6
6
  disabledPlus?: boolean;
7
7
  allowHotkeyInTypes?: CustomElementKinds[];
8
8
  }
9
- export declare const withQuickInsert: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
9
+ export declare const withQuickInsert: <T extends Editor>(editor: T) => T;
10
10
  export declare const createQuickInsertPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, QuickInsertPluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, QuickInsertPluginOptions>;
11
11
  export declare const allowOpenInsertMenu: (editor: Editor, allowTypes: ElementKinds[]) => boolean;
@@ -1,6 +1,6 @@
1
- import { Editor, Location, NodeEntry, Path, Point, Range } from 'slate';
1
+ import { Editor, Element, Location, NodeEntry, Path, Point, Range } from 'slate';
2
2
  import { Alignment, Indents, MarkTypes, VerticalAlignment } from '../../constants';
3
- import { CustomElement, TableCellElement, TableElement } from '../../custom-types';
3
+ import { TableCellElement, TableElement } from '../../custom-types';
4
4
  import { TheEditor } from '../../interfaces';
5
5
  import { TableOptions, TheTableOptions } from './table.types';
6
6
  export declare const TableEditor: {
@@ -10,7 +10,7 @@ export declare const TableEditor: {
10
10
  removeTable(editor: Editor, optionsParam?: TableOptions): void;
11
11
  removeRow(editor: Editor, rowIndex?: number, optionsParam?: TableOptions): void;
12
12
  removeColumn(editor: Editor, colIndex?: number, optionsParam?: TableOptions): void;
13
- clearCell(editor: Editor, nodeEntry?: NodeEntry<CustomElement>, optionsParam?: TableOptions): void;
13
+ clearCell(editor: Editor, nodeEntry?: NodeEntry<Element>, optionsParam?: TableOptions): void;
14
14
  setCellsBackgroundColor(editor: Editor, color: string, cells?: TableCellElement[]): void;
15
15
  mergeCell(editor: Editor): void;
16
16
  splitCell(editor: Editor): void;
@@ -25,15 +25,7 @@ export declare const TableEditor: {
25
25
  isVerticalAlignActive(editor: TheEditor, alignment: VerticalAlignment): boolean;
26
26
  toggleMark(editor: TheEditor, isActive: boolean, format: string | string[], value?: string | number | boolean): boolean;
27
27
  clearMark(editor: TheEditor): boolean;
28
- formatBrush(editor: TheEditor, marks: {
29
- bold?: any;
30
- italic?: any;
31
- underlined?: any;
32
- strike?: any;
33
- color?: any;
34
- "background-color"?: any;
35
- "font-size"?: any;
36
- }): boolean;
28
+ formatBrush(editor: TheEditor, marks: { [key in MarkTypes]?: any; }): boolean;
37
29
  handleSelectedCells(editor: TheEditor, handle: (cellPath: Path, cellRange: Range) => void, cells?: TableCellElement[]): boolean;
38
30
  hasHeaderRow(editor: TheEditor, location?: Location): boolean;
39
31
  hasHeaderColumn(editor: TheEditor, location?: Location): boolean;
@@ -1,5 +1,6 @@
1
+ import { Editor } from 'slate';
1
2
  export interface TodoItemPluginOptions {
2
3
  editableWithReadonly?: boolean;
3
4
  }
4
- export declare const withTodoItem: <T extends import("../../interfaces").TheEditor>(editor: T) => T;
5
+ export declare const withTodoItem: <T extends Editor>(editor: T) => T;
5
6
  export declare const createTodoItemPlugin: <T = {}>(override?: Partial<import("../../interfaces").ThePlugin<T, TodoItemPluginOptions>>, overrideByKey?: import("../../interfaces").OverrideByKey) => import("../../interfaces").ThePlugin<T, TodoItemPluginOptions>;
@@ -7,4 +7,4 @@ import { FindNodeOptions } from './find-node';
7
7
  /**
8
8
  * Get the first descendant node matching the condition.
9
9
  */
10
- export declare const findDescendant: <T extends Node = Node>(editor: Editor, options: FindNodeOptions<T>) => NodeEntry<T>;
10
+ export declare const findDescendant: <T extends Node = Node>(editor: Editor, options: FindNodeOptions<T>) => NodeEntry<T> | undefined;
@@ -12,4 +12,4 @@ export type FindNodeOptions<T extends Node = Node> = {
12
12
  /**
13
13
  * Find node matching the condition.
14
14
  */
15
- export declare const findNode: <T extends Node = Node>(editor: Editor, options: FindNodeOptions<T>) => NodeEntry<T>;
15
+ export declare const findNode: <T extends Node = Node>(editor: Editor, options: FindNodeOptions<T>) => NodeEntry<T> | undefined;
@@ -3,4 +3,4 @@ import { EditorAboveOptions } from '../interfaces';
3
3
  /**
4
4
  * Get the block above a location (default: selection) by type.
5
5
  */
6
- export declare const getAboveByType: (editor: Editor, types: string[] | string, options?: Omit<EditorAboveOptions, 'match'>) => import("slate").NodeEntry<import("slate").Ancestor>;
6
+ export declare const getAboveByType: (editor: Editor, types: string[] | string, options?: Omit<EditorAboveOptions, "match">) => import("slate").NodeEntry<import("slate").Ancestor>;
@@ -1,2 +1,2 @@
1
- import { Editor, NodeEntry, Path, Point } from 'slate';
2
- export declare const getAnchorBlockEntry: (editor: Editor, at?: Path | Point) => NodeEntry<import("@worktile/theia").CustomElement>;
1
+ import { Editor, NodeEntry, Path, Point, Element } from 'slate';
2
+ export declare const getAnchorBlockEntry: (editor: Editor, at?: Path | Point) => NodeEntry<Element>;
@@ -4,4 +4,4 @@ import { EditorAboveOptions } from '../interfaces';
4
4
  * Get the block above a location (default: selection).
5
5
  * If not found, return the editor entry.
6
6
  */
7
- export declare const getBlockAbove: (editor: Editor, options?: Omit<EditorAboveOptions, 'match'>) => NodeEntry<Ancestor>;
7
+ export declare const getBlockAbove: (editor: Editor, options?: Omit<EditorAboveOptions, "match">) => NodeEntry<Ancestor>;
@@ -4,4 +4,4 @@ import { EditorAboveOptions } from '../interfaces/editor';
4
4
  * Get the block above a location (default: selection).
5
5
  * If not found, return the editor entry.
6
6
  */
7
- export declare const getBlockCardAbove: (editor: Editor, options?: Omit<EditorAboveOptions, 'match'>) => NodeEntry<Ancestor>;
7
+ export declare const getBlockCardAbove: (editor: Editor, options?: Omit<EditorAboveOptions, "match">) => NodeEntry<Ancestor>;
@@ -3,4 +3,4 @@ import { EditorNodesOptions } from '../interfaces';
3
3
  /**
4
4
  * Get the nodes with a type included in `types` at a location (default: selection).
5
5
  */
6
- export declare const getNodesByType: (editor: Editor, types: string[] | string, options?: Omit<EditorNodesOptions, 'match'>) => Generator<import("slate").NodeEntry<import("slate").Node>, void, undefined>;
6
+ export declare const getNodesByType: (editor: Editor, types: string[] | string, options?: Omit<EditorNodesOptions, "match">) => Generator<import("slate").NodeEntry<import("slate").Node>, void, undefined>;
@@ -3,7 +3,7 @@ import { EditorAboveOptions } from '../interfaces';
3
3
  /**
4
4
  * Get the range from the start of the block above a location (default: selection) to the location.
5
5
  */
6
- export declare const getRangeFromBlockStart: (editor: Editor, options?: Omit<EditorAboveOptions, 'match'>) => false | {
6
+ export declare const getRangeFromBlockStart: (editor: Editor, options?: Omit<EditorAboveOptions, "match">) => false | {
7
7
  anchor: import("slate").BasePoint;
8
8
  focus: import("slate").BasePoint;
9
9
  };
@@ -1,11 +1,3 @@
1
1
  import { Editor } from 'slate';
2
2
  import { MarkTypes } from '../constants';
3
- export declare const getSelectionMarks: (editor: Editor) => {
4
- bold?: any;
5
- italic?: any;
6
- underlined?: any;
7
- strike?: any;
8
- color?: any;
9
- "background-color"?: any;
10
- "font-size"?: any;
11
- };
3
+ export declare const getSelectionMarks: (editor: Editor) => { [key in MarkTypes]?: any; };
@@ -3,4 +3,4 @@ import { EditorNodesOptions } from '../interfaces';
3
3
  /**
4
4
  * Is there a node with a type included in `types` at a location (default: selection).
5
5
  */
6
- export declare const isNodeTypeIn: (editor: Editor, types: string[] | string, options?: Omit<EditorNodesOptions, 'match'>) => boolean;
6
+ export declare const isNodeTypeIn: (editor: Editor, types: string[] | string, options?: Omit<EditorNodesOptions, "match">) => boolean;
@@ -3,6 +3,6 @@ import { EditorAboveOptions } from '../interfaces';
3
3
  /**
4
4
  * Is the range (default: selection) across blocks.
5
5
  */
6
- export declare const isRangeAcrossBlocks: (editor: Editor, { at, ...options }?: Omit<EditorAboveOptions<import("slate").Ancestor>, "at" | "match"> & {
6
+ export declare const isRangeAcrossBlocks: (editor: Editor, { at, ...options }?: Omit<EditorAboveOptions, "at" | "match"> & {
7
7
  at?: Range | null;
8
8
  }) => boolean;
@@ -2,4 +2,4 @@ import { ApplyDeepToNodesOptions } from './apply-deep-to-nodes';
2
2
  /**
3
3
  * Recursively merge a source object to children nodes with a query.
4
4
  */
5
- export declare const mergeDeepToNodes: (options: Omit<ApplyDeepToNodesOptions, 'apply'>) => void;
5
+ export declare const mergeDeepToNodes: (options: Omit<ApplyDeepToNodesOptions, "apply">) => void;
@@ -1,11 +1,3 @@
1
1
  import { Editor, Path, Point, Range } from 'slate';
2
2
  import { MarkTypes } from '../constants';
3
- export declare const setMarks: (editor: Editor, marks: {
4
- bold?: any;
5
- italic?: any;
6
- underlined?: any;
7
- strike?: any;
8
- color?: any;
9
- "background-color"?: any;
10
- "font-size"?: any;
11
- }, at?: Path | Point | Range) => void;
3
+ export declare const setMarks: (editor: Editor, marks: { [key in MarkTypes]?: any; }, at?: Path | Point | Range) => void;
@@ -3,4 +3,4 @@ import { WrapOptions } from '../interfaces';
3
3
  /**
4
4
  * Unwrap nodes by type
5
5
  */
6
- export declare const unwrapNodesByType: (editor: Editor, types: string[] | string, options?: Omit<WrapOptions, 'match'>) => void;
6
+ export declare const unwrapNodesByType: (editor: Editor, types: string[] | string, options?: Omit<WrapOptions, "match">) => void;