diff options
| author | Ellie Huxtable <ellie@elliehuxtable.com> | 2024-05-30 12:49:22 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-30 12:49:22 +0100 |
| commit | 467f89c104df40904ef4c6b408507e90fe661724 (patch) | |
| tree | e93697bdfa14ca6b083b0ea02c85d1d0688e0eba /ui/src/state/client.ts | |
| parent | chore(deps): bump rusty_paseto and rusty_paserk (#2054) (diff) | |
| download | atuin-467f89c104df40904ef4c6b408507e90fe661724.zip | |
feat(ui): add login/register dialog (#2056)
Diffstat (limited to 'ui/src/state/client.ts')
| -rw-r--r-- | ui/src/state/client.ts | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/ui/src/state/client.ts b/ui/src/state/client.ts index f43683c1..5ec0d8a7 100644 --- a/ui/src/state/client.ts +++ b/ui/src/state/client.ts @@ -11,3 +11,19 @@ export async function sessionToken(): Promise<String> { export async function settings(): Promise<Settings> { return await invoke("config"); } + +export async function login( + username: string, + password: string, + key: string, +): Promise<string> { + return await invoke("login", { username, password, key }); +} + +export async function register( + username: string, + email: string, + password: string, +): Promise<string> { + return await invoke("register", { username, email, password }); +} |
