From ade31f993b61722c16e97c79bd542a6d111049fc Mon Sep 17 00:00:00 2001 From: V Date: Fri, 12 May 2023 03:41:00 +0200 Subject: Implement plugin tags --- src/components/PluginSettings/index.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/components/PluginSettings') diff --git a/src/components/PluginSettings/index.tsx b/src/components/PluginSettings/index.tsx index 8ccc740..e1b36ef 100644 --- a/src/components/PluginSettings/index.tsx +++ b/src/components/PluginSettings/index.tsx @@ -228,9 +228,12 @@ export default function PluginSettings() { if (enabled && searchValue.status === SearchStatus.DISABLED) return false; if (!enabled && searchValue.status === SearchStatus.ENABLED) return false; if (!searchValue.value.length) return true; + + const v = searchValue.value.toLowerCase(); return ( - plugin.name.toLowerCase().includes(searchValue.value.toLowerCase()) || - plugin.description.toLowerCase().includes(searchValue.value.toLowerCase()) + plugin.name.toLowerCase().includes(v) || + plugin.description.toLowerCase().includes(v) || + plugin.tags?.some(t => t.toLowerCase().includes(v)) ); }; -- cgit