@lexical/list 0.13.0 → 0.14.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/LexicalList.dev.esm.js +1195 -0
- package/LexicalList.dev.js +107 -129
- package/LexicalList.esm.js +23 -0
- package/LexicalList.js +1 -1
- package/LexicalList.prod.esm.js +7 -0
- package/LexicalList.prod.js +30 -28
- package/LexicalListItemNode.d.ts +0 -1
- package/LexicalListNode.d.ts +1 -0
- package/README.md +3 -1
- package/formatList.d.ts +4 -5
- package/package.json +6 -4
package/README.md
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
`@lexical/list`
|
|
2
2
|
|
|
3
|
+
[](https://lexical.dev/docs/api/modules/lexical_list)
|
|
4
|
+
|
|
3
5
|
This package exposes the primitives for implementing lists in Lexical. If you're trying to implement conventional lists with React, take a look at the ListPlugin exposed
|
|
4
6
|
by [@lexical/react](https://lexical.dev/docs/packages/lexical-react), which wraps these primitives into a neat component that you can drop into any LexicalComposer.
|
|
5
7
|
|
|
@@ -55,7 +57,7 @@ function onButtonClick(e: MouseEvent) {
|
|
|
55
57
|
|
|
56
58
|
## Theming
|
|
57
59
|
|
|
58
|
-
Lists can be styled using the following properties in the EditorTheme passed to the editor in the initial config (the values are
|
|
60
|
+
Lists can be styled using the following properties in the EditorTheme passed to the editor in the initial config (the values are classes that will be applied in the denoted contexts):
|
|
59
61
|
|
|
60
62
|
```ts
|
|
61
63
|
{
|
package/formatList.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
7
|
*/
|
|
8
|
-
import { LexicalEditor
|
|
8
|
+
import { LexicalEditor } from 'lexical';
|
|
9
9
|
import { ListItemNode, ListNode } from './';
|
|
10
10
|
import { ListType } from './LexicalListNode';
|
|
11
11
|
/**
|
|
@@ -36,12 +36,11 @@ export declare function mergeLists(list1: ListNode, list2: ListNode): void;
|
|
|
36
36
|
export declare function removeList(editor: LexicalEditor): void;
|
|
37
37
|
/**
|
|
38
38
|
* Takes the value of a child ListItemNode and makes it the value the ListItemNode
|
|
39
|
-
* should be if it isn't already.
|
|
40
|
-
*
|
|
39
|
+
* should be if it isn't already. Also ensures that checked is undefined if the
|
|
40
|
+
* parent does not have a list type of 'check'.
|
|
41
41
|
* @param list - The list whose children are updated.
|
|
42
|
-
* @param children - An array of the children to be updated.
|
|
43
42
|
*/
|
|
44
|
-
export declare function updateChildrenListItemValue(list: ListNode
|
|
43
|
+
export declare function updateChildrenListItemValue(list: ListNode): void;
|
|
45
44
|
/**
|
|
46
45
|
* Adds an empty ListNode/ListItemNode chain at listItemNode, so as to
|
|
47
46
|
* create an indent effect. Won't indent ListItemNodes that have a ListNode as
|
package/package.json
CHANGED
|
@@ -8,17 +8,19 @@
|
|
|
8
8
|
"list"
|
|
9
9
|
],
|
|
10
10
|
"license": "MIT",
|
|
11
|
-
"version": "0.
|
|
11
|
+
"version": "0.14.0",
|
|
12
12
|
"main": "LexicalList.js",
|
|
13
13
|
"peerDependencies": {
|
|
14
|
-
"lexical": "0.
|
|
14
|
+
"lexical": "0.14.0"
|
|
15
15
|
},
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@lexical/utils": "0.
|
|
17
|
+
"@lexical/utils": "0.14.0"
|
|
18
18
|
},
|
|
19
19
|
"repository": {
|
|
20
20
|
"type": "git",
|
|
21
21
|
"url": "https://github.com/facebook/lexical",
|
|
22
22
|
"directory": "packages/lexical-list"
|
|
23
|
-
}
|
|
23
|
+
},
|
|
24
|
+
"module": "LexicalList.esm.js",
|
|
25
|
+
"sideEffects": false
|
|
24
26
|
}
|