feat: support configuring default server URL for desktop (#7363)
This commit is contained in:
parent
a8f23fb548
commit
02b7eb59f8
8 changed files with 232 additions and 26 deletions
|
|
@ -257,6 +257,15 @@ const platform: Platform = {
|
|||
|
||||
// @ts-expect-error
|
||||
fetch: tauriFetch,
|
||||
|
||||
getDefaultServerUrl: async () => {
|
||||
const result = await invoke<string | null>("get_default_server_url").catch(() => null)
|
||||
return result
|
||||
},
|
||||
|
||||
setDefaultServerUrl: async (url: string | null) => {
|
||||
await invoke("set_default_server_url", { url })
|
||||
},
|
||||
}
|
||||
|
||||
createMenu()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue