Emoji substring search (#39353)

This commit is contained in:
Echo authored and GitHub committed 2026-06-10 10:40:48 +00:00
1 parent b2996dcbbc
commit 9f7e2d0002
14 files changed
+169 -54

No files matched your search

@@ -214,6 +214,11 @@ export function extractTokens(
}
const tokens: string[] = [];
// Handle the edge case of thumbs up and down emoticons.
if (input === '+1' || input === '-1') {
return [input];
}
// Prefer to use Intl.Segmenter if available for better locale support.
if (segmenter) {
for (const { isWordLike, segment } of segmenter.segment(