@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 04:45 UTC

main
ts 9 lines 372 Bytes
Raw
1 import { normalizeSearchText } from "~/lib/utils";
2
3 export function threadLinkMatcher(query: string, locale?: string) {
4 const localQuery = query.trim().toLocaleLowerCase(locale);
5 const foldedQuery = normalizeSearchText(query);
6 return (text: string) =>
7 text.toLocaleLowerCase(locale).includes(localQuery) ||
8 normalizeSearchText(text).includes(foldedQuery);
9 }