@ones-editor/editor 2.1.7 → 2.1.8-beta.10
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.
- package/@ones-editor/block-menu/src/block-menu-button/menu-button/index.d.ts +1 -1
- package/@ones-editor/block-padding/src/index.d.ts +1 -1
- package/@ones-editor/callout-block/src/callout-block/callout-quick-menu-item-filter.d.ts +3 -4
- package/@ones-editor/callout-block/src/index.d.ts +1 -0
- package/@ones-editor/comments/src/comments-helper/old-version-comment.d.ts +16 -0
- package/@ones-editor/comments/src/index.d.ts +5 -1
- package/@ones-editor/comments/src/text-comments/comments-command-provider.d.ts +4 -3
- package/@ones-editor/core/src/core/block-renderers/block-renderers.d.ts +1 -0
- package/@ones-editor/core/src/core/blocks/common/block-properties.d.ts +9 -9
- package/@ones-editor/core/src/core/blocks/common/execute-block-command.d.ts +2 -2
- package/@ones-editor/core/src/core/blocks/complex-blocks/child-blocks.d.ts +2 -1
- package/@ones-editor/core/src/core/blocks/complex-blocks/complex-block-helper.d.ts +3 -5
- package/@ones-editor/core/src/core/blocks/text-blocks/base/child.d.ts +1 -7
- package/@ones-editor/core/src/core/blocks/text-blocks/base/line-breaks.d.ts +1 -2
- package/@ones-editor/core/src/core/blocks/text-blocks/base/range.d.ts +1 -2
- package/@ones-editor/core/src/core/blocks/text-blocks/base/text-offset.d.ts +1 -2
- package/@ones-editor/core/src/core/command-providers/abstract-providers.d.ts +25 -0
- package/@ones-editor/core/src/core/command-providers/block-attributes.d.ts +16 -0
- package/@ones-editor/core/src/core/command-providers/commands/index.d.ts +2 -0
- package/@ones-editor/core/src/core/command-providers/commands/inject-source.d.ts +3 -0
- package/@ones-editor/core/src/core/command-providers/commands/merge-commands.d.ts +4 -0
- package/@ones-editor/core/src/core/command-providers/commands/range-commands.d.ts +2 -5
- package/@ones-editor/core/src/core/command-providers/editor-command-providers.d.ts +5 -14
- package/@ones-editor/core/src/core/command-providers/index.d.ts +3 -1
- package/@ones-editor/core/src/core/composition/editor-input.d.ts +1 -1
- package/@ones-editor/core/src/core/containers/root-container.d.ts +3 -2
- package/@ones-editor/core/src/core/doc/doc.d.ts +4 -1
- package/@ones-editor/core/src/core/doc/rich-text/text-style.d.ts +2 -0
- package/@ones-editor/core/src/core/editor/actions/clear-selected-contents.d.ts +2 -2
- package/@ones-editor/core/src/core/editor/editor-dom/editor-dom.d.ts +1 -0
- package/@ones-editor/core/src/core/editor/index.d.ts +1 -1
- package/@ones-editor/core/src/core/insertions/editor-insertions.d.ts +1 -0
- package/@ones-editor/core/src/core/selection/actions/index.d.ts +2 -1
- package/@ones-editor/core/src/core/selection/adjust-selection-pos.d.ts +5 -1
- package/@ones-editor/core/src/core/selection/index.d.ts +1 -0
- package/@ones-editor/core/src/core/selection/select-handler.d.ts +3 -3
- package/@ones-editor/core/src/core/types.d.ts +53 -28
- package/@ones-editor/core/src/core/undo-manager/actions/action.d.ts +5 -1
- package/@ones-editor/core/src/core/undo-manager/actions/block-action.d.ts +1 -0
- package/@ones-editor/core/src/core/undo-manager/actions/update-block-data-action.d.ts +1 -0
- package/@ones-editor/core/src/helper/hovering-block.d.ts +3 -4
- package/@ones-editor/core/src/utils/animate-scroll.d.ts +2 -0
- package/@ones-editor/core/src/utils/dom.d.ts +4 -1
- package/@ones-editor/core/src/utils/drag-drop.d.ts +8 -3
- package/@ones-editor/embed-block-helper/src/block-properties/embed-block-properties.d.ts +6 -5
- package/@ones-editor/excalidraw/package.json +4 -0
- package/@ones-editor/file/src/locale/en-us.d.ts +1 -0
- package/@ones-editor/file/src/locale/ja-jp.d.ts +1 -0
- package/@ones-editor/file/src/locale/zh-cn.d.ts +1 -0
- package/@ones-editor/graph-embed/src/helper/graph-block-commands.d.ts +5 -19
- package/@ones-editor/image-embed/src/hovering-toolbar/index.d.ts +12 -1
- package/@ones-editor/image-embed/src/image-object.d.ts +1 -0
- package/@ones-editor/image-embed/src/splitter-resizer/index.d.ts +3 -3
- package/@ones-editor/input-handlers/src/i18n/en-us.d.ts +1 -0
- package/@ones-editor/input-handlers/src/i18n/ja-jp.d.ts +1 -0
- package/@ones-editor/input-handlers/src/i18n/zh-cn.d.ts +1 -0
- package/@ones-editor/layout-block/src/command-filter.d.ts +6 -0
- package/@ones-editor/layout-block/src/index.d.ts +1 -0
- package/@ones-editor/list-block/src/index.d.ts +2 -1
- package/@ones-editor/media-embed/src/core/hovering-toolbar/index.d.ts +12 -1
- package/@ones-editor/media-embed/src/utils/dom.d.ts +2 -0
- package/@ones-editor/mention/src/locale/en-us.d.ts +3 -0
- package/@ones-editor/mention/src/locale/ja-jp.d.ts +3 -0
- package/@ones-editor/mention/src/locale/zh-cn.d.ts +3 -0
- package/@ones-editor/mention/src/mention.d.ts +24 -1
- package/@ones-editor/mobile-helper/src/cursor-toolbar.d.ts +15 -0
- package/@ones-editor/mobile-helper/src/embed-mask.d.ts +10 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/active-observer.d.ts +11 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/fixed-providers.d.ts +6 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/index.d.ts +18 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/align-dropdown.d.ts +9 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/group.d.ts +7 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/insert-menu.d.ts +13 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/insert.d.ts +8 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/paragraph.d.ts +9 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/tab-provider.d.ts +10 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/text-dropdown.d.ts +9 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/turn-into.d.ts +8 -0
- package/@ones-editor/mobile-helper/src/fixed-toolbar/toolbar-handler.d.ts +15 -0
- package/@ones-editor/mobile-helper/src/index.d.ts +14 -2
- package/@ones-editor/mobile-helper/src/locale/en-us.d.ts +9 -0
- package/@ones-editor/mobile-helper/src/locale/ja-jp.d.ts +9 -0
- package/@ones-editor/mobile-helper/src/locale/zh-cn.d.ts +9 -0
- package/@ones-editor/mobile-helper/src/selection-gripper/index.d.ts +19 -0
- package/@ones-editor/mobile-helper/src/selection-gripper/select-handle.d.ts +3 -0
- package/@ones-editor/scroll-container/src/utils.d.ts +1 -1
- package/@ones-editor/sharedb-doc/src/index.d.ts +3 -0
- package/@ones-editor/sharedb-doc/src/versions/sharedb-server.d.ts +1 -1
- package/@ones-editor/sharedb-doc/src/versions/simple-client.d.ts +1 -1
- package/@ones-editor/table-block/src/commands/index.d.ts +2 -0
- package/@ones-editor/table-block/src/commands/mobile-command-provider.d.ts +12 -0
- package/@ones-editor/table-block/src/commands/table-block-commands.d.ts +4 -3
- package/@ones-editor/table-block/src/index.d.ts +2 -1
- package/@ones-editor/table-block/src/locale/en-us.d.ts +5 -0
- package/@ones-editor/table-block/src/locale/ja-jp.d.ts +5 -0
- package/@ones-editor/table-block/src/locale/zh-cn.d.ts +5 -0
- package/@ones-editor/table-block/src/table-block/cell-menu/table-cell-dom.d.ts +6 -0
- package/@ones-editor/table-block/src/table-block/table-resize/resize-drag-drop.d.ts +4 -4
- package/@ones-editor/text-commands/src/index.d.ts +1 -3
- package/@ones-editor/to-docx/src/doc2other/core.d.ts +1 -1
- package/@ones-editor/to-docx/src/doc2other/table.d.ts +1 -0
- package/@ones-editor/tsconfig.tsbuildinfo +1 -1
- package/@ones-editor/ui/src/block-menu/block-command-providers.d.ts +8 -0
- package/@ones-editor/{block-menu → ui}/src/block-menu/index.d.ts +3 -1
- package/@ones-editor/ui/src/box-helper/standard-box-commands.d.ts +10 -0
- package/@ones-editor/ui/src/box-helper/standard-box-provider.d.ts +9 -0
- package/@ones-editor/ui/src/index.d.ts +33 -8
- package/@ones-editor/ui/src/link-popup/mobile-link-popup.d.ts +22 -0
- package/@ones-editor/ui/src/link-popup/types.d.ts +34 -0
- package/@ones-editor/ui/src/link-popup/web-link-popup.d.ts +19 -0
- package/@ones-editor/ui/src/locale/en-us.d.ts +14 -0
- package/@ones-editor/ui/src/locale/ja-jp.d.ts +14 -0
- package/@ones-editor/ui/src/locale/zh-cn.d.ts +14 -0
- package/@ones-editor/ui/src/providers/align-dropdown.d.ts +10 -0
- package/@ones-editor/ui/src/providers/align.d.ts +11 -0
- package/@ones-editor/ui/src/providers/block-hook-provider.d.ts +16 -0
- package/@ones-editor/ui/src/providers/clipboard-provider.d.ts +20 -0
- package/@ones-editor/ui/src/providers/color-provider.d.ts +18 -0
- package/@ones-editor/ui/src/providers/edit-link-provider.d.ts +6 -0
- package/@ones-editor/ui/src/providers/heading.d.ts +13 -0
- package/@ones-editor/ui/src/providers/inline-code-provider.d.ts +10 -0
- package/@ones-editor/ui/src/providers/inline-style-provider.d.ts +10 -0
- package/@ones-editor/ui/src/providers/insert-above.d.ts +9 -0
- package/@ones-editor/ui/src/providers/insert-after.d.ts +9 -0
- package/@ones-editor/ui/src/providers/insert-box-provider.d.ts +12 -0
- package/@ones-editor/ui/src/providers/insert-group.d.ts +7 -0
- package/@ones-editor/ui/src/providers/insert-menu.d.ts +16 -0
- package/@ones-editor/ui/src/providers/link.d.ts +12 -0
- package/@ones-editor/ui/src/providers/list.d.ts +13 -0
- package/@ones-editor/ui/src/providers/mobile-link-provider.d.ts +13 -0
- package/@ones-editor/ui/src/providers/paragraph.d.ts +9 -0
- package/@ones-editor/ui/src/providers/proxy-provider.d.ts +9 -0
- package/@ones-editor/ui/src/providers/quoted.d.ts +10 -0
- package/@ones-editor/ui/src/providers/script-with-dropdown.d.ts +9 -0
- package/@ones-editor/ui/src/providers/selection-provider.d.ts +9 -0
- package/@ones-editor/ui/src/providers/text-command-provider.d.ts +16 -0
- package/@ones-editor/ui/src/providers/text-fixed-provider.d.ts +16 -0
- package/@ones-editor/ui/src/providers/text-script-provider.d.ts +10 -0
- package/@ones-editor/ui/src/providers/text-styles.d.ts +9 -0
- package/@ones-editor/ui/src/providers/turn-into.d.ts +9 -0
- package/@ones-editor/ui/src/providers/utils/add-section.d.ts +2 -0
- package/@ones-editor/ui/src/{quick-menu → providers/utils}/basic-commands.d.ts +1 -2
- package/@ones-editor/ui/src/providers/utils/clipboard.d.ts +6 -0
- package/@ones-editor/ui/src/providers/utils/index.d.ts +2 -0
- package/@ones-editor/ui/src/providers/utils/inject-block-options.d.ts +8 -0
- package/@ones-editor/ui/src/providers/utils/text-styles.d.ts +6 -0
- package/@ones-editor/ui/src/quick-menu/index.d.ts +7 -19
- package/@ones-editor/ui/src/quick-menu/quick-command-providers.d.ts +8 -0
- package/@ones-editor/ui/src/quick-menu/types.d.ts +2 -5
- package/@ones-editor/ui/src/readonly-toolbar/add-comment-to-old-doc.d.ts +22 -0
- package/@ones-editor/ui/src/readonly-toolbar/index.d.ts +29 -0
- package/@ones-editor/ui/src/readonly-toolbar/types.d.ts +12 -0
- package/@ones-editor/ui/src/toolbar/link-commands.d.ts +11 -0
- package/@ones-editor/ui/src/toolbar/text-commands.d.ts +2 -2
- package/@ones-editor/ui/src/toolbar/toolbar-handler.d.ts +2 -1
- package/@ones-editor/ui/src/tooltips/index.d.ts +21 -9
- package/@ones-editor/ui/src/utils/hide-toolbar.d.ts +2 -0
- package/@ones-editor/ui-base/src/auto-suggest/auto-suggest-menu.d.ts +4 -1
- package/@ones-editor/ui-base/src/auto-suggest/auto-suggest.d.ts +3 -1
- package/@ones-editor/ui-base/src/color-button/text-color-item.d.ts +18 -8
- package/@ones-editor/ui-base/src/color-palette/color-palette.d.ts +7 -1
- package/@ones-editor/ui-base/src/color-palette/index.d.ts +3 -3
- package/@ones-editor/ui-base/src/command-bar/command-bar.d.ts +4 -2
- package/@ones-editor/ui-base/src/command-bar/fixed-toolbar.d.ts +2 -1
- package/@ones-editor/ui-base/src/command-bar/init-toolbar-item.d.ts +1 -0
- package/@ones-editor/ui-base/src/command-bar/manual-command-bar.d.ts +1 -0
- package/@ones-editor/ui-base/src/command-bar/types.d.ts +7 -2
- package/@ones-editor/ui-base/src/dialog/manual-close-dialog.d.ts +1 -1
- package/@ones-editor/ui-base/src/icons/index.d.ts +5 -1
- package/@ones-editor/ui-base/src/index.d.ts +3 -0
- package/@ones-editor/ui-base/src/input/create-input.d.ts +24 -3
- package/@ones-editor/ui-base/src/locale/en-us.d.ts +1 -0
- package/@ones-editor/ui-base/src/locale/ja-jp.d.ts +1 -0
- package/@ones-editor/ui-base/src/locale/zh-cn.d.ts +1 -0
- package/@ones-editor/ui-base/src/mobile-command-bar/init-menu-item.d.ts +3 -0
- package/@ones-editor/ui-base/src/mobile-command-bar/mobile-bottom-menu.d.ts +21 -0
- package/@ones-editor/ui-base/src/mobile-command-bar/scroll-into-view.d.ts +3 -0
- package/@ones-editor/ui-base/src/popup/popup.d.ts +1 -1
- package/@ones-editor/{ui → ui-base}/src/text-button/index.d.ts +1 -1
- package/@ones-editor/versions/package.json +3 -0
- package/@ones-editor/versions/src/constant/index.d.ts +2 -0
- package/@ones-editor/versions/src/history-doc/history-doc.d.ts +2 -2
- package/@ones-editor/versions/src/history-render/index.d.ts +15 -1
- package/@ones-editor/versions/src/history-tooltip/index.d.ts +14 -0
- package/@ones-editor/versions/src/index.d.ts +1 -0
- package/@ones-editor/versions/src/locale/en-us.d.ts +1 -0
- package/@ones-editor/versions/src/locale/ja-jp.d.ts +1 -0
- package/@ones-editor/versions/src/locale/zh-cn.d.ts +1 -0
- package/@ones-editor/versions/src/types.d.ts +4 -0
- package/@ones-editor/versions/src/utils/block-text.d.ts +3 -1
- package/dist/auto-new-line.d.ts +7 -0
- package/dist/comments/local-doc-comments-provider.d.ts +2 -1
- package/dist/index.d.ts +7 -3
- package/dist/index.js +30396 -25663
- package/dist/lang/en-us.d.ts +1 -1
- package/dist/lang/ja-jp.d.ts +1 -1
- package/dist/lang/zh-cn.d.ts +1 -1
- package/dist/types.d.ts +5 -2
- package/package.json +2 -1
- package/@ones-editor/block-menu/src/block-menu/items/block-command-items.d.ts +0 -3
- package/@ones-editor/block-menu/src/block-menu/items/index.d.ts +0 -5
- package/@ones-editor/block-menu/src/block-menu/items/insert-block-items/index.d.ts +0 -5
- package/@ones-editor/block-menu/src/block-menu/items/text-styles/text-style-item.d.ts +0 -30
- package/@ones-editor/block-menu/src/block-menu/items/types.d.ts +0 -5
- package/@ones-editor/text-commands/src/locale/en-us.d.ts +0 -13
- package/@ones-editor/text-commands/src/locale/ja-jp.d.ts +0 -13
- package/@ones-editor/text-commands/src/locale/zh-cn.d.ts +0 -13
- package/@ones-editor/text-commands/src/text-command-provider.d.ts +0 -24
- package/@ones-editor/text-commands/src/text-commands.d.ts +0 -4
- package/@ones-editor/text-commands/src/text-styles.d.ts +0 -4
- package/@ones-editor/ui/src/quick-menu/basic-menu-items.d.ts +0 -16
- package/@ones-editor/ui/src/quick-menu/inline-box-items.d.ts +0 -8
- package/@ones-editor/ui/src/quick-menu/insert-empty-block.d.ts +0 -4
- package/@ones-editor/ui/src/quick-menu/order.d.ts +0 -1
- package/@ones-editor/ui/src/quick-menu/quick-menu-items.d.ts +0 -9
- package/@ones-editor/ui/src/toolbar/commands/align.d.ts +0 -10
- package/@ones-editor/ui/src/toolbar/commands/paragraph.d.ts +0 -11
- package/@ones-editor/ui/src/toolbar/commands/turn-into.d.ts +0 -10
- package/@ones-editor/ui/src/toolbar/merge-commands.d.ts +0 -2
- /package/@ones-editor/{text-commands → mobile-helper}/src/locale/index.d.ts +0 -0
- /package/@ones-editor/{block-menu → ui}/src/block-menu/standard-block-actions/hook.d.ts +0 -0
package/dist/lang/en-us.d.ts
CHANGED
package/dist/lang/ja-jp.d.ts
CHANGED
package/dist/lang/zh-cn.d.ts
CHANGED
package/dist/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Embed, Box, i18n, OnesEditor, OnesEditorUser, OnesEditorUserPermission, OnesEditorBlockHook, OnesEditorCommandProvider, LogLevel, Block, ShortcutRecords, OnesEditorBlockRenderer, BuildResourceUrlOptions, UploadResourceOptions, UploadResourceResult } from '../@ones-editor/core';
|
|
1
|
+
import { Embed, Box, i18n, OnesEditor, OnesEditorUser, OnesEditorUserPermission, OnesEditorBlockHook, OnesEditorCommandProvider, LogLevel, Block, ShortcutRecords, OnesEditorBlockRenderer, BuildResourceUrlOptions, UploadResourceOptions, UploadResourceResult, MobileClient } from '../@ones-editor/core';
|
|
2
2
|
import { DrawIoOptions } from '../@ones-editor/drawio-embed';
|
|
3
3
|
import { FlowCharEmbedOptions, MermaidEmbedOptions, PlantumlEmbedOptions } from '../@ones-editor/graph-embed';
|
|
4
4
|
import { ImageOptions } from '../@ones-editor/image-embed';
|
|
@@ -8,7 +8,7 @@ import { WebpageOptions } from '../@ones-editor/webpage-embed';
|
|
|
8
8
|
import { OnesEditorCommentOptions } from '../@ones-editor/comments';
|
|
9
9
|
import { FileOptions } from '../@ones-editor/file';
|
|
10
10
|
import { ListOptions } from '../@ones-editor/list-block';
|
|
11
|
-
import { QuickMenuOptions } from '../@ones-editor/ui
|
|
11
|
+
import { QuickMenuOptions } from '../@ones-editor/ui';
|
|
12
12
|
import { TemplateOptions } from '../@ones-editor/templates';
|
|
13
13
|
import { FindDialogOptions, PopoverOptions } from '../@ones-editor/ui-base';
|
|
14
14
|
import { CodeBlockExternalOptions } from '../@ones-editor/code-block';
|
|
@@ -42,6 +42,7 @@ export type EditorComponentOptions = {
|
|
|
42
42
|
mathjax?: MathjaxOptions;
|
|
43
43
|
link?: LinkOptions;
|
|
44
44
|
columns?: EditorConfigLayoutOptions;
|
|
45
|
+
mobile?: MobileClient;
|
|
45
46
|
};
|
|
46
47
|
export type EditorEvents = {
|
|
47
48
|
onClickLink?: (editor: OnesEditor, event: MouseEvent, link: Element) => void;
|
|
@@ -60,6 +61,7 @@ export interface CreateOnesEditorOptions {
|
|
|
60
61
|
lang?: i18n.LANGS;
|
|
61
62
|
logLevel?: LogLevel;
|
|
62
63
|
hideTitle?: boolean;
|
|
64
|
+
autoNewLine?: boolean;
|
|
63
65
|
placeholder?: {
|
|
64
66
|
applyContentPlaceholder?: (editor: OnesEditor) => boolean;
|
|
65
67
|
};
|
|
@@ -103,4 +105,5 @@ export interface CreateLocalEditorOptions {
|
|
|
103
105
|
events?: EditorEvents;
|
|
104
106
|
componentsOptions?: EditorComponentOptions;
|
|
105
107
|
hideTitle?: boolean;
|
|
108
|
+
autoNewLine?: boolean;
|
|
106
109
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ones-editor/editor",
|
|
3
|
-
"version": "2.1.
|
|
3
|
+
"version": "2.1.8-beta.10",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -32,6 +32,7 @@
|
|
|
32
32
|
"lodash.intersection": "^4.4.0",
|
|
33
33
|
"lodash.isequal": "^4.5.0",
|
|
34
34
|
"lodash.merge": "^4.6.2",
|
|
35
|
+
"lodash.pick": "^4.4.0",
|
|
35
36
|
"lodash.throttle": "^4.1.1",
|
|
36
37
|
"lodash.uniqby": "^4.7.0",
|
|
37
38
|
"lodash.upperfirst": "^4.3.1",
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { BlockElement, OnesEditor } from '../../../../../@ones-editor/core';
|
|
2
|
-
import { TextStyleItemOptions } from './text-styles/text-style-item';
|
|
3
|
-
import { BlockMenuItem } from './types';
|
|
4
|
-
export declare function getBlockMenuItems(editor: OnesEditor, block: BlockElement, options: TextStyleItemOptions): BlockMenuItem[];
|
|
5
|
-
export declare function handleBlockMenuItemClick(editor: OnesEditor, block: BlockElement, item: BlockMenuItem): void;
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import { BlockElement, OnesEditor } from '../../../../../../@ones-editor/core';
|
|
2
|
-
import type { GetAllQuickMenuItemsOptions } from '../../../../../../@ones-editor/ui';
|
|
3
|
-
import type { BlockMenuItem } from '../types';
|
|
4
|
-
export declare function getAllInsertBlockItems(editor: OnesEditor, block: BlockElement, source: 'insert-block' | 'insert-block-before', options: GetAllQuickMenuItemsOptions): BlockMenuItem[];
|
|
5
|
-
export declare function executeInsertBlockCommand(editor: OnesEditor, block: BlockElement, item: BlockMenuItem, insertAbove?: boolean): Promise<BlockElement | null> | undefined;
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { BlockElement, OnesEditor, DocBlock } from '../../../../../../@ones-editor/core';
|
|
2
|
-
import { BlockMenuItem } from '../types';
|
|
3
|
-
export interface ParagraphBlockAttribute extends DocBlock {
|
|
4
|
-
'heading'?: number;
|
|
5
|
-
quoted?: boolean;
|
|
6
|
-
align?: 'left' | 'center' | 'right';
|
|
7
|
-
checkbox?: 'checked' | 'unchecked';
|
|
8
|
-
ordered?: boolean;
|
|
9
|
-
}
|
|
10
|
-
export type TextStyleItemOptions = {
|
|
11
|
-
fromEmbed?: boolean;
|
|
12
|
-
onAfterStyleItemClick?: () => void;
|
|
13
|
-
};
|
|
14
|
-
export default class TextStyleItem implements BlockMenuItem {
|
|
15
|
-
private editor;
|
|
16
|
-
private block;
|
|
17
|
-
private options;
|
|
18
|
-
source: string;
|
|
19
|
-
id: string;
|
|
20
|
-
name: string;
|
|
21
|
-
element: HTMLElement;
|
|
22
|
-
private textStylesTooltips;
|
|
23
|
-
constructor(editor: OnesEditor, block: BlockElement, options: TextStyleItemOptions);
|
|
24
|
-
createItemElement(editor: OnesEditor, block: BlockElement): HTMLDivElement;
|
|
25
|
-
private createHeadingItemElement;
|
|
26
|
-
private createListItemElement;
|
|
27
|
-
createItem(id: string, icon: string, parent: HTMLElement, active?: boolean): void;
|
|
28
|
-
handleClick: (editor: OnesEditor, event: Event) => void;
|
|
29
|
-
private calcTextStyleItemTooltipsEnum;
|
|
30
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { BlockCommandItem, BlockElement, CommandParams, CommandResult, DocBlockTextAttributes, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../@ones-editor/core';
|
|
2
|
-
export default class TextCommandProvider implements OnesEditorCommandProvider {
|
|
3
|
-
private editor;
|
|
4
|
-
id: string;
|
|
5
|
-
private emptyTextBlockAttributes;
|
|
6
|
-
private colorItem;
|
|
7
|
-
constructor(editor: OnesEditor);
|
|
8
|
-
destroy(): void;
|
|
9
|
-
private updateButtonColor;
|
|
10
|
-
getAvailableCommands(editor: OnesEditor, block: BlockElement, range: SelectionRange): BlockCommandItem[];
|
|
11
|
-
executeCommand(editor: OnesEditor, block: BlockElement, range: SelectionRange, item: BlockCommandItem, params: CommandParams, result: CommandResult): boolean;
|
|
12
|
-
private executeCommandOnEmptyText;
|
|
13
|
-
private getCommandsOnEmptyText;
|
|
14
|
-
private setCommandsStates;
|
|
15
|
-
getEmptyBlockTextAttributes(editor: OnesEditor, blockId: string): DocBlockTextAttributes | undefined;
|
|
16
|
-
private handleChangeColor;
|
|
17
|
-
private getEmptyTextBlockColor;
|
|
18
|
-
private setEmptyTextBlockColor;
|
|
19
|
-
private static toTextCommand;
|
|
20
|
-
private static fromTextCommandId;
|
|
21
|
-
private static fromTextCommand;
|
|
22
|
-
private static toTextCommands;
|
|
23
|
-
private static fromTextCommands;
|
|
24
|
-
}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { BlockCommandItem, BlockElement, CommandParams, CommandResult, OnesEditor, SelectionRange } from '../../../@ones-editor/core';
|
|
2
|
-
export declare function getStandardEmptyStyleCommands(editor: OnesEditor, block: BlockElement): BlockCommandItem[];
|
|
3
|
-
export declare function getAvailableStyleCommands(editor: OnesEditor, block: BlockElement, range: SelectionRange): BlockCommandItem[];
|
|
4
|
-
export declare function executeStyleCommand(editor: OnesEditor, block: BlockElement, range: SelectionRange, command: string, params: CommandParams, result: CommandResult): boolean;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { BlockElement, DocBlockText, OnesEditor, SelectionRange, TextStyles } from '../../../@ones-editor/core';
|
|
2
|
-
export declare function getIntersectionStyles(text: DocBlockText): Map<any, any>;
|
|
3
|
-
export declare function getTextStyles(editor: OnesEditor, block: BlockElement, range: SelectionRange): TextStyles;
|
|
4
|
-
export declare function applyTextStyle(editor: OnesEditor, block: BlockElement, range: SelectionRange, style: string, value?: boolean | string | number): DocBlockText;
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { BlockElement } from '../../../../@ones-editor/core';
|
|
2
|
-
import type { BlockOptions, CommandItem, OnesEditor, InsertEmptyBlockOptions } from '../../../../@ones-editor/core';
|
|
3
|
-
import type { AddMenuCommand, QuickMenuCommandBetween, QuickMenuCommandInline, QuickMenuCommandProvider } from './types';
|
|
4
|
-
export declare function addQuickMenuItemFields(item: CommandItem, options: BlockOptions, blockType: string): void;
|
|
5
|
-
export declare function getPlainTextMenuOptions(): BlockOptions;
|
|
6
|
-
export declare function getHeadingMenuOptions(start?: number): BlockOptions;
|
|
7
|
-
export declare function getCompleteHeadingMenuOptions(): CommandItem[];
|
|
8
|
-
export declare class BasicCommandProvider implements QuickMenuCommandProvider {
|
|
9
|
-
private withPlainText?;
|
|
10
|
-
constructor(withPlainText?: boolean | undefined);
|
|
11
|
-
getCommands(): CommandItem[];
|
|
12
|
-
updateBlock(editor: OnesEditor, containerId: string, block: BlockElement, item: CommandItem): null;
|
|
13
|
-
handleUpdateBlockCore(editor: OnesEditor, options: InsertEmptyBlockOptions): Promise<null>;
|
|
14
|
-
handleInsertEmptyBlockCore(editor: OnesEditor, options: InsertEmptyBlockOptions): Promise<null>;
|
|
15
|
-
executeCommand(editor: OnesEditor, item: CommandItem, params: QuickMenuCommandInline | QuickMenuCommandBetween | AddMenuCommand): Promise<BlockElement | null>;
|
|
16
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { InsertEmptyBlockOptions, OnesEditor, BlockElement, CommandItem } from '../../../../@ones-editor/core';
|
|
2
|
-
import { AddMenuCommand, QuickMenuCommandBetween, QuickMenuCommandInline, QuickMenuCommandProvider } from './types';
|
|
3
|
-
export declare class InlineBoxCommandProvider implements QuickMenuCommandProvider {
|
|
4
|
-
getCommands(): CommandItem[];
|
|
5
|
-
handleUpdateBlockCore(editor: OnesEditor, options: InsertEmptyBlockOptions): Promise<void | BlockElement | null>;
|
|
6
|
-
handleInsertEmptyBlockCore(editor: OnesEditor, options: InsertEmptyBlockOptions): Promise<BlockElement | null>;
|
|
7
|
-
executeCommand(editor: OnesEditor, item: CommandItem, params: QuickMenuCommandInline | QuickMenuCommandBetween | AddMenuCommand): Promise<BlockElement | null>;
|
|
8
|
-
}
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import { OnesEditor } from '../../../../@ones-editor/core';
|
|
2
|
-
import { AutoSuggestAnchor } from '../../../../@ones-editor/ui-base';
|
|
3
|
-
import { QuickMenuItem } from './types';
|
|
4
|
-
export declare function insertEmptyBlock(editor: OnesEditor, quickItem: QuickMenuItem, anchor: AutoSuggestAnchor): void;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const GroupOrder: Record<string, number>;
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { BlockElement, CommandItemMenuType, OnesEditor } from '../../../../@ones-editor/core';
|
|
2
|
-
import { QuickMenuCommandParams, QuickMenuItem } from './types';
|
|
3
|
-
export interface GetAllQuickMenuItemsOptions {
|
|
4
|
-
withPlainText: boolean;
|
|
5
|
-
from: QuickMenuCommandParams['from'];
|
|
6
|
-
type: CommandItemMenuType;
|
|
7
|
-
ignoreFilter?: boolean;
|
|
8
|
-
}
|
|
9
|
-
export declare function getAllQuickMenuItems(editor: OnesEditor, block: BlockElement | undefined, options: GetAllQuickMenuItemsOptions): QuickMenuItem[];
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BlockCommandItem, BlockElement, DocBlock, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
|
|
2
|
-
export default class AlignProvider implements OnesEditorCommandProvider {
|
|
3
|
-
private editor;
|
|
4
|
-
id: string;
|
|
5
|
-
constructor(editor: OnesEditor);
|
|
6
|
-
applyAlignStyle(editor: OnesEditor, block: BlockElement, align: string): void;
|
|
7
|
-
isChecked(blockData: DocBlock, id: string): boolean;
|
|
8
|
-
getAvailableCommands(editor: OnesEditor, block: BlockElement, range: SelectionRange): BlockCommandItem[];
|
|
9
|
-
executeCommand(editor: OnesEditor, block: BlockElement, range: SelectionRange, command: BlockCommandItem): boolean;
|
|
10
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { BlockCommandItem, BlockElement, DocBlock, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
|
|
2
|
-
export default class ParagraphProvider implements OnesEditorCommandProvider {
|
|
3
|
-
private editor;
|
|
4
|
-
id: string;
|
|
5
|
-
constructor(editor: OnesEditor);
|
|
6
|
-
isChecked(blockData: DocBlock, id: string): boolean;
|
|
7
|
-
getAvailableCommands(editor: OnesEditor, block: BlockElement): BlockCommandItem[];
|
|
8
|
-
convertLink(editor: OnesEditor, range: SelectionRange, block: BlockElement): void;
|
|
9
|
-
convertToList(editor: OnesEditor, block: BlockElement, listType: 'unordered' | 'ordered' | 'unchecked'): void;
|
|
10
|
-
executeCommand(editor: OnesEditor, block: BlockElement, range: SelectionRange, command: BlockCommandItem): boolean;
|
|
11
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { BlockCommandItem, BlockElement, OnesEditor, OnesEditorCommandProvider, SelectionRange } from '../../../../../@ones-editor/core';
|
|
2
|
-
export default class BlockTurnIntoCommandProvider implements OnesEditorCommandProvider {
|
|
3
|
-
private editor;
|
|
4
|
-
id: string;
|
|
5
|
-
constructor(editor: OnesEditor);
|
|
6
|
-
getHeadingIndex(): number;
|
|
7
|
-
getAvailableCommands(editor: OnesEditor, block: BlockElement, range: SelectionRange): BlockCommandItem[];
|
|
8
|
-
applyHeadingStyle(editor: OnesEditor, block: BlockElement, heading: number | null): void;
|
|
9
|
-
executeCommand(editor: OnesEditor, block: BlockElement, range: SelectionRange, command: BlockCommandItem): boolean;
|
|
10
|
-
}
|
|
File without changes
|
|
File without changes
|