-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
This HTML:
<ul>
<li>
<ul>
<li>
<ul>
<li>level 3</li>
</ul>
</li>
</ul>
</li>
<li>level 1, item 2</li>
</ul>
is represented in portable text as:
[
{
"_type": "block",
"children": [
{
"_type": "span",
"text": "level 3, item 1",
"marks": [],
"_key": "bdb63dc6ecd8"
}
],
"markDefs": [],
"style": "normal",
"_key": "6ddb7cdfd2da",
"level": 3,
"listItem": "number"
},
{
"_type": "block",
"children": [
{
"_type": "span",
"text": "level 1, item 2",
"marks": [],
"_key": "6efddef7f088"
}
],
"markDefs": [],
"style": "normal",
"_key": "96e69372dfa0",
"level": 1,
"listItem": "number"
}
]
nestLists should assume a start level of 0 before the first item and then needs to create additional nested lists for each level that is changed.
Also see portabletext/to-html#108
schalk-b
Metadata
Metadata
Assignees
Labels
No labels