File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
frontend/src/ts/commandline Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ import * as FPSCounter from "../elements/fps-counter";
3131import { Command , CommandsSubgroup } from "./types" ;
3232import { buildCommandForConfigKey } from "./util" ;
3333import { CommandlineConfigMetadataObject } from "./commandline-metadata" ;
34+ import { isAuthAvailable , isAuthenticated , signOut } from "../firebase" ;
3435
3536const challengesPromise = JSONData . getChallengeList ( ) ;
3637challengesPromise
@@ -366,6 +367,17 @@ export const commands: CommandsSubgroup = {
366367 window . open ( "https://discord.gg/monkeytype" ) ;
367368 } ,
368369 } ,
370+ {
371+ id : "signOut" ,
372+ display : "Sign out" ,
373+ icon : "fa-sign-out-alt" ,
374+ exec : ( ) : void => {
375+ void signOut ( ) ;
376+ } ,
377+ available : ( ) => {
378+ return isAuthAvailable ( ) && isAuthenticated ( ) ;
379+ } ,
380+ } ,
369381 ] ,
370382} ;
371383
You can’t perform that action at this time.
0 commit comments