Attachment Modal: Fix text paste (#3756)

This commit is contained in:
Alexander Zinchuk 2023-09-04 04:04:57 +02:00
parent 807fe46657
commit 43c9354944
2 changed files with 3 additions and 3 deletions

View File

@ -713,7 +713,7 @@
.placeholder-text {
top: auto;
bottom: 0.875rem;
bottom: 1.0625rem;
left: 0.875rem;
}
}

View File

@ -436,12 +436,12 @@ const Composer: FC<OwnProps & StateProps> = ({
if (inInputId === editableInputId) {
messageInput = document.querySelector<HTMLDivElement>(editableInputCssSelector)!;
} else {
messageInput = document.getElementById(editableInputId) as HTMLDivElement;
messageInput = document.getElementById(inInputId) as HTMLDivElement;
}
if (selection.rangeCount) {
const selectionRange = selection.getRangeAt(0);
if (isSelectionInsideInput(selectionRange, editableInputId)) {
if (isSelectionInsideInput(selectionRange, inInputId)) {
insertHtmlInSelection(newHtml);
messageInput.dispatchEvent(new Event('input', { bubbles: true }));
return;