slate-edit-list
Version:
A Slate plugin to handle keyboard events in lists.
65 lines (63 loc) • 1.3 kB
YAML
document:
nodes:
- kind: block
type: ul_list
nodes:
- kind: block
type: list_item
nodes:
- kind: block
type: paragraph
nodes:
- kind: text
text: "1"
- kind: block
type: ul_list
nodes:
- kind: block
type: list_item
nodes:
- kind: block
type: paragraph
nodes:
- kind: text
text: "1.1"
- kind: block
type: list_item
nodes:
- kind: block
type: paragraph
nodes:
- kind: text
text: "1.2"
- kind: block
type: list_item
nodes:
- kind: block
type: paragraph
nodes:
- kind: text
text: "1.3"
- kind: block
type: list_item
nodes:
- kind: block
type: paragraph
nodes:
- kind: text
text: "1.4"
- kind: block
type: list_item
nodes:
- kind: block
type: paragraph
nodes:
- kind: text
key: 'cursor'
text: "2"
selection:
anchorKey: cursor
anchorOffset: 0
focusKey: cursor
focusOffset: 0
isFocused: true