diff --git a/site/examples/richtext.tsx b/site/examples/richtext.tsx index 243a182b0..92ef20155 100644 --- a/site/examples/richtext.tsx +++ b/site/examples/richtext.tsx @@ -66,9 +66,9 @@ const toggleBlock = (editor, format) => { Transforms.unwrapNodes(editor, { match: n => - LIST_TYPES.includes( - !Editor.isEditor(n) && SlateElement.isElement(n) && n.type - ), + !Editor.isEditor(n) && + SlateElement.isElement(n) && + LIST_TYPES.includes(n.type), split: true, }) const newProperties: Partial = {