1
Fork 0
mirror of https://github.com/Steffo99/festa.git synced 2024-12-23 07:04:22 +00:00
festa/components/LogoutLink.tsx

18 lines
504 B
TypeScript
Raw Normal View History

2022-05-27 00:46:30 +00:00
import { useTranslation } from "next-i18next"
2022-06-08 15:38:30 +00:00
import { LoginContext } from "./contexts/login"
2022-05-27 00:46:30 +00:00
import { useDefinedContext } from "../utils/definedContext"
export function LogoutLink() {
const [login, setLogin] = useDefinedContext(LoginContext)
const {t} = useTranslation("common")
return (
<small>
2022-05-28 03:45:05 +00:00
(
2022-05-27 00:46:30 +00:00
<a href="javascript:void(0)" onClick={() => setLogin(null)}>
{t("introTelegramLogout")}
</a>
2022-05-28 03:45:05 +00:00
)
2022-05-27 00:46:30 +00:00
</small>
)
}