chore: extract more strings (#933)

This commit is contained in:
Mihai C authored and GitHub committed 2021-10-13 10:34:55 +01:00
1 parent 4ce4b141b4
commit bee41b242b
8 files changed
+146 -99

No files matched your search

+9 -5
View File
@@ -1,28 +1,32 @@
import { CodeIcon, CreditCardIcon, KeyIcon, UserGroupIcon, UserIcon } from "@heroicons/react/solid";
import React from "react";
import { useLocale } from "@lib/hooks/useLocale";
import NavTabs from "./NavTabs";
export default function SettingsShell({ children }: { children: React.ReactNode }) {
const { t } = useLocale();
const tabs = [
{
name: "Profile",
name: t("profile"),
href: "/settings/profile",
icon: UserIcon,
},
{
name: "Security",
name: t("security"),
href: "/settings/security",
icon: KeyIcon,
},
{ name: "Embed & Webhooks", href: "/settings/embed", icon: CodeIcon },
{ name: t("embed_and_webhooks"), href: "/settings/embed", icon: CodeIcon },
{
name: "Teams",
name: t("teams"),
href: "/settings/teams",
icon: UserGroupIcon,
},
{
name: "Billing",
name: t("billing"),
href: "/settings/billing",
icon: CreditCardIcon,
},
+2 -2
View File
@@ -19,7 +19,7 @@ const TwoFactorAuthSection = ({ twoFactorEnabled }: { twoFactorEnabled: boolean
<div className="flex flex-row items-center">
<h2 className="font-cal text-lg leading-6 font-medium text-gray-900">{t("2fa")}</h2>
<Badge className="text-xs ml-2" variant={enabled ? "success" : "gray"}>
{enabled ? "Enabled" : "Disabled"}
{enabled ? t("enabled") : t("disabled")}
</Badge>
</div>
<p className="mt-1 text-sm text-gray-500">{t("add_an_extra_layer_of_security")}</p>
@@ -28,7 +28,7 @@ const TwoFactorAuthSection = ({ twoFactorEnabled }: { twoFactorEnabled: boolean
className="mt-6"
type="submit"
onClick={() => (enabled ? setDisableModalOpen(true) : setEnableModalOpen(true))}>
{enabled ? "Disable" : "Enable"} {t("2fa")}
{enabled ? t("disable") : t("enable")} {t("2fa")}
</Button>
{enableModalOpen && (