Fixed searching in all chains (case insensitive + pretty name)
This commit is contained in:
parent
4555bb9424
commit
fe79a2ab11
@ -14,8 +14,10 @@ const dashboard = useDashboard();
|
||||
const keywords = ref('');
|
||||
const chains = computed(() => {
|
||||
if (keywords.value) {
|
||||
const lowercaseKeywords = keywords.value.toLowerCase();
|
||||
|
||||
return Object.values(dashboard.chains).filter(
|
||||
(x: ChainConfig) => x.chainName.indexOf(keywords.value) > -1
|
||||
(x: ChainConfig) => x.prettyName.toLowerCase().indexOf(lowercaseKeywords) > -1
|
||||
);
|
||||
} else {
|
||||
return Object.values(dashboard.chains);
|
||||
|
Loading…
Reference in New Issue
Block a user