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

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 }