@ckeditor/ckeditor5-list 48.2.0-alpha.7 → 48.3.0-alpha.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.
- package/dist/augmentation.d.ts +54 -54
- package/dist/index.css.map +1 -1
- package/dist/index.d.ts +67 -67
- package/dist/index.js +7187 -8921
- package/dist/index.js.map +1 -1
- package/dist/legacyerrors.d.ts +0 -4
- package/dist/legacylist/legacyconverters.d.ts +184 -184
- package/dist/legacylist/legacyindentcommand.d.ts +33 -33
- package/dist/legacylist/legacylistcommand.d.ts +52 -52
- package/dist/legacylist/legacylistediting.d.ts +32 -32
- package/dist/legacylist/legacylistutils.d.ts +40 -40
- package/dist/legacylist/legacyutils.d.ts +91 -91
- package/dist/legacylist.d.ts +25 -25
- package/dist/legacylistproperties/legacylistpropertiesediting.d.ts +71 -71
- package/dist/legacylistproperties/legacylistreversedcommand.d.ts +33 -33
- package/dist/legacylistproperties/legacyliststartcommand.d.ts +33 -33
- package/dist/legacylistproperties/legacyliststylecommand.d.ts +63 -63
- package/dist/legacylistproperties.d.ts +26 -26
- package/dist/legacytodolist/legacychecktodolistcommand.d.ts +47 -47
- package/dist/legacytodolist/legacytodolistconverters.d.ts +76 -76
- package/dist/legacytodolist/legacytodolistediting.d.ts +46 -46
- package/dist/legacytodolist.d.ts +26 -26
- package/dist/list/adjacentlistssupport.d.ts +16 -16
- package/dist/list/converters.d.ts +68 -68
- package/dist/list/listcommand.d.ts +84 -84
- package/dist/list/listediting.d.ts +213 -219
- package/dist/list/listindentcommand.d.ts +54 -54
- package/dist/list/listmergecommand.d.ts +68 -68
- package/dist/list/listsplitcommand.d.ts +59 -59
- package/dist/list/listui.d.ts +19 -19
- package/dist/list/listutils.d.ts +55 -55
- package/dist/list/utils/listwalker.d.ts +139 -139
- package/dist/list/utils/model.d.ts +202 -202
- package/dist/list/utils/postfixers.d.ts +30 -30
- package/dist/list/utils/view.d.ts +65 -65
- package/dist/list/utils.d.ts +15 -15
- package/dist/list.d.ts +25 -25
- package/dist/listconfig.d.ts +234 -234
- package/dist/listformatting/listitemboldintegration.d.ts +29 -29
- package/dist/listformatting/listitemfontcolorintegration.d.ts +29 -29
- package/dist/listformatting/listitemfontfamilyintegration.d.ts +29 -29
- package/dist/listformatting/listitemfontsizeintegration.d.ts +29 -29
- package/dist/listformatting/listitemitalicintegration.d.ts +29 -29
- package/dist/listformatting.d.ts +66 -66
- package/dist/listproperties/converters.d.ts +15 -15
- package/dist/listproperties/listpropertiesediting.d.ts +91 -91
- package/dist/listproperties/listpropertiesui.d.ts +22 -22
- package/dist/listproperties/listpropertiesutils.d.ts +32 -32
- package/dist/listproperties/listreversedcommand.d.ts +31 -31
- package/dist/listproperties/liststartcommand.d.ts +34 -34
- package/dist/listproperties/liststylecommand.d.ts +67 -67
- package/dist/listproperties/ui/listpropertiesview.d.ts +147 -147
- package/dist/listproperties/utils/config.d.ts +32 -32
- package/dist/listproperties/utils/style.d.ts +31 -31
- package/dist/listproperties.d.ts +26 -26
- package/dist/todolist/checktodolistcommand.d.ts +44 -44
- package/dist/todolist/todocheckboxchangeobserver.d.ts +36 -36
- package/dist/todolist/todolistediting.d.ts +45 -45
- package/dist/todolist/todolistui.d.ts +19 -19
- package/dist/todolist.d.ts +26 -26
- package/package.json +10 -10
|
@@ -1,156 +1,156 @@
|
|
|
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 ArrayOrItem } from
|
|
9
|
-
import { type ListElement } from
|
|
10
|
-
import type { ModelElement, ModelNode } from
|
|
6
|
+
* @module list/list/utils/listwalker
|
|
7
|
+
*/
|
|
8
|
+
import { type ArrayOrItem } from "@ckeditor/ckeditor5-utils";
|
|
9
|
+
import { type ListElement } from "./model.js";
|
|
10
|
+
import type { ModelElement, ModelNode } from "@ckeditor/ckeditor5-engine";
|
|
11
11
|
/**
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
12
|
+
* Document list blocks iterator.
|
|
13
|
+
*
|
|
14
|
+
* @internal
|
|
15
|
+
*/
|
|
16
16
|
export declare class ListWalker {
|
|
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
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
17
|
+
/**
|
|
18
|
+
* The start list item block element.
|
|
19
|
+
*/
|
|
20
|
+
private _startElement;
|
|
21
|
+
/**
|
|
22
|
+
* The reference indent. Initialized by the indent of the start block.
|
|
23
|
+
*/
|
|
24
|
+
private _referenceIndent;
|
|
25
|
+
/**
|
|
26
|
+
* The iterating direction.
|
|
27
|
+
*/
|
|
28
|
+
private _isForward;
|
|
29
|
+
/**
|
|
30
|
+
* Whether start block should be included in the result (if it's matching other criteria).
|
|
31
|
+
*/
|
|
32
|
+
private _includeSelf;
|
|
33
|
+
/**
|
|
34
|
+
* Additional attributes that must be the same for each block.
|
|
35
|
+
*/
|
|
36
|
+
private _sameAttributes;
|
|
37
|
+
/**
|
|
38
|
+
* Whether blocks with the same indent level as the start block should be included in the result.
|
|
39
|
+
*/
|
|
40
|
+
private _sameIndent;
|
|
41
|
+
/**
|
|
42
|
+
* Whether blocks with a lower indent level than the start block should be included in the result.
|
|
43
|
+
*/
|
|
44
|
+
private _lowerIndent;
|
|
45
|
+
/**
|
|
46
|
+
* Whether blocks with a higher indent level than the start block should be included in the result.
|
|
47
|
+
*/
|
|
48
|
+
private _higherIndent;
|
|
49
|
+
/**
|
|
50
|
+
* Creates a document list iterator.
|
|
51
|
+
*
|
|
52
|
+
* @param startElement The start list item block element.
|
|
53
|
+
* @param options.direction The iterating direction.
|
|
54
|
+
* @param options.includeSelf Whether start block should be included in the result (if it's matching other criteria).
|
|
55
|
+
* @param options.sameAttributes Additional attributes that must be the same for each block.
|
|
56
|
+
* @param options.sameIndent Whether blocks with the same indent level as the start block should be included
|
|
57
|
+
* in the result.
|
|
58
|
+
* @param options.lowerIndent Whether blocks with a lower indent level than the start block should be included
|
|
59
|
+
* in the result.
|
|
60
|
+
* @param options.higherIndent Whether blocks with a higher indent level than the start block should be included
|
|
61
|
+
* in the result.
|
|
62
|
+
*/
|
|
63
|
+
constructor(startElement: ModelNode, options: ListWalkerOptions);
|
|
64
|
+
/**
|
|
65
|
+
* Performs only first step of iteration and returns the result.
|
|
66
|
+
*
|
|
67
|
+
* @param startElement The start list item block element.
|
|
68
|
+
* @param options.direction The iterating direction.
|
|
69
|
+
* @param options.includeSelf Whether start block should be included in the result (if it's matching other criteria).
|
|
70
|
+
* @param options.sameAttributes Additional attributes that must be the same for each block.
|
|
71
|
+
* @param options.sameIndent Whether blocks with the same indent level as the start block should be included
|
|
72
|
+
* in the result.
|
|
73
|
+
* @param options.lowerIndent Whether blocks with a lower indent level than the start block should be included
|
|
74
|
+
* in the result.
|
|
75
|
+
* @param options.higherIndent Whether blocks with a higher indent level than the start block should be included
|
|
76
|
+
* in the result.
|
|
77
|
+
*/
|
|
78
|
+
static first(startElement: ModelNode, options: ListWalkerOptions): ListElement | null;
|
|
79
|
+
/**
|
|
80
|
+
* Iterable interface.
|
|
81
|
+
*/
|
|
82
|
+
[Symbol.iterator](): Iterator<ListElement>;
|
|
83
|
+
/**
|
|
84
|
+
* Returns the model element to start iterating.
|
|
85
|
+
*/
|
|
86
|
+
private _getStartNode;
|
|
87
87
|
}
|
|
88
88
|
/**
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
89
|
+
* Iterates sibling list blocks starting from the given node.
|
|
90
|
+
*
|
|
91
|
+
* @internal
|
|
92
|
+
*/
|
|
93
93
|
export declare class SiblingListBlocksIterator implements IterableIterator<ListIteratorValue> {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
94
|
+
private _node;
|
|
95
|
+
private _isForward;
|
|
96
|
+
private _previousNodesByIndent;
|
|
97
|
+
private _previous;
|
|
98
|
+
private _previousNodeIndent;
|
|
99
|
+
/**
|
|
100
|
+
* @param node The model node.
|
|
101
|
+
* @param direction Iteration direction.
|
|
102
|
+
*/
|
|
103
|
+
constructor(node: ModelNode | null, direction?: "forward" | "backward");
|
|
104
|
+
[Symbol.iterator](): IterableIterator<ListIteratorValue>;
|
|
105
|
+
next(): IteratorResult<ListIteratorValue>;
|
|
106
106
|
}
|
|
107
107
|
/**
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
108
|
+
* The iterable protocol over the list elements.
|
|
109
|
+
*
|
|
110
|
+
* @internal
|
|
111
|
+
*/
|
|
112
112
|
export declare class ListBlocksIterable {
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
113
|
+
private _listHead;
|
|
114
|
+
/**
|
|
115
|
+
* @param listHead The head element of a list.
|
|
116
|
+
*/
|
|
117
|
+
constructor(listHead: ModelElement);
|
|
118
|
+
/**
|
|
119
|
+
* List blocks iterator.
|
|
120
|
+
*
|
|
121
|
+
* Iterates over all blocks of a list.
|
|
122
|
+
*/
|
|
123
|
+
[Symbol.iterator](): Iterator<ListIteratorValue>;
|
|
124
124
|
}
|
|
125
125
|
/**
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
126
|
+
* Object returned by `SiblingListBlocksIterator` when traversing a list.
|
|
127
|
+
*
|
|
128
|
+
* @internal
|
|
129
|
+
*/
|
|
130
130
|
export interface ListIteratorValue {
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
131
|
+
/**
|
|
132
|
+
* The current list node.
|
|
133
|
+
*/
|
|
134
|
+
node: ListElement;
|
|
135
|
+
/**
|
|
136
|
+
* The previous list node.
|
|
137
|
+
*/
|
|
138
|
+
previous: ListElement | null;
|
|
139
|
+
/**
|
|
140
|
+
* The previous list node at the same indent as current node.
|
|
141
|
+
*/
|
|
142
|
+
previousNodeInList: ListElement | null;
|
|
143
143
|
}
|
|
144
144
|
/**
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
145
|
+
* Document list blocks iterator options.
|
|
146
|
+
*
|
|
147
|
+
* @internal
|
|
148
|
+
*/
|
|
149
149
|
export type ListWalkerOptions = {
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
150
|
+
direction?: "forward" | "backward";
|
|
151
|
+
includeSelf?: boolean;
|
|
152
|
+
sameAttributes?: ArrayOrItem<string>;
|
|
153
|
+
sameIndent?: boolean;
|
|
154
|
+
lowerIndent?: boolean;
|
|
155
|
+
higherIndent?: boolean;
|
|
156
156
|
};
|