Open webhao opened 3 years ago
// in table.js
const List = Quill.import('formats/list')
const Block = Quill.import('blots/block')
...
TableCell.allowedChildren = [..., List.requiredContainer, Block]
List.requiredContainer
can make you add ul, and Block
can preserve the TableCell after cancel ul format
@WongYAQi It's not enough for adding ul/ol in table cell.
To achieve it, the listItem
blot and listContainer
blot need to be modified accordingly (like table cell line). Currently there is no support for ul/ol in table cell.
@WongYAQi It's not enough for adding ul/ol in table cell. To achieve it, the
listItem
blot andlistContainer
blot need to be modified accordingly (like table cell line). Currently there is no support for ul/ol in table cell.
yes, I found that there was problem when merge two list cell, and checkMerge
function would throw error.
So I realized that "add ui in table" would be a long-term job.But this may be helpful when just show the ul element with this little change.
// in table.js const List = Quill.import('formats/list') const Block = Quill.import('blots/block') ... TableCell.allowedChildren = [..., List.requiredContainer, Block]
List.requiredContainer
can make you add ul, andBlock
can preserve the TableCell after cancel ul format
I'll do as you say, It's half done, The other half is the problem of setting, Didn't you solve it?
The setContents
will go wrong