diff --git a/src/components/setting/mods/tun-viewer.tsx b/src/components/setting/mods/tun-viewer.tsx index 603fd6d..02d22f6 100644 --- a/src/components/setting/mods/tun-viewer.tsx +++ b/src/components/setting/mods/tun-viewer.tsx @@ -113,7 +113,7 @@ export const TunViewer = forwardRef((props, ref) => { spellCheck="false" sx={{ width: 250 }} value={values.device} - placeholder="Mihomo" + placeholder="Meta" onChange={(e) => setValues((v) => ({ ...v, device: e.target.value })) } diff --git a/src/hooks/use-clash.ts b/src/hooks/use-clash.ts index 6f3f5fa..6f5895d 100644 --- a/src/hooks/use-clash.ts +++ b/src/hooks/use-clash.ts @@ -1,17 +1,16 @@ import useSWR, { mutate } from "swr"; import { useLockFn } from "ahooks"; +import { getAxios, getVersion, updateConfigs } from "@/services/api"; import { - getAxios, - getClashConfig, - getVersion, - updateConfigs, -} from "@/services/api"; -import { getClashInfo, patchClashConfig } from "@/services/cmds"; + getClashInfo, + patchClashConfig, + getRuntimeConfig, +} from "@/services/cmds"; export const useClash = () => { const { data: clash, mutate: mutateClash } = useSWR( - "getClashConfig", - getClashConfig + "getRuntimeConfig", + getRuntimeConfig ); const { data: versionData, mutate: mutateVersion } = useSWR( diff --git a/src/services/cmds.ts b/src/services/cmds.ts index 3c5e80e..1b813f8 100644 --- a/src/services/cmds.ts +++ b/src/services/cmds.ts @@ -90,8 +90,9 @@ export async function getClashInfo() { return invoke("get_clash_info"); } +// Get runtime config which controlled by verge export async function getRuntimeConfig() { - return invoke("get_runtime_config"); + return invoke("get_runtime_config"); } export async function getRuntimeYaml() {