From bd6547873fcc64a500eadda78a1607be59e11a97 Mon Sep 17 00:00:00 2001 From: YetAnotherZephyruso <176294927+YetAnotherZephyruso@users.noreply.github.com> Date: Thu, 22 Aug 2024 16:43:23 +0800 Subject: [PATCH] feat: hidden api & remove domain unmaintained (#939) --- README.md | 2 -- src/pages/Proxies.tsx | 7 +++++-- src/types/index.d.ts | 1 + 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index f839813..e813d4c 100644 --- a/README.md +++ b/README.md @@ -17,8 +17,6 @@ Mihomo Dashboard, The Official One, XD ## Published Official Links -GH Pages Custom Domain: http://d.metacubex.one - GH Pages: https://metacubex.github.io/metacubexd Cloudflare Pages: https://metacubexd.pages.dev diff --git a/src/pages/Proxies.tsx b/src/pages/Proxies.tsx index 133a890..95191b6 100644 --- a/src/pages/Proxies.tsx +++ b/src/pages/Proxies.tsx @@ -62,6 +62,9 @@ export default () => { updatingMap, } = useProxies() + const renderProxies = createMemo(() => + proxies().filter((proxy) => !proxy.hidden), + ) const { speedGroupByName } = useConnections() const [collapsedMap, setCollapsedMap] = makePersisted( @@ -110,7 +113,7 @@ export default () => { { type: ActiveTab.proxies, name: t('proxies'), - count: proxies().length, + count: renderProxies().length, }, { type: ActiveTab.proxyProviders, @@ -171,7 +174,7 @@ export default () => { renderProxiesInTwoColumns() ? 'sm:grid-cols-2' : 'sm:grid-cols-1', )} > - + {(proxyGroup) => { const sortedProxyNames = createMemo(() => filterProxiesByAvailability( diff --git a/src/types/index.d.ts b/src/types/index.d.ts index 849b162..32421f0 100644 --- a/src/types/index.d.ts +++ b/src/types/index.d.ts @@ -17,6 +17,7 @@ export type Proxy = { time: string delay: number }[] + hidden: boolean udp: boolean xudp: boolean tfo: boolean