search for effects

i'll keep this and if the owner wants it i'll submit a PR.
but i really did this to see if i could.
This commit is contained in:
Justin Garza
2024-10-27 11:31:07 -04:00
parent 6f9b56a69a
commit 2e54d0002b
24 changed files with 240 additions and 23 deletions
+16
View File
@@ -173,3 +173,19 @@ export function parseColor(string) {
return [color.red / 255, color.green / 255, color.blue / 255, color.alpha / 255];
}
//used for searching
// Simple fuzzy match function
//NOTE: i'll improve the fuzzy function before rolling this out
/*
function fuzzyMatch(text, query) {
let queryIndex = 0;
for (let i = 0; i < text.length && queryIndex < query.length; i++) {
if (text[i] === query[queryIndex]) {
queryIndex++;
}
}
return queryIndex === query.length; // Returns true if all chars in query matched in order
}
*/