chore: adjust type

This commit is contained in:
GyDi
2022-11-19 17:22:29 +08:00
parent a4c985a219
commit 5fb1afc681
26 changed files with 274 additions and 283 deletions

View File

@@ -13,7 +13,7 @@ import ProxyItem from "./proxy-item";
interface Props {
groupName: string;
curProxy?: string;
proxies: ApiType.ProxyItem[];
proxies: IProxyItem[];
}
// this component will be used for DIRECT/GLOBAL

View File

@@ -30,7 +30,7 @@ import ProxyHead from "./proxy-head";
import ProxyItem from "./proxy-item";
interface Props {
group: ApiType.ProxyGroupItem;
group: IProxyGroupItem;
}
const ProxyGroup = ({ group }: Props) => {

View File

@@ -17,7 +17,7 @@ import BaseLoading from "../base/base-loading";
interface Props {
groupName: string;
proxy: ApiType.ProxyItem;
proxy: IProxyItem;
selected: boolean;
showType?: boolean;
sx?: SxProps<Theme>;

View File

@@ -5,7 +5,7 @@ import delayManager from "@/services/delay";
export type ProxySortType = 0 | 1 | 2;
export default function useFilterSort(
proxies: ApiType.ProxyItem[],
proxies: IProxyItem[],
groupName: string,
filterText: string,
sortType: ProxySortType
@@ -47,7 +47,7 @@ const regex2 = /type=(.*)/i;
* according to the regular conditions
*/
function filterProxies(
proxies: ApiType.ProxyItem[],
proxies: IProxyItem[],
groupName: string,
filterText: string
) {
@@ -87,7 +87,7 @@ function filterProxies(
* sort the proxy
*/
function sortProxies(
proxies: ApiType.ProxyItem[],
proxies: IProxyItem[],
groupName: string,
sortType: ProxySortType
) {