feat: support more options for remote profile

This commit is contained in:
GyDi
2022-03-10 02:03:55 +08:00
parent afe767e28a
commit ca0e936f7c
7 changed files with 135 additions and 28 deletions

View File

@@ -22,11 +22,17 @@ export async function viewProfile(index: string) {
}
export async function importProfile(url: string) {
return invoke<void>("import_profile", { url, withProxy: true });
return invoke<void>("import_profile", {
url,
option: { with_proxy: true },
});
}
export async function updateProfile(index: string, withProxy: boolean) {
return invoke<void>("update_profile", { index, withProxy });
export async function updateProfile(
index: string,
option?: CmdType.ProfileOption
) {
return invoke<void>("update_profile", { index, option });
}
export async function deleteProfile(index: string) {