Skip to content

Commit

Permalink
[bulk-textarea] UIK-3158 fixed pasting value
Browse files Browse the repository at this point in the history
  • Loading branch information
ilyabrower committed Jan 13, 2025
1 parent 09d2f3e commit 97c66f9
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,7 @@ class InputField extends Component<InputFieldProps, {}, State, typeof InputField
let textNode: ChildNode | null = null;
let position: number | null = null;

if (focusNode === this.textarea && focusElement instanceof HTMLParagraphElement) {
paragraph = true;
} else if (
if (
focusElement instanceof Text &&
focusNode instanceof HTMLParagraphElement &&
anchorElement instanceof Text &&
Expand All @@ -305,7 +303,7 @@ class InputField extends Component<InputFieldProps, {}, State, typeof InputField
paragraph = true;
}

if (focusNode === this.textarea) {
if (focusElement === this.textarea) {
this.textarea.append(...listOfNodes);

const lastNodeToInsert = listOfNodes[listOfNodes.length - 1];
Expand Down

0 comments on commit 97c66f9

Please sign in to comment.