@ones-editor/editor 2.1.7-beta.3 → 2.1.7-beta.31

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 (255) hide show
  1. package/@ones-editor/block-menu/src/block-menu-button/menu-button/index.d.ts +1 -1
  2. package/@ones-editor/block-menu/src/index.d.ts +0 -1
  3. package/@ones-editor/block-padding/src/index.d.ts +1 -1
  4. package/@ones-editor/block-resizer/src/index.d.ts +1 -0
  5. package/@ones-editor/callout-block/src/callout-block/callout-quick-menu-item-filter.d.ts +3 -4
  6. package/@ones-editor/callout-block/src/index.d.ts +1 -0
  7. package/@ones-editor/comments/src/block-hook/block-comment-hook.d.ts +10 -0
  8. package/@ones-editor/comments/src/comment-quick-reply/index.d.ts +1 -0
  9. package/@ones-editor/comments/src/comments-helper/get-comment-abstract.d.ts +2 -1
  10. package/@ones-editor/comments/src/index.d.ts +2 -1
  11. package/@ones-editor/comments/src/text-comments/comments-command-provider.d.ts +4 -3
  12. package/@ones-editor/core/src/core/block-renderers/block-renderers.d.ts +1 -0
  13. package/@ones-editor/core/src/core/blocks/common/execute-block-command.d.ts +2 -2
  14. package/@ones-editor/core/src/core/blocks/complex-blocks/complex-block-helper.d.ts +2 -5
  15. package/@ones-editor/core/src/core/blocks/text-blocks/base/child.d.ts +1 -2
  16. package/@ones-editor/core/src/core/blocks/text-blocks/base/line-breaks.d.ts +1 -2
  17. package/@ones-editor/core/src/core/blocks/text-blocks/base/range.d.ts +1 -2
  18. package/@ones-editor/core/src/core/blocks/text-blocks/base/text-offset.d.ts +1 -2
  19. package/@ones-editor/core/src/core/blocks/text-blocks/text-block/to-plain-html.d.ts +2 -2
  20. package/@ones-editor/core/src/core/command-providers/abstract-providers.d.ts +25 -0
  21. package/@ones-editor/core/src/core/command-providers/block-attributes.d.ts +16 -0
  22. package/@ones-editor/core/src/core/command-providers/commands/index.d.ts +2 -0
  23. package/@ones-editor/core/src/core/command-providers/commands/inject-source.d.ts +3 -0
  24. package/@ones-editor/core/src/core/command-providers/commands/merge-commands.d.ts +4 -0
  25. package/@ones-editor/core/src/core/command-providers/commands/range-commands.d.ts +2 -5
  26. package/@ones-editor/core/src/core/command-providers/editor-command-providers.d.ts +5 -14
  27. package/@ones-editor/core/src/core/command-providers/index.d.ts +3 -1
  28. package/@ones-editor/core/src/core/composition/editor-input.d.ts +2 -2
  29. package/@ones-editor/core/src/core/composition/index.d.ts +1 -0
  30. package/@ones-editor/core/src/core/containers/root-container.d.ts +3 -2
  31. package/@ones-editor/core/src/core/doc/doc.d.ts +1 -1
  32. package/@ones-editor/core/src/core/doc/rich-text/text-style.d.ts +2 -0
  33. package/@ones-editor/core/src/core/editor/actions/clear-selected-contents.d.ts +2 -2
  34. package/@ones-editor/core/src/core/editor/editor-dom/dom-events.d.ts +2 -2
  35. package/@ones-editor/core/src/core/editor/editor-dom/editor-dom.d.ts +1 -0
  36. package/@ones-editor/core/src/core/editor/index.d.ts +1 -1
  37. package/@ones-editor/core/src/core/input-handler/input-handler.d.ts +2 -1
  38. package/@ones-editor/core/src/core/insertions/editor-insertions.d.ts +1 -0
  39. package/@ones-editor/core/src/core/selection/actions/index.d.ts +2 -1
  40. package/@ones-editor/core/src/core/selection/adjust-selection-pos.d.ts +5 -1
  41. package/@ones-editor/core/src/core/selection/index.d.ts +1 -0
  42. package/@ones-editor/core/src/core/selection/select-handler.d.ts +3 -3
  43. package/@ones-editor/core/src/core/types.d.ts +45 -30
  44. package/@ones-editor/core/src/core/undo-manager/actions/action.d.ts +5 -1
  45. package/@ones-editor/core/src/core/undo-manager/actions/block-action.d.ts +1 -0
  46. package/@ones-editor/core/src/core/undo-manager/actions/update-block-data-action.d.ts +1 -0
  47. package/@ones-editor/core/src/helper/hovering-block.d.ts +3 -4
  48. package/@ones-editor/core/src/utils/animate-scroll.d.ts +2 -0
  49. package/@ones-editor/core/src/utils/dom.d.ts +4 -1
  50. package/@ones-editor/core/src/utils/drag-drop.d.ts +8 -3
  51. package/@ones-editor/embed-block-helper/src/block-properties/embed-block-properties.d.ts +6 -5
  52. package/@ones-editor/embed-block-helper/src/block-resizer/index.d.ts +1 -0
  53. package/@ones-editor/excalidraw/package.json +4 -0
  54. package/@ones-editor/file/src/locale/en-us.d.ts +1 -0
  55. package/@ones-editor/file/src/locale/ja-jp.d.ts +1 -0
  56. package/@ones-editor/file/src/locale/zh-cn.d.ts +1 -0
  57. package/@ones-editor/graph-embed/src/helper/graph-block-commands.d.ts +5 -19
  58. package/@ones-editor/html-to-doc/src/html-to-doc/normal-html/underline.d.ts +1 -0
  59. package/@ones-editor/image-embed/src/hovering-toolbar/index.d.ts +1 -1
  60. package/@ones-editor/image-embed/src/image-object.d.ts +1 -0
  61. package/@ones-editor/image-embed/src/splitter-resizer/index.d.ts +3 -3
  62. package/@ones-editor/input-handlers/src/i18n/en-us.d.ts +1 -0
  63. package/@ones-editor/input-handlers/src/i18n/ja-jp.d.ts +1 -0
  64. package/@ones-editor/input-handlers/src/i18n/zh-cn.d.ts +1 -0
  65. package/@ones-editor/layout-block/src/command-filter.d.ts +6 -0
  66. package/@ones-editor/layout-block/src/index.d.ts +1 -0
  67. package/@ones-editor/list-block/src/index.d.ts +2 -1
  68. package/@ones-editor/list-block/src/list-data/index.d.ts +2 -0
  69. package/@ones-editor/main-toolbar/src/index.d.ts +2 -0
  70. package/@ones-editor/main-toolbar/src/items/comment.d.ts +8 -0
  71. package/@ones-editor/main-toolbar/src/items/find.d.ts +8 -0
  72. package/@ones-editor/main-toolbar/src/items/font-style.d.ts +13 -1
  73. package/@ones-editor/main-toolbar/src/items/index.d.ts +8 -4
  74. package/@ones-editor/main-toolbar/src/items/insert.d.ts +12 -0
  75. package/@ones-editor/main-toolbar/src/items/link.d.ts +1 -1
  76. package/@ones-editor/main-toolbar/src/items/list.d.ts +4 -4
  77. package/@ones-editor/main-toolbar/src/items/quote.d.ts +1 -1
  78. package/@ones-editor/main-toolbar/src/items/text-color.d.ts +39 -2
  79. package/@ones-editor/main-toolbar/src/items/undo.d.ts +18 -0
  80. package/@ones-editor/main-toolbar/src/locale/en-us.d.ts +9 -0
  81. package/@ones-editor/main-toolbar/src/locale/ja-jp.d.ts +9 -0
  82. package/@ones-editor/main-toolbar/src/locale/zh-cn.d.ts +9 -0
  83. package/@ones-editor/markdown-to-doc/src/custom/tag.d.ts +8 -0
  84. package/@ones-editor/markdown-to-doc/src/tokens/inline-tokens/custom-tag.d.ts +4 -0
  85. package/@ones-editor/markdown-to-doc/src/tokens/inline-tokens/html.d.ts +2 -0
  86. package/@ones-editor/mathjax/package.json +2 -1
  87. package/@ones-editor/mathjax/src/mathjax-box/mathjax-editor.d.ts +1 -0
  88. package/@ones-editor/mathjax/src/mathjax-state/index.d.ts +2 -0
  89. package/@ones-editor/media-embed/src/core/hovering-toolbar/index.d.ts +3 -10
  90. package/@ones-editor/media-embed/src/utils/dom.d.ts +2 -0
  91. package/@ones-editor/mention/src/locale/en-us.d.ts +3 -0
  92. package/@ones-editor/mention/src/locale/ja-jp.d.ts +3 -0
  93. package/@ones-editor/mention/src/locale/zh-cn.d.ts +3 -0
  94. package/@ones-editor/mention/src/mention.d.ts +24 -1
  95. package/@ones-editor/mobile-helper/src/cursor-toolbar.d.ts +15 -0
  96. package/@ones-editor/mobile-helper/src/embed-mask.d.ts +10 -0
  97. package/@ones-editor/mobile-helper/src/fixed-toolbar/active-observer.d.ts +11 -0
  98. package/@ones-editor/mobile-helper/src/fixed-toolbar/fixed-providers.d.ts +6 -0
  99. package/@ones-editor/mobile-helper/src/fixed-toolbar/index.d.ts +18 -0
  100. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/align-dropdown.d.ts +9 -0
  101. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/group.d.ts +7 -0
  102. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/insert-menu.d.ts +13 -0
  103. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/insert.d.ts +8 -0
  104. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/paragraph.d.ts +9 -0
  105. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/tab-provider.d.ts +10 -0
  106. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/text-dropdown.d.ts +9 -0
  107. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/turn-into.d.ts +8 -0
  108. package/@ones-editor/mobile-helper/src/fixed-toolbar/toolbar-handler.d.ts +15 -0
  109. package/@ones-editor/mobile-helper/src/index.d.ts +14 -2
  110. package/@ones-editor/mobile-helper/src/locale/en-us.d.ts +9 -0
  111. package/@ones-editor/mobile-helper/src/locale/index.d.ts +1 -0
  112. package/@ones-editor/mobile-helper/src/locale/ja-jp.d.ts +9 -0
  113. package/@ones-editor/mobile-helper/src/locale/zh-cn.d.ts +9 -0
  114. package/@ones-editor/mobile-helper/src/selection-gripper/index.d.ts +19 -0
  115. package/@ones-editor/mobile-helper/src/selection-gripper/select-handle.d.ts +3 -0
  116. package/@ones-editor/scroll-container/src/utils.d.ts +1 -1
  117. package/@ones-editor/sharedb-doc/src/types.d.ts +3 -3
  118. package/@ones-editor/sharedb-doc/src/versions/sharedb-server.d.ts +1 -1
  119. package/@ones-editor/sharedb-doc/src/versions/simple-client.d.ts +1 -1
  120. package/@ones-editor/table-block/src/commands/index.d.ts +2 -0
  121. package/@ones-editor/table-block/src/commands/mobile-command-provider.d.ts +12 -0
  122. package/@ones-editor/table-block/src/commands/table-block-commands.d.ts +4 -3
  123. package/@ones-editor/table-block/src/index.d.ts +2 -1
  124. package/@ones-editor/table-block/src/locale/en-us.d.ts +5 -0
  125. package/@ones-editor/table-block/src/locale/ja-jp.d.ts +5 -0
  126. package/@ones-editor/table-block/src/locale/zh-cn.d.ts +5 -0
  127. package/@ones-editor/table-block/src/table-block/cell-menu/table-cell-dom.d.ts +6 -0
  128. package/@ones-editor/table-block/src/table-block/table-resize/resize-drag-drop.d.ts +4 -4
  129. package/@ones-editor/text-commands/src/index.d.ts +1 -3
  130. package/@ones-editor/to-docx/src/doc2other/core.d.ts +1 -1
  131. package/@ones-editor/to-docx/src/doc2other/table.d.ts +1 -0
  132. package/@ones-editor/to-docx/src/errors.d.ts +3 -0
  133. package/@ones-editor/to-docx/src/index.d.ts +2 -0
  134. package/@ones-editor/tsconfig.tsbuildinfo +1 -1
  135. package/@ones-editor/ui/src/block-menu/block-command-providers.d.ts +8 -0
  136. package/@ones-editor/{block-menu → ui}/src/block-menu/index.d.ts +3 -1
  137. package/@ones-editor/ui/src/box-helper/standard-box-commands.d.ts +10 -0
  138. package/@ones-editor/ui/src/box-helper/standard-box-provider.d.ts +9 -0
  139. package/@ones-editor/ui/src/index.d.ts +30 -8
  140. package/@ones-editor/ui/src/link-popup/mobile-link-popup.d.ts +22 -0
  141. package/@ones-editor/ui/src/link-popup/types.d.ts +34 -0
  142. package/@ones-editor/ui/src/link-popup/web-link-popup.d.ts +19 -0
  143. package/@ones-editor/ui/src/locale/en-us.d.ts +14 -0
  144. package/@ones-editor/ui/src/locale/ja-jp.d.ts +14 -0
  145. package/@ones-editor/ui/src/locale/zh-cn.d.ts +14 -0
  146. package/@ones-editor/ui/src/providers/align-dropdown.d.ts +10 -0
  147. package/@ones-editor/ui/src/providers/align.d.ts +11 -0
  148. package/@ones-editor/ui/src/providers/block-hook-provider.d.ts +16 -0
  149. package/@ones-editor/ui/src/providers/clipboard-provider.d.ts +20 -0
  150. package/@ones-editor/ui/src/providers/color-provider.d.ts +18 -0
  151. package/@ones-editor/ui/src/providers/edit-link-provider.d.ts +6 -0
  152. package/@ones-editor/ui/src/providers/heading.d.ts +13 -0
  153. package/@ones-editor/ui/src/providers/inline-code-provider.d.ts +10 -0
  154. package/@ones-editor/ui/src/providers/inline-style-provider.d.ts +10 -0
  155. package/@ones-editor/ui/src/providers/insert-above.d.ts +9 -0
  156. package/@ones-editor/ui/src/providers/insert-after.d.ts +9 -0
  157. package/@ones-editor/ui/src/providers/insert-box-provider.d.ts +12 -0
  158. package/@ones-editor/ui/src/providers/insert-group.d.ts +7 -0
  159. package/@ones-editor/ui/src/providers/insert-menu.d.ts +16 -0
  160. package/@ones-editor/ui/src/providers/link.d.ts +12 -0
  161. package/@ones-editor/ui/src/providers/list.d.ts +13 -0
  162. package/@ones-editor/ui/src/providers/mobile-link-provider.d.ts +13 -0
  163. package/@ones-editor/ui/src/providers/paragraph.d.ts +9 -0
  164. package/@ones-editor/ui/src/providers/proxy-provider.d.ts +9 -0
  165. package/@ones-editor/ui/src/providers/quoted.d.ts +10 -0
  166. package/@ones-editor/ui/src/providers/script-with-dropdown.d.ts +9 -0
  167. package/@ones-editor/ui/src/providers/selection-provider.d.ts +9 -0
  168. package/@ones-editor/ui/src/providers/text-command-provider.d.ts +16 -0
  169. package/@ones-editor/ui/src/providers/text-fixed-provider.d.ts +16 -0
  170. package/@ones-editor/ui/src/providers/text-script-provider.d.ts +10 -0
  171. package/@ones-editor/ui/src/providers/text-styles.d.ts +9 -0
  172. package/@ones-editor/ui/src/providers/turn-into.d.ts +9 -0
  173. package/@ones-editor/ui/src/providers/utils/add-section.d.ts +2 -0
  174. package/@ones-editor/ui/src/{quick-menu → providers/utils}/basic-commands.d.ts +1 -2
  175. package/@ones-editor/ui/src/providers/utils/clipboard.d.ts +6 -0
  176. package/@ones-editor/ui/src/providers/utils/index.d.ts +2 -0
  177. package/@ones-editor/ui/src/providers/utils/inject-block-options.d.ts +8 -0
  178. package/@ones-editor/ui/src/providers/utils/text-styles.d.ts +6 -0
  179. package/@ones-editor/ui/src/quick-menu/index.d.ts +7 -19
  180. package/@ones-editor/ui/src/quick-menu/quick-command-providers.d.ts +8 -0
  181. package/@ones-editor/ui/src/quick-menu/types.d.ts +2 -5
  182. package/@ones-editor/ui/src/readonly-toolbar/add-comment-to-old-doc.d.ts +2 -0
  183. package/@ones-editor/ui/src/readonly-toolbar/helper.d.ts +2 -0
  184. package/@ones-editor/ui/src/readonly-toolbar/index.d.ts +3 -2
  185. package/@ones-editor/ui/src/toolbar/link-commands.d.ts +4 -0
  186. package/@ones-editor/ui/src/toolbar/text-commands.d.ts +2 -2
  187. package/@ones-editor/ui/src/toolbar/toolbar-handler.d.ts +4 -1
  188. package/@ones-editor/ui/src/tooltips/index.d.ts +21 -9
  189. package/@ones-editor/ui/src/utils/hide-toolbar.d.ts +2 -0
  190. package/@ones-editor/ui-base/src/auto-suggest/auto-suggest-menu.d.ts +4 -1
  191. package/@ones-editor/ui-base/src/auto-suggest/auto-suggest.d.ts +3 -1
  192. package/@ones-editor/ui-base/src/color-button/text-color-item.d.ts +18 -8
  193. package/@ones-editor/ui-base/src/color-palette/color-palette.d.ts +7 -1
  194. package/@ones-editor/ui-base/src/color-palette/index.d.ts +3 -3
  195. package/@ones-editor/ui-base/src/command-bar/active-observer.d.ts +11 -0
  196. package/@ones-editor/ui-base/src/command-bar/command-bar.d.ts +5 -2
  197. package/@ones-editor/ui-base/src/command-bar/fixed-toolbar.d.ts +3 -1
  198. package/@ones-editor/ui-base/src/command-bar/init-toolbar-item.d.ts +1 -0
  199. package/@ones-editor/ui-base/src/command-bar/manual-command-bar.d.ts +1 -0
  200. package/@ones-editor/ui-base/src/command-bar/types.d.ts +7 -2
  201. package/@ones-editor/ui-base/src/dialog/manual-close-dialog.d.ts +1 -1
  202. package/@ones-editor/ui-base/src/dropdown/index.d.ts +1 -0
  203. package/@ones-editor/ui-base/src/icons/index.d.ts +5 -1
  204. package/@ones-editor/ui-base/src/index.d.ts +3 -0
  205. package/@ones-editor/ui-base/src/input/create-input.d.ts +24 -3
  206. package/@ones-editor/ui-base/src/locale/en-us.d.ts +1 -0
  207. package/@ones-editor/ui-base/src/locale/ja-jp.d.ts +1 -0
  208. package/@ones-editor/ui-base/src/locale/zh-cn.d.ts +1 -0
  209. package/@ones-editor/ui-base/src/mobile-command-bar/init-menu-item.d.ts +3 -0
  210. package/@ones-editor/ui-base/src/mobile-command-bar/mobile-bottom-menu.d.ts +21 -0
  211. package/@ones-editor/ui-base/src/mobile-command-bar/scroll-into-view.d.ts +3 -0
  212. package/@ones-editor/ui-base/src/popup/popup.d.ts +1 -1
  213. package/@ones-editor/{ui → ui-base}/src/text-button/index.d.ts +1 -1
  214. package/@ones-editor/versions/package.json +3 -0
  215. package/@ones-editor/versions/src/constant/index.d.ts +2 -0
  216. package/@ones-editor/versions/src/history-doc/history-doc.d.ts +2 -2
  217. package/@ones-editor/versions/src/history-render/index.d.ts +15 -1
  218. package/@ones-editor/versions/src/history-tooltip/index.d.ts +14 -0
  219. package/@ones-editor/versions/src/index.d.ts +1 -0
  220. package/@ones-editor/versions/src/locale/en-us.d.ts +1 -0
  221. package/@ones-editor/versions/src/locale/ja-jp.d.ts +1 -0
  222. package/@ones-editor/versions/src/locale/zh-cn.d.ts +1 -0
  223. package/@ones-editor/versions/src/types.d.ts +5 -0
  224. package/@ones-editor/versions/src/utils/block-text.d.ts +3 -1
  225. package/@ones-editor/versions/src/version-dialog/versions-dropdown.d.ts +2 -0
  226. package/dist/auto-new-line.d.ts +7 -0
  227. package/dist/index.d.ts +10 -4
  228. package/dist/index.js +17896 -13052
  229. package/dist/lang/en-us.d.ts +1 -1
  230. package/dist/lang/ja-jp.d.ts +1 -1
  231. package/dist/lang/zh-cn.d.ts +1 -1
  232. package/dist/types.d.ts +15 -4
  233. package/package.json +3 -1
  234. package/@ones-editor/block-menu/src/block-menu/items/block-command-items.d.ts +0 -3
  235. package/@ones-editor/block-menu/src/block-menu/items/index.d.ts +0 -5
  236. package/@ones-editor/block-menu/src/block-menu/items/insert-block-items/index.d.ts +0 -5
  237. package/@ones-editor/block-menu/src/block-menu/items/text-styles/text-style-item.d.ts +0 -30
  238. package/@ones-editor/block-menu/src/block-menu/items/types.d.ts +0 -5
  239. package/@ones-editor/text-commands/src/locale/en-us.d.ts +0 -13
  240. package/@ones-editor/text-commands/src/locale/ja-jp.d.ts +0 -13
  241. package/@ones-editor/text-commands/src/locale/zh-cn.d.ts +0 -13
  242. package/@ones-editor/text-commands/src/text-command-provider.d.ts +0 -24
  243. package/@ones-editor/text-commands/src/text-commands.d.ts +0 -4
  244. package/@ones-editor/text-commands/src/text-styles.d.ts +0 -4
  245. package/@ones-editor/ui/src/quick-menu/basic-menu-items.d.ts +0 -16
  246. package/@ones-editor/ui/src/quick-menu/inline-box-items.d.ts +0 -8
  247. package/@ones-editor/ui/src/quick-menu/insert-empty-block.d.ts +0 -4
  248. package/@ones-editor/ui/src/quick-menu/order.d.ts +0 -1
  249. package/@ones-editor/ui/src/quick-menu/quick-menu-items.d.ts +0 -9
  250. package/@ones-editor/ui/src/toolbar/commands/align.d.ts +0 -10
  251. package/@ones-editor/ui/src/toolbar/commands/paragraph.d.ts +0 -11
  252. package/@ones-editor/ui/src/toolbar/commands/turn-into.d.ts +0 -10
  253. package/@ones-editor/ui/src/toolbar/merge-commands.d.ts +0 -2
  254. /package/@ones-editor/{text-commands → main-toolbar}/src/locale/index.d.ts +0 -0
  255. /package/@ones-editor/{block-menu → ui}/src/block-menu/standard-block-actions/hook.d.ts +0 -0
@@ -1,11 +1,11 @@
1
- import { BlockCommandItemWithSource, CommandItemState, OnesEditor } from '../../../../@ones-editor/core';
1
+ import { CommandItemWithSource, CommandItemState, OnesEditor } from '../../../../@ones-editor/core';
2
2
  import { ToolbarItem } from '../types';
3
3
  export declare class OrderedListItem implements ToolbarItem {
4
4
  id: string;
5
5
  name: string;
6
6
  icon: string;
7
7
  states: CommandItemState[];
8
- getCommand(editor: OnesEditor): BlockCommandItemWithSource | undefined;
8
+ getCommand(editor: OnesEditor): CommandItemWithSource | undefined;
9
9
  updateState(editor: OnesEditor): void;
10
10
  onClick(editor: OnesEditor, item: ToolbarItem): void;
11
11
  }
@@ -14,7 +14,7 @@ export declare class UnorderedListItem implements ToolbarItem {
14
14
  name: string;
15
15
  icon: string;
16
16
  states: CommandItemState[];
17
- getCommand(editor: OnesEditor): BlockCommandItemWithSource | undefined;
17
+ getCommand(editor: OnesEditor): CommandItemWithSource | undefined;
18
18
  updateState(editor: OnesEditor): void;
19
19
  onClick(editor: OnesEditor, item: ToolbarItem): void;
20
20
  }
@@ -23,7 +23,7 @@ export declare class CheckListItem implements ToolbarItem {
23
23
  name: string;
24
24
  icon: string;
25
25
  states: CommandItemState[];
26
- getCommand(editor: OnesEditor): BlockCommandItemWithSource | undefined;
26
+ getCommand(editor: OnesEditor): CommandItemWithSource | undefined;
27
27
  updateState(editor: OnesEditor): void;
28
28
  onClick(editor: OnesEditor, item: ToolbarItem): void;
29
29
  }
@@ -5,7 +5,7 @@ export declare class QuoteItem implements ToolbarItem {
5
5
  name: string;
6
6
  icon: string;
7
7
  states: CommandItemState[];
8
- getCommand(editor: OnesEditor): import("@ones-editor/core").BlockCommandItemWithSource | undefined;
8
+ getCommand(editor: OnesEditor): import("@ones-editor/core").CommandItemWithSource | undefined;
9
9
  updateState(editor: OnesEditor): void;
10
10
  onClick(editor: OnesEditor, item: ToolbarItem): void;
11
11
  }
@@ -1,10 +1,47 @@
1
1
  import { CommandItemChildrenPlacement, CommandItemState, OnesEditor } from '../../../../@ones-editor/core';
2
- import { TextColorItem as ColorItem } from '../../../../@ones-editor/ui-base';
2
+ import { TextColorItem } from '../../../../@ones-editor/ui-base';
3
+ import { ColorStyleProvider } from '../../../../@ones-editor/ui';
3
4
  import { ToolbarItem } from '../types';
4
- export declare class TextColorItem extends ColorItem implements ToolbarItem {
5
+ export declare class ColorItem extends TextColorItem implements ToolbarItem {
5
6
  childrenPlacement: CommandItemChildrenPlacement;
6
7
  states?: CommandItemState[] | undefined;
8
+ provider: ColorStyleProvider;
7
9
  constructor(editor: OnesEditor);
10
+ getCommand(): {
11
+ id: string;
12
+ name: string;
13
+ desc?: string | undefined;
14
+ states?: CommandItemState[] | undefined;
15
+ value?: string | undefined;
16
+ order?: number | undefined;
17
+ type?: import("@ones-editor/core").CommandItemType | undefined;
18
+ element?: HTMLElement | ((item: import("@ones-editor/core").CommandItem) => HTMLElement) | undefined;
19
+ icon?: string | undefined;
20
+ childrenType?: "menu" | "toolbar" | "mobile-bottom-menu" | undefined;
21
+ children?: import("@ones-editor/core").CommandItem[] | undefined;
22
+ childrenMenuId?: string | undefined;
23
+ data?: unknown;
24
+ group?: string | undefined;
25
+ groupOrder?: number | undefined;
26
+ dropdown?: boolean | undefined;
27
+ dropSplit?: boolean | undefined;
28
+ splitTooltip?: string | undefined;
29
+ manualShowChildren?: boolean | undefined;
30
+ childrenPlacement?: CommandItemChildrenPlacement | undefined;
31
+ childrenOffset?: [number, number] | undefined;
32
+ childArrow?: boolean | undefined;
33
+ subText?: string | undefined;
34
+ defaultCheckedChildren?: string[] | undefined;
35
+ ellipsisTooltip?: string | undefined;
36
+ disableTooltip?: boolean | undefined;
37
+ tooltipPlacement?: CommandItemChildrenPlacement | undefined;
38
+ disableReason?: string | undefined;
39
+ hideGroupItem?: boolean | undefined;
40
+ setCloseable?: ((closeable: import("@ones-editor/core").Closeable) => void) | undefined;
41
+ beforePopup?: ((parent: unknown) => void) | undefined;
42
+ switchable?: boolean | undefined;
43
+ clickToClose?: boolean | undefined;
44
+ } | null;
8
45
  handleChangeColor(type: 'color' | 'backgroundColor' | 'clearColor', value: number): void;
9
46
  handleMousedown: (event: MouseEvent) => void;
10
47
  updateState(editor: OnesEditor): void;
@@ -0,0 +1,18 @@
1
+ import { CommandItemState, OnesEditor } from '../../../../@ones-editor/core';
2
+ import { ToolbarItem } from '../types';
3
+ export declare class UndoItem implements ToolbarItem {
4
+ icon: string;
5
+ id: string;
6
+ name: string;
7
+ states: CommandItemState[];
8
+ onClick(editor: OnesEditor, item: ToolbarItem): void;
9
+ updateState(editor: OnesEditor): void;
10
+ }
11
+ export declare class RedoItem implements ToolbarItem {
12
+ icon: string;
13
+ id: string;
14
+ name: string;
15
+ states: CommandItemState[];
16
+ onClick(editor: OnesEditor, item: ToolbarItem): void;
17
+ updateState(editor: OnesEditor): void;
18
+ }
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ toolbar: {
3
+ undo: string;
4
+ redo: string;
5
+ insert: string;
6
+ findReplace: string;
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ toolbar: {
3
+ undo: string;
4
+ redo: string;
5
+ insert: string;
6
+ findReplace: string;
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ toolbar: {
3
+ undo: string;
4
+ redo: string;
5
+ insert: string;
6
+ findReplace: string;
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,8 @@
1
+ import { marked } from 'marked';
2
+ export interface CustomTagToken extends marked.Tokens.Generic {
3
+ type: 'custom';
4
+ content: string;
5
+ }
6
+ export declare const extendedCustomTag: () => {
7
+ extensions: marked.TokenizerExtension[];
8
+ };
@@ -0,0 +1,4 @@
1
+ import { DocBlockText, DocBlockTextAttributes } from '../../../../../@ones-editor/core';
2
+ import { TokenToBlockOptions } from '../base';
3
+ import { CustomTagToken } from '../../custom/tag';
4
+ export declare function customTagToText(token: CustomTagToken, attributes: DocBlockTextAttributes, options: TokenToBlockOptions): DocBlockText;
@@ -0,0 +1,2 @@
1
+ import { DocBlockTextAttributes } from '../../../../../@ones-editor/core';
2
+ export declare function applyHtmlToText(htm: string, attributes: DocBlockTextAttributes): void;
@@ -5,8 +5,9 @@
5
5
  "type": "module",
6
6
  "main": "./src/index.ts",
7
7
  "devDependencies": {
8
+ "@types/lodash.clonedeep": "^4.5.0",
8
9
  "@types/lodash.debounce": "^4.0.7",
9
- "@types/lodash.clonedeep": "^4.5.0"
10
+ "@types/lodash.memoize": "^4.1.9"
10
11
  },
11
12
  "types": "src/index.d.ts"
12
13
  }
@@ -6,6 +6,7 @@ export default class MathjaxEditor {
6
6
  editMathjaxPopup: Popup | null;
7
7
  onChange: OnEditChange | null;
8
8
  tex: string;
9
+ oldTex: string;
9
10
  private observer;
10
11
  editMathjax(elem: HTMLElement, tex: string, onChange: OnEditChange, options?: ManualShowCommandBarOptions): void;
11
12
  handleClose: (commandBar: AbstractCommandBar) => void;
@@ -1,7 +1,9 @@
1
1
  export declare class MathjaxStateData {
2
2
  dataUrl: string;
3
+ texWidth: [string, number] | null;
3
4
  error: Error | null;
4
5
  destroy(): void;
5
6
  setDataUrl(url: string): void;
6
7
  setError(error: Error): void;
8
+ setTexWidth(tex: string, width: number): void;
7
9
  }
@@ -1,22 +1,15 @@
1
1
  import { BlockCommands, BlockElement, CommandItem, OnesEditor } from '../../../../../@ones-editor/core';
2
- import type { CommandItemType } from '../../../../../@ones-editor/core';
3
2
  export default class ImageHoveringToolbarCommands implements BlockCommands {
4
3
  protected editor: OnesEditor;
5
4
  protected block: BlockElement;
6
5
  group: string;
7
6
  constructor(editor: OnesEditor, block: BlockElement);
8
- _commands: ({
7
+ _commands: {
9
8
  id: string;
10
9
  name: string;
11
10
  icon: string;
12
- type?: undefined;
13
- } | {
14
- id: string;
15
- name: string;
16
- type: CommandItemType;
17
- icon?: undefined;
18
- })[];
19
- private createIconItem;
11
+ }[];
12
+ isHoveringImageEmpty: () => boolean;
20
13
  get commands(): CommandItem[];
21
14
  executeCommand(editor: OnesEditor, block: BlockElement, item: CommandItem): void;
22
15
  }
@@ -0,0 +1,2 @@
1
+ import { BlockElement } from '../../../../@ones-editor/core';
2
+ export declare const isVideoBlock: (block: BlockElement) => boolean;
@@ -1,6 +1,9 @@
1
1
  declare const _default: {
2
2
  mention: {
3
3
  abstract: string;
4
+ placeholder: string;
5
+ noResult: string;
6
+ header: string;
4
7
  };
5
8
  };
6
9
  export default _default;
@@ -1,6 +1,9 @@
1
1
  declare const _default: {
2
2
  mention: {
3
3
  abstract: string;
4
+ placeholder: string;
5
+ noResult: string;
6
+ header: string;
4
7
  };
5
8
  };
6
9
  export default _default;
@@ -1,6 +1,9 @@
1
1
  declare const _default: {
2
2
  mention: {
3
3
  abstract: string;
4
+ placeholder: string;
5
+ noResult: string;
6
+ header: string;
4
7
  };
5
8
  };
6
9
  export default _default;
@@ -1,14 +1,37 @@
1
+ /// <reference types="lodash" />
1
2
  import { CommandItem, OnesEditor, OnesEditorCustom } from '../../../@ones-editor/core';
2
- import { AutoSuggestAnchor, OnesEditorAutoSuggest } from '../../../@ones-editor/ui-base';
3
+ import { AutoSuggestAnchor, EditorInput, OnesEditorAutoSuggest } from '../../../@ones-editor/ui-base';
3
4
  import { MentionOptions } from './types';
5
+ interface MobileWrap {
6
+ wrapper: HTMLElement;
7
+ input: EditorInput;
8
+ content: HTMLElement;
9
+ }
4
10
  export default class OnesEditorMention implements OnesEditorCustom {
5
11
  private editor;
6
12
  private options;
7
13
  suggest: OnesEditorAutoSuggest;
14
+ private mobileWrap?;
15
+ private items;
8
16
  constructor(editor: OnesEditor, options: MentionOptions);
17
+ createMobileHeader: () => HTMLDivElement | undefined;
9
18
  onClose: () => void;
10
19
  destroy(): void;
11
20
  onShow: (suggest: OnesEditorAutoSuggest, containerId: string, blockIndex: number, offset: number) => boolean;
21
+ onShown: (bar: OnesEditorAutoSuggest) => void;
22
+ handleClickItem: (item: CommandItem) => void;
23
+ handleMobileWrapClick: (e: Event) => void;
12
24
  onClickItem: (menu: OnesEditorAutoSuggest, item: CommandItem, anchor: AutoSuggestAnchor) => void;
25
+ createItemElement: (item: CommandItem, find: string) => HTMLElement;
26
+ createMobileItems: (content: HTMLElement, items: CommandItem[], find: string) => void;
27
+ onInputChanged: import("lodash").DebouncedFunc<(content: HTMLElement, e: Event) => void>;
28
+ createMobileWrap: () => MobileWrap;
29
+ createMobileCommandItem: (items: CommandItem[]) => {
30
+ id: string;
31
+ name: string;
32
+ element: HTMLElement;
33
+ }[];
34
+ _queryItems: (text: string) => Promise<CommandItem[]>;
13
35
  queryItems: (menu: OnesEditorAutoSuggest, text: string) => Promise<CommandItem[]>;
14
36
  }
37
+ export {};
@@ -0,0 +1,15 @@
1
+ import { CommandItem, OnesEditor } from '../../../@ones-editor/core';
2
+ export declare class CursorToolbarHandler {
3
+ private editor;
4
+ private toolbar;
5
+ private clipboardProvider;
6
+ constructor(editor: OnesEditor);
7
+ handleButtonClick: (toolbar: any, item: CommandItem) => void;
8
+ private handleSelectionChange;
9
+ getCommands: () => CommandItem[];
10
+ showToolbar: () => void;
11
+ close: () => void;
12
+ destroy(): void;
13
+ }
14
+ export declare const createCursorToolbar: (editor: OnesEditor) => CursorToolbarHandler;
15
+ export declare const hideCursorToolbar: (editor: OnesEditor) => void;
@@ -0,0 +1,10 @@
1
+ /// <reference types="lodash" />
2
+ import { BlockElement, OnesEditor } from '../../../@ones-editor/core';
3
+ export default class MobileEmbedMask {
4
+ private editor;
5
+ constructor(editor: OnesEditor);
6
+ addMask: (block: BlockElement) => void;
7
+ removeMask: (block: BlockElement) => void;
8
+ handleSelectionChanged: import("lodash").DebouncedFunc<() => void>;
9
+ destroy(): void;
10
+ }
@@ -0,0 +1,11 @@
1
+ export type Options = {
2
+ onFocused: () => void;
3
+ onBlurred: () => void;
4
+ };
5
+ export declare class ActiveElementObserver {
6
+ private options;
7
+ constructor(options: Options);
8
+ handleFocusIn: () => void;
9
+ handleFocusOut: () => void;
10
+ destroy(): void;
11
+ }
@@ -0,0 +1,6 @@
1
+ import { AbstractProvider, OnesEditor, OnesEditorCommandProviders } from '../../../../@ones-editor/core';
2
+ export declare class FixedProviders extends AbstractProvider implements OnesEditorCommandProviders {
3
+ protected editor: OnesEditor;
4
+ id: string;
5
+ constructor(editor: OnesEditor);
6
+ }
@@ -0,0 +1,18 @@
1
+ /// <reference types="lodash" />
2
+ import { OnesEditor } from '../../../../@ones-editor/core';
3
+ import './mobile.scss';
4
+ export declare class MobileCommandHandler {
5
+ private editor;
6
+ private commandBar;
7
+ private observer;
8
+ private timer;
9
+ private mobileClient?;
10
+ constructor(editor: OnesEditor);
11
+ private toggleDelay;
12
+ private preHeight;
13
+ layoutBar: import("lodash").DebouncedFunc<() => void>;
14
+ handScroll: import("lodash").DebouncedFunc<() => void>;
15
+ destroy(): void;
16
+ handleFocusIn: () => void;
17
+ handleFocusOut: () => void;
18
+ }
@@ -0,0 +1,9 @@
1
+ import { BlockElement, CommandItem, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class AlignDropdownProvider extends ProxyProvider implements OnesEditorCommandProvider {
4
+ private editor;
5
+ id: string;
6
+ constructor(editor: OnesEditor);
7
+ getInsertCommands: () => never[];
8
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange) => CommandItem[];
9
+ }
@@ -0,0 +1,7 @@
1
+ import { OnesEditor, OnesEditorCommandProvider } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class GroupProvider extends ProxyProvider implements OnesEditorCommandProvider {
4
+ private editor;
5
+ id: string;
6
+ constructor(editor: OnesEditor);
7
+ }
@@ -0,0 +1,13 @@
1
+ import { BlockElement, CommandItem, CommandItemWithSource, CommandParams, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class MobileInsertMenuProvider extends ProxyProvider {
4
+ private editor;
5
+ id: string;
6
+ get whiteList(): string[];
7
+ providers: OnesEditorCommandProvider[];
8
+ constructor(editor: OnesEditor);
9
+ getInsertCommands: () => CommandItem[];
10
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange, params?: CommandParams) => CommandItem[];
11
+ executeInsertCommand: () => boolean;
12
+ executeCommand: (editor: OnesEditor, block: BlockElement, range: SelectionRange, item: CommandItemWithSource, params: CommandParams) => boolean;
13
+ }
@@ -0,0 +1,8 @@
1
+ import { BlockElement, CommandItem, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class InsertProvider extends ProxyProvider implements OnesEditorCommandProvider {
4
+ private editor;
5
+ id: string;
6
+ constructor(editor: OnesEditor);
7
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange) => CommandItem[];
8
+ }
@@ -0,0 +1,9 @@
1
+ import { BlockElement, CommandItem, CommandParams, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class ParagraphProvider extends ProxyProvider implements OnesEditorCommandProvider {
4
+ private editor;
5
+ id: string;
6
+ groupIndex: number;
7
+ constructor(editor: OnesEditor);
8
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange, params?: CommandParams) => CommandItem[];
9
+ }
@@ -0,0 +1,10 @@
1
+ import { BlockElement, CommandItem, CommandParams, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ export default class TabProvider implements OnesEditorCommandProvider {
3
+ private editor;
4
+ id: string;
5
+ constructor(editor: OnesEditor);
6
+ isDisabled: (block: BlockElement) => boolean;
7
+ getAvailableCommands(editor: OnesEditor, block: BlockElement, range: SelectionRange, params?: CommandParams): CommandItem[];
8
+ getInsertCommands: () => never[];
9
+ executeCommand(editor: OnesEditor, block: BlockElement, range: SelectionRange, command: CommandItem): boolean;
10
+ }
@@ -0,0 +1,9 @@
1
+ import { BlockElement, CommandItem, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class TextDropdownProvider extends ProxyProvider implements OnesEditorCommandProvider {
4
+ private editor;
5
+ id: string;
6
+ constructor(editor: OnesEditor);
7
+ getInsertCommands: () => never[];
8
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange) => CommandItem[];
9
+ }
@@ -0,0 +1,8 @@
1
+ import { BlockElement, CommandItem, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
2
+ import { ProxyProvider } from '../../../../../@ones-editor/ui';
3
+ export default class TurnIntoCommandProvider extends ProxyProvider implements OnesEditorCommandProvider {
4
+ private editor;
5
+ id: string;
6
+ constructor(editor: OnesEditor);
7
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange) => CommandItem[];
8
+ }
@@ -0,0 +1,15 @@
1
+ import type { CommandItem, OnesEditor } from '../../../../@ones-editor/core';
2
+ export declare class MobileToolbarHandler {
3
+ private editor;
4
+ private mobileToolbar;
5
+ private fixedProviders;
6
+ bar: HTMLElement;
7
+ constructor(editor: OnesEditor, parent: HTMLElement);
8
+ private subBar;
9
+ private addSubBar;
10
+ private handleSubBarShown;
11
+ layoutSubBar(): void;
12
+ private handleSelectionChange;
13
+ handleClick: (_: any, item: CommandItem) => void;
14
+ destroy(): void;
15
+ }
@@ -1,11 +1,23 @@
1
+ /// <reference types="lodash" />
1
2
  import { OnesEditor, OnesEditorCustom } from '../../../@ones-editor/core';
3
+ import { MobileCommandHandler } from './fixed-toolbar';
4
+ import './locale';
5
+ import './mobile-helper-styles.scss';
6
+ export { MobileCommandHandler };
2
7
  export declare class OnesEditorMobileHelper implements OnesEditorCustom {
3
8
  private editor;
4
9
  private longPressTimeout;
10
+ private longPressTriggered;
11
+ private gripper;
12
+ private cursorToolbar;
13
+ private isMoving;
14
+ private mobileEmbedMask;
5
15
  constructor(editor: OnesEditor);
6
16
  destroy(): void;
7
- handleSelectionChange: () => void;
8
- handleLongPress: (event: TouchEvent) => void;
17
+ handleSelectionChange: import("lodash").DebouncedFunc<() => void>;
18
+ handleLongPress: (event: TouchEvent) => boolean;
19
+ handleTouchMove: (event: TouchEvent) => void;
9
20
  handleTouchStart: (event: TouchEvent) => void;
21
+ debounceShowCursorToolbar: import("lodash").DebouncedFunc<() => void>;
10
22
  handleTouchEnd: (event: TouchEvent) => void;
11
23
  }
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ mobile: {
3
+ insert: string;
4
+ commands: {
5
+ select: string;
6
+ };
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ mobile: {
3
+ insert: string;
4
+ commands: {
5
+ select: string;
6
+ };
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ mobile: {
3
+ insert: string;
4
+ commands: {
5
+ select: string;
6
+ };
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,19 @@
1
+ import { DragDrop, OnesEditor } from '../../../../@ones-editor/core';
2
+ interface DragData {
3
+ type: 'start' | 'end';
4
+ }
5
+ export default class SelectionGripper {
6
+ private editor;
7
+ private startGripper;
8
+ private endGripper;
9
+ private dragDropStart;
10
+ private dragDropEnd;
11
+ constructor(editor: OnesEditor);
12
+ destroy(): void;
13
+ handleDragStart: (drag: DragDrop<DragData>, event: MouseEvent | TouchEvent, elem: HTMLElement) => void;
14
+ handleDragging: (drag: DragDrop<DragData>, event: MouseEvent | TouchEvent, elem: HTMLElement) => void;
15
+ handleDragEnd: (drag: DragDrop<DragData>, event: MouseEvent | TouchEvent, elem: HTMLElement) => void;
16
+ update(): void;
17
+ close(): void;
18
+ }
19
+ export {};
@@ -0,0 +1,3 @@
1
+ export declare const HANDLE_CIRCLE_SIZE = 12;
2
+ export declare const HANDLE_WIDTH = 12;
3
+ export declare function createSelectHandle(type: 'start' | 'end'): HTMLDivElement;
@@ -1,5 +1,5 @@
1
1
  import { ContainerElement, ScrollAreaElement, ScrollContainerElement, ScrollCore } from './common-types';
2
- export declare function getContainerOption(scrollCore: ScrollCore, container: ContainerElement): import("./types").ScrollContainerOptions | undefined;
2
+ export declare function getContainerOption(scrollCore: ScrollCore, container: ContainerElement): import("@ones-editor/editor").ScrollContainerOptions | undefined;
3
3
  export declare function getScrollContainer(scrollChild: HTMLElement): ScrollContainerElement;
4
4
  export declare function getContainerScrollArea(scrollContainer: ScrollContainerElement): ScrollAreaElement;
5
5
  export declare function getContainer(scrollChild: HTMLElement): ContainerElement;
@@ -1,4 +1,4 @@
1
- import { BuildResourceUrlOptions, DocBlock, DocComment, OnesEditorDocCallbacks, OnesEditorDocRange, OnesEditorUser, OnesEditorUserPermission, UploadResourceOptions, UploadResourceResult } from '../../../@ones-editor/core';
1
+ import { BuildResourceUrlOptions, DocBlock, DocComment, OnesEditorDoc, OnesEditorDocCallbacks, OnesEditorDocRange, OnesEditorUser, OnesEditorUserPermission, UploadResourceOptions, UploadResourceResult } from '../../../@ones-editor/core';
2
2
  import { Op } from 'sharedb';
3
3
  export type { Op } from 'sharedb/lib/client';
4
4
  export type BlocksType = DocBlock[];
@@ -72,8 +72,8 @@ export interface ShareDBDocOptions {
72
72
  templateData?: EditorDoc;
73
73
  disableLogout?: boolean;
74
74
  onMaxUsersError?: () => void;
75
- buildResourceUrl?: (resourceId: string, options?: BuildResourceUrlOptions) => string;
76
- uploadResource?: (file: File, options?: UploadResourceOptions) => Promise<UploadResourceResult>;
75
+ buildResourceUrl?: (doc: OnesEditorDoc, resourceId: string, options?: BuildResourceUrlOptions) => string;
76
+ uploadResource?: (doc: OnesEditorDoc, file: File, options?: UploadResourceOptions) => Promise<UploadResourceResult>;
77
77
  }
78
78
  export interface EditorOp {
79
79
  c: string;
@@ -10,7 +10,7 @@ export default class ShareDBServer extends EventCallbacks<ShareDBDocCallbacks> i
10
10
  buildResourceUrl(resourceId: string, options?: BuildResourceUrlOptions): string;
11
11
  getRemoteUsers(): RemoteUsers;
12
12
  getVersionHelper(): OnesEditorDocVersionHelper;
13
- getVersions(): Promise<DocVersion[]>;
13
+ getVersions(showPublished?: boolean): Promise<DocVersion[]>;
14
14
  getVersion(ver: number): Promise<DocObject>;
15
15
  getLatestVersion(): Promise<DocObject>;
16
16
  getHistoryData(version: number, from?: number | undefined): Promise<{
@@ -11,7 +11,7 @@ export default class ShareDBSimpleClient {
11
11
  getBaseURL(): string;
12
12
  getBase64BaseURL(): string;
13
13
  request<T = unknown>(url: string, opt?: any): Promise<AxiosResponse<any, T>>;
14
- getVersions(): Promise<DocVersion[]>;
14
+ getVersions(showPublished: boolean): Promise<DocVersion[]>;
15
15
  getVersion(ver: number): Promise<EditorDoc>;
16
16
  getLatestVersion(): Promise<EditorDoc>;
17
17
  getVersionOps(version: number, from?: number): Promise<{
@@ -9,4 +9,6 @@ export * from './split-cell';
9
9
  export * from './merge-cells';
10
10
  export * from './change-cell-color';
11
11
  export * from './chart';
12
+ export * from './insert-column';
13
+ export * from './insert-row';
12
14
  export { TableBlockCommandProvider };
@@ -0,0 +1,12 @@
1
+ import { BlockElement, CommandItem, CommandParams, CommandResult, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../@ones-editor/core';
2
+ export default class MobileTableCommandProvider implements OnesEditorCommandProvider {
3
+ private editor;
4
+ id: string;
5
+ constructor(editor: OnesEditor);
6
+ getAvailableCommands: (editor: OnesEditor, block: BlockElement, range: SelectionRange) => CommandItem[];
7
+ deleteRow: (tableBlock: BlockElement) => void;
8
+ deleteCol: (tableBlock: BlockElement) => void;
9
+ insertRowToBottom: (tableBlock: BlockElement) => void;
10
+ insertColToRight: (tableBlock: BlockElement) => void;
11
+ executeCommand: (editor: OnesEditor, block: BlockElement, range: SelectionRange, item: CommandItem, params: CommandParams, result?: CommandResult | undefined) => boolean;
12
+ }