Skip to content

Commit 39a4f7e

Browse files
authored
Merge branch 'main' into fix/tooltip-hidden-under-toolbar
2 parents de7a072 + 26a4b6b commit 39a4f7e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/utils/nodes.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,9 @@ export function findFirstTextblockChild(
2323
export const isNodeEmpty = (node: Node) => {
2424
const emptyChildren = findChildren(
2525
node,
26-
(n) => (!n.isText && !n.isAtom && n.content.size === 0) || (n.isText && !n.textContent),
26+
(n) =>
27+
(!n.isText && !n.isAtom && n.content.size === 0 && n.type.name === 'paragraph') ||
28+
(n.isText && !n.textContent),
2729
true,
2830
);
2931

0 commit comments

Comments
 (0)