Fix formatting

Signed-off-by: Anton Alexeyev <alexeyev.anton@gmail.com>
This commit is contained in:
Anton Alexeyev 2025-05-14 16:46:00 +07:00
parent a12a960e09
commit 76617b8746
2 changed files with 8 additions and 2 deletions

View File

@ -76,7 +76,7 @@
border-radius: 0.25rem;
}
&.preview {
margin: 0.0rem;
margin: 0rem;
padding: 0.25rem;
width: 1.5rem;
height: 1.5rem;

View File

@ -86,7 +86,13 @@ function detectPasteEmojis (text: string, regExp: RegExp): PasteRuleMatch[] | nu
}
if (matchEnd < text.length) {
if (index === matches.length - 1 && text[matchEnd] !== ' ') continue
if (index < matches.length - 1 && text.indexOf(matches[index + 1], matchEnd) > matchEnd && text[matchEnd] !== ' ') { continue }
if (
index < matches.length - 1 &&
text.indexOf(matches[index + 1], matchEnd) > matchEnd &&
text[matchEnd] !== ' '
) {
continue
}
}
result.push({ index: matchStart, text: match })
}