@ckeditor/ckeditor5-editor-multi-root 48.2.0 → 48.3.0-alpha.1
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/dist/augmentation.d.ts +36 -36
- package/dist/index-content.css +1 -0
- package/dist/index-editor.css +1 -0
- package/dist/index.css +0 -2
- package/dist/index.d.ts +11 -11
- package/dist/index.js +842 -962
- package/dist/index.js.map +1 -1
- package/dist/legacyerrors.d.ts +0 -4
- package/dist/multirooteditor.d.ts +768 -768
- package/dist/multirooteditorui.d.ts +69 -69
- package/dist/multirooteditoruiview.d.ts +78 -78
- package/package.json +5 -5
- package/dist/index.css.map +0 -1
|
@@ -1,74 +1,74 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
|
+
*/
|
|
5
5
|
/**
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
import { type Editor } from
|
|
9
|
-
import { EditorUI, type InlineEditableUIView } from
|
|
10
|
-
import { type MultiRootEditorUIView } from
|
|
6
|
+
* @module editor-multi-root/multirooteditorui
|
|
7
|
+
*/
|
|
8
|
+
import { type Editor } from "@ckeditor/ckeditor5-core";
|
|
9
|
+
import { EditorUI, type InlineEditableUIView } from "@ckeditor/ckeditor5-ui";
|
|
10
|
+
import { type MultiRootEditorUIView } from "./multirooteditoruiview.js";
|
|
11
11
|
/**
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
* The multi-root editor UI class.
|
|
13
|
+
*/
|
|
14
14
|
export declare class MultiRootEditorUI extends EditorUI {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
15
|
+
/**
|
|
16
|
+
* The main (top–most) view of the editor UI.
|
|
17
|
+
*/
|
|
18
|
+
readonly view: MultiRootEditorUIView;
|
|
19
|
+
/**
|
|
20
|
+
* The editable element that was focused the last time when any of the editables had focus.
|
|
21
|
+
*/
|
|
22
|
+
private _lastFocusedEditableElement;
|
|
23
|
+
/**
|
|
24
|
+
* Creates an instance of the multi-root editor UI class.
|
|
25
|
+
*
|
|
26
|
+
* @param editor The editor instance.
|
|
27
|
+
* @param view The view of the UI.
|
|
28
|
+
*/
|
|
29
|
+
constructor(editor: Editor, view: MultiRootEditorUIView);
|
|
30
|
+
/**
|
|
31
|
+
* Initializes the UI.
|
|
32
|
+
*/
|
|
33
|
+
init(): void;
|
|
34
|
+
/**
|
|
35
|
+
* Adds the editable to the editor UI.
|
|
36
|
+
*
|
|
37
|
+
* After the editable is added to the editor UI it can be considered "active".
|
|
38
|
+
*
|
|
39
|
+
* The editable is attached to the editor editing pipeline, which means that it will be updated as the editor model updates and
|
|
40
|
+
* changing its content will be reflected in the editor model. Keystrokes, focus handling and placeholder are initialized.
|
|
41
|
+
*
|
|
42
|
+
* @param editable The editable instance to add.
|
|
43
|
+
* @param placeholder Placeholder for the editable element. If not set, placeholder value from the
|
|
44
|
+
* {@link module:core/editor/editorconfig~EditorConfig#placeholder editor configuration} will be used (if it was provided).
|
|
45
|
+
*/
|
|
46
|
+
addEditable(editable: InlineEditableUIView, placeholder?: string): void;
|
|
47
|
+
/**
|
|
48
|
+
* Removes the editable instance from the editor UI.
|
|
49
|
+
*
|
|
50
|
+
* Removed editable can be considered "deactivated".
|
|
51
|
+
*
|
|
52
|
+
* The editable is detached from the editing pipeline, so model changes are no longer reflected in it. All handling added in
|
|
53
|
+
* {@link #addEditable} is removed.
|
|
54
|
+
*
|
|
55
|
+
* @param editable Editable to remove from the editor UI.
|
|
56
|
+
*/
|
|
57
|
+
removeEditable(editable: InlineEditableUIView): void;
|
|
58
|
+
/**
|
|
59
|
+
* @inheritDoc
|
|
60
|
+
*/
|
|
61
|
+
override destroy(): void;
|
|
62
|
+
/**
|
|
63
|
+
* Initializes the editor main toolbar and its panel.
|
|
64
|
+
*/
|
|
65
|
+
private _initToolbar;
|
|
66
|
+
/**
|
|
67
|
+
* Enables the placeholder text on a given editable.
|
|
68
|
+
*
|
|
69
|
+
* @param editable Editable on which the placeholder should be set.
|
|
70
|
+
* @param placeholder Placeholder for the editable element. If not set, placeholder value from the
|
|
71
|
+
* {@link module:core/editor/editorconfig~EditorConfig#placeholder editor configuration} will be used (if it was provided).
|
|
72
|
+
*/
|
|
73
|
+
private _initPlaceholder;
|
|
74
74
|
}
|
|
@@ -1,83 +1,83 @@
|
|
|
1
1
|
/**
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
* @license Copyright (c) 2003-2026, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-licensing-options
|
|
4
|
+
*/
|
|
5
5
|
/**
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
import { EditorUIView, InlineEditableUIView, MenuBarView, ToolbarView } from
|
|
9
|
-
import type { Locale } from
|
|
10
|
-
import type { EditingView } from
|
|
11
|
-
import type { ViewRootElementDefinition } from
|
|
6
|
+
* @module editor-multi-root/multirooteditoruiview
|
|
7
|
+
*/
|
|
8
|
+
import { EditorUIView, InlineEditableUIView, MenuBarView, ToolbarView } from "@ckeditor/ckeditor5-ui";
|
|
9
|
+
import type { Locale } from "@ckeditor/ckeditor5-utils";
|
|
10
|
+
import type { EditingView } from "@ckeditor/ckeditor5-engine";
|
|
11
|
+
import type { ViewRootElementDefinition } from "@ckeditor/ckeditor5-core";
|
|
12
12
|
/**
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
13
|
+
* The multi-root editor UI view. It is a virtual view providing an inline
|
|
14
|
+
* {@link module:editor-multi-root/multirooteditoruiview~MultiRootEditorUIView#editable} and a
|
|
15
|
+
* {@link module:editor-multi-root/multirooteditoruiview~MultiRootEditorUIView#toolbar}, but without any
|
|
16
|
+
* specific arrangement of the components in the DOM.
|
|
17
|
+
*
|
|
18
|
+
* See {@link module:editor-multi-root/multirooteditor~MultiRootEditor.create `MultiRootEditor.create()`}
|
|
19
|
+
* to learn more about this view.
|
|
20
|
+
*/
|
|
21
21
|
export declare class MultiRootEditorUIView extends EditorUIView {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
22
|
+
/**
|
|
23
|
+
* The main toolbar of the multi-root editor UI.
|
|
24
|
+
*/
|
|
25
|
+
override readonly toolbar: ToolbarView;
|
|
26
|
+
/**
|
|
27
|
+
* Editable elements used by the multi-root editor UI.
|
|
28
|
+
*/
|
|
29
|
+
readonly editables: Record<string, InlineEditableUIView>;
|
|
30
|
+
readonly editable: InlineEditableUIView;
|
|
31
|
+
/**
|
|
32
|
+
* Menu bar view instance.
|
|
33
|
+
*/
|
|
34
|
+
override menuBarView: MenuBarView;
|
|
35
|
+
/**
|
|
36
|
+
* The editing view instance this view is related to.
|
|
37
|
+
*/
|
|
38
|
+
private readonly _editingView;
|
|
39
|
+
/**
|
|
40
|
+
* Creates an instance of the multi-root editor UI view.
|
|
41
|
+
*
|
|
42
|
+
* @param locale The {@link module:core/editor/editor~Editor#locale} instance.
|
|
43
|
+
* @param editingView The editing view instance this view is related to.
|
|
44
|
+
* @param editableNames Names for all editable views. For each name, one
|
|
45
|
+
* {@link module:ui/editableui/inline/inlineeditableuiview~InlineEditableUIView `InlineEditableUIView`} instance will be initialized.
|
|
46
|
+
* @param options Configuration options for the view instance.
|
|
47
|
+
* @param options.editableElements The editable elements to be used, assigned to their names. If not specified, they will be
|
|
48
|
+
* automatically created by {@link module:ui/editableui/inline/inlineeditableuiview~InlineEditableUIView `InlineEditableUIView`}
|
|
49
|
+
* instances.
|
|
50
|
+
* @param options.shouldToolbarGroupWhenFull When set to `true` enables automatic items grouping
|
|
51
|
+
* in the main {@link module:editor-multi-root/multirooteditoruiview~MultiRootEditorUIView#toolbar toolbar}.
|
|
52
|
+
* See {@link module:ui/toolbar/toolbarview~ToolbarOptions#shouldGroupWhenFull} to learn more.
|
|
53
|
+
* @param options.label When set, this value will be used as an accessible `aria-label` of the
|
|
54
|
+
* {@link module:ui/editableui/editableuiview~EditableUIView editable view} elements.
|
|
55
|
+
*/
|
|
56
|
+
constructor(locale: Locale, editingView: EditingView, editableNames: Array<string>, options?: {
|
|
57
|
+
editableElements?: Record<string, HTMLElement | ViewRootElementDefinition>;
|
|
58
|
+
shouldToolbarGroupWhenFull?: boolean;
|
|
59
|
+
label?: string | Record<string, string>;
|
|
60
|
+
});
|
|
61
|
+
/**
|
|
62
|
+
* Creates an editable instance with given name and registers it in the editor UI view.
|
|
63
|
+
*
|
|
64
|
+
* If `editableElement` is provided, the editable instance will be created on top of it. Otherwise, the editor will create a new
|
|
65
|
+
* DOM element and use it instead.
|
|
66
|
+
*
|
|
67
|
+
* @param editableName The name for the editable.
|
|
68
|
+
* @param editableElement DOM element for which the editable should be created.
|
|
69
|
+
* @param label The accessible editable label used by assistive technologies.
|
|
70
|
+
* @returns The created editable instance.
|
|
71
|
+
*/
|
|
72
|
+
createEditable(editableName: string, editableElement?: HTMLElement | ViewRootElementDefinition, label?: string): InlineEditableUIView;
|
|
73
|
+
/**
|
|
74
|
+
* Destroys and removes the editable from the editor UI view.
|
|
75
|
+
*
|
|
76
|
+
* @param editableName The name of the editable that should be removed.
|
|
77
|
+
*/
|
|
78
|
+
removeEditable(editableName: string): void;
|
|
79
|
+
/**
|
|
80
|
+
* @inheritDoc
|
|
81
|
+
*/
|
|
82
|
+
override render(): void;
|
|
83
83
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-editor-multi-root",
|
|
3
|
-
"version": "48.
|
|
3
|
+
"version": "48.3.0-alpha.1",
|
|
4
4
|
"description": "Multi-root editor implementation for CKEditor 5.",
|
|
5
5
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
6
6
|
"author": "CKSource (http://cksource.com/)",
|
|
@@ -25,10 +25,10 @@
|
|
|
25
25
|
"./package.json": "./package.json"
|
|
26
26
|
},
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@ckeditor/ckeditor5-core": "48.
|
|
29
|
-
"@ckeditor/ckeditor5-engine": "48.
|
|
30
|
-
"@ckeditor/ckeditor5-ui": "48.
|
|
31
|
-
"@ckeditor/ckeditor5-utils": "48.
|
|
28
|
+
"@ckeditor/ckeditor5-core": "48.3.0-alpha.1",
|
|
29
|
+
"@ckeditor/ckeditor5-engine": "48.3.0-alpha.1",
|
|
30
|
+
"@ckeditor/ckeditor5-ui": "48.3.0-alpha.1",
|
|
31
|
+
"@ckeditor/ckeditor5-utils": "48.3.0-alpha.1",
|
|
32
32
|
"es-toolkit": "1.45.1"
|
|
33
33
|
},
|
|
34
34
|
"files": [
|
package/dist/index.css.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["index.css"],"names":[],"mappings":";;;;;;AAEA,CAAC,CAAC,CAAC,CAAC,gBAAgB,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC","file":"index.css.map","sourcesContent":["\n\n/*# sourceMappingURL=index.css.map */"]}
|