Encoder should respect hardBreaks at the end of list items
Issue #68
new
The library encoder ‘zaps’ away a hardBreak
if it is at the end of a list item, whereas the CS encoder respects it. For consistency, we think the behaviours should match.
ADF Request:
{
"version": 1,
"type": "doc",
"content": [
{
"type": "bulletList",
"content": [
{
"type": "listItem",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "List item 1"
}
]
}
]
},
{
"type": "listItem",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "List item 2 (with hard break)"
},
{
"type": "hardBreak"
}
]
}
]
},
{
"type": "listItem",
"content": [
{
"type": "paragraph",
"content": [
{
"type": "text",
"text": "List item 3"
}
]
}
]
}
]
}
]
}
CS:
* List item 1
* List item 2 (with hard break)
* List item 3
Lib:
* List item 1
* List item 2 (with hard break)
* List item 3"