Skip to content

Commit

Permalink
Fixed: for #5162, The beginning of a TextNode with canInsertTextBefor…
Browse files Browse the repository at this point in the history
…e false in … (#5363)
  • Loading branch information
matsuyama-k1 authored Dec 12, 2023
1 parent c9b956e commit ee82c4f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/lexical/src/LexicalUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -650,7 +650,8 @@ export function $updateTextNodeFromDOMContent(
prevSelection.anchor.offset === 0) ||
(prevSelection.anchor.key === textNode.__key &&
prevSelection.anchor.offset === 0 &&
!node.canInsertTextBefore()) ||
!node.canInsertTextBefore() &&
!isComposing) ||
(prevSelection.focus.key === textNode.__key &&
prevSelection.focus.offset === prevTextContentSize &&
!node.canInsertTextAfter())))
Expand Down

2 comments on commit ee82c4f

@vercel
Copy link

@vercel vercel bot commented on ee82c4f Dec 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

lexical – ./packages/lexical-website

lexical-fbopensource.vercel.app
lexical-git-main-fbopensource.vercel.app
lexicaljs.com
lexicaljs.org
lexical.dev
www.lexical.dev

@vercel
Copy link

@vercel vercel bot commented on ee82c4f Dec 12, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

lexical-playground – ./packages/lexical-playground

lexical-playground-fbopensource.vercel.app
lexical-playground-git-main-fbopensource.vercel.app
lexical-playground.vercel.app
playground.lexical.dev

Please sign in to comment.