diff --git a/frontend/src/ts/commandline/lists.ts b/frontend/src/ts/commandline/lists.ts index b7405613e..09894ad90 100644 --- a/frontend/src/ts/commandline/lists.ts +++ b/frontend/src/ts/commandline/lists.ts @@ -31,6 +31,7 @@ import * as FPSCounter from "../elements/fps-counter"; import { Command, CommandsSubgroup } from "./types"; import { buildCommandForConfigKey } from "./util"; import { CommandlineConfigMetadataObject } from "./commandline-metadata"; +import { isAuthAvailable, isAuthenticated, signOut } from "../firebase"; const challengesPromise = JSONData.getChallengeList(); challengesPromise @@ -366,6 +367,17 @@ export const commands: CommandsSubgroup = { window.open("https://discord.gg/monkeytype"); }, }, + { + id: "signOut", + display: "Sign out", + icon: "fa-sign-out-alt", + exec: (): void => { + void signOut(); + }, + available: () => { + return isAuthAvailable() && isAuthenticated(); + }, + }, ], };